Snitz Forums 2000
Snitz Forums 2000
Home | Profile | Register | Active Topics | Members | Search | FAQ
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 Community Forums
 Community Discussions (All other subjects)
 windows 2003 server and downloads..
 New Topic  Topic Locked
 Printer Friendly
Previous Page | Next Page
Author Previous Topic Topic Next Topic
Page: of 4

weeweeslap
Senior Member

USA
1077 Posts

Posted - 18 January 2007 :  02:21:06  Show Profile  Visit weeweeslap's Homepage  Send weeweeslap an AOL message  Send weeweeslap a Yahoo! Message
I uploaded that same package( through upload component ), looked at it on the server after upload and it's the same file size (1.45 mb) and even installed the program that runs it and it ran just fine, but when I downloaded, it downloaded as 28.8kb.

coaster crazy

Edited by - weeweeslap on 18 January 2007 04:03:01
Go to Top of Page

pdrg
Support Moderator

United Kingdom
2897 Posts

Posted - 18 January 2007 :  11:34:07  Show Profile  Send pdrg a Yahoo! Message
quote:
Originally posted by weeweeslap

I uploaded that same package( through upload component ), looked at it on the server after upload and it's the same file size (1.45 mb) and even installed the program that runs it and it ran just fine, but when I downloaded, it downloaded as 28.8kb.



Yes, it downloads at 28.8kb - have a look at the file contents, they're

(snip)

<head>
<title>WeeWeeSlap.com</title>
<meta name="copyright" content="This Forum code is Copyright (C) 2000-02 Michael Anderson, Pierre Gorissen, Huw Reddick and Richard Kinser, Non-Forum Related code is Copyright (C)  2002-2006 WeeWeeSlap.com">

(snip)


Basically the download component is serving up a snitz file for some reason. Have you checked (in the case of http://www.weeweeslap.com/track_exchange/download.asp?tid=11316 which I clicked) that tid=11316 doesn't point to the asp file/page instead of the actual object itself?
Go to Top of Page

pdrg
Support Moderator

United Kingdom
2897 Posts

Posted - 18 January 2007 :  11:50:13  Show Profile  Send pdrg a Yahoo! Message
Interestingly, if I change the link tid=xxxxx from xxxxx=11316 to xxxxx=11315, 11314, I still get the same file back. There's something really screwy going on with your download.asp file! Is it code-identical to dayve's post at the top of this thread?
Go to Top of Page

weeweeslap
Senior Member

USA
1077 Posts

Posted - 18 January 2007 :  13:35:28  Show Profile  Visit weeweeslap's Homepage  Send weeweeslap an AOL message  Send weeweeslap a Yahoo! Message
yes sir, in fact here's the entire content's of download.asp
http://www.weeweeslap.com/track_exchange/download.txt
Funny how there's no problem linking directly to download.txt... The lines of code where the download initiates is lines 100-109, line 110 is what was there and worked on windows 2000 and didn't work in 2003. Changing the number at the end of URL only tells download.asp to grab a trackfile with that identification. There's over 11,000 files to grab off the server.
Thanks!

coaster crazy

Edited by - weeweeslap on 18 January 2007 13:36:32
Go to Top of Page

pdrg
Support Moderator

United Kingdom
2897 Posts

Posted - 18 January 2007 :  15:05:15  Show Profile  Send pdrg a Yahoo! Message
Just ideas/questions as I've no dev tools any more, so trying to apply crazy head logic instead here...

Lines near the top somewhere...

strSql = "SELECT T_DOWNLOADED"
strSql = strSql & ", T_FILE"
strSql = strSql & " FROM " & strTablePrefix & "TRACKS"
strSql = strSql & " WHERE T_ID=" & strQueryTrackID
set rs = my_Conn.Execute (strSql)

Have you confirmed strSQL returns the correct values (throw in a response.write then comment it out once debugged)?

If so, next try taking the EXACT values from the above (with all the slashes, etc), and temporarily hard-code the strDBFileName
in the section around line 100 where it seems to fubar - let's see if it still does, or if it can deliver the correct file.

If not, another response.write will give us the exact FPath you have, is it correct?

It may be that there's a problem with paths, maybe an extra or missing slash or two, maybe a missing mappath, or something. That could then be erroring the adoStream.LoadFromFile(FPath), and maybe the 404/500 actually resolves to the file that ends up downloading. Which file on your server is it that gets downloaded at the moment? the 28.8k one? Do any response.redirects point there? Does your 404/500?

Just a few thoughts and tests - it's the direction I'd go if it were my app, so it may help...

fingers crossed for you!
Go to Top of Page

weeweeslap
Senior Member

USA
1077 Posts

Posted - 18 January 2007 :  15:26:16  Show Profile  Visit weeweeslap's Homepage  Send weeweeslap an AOL message  Send weeweeslap a Yahoo! Message
it has been fixed! Annoyed a buddy on MSN for about an hour
chatlog:
quote:

ñ#1769;#1758;#1769;ñ SEO Specialist ñ#1769;#1758;#1769;ñ says:
it should work now...
ñ#1769;#1758;#1769;ñ SEO Specialist ñ#1769;#1758;#1769;ñ says:
I foun a few issues
weeweeslap says:
oh? which ones?
ñ#1769;#1758;#1769;ñ SEO Specialist ñ#1769;#1758;#1769;ñ says:
firstly, you were not using a filepath.... just a filename...
ñ#1769;#1758;#1769;ñ SEO Specialist ñ#1769;#1758;#1769;ñ says:
you needed server.mappath
ñ#1769;#1758;#1769;ñ SEO Specialist ñ#1769;#1758;#1769;ñ says:
secondly, your content types needs to change depending on zip, or something else...
ñ#1769;#1758;#1769;ñ SEO Specialist ñ#1769;#1758;#1769;ñ says:
lastly, you had a space after the %>
ñ#1769;#1758;#1769;ñ SEO Specialist ñ#1769;#1758;#1769;ñ says:
that one little space after your ASP block was the *** to put my finger on


now it looks like this:
Response.clear
Response.ContentType = ContentType ' arbitrary
FPath = server.mappath("./upload/" & strDBFileName)
Response.AddHeader "Content-Disposition","attachment; filename=" & strDBFileName
Set adoStream = CreateObject("ADODB.Stream")
adoStream.Open()
adoStream.Type = 1
adoStream.LoadFromFile(FPath)
Response.BinaryWrite adoStream.Read()
Response.Flush
adoStream.Close
Set adoStream = Nothing
response.end

Thanks guys for your help in helping get into the right direction. I appreciate your help a lot! That's why SNitz is the best, the support is umatched

coaster crazy
Go to Top of Page

pdrg
Support Moderator

United Kingdom
2897 Posts

Posted - 18 January 2007 :  17:02:34  Show Profile  Send pdrg a Yahoo! Message
Yay! And I see it was a paths problem...I diagnosed that just with notepad and a coffee, and I haven't written a single line of code in 3 years...I've still got it ;-)
Go to Top of Page

weeweeslap
Senior Member

USA
1077 Posts

Posted - 18 January 2007 :  18:22:51  Show Profile  Visit weeweeslap's Homepage  Send weeweeslap an AOL message  Send weeweeslap a Yahoo! Message
though shouldn't it have thrown a 404? windows 2003 is weird

coaster crazy
Go to Top of Page

pdrg
Support Moderator

United Kingdom
2897 Posts

Posted - 19 January 2007 :  09:49:58  Show Profile  Send pdrg a Yahoo! Message
Maybe it's a 500? I don't know your setup, but it looks like you're up and running, which is the main thing :)
Go to Top of Page

weeweeslap
Senior Member

USA
1077 Posts

Posted - 19 January 2007 :  12:50:03  Show Profile  Visit weeweeslap's Homepage  Send weeweeslap an AOL message  Send weeweeslap a Yahoo! Message
Yes it is! We're up to 100% operating status so that's good. Hopefully I don't have to go through this anytime soon again, thanks

coaster crazy
Go to Top of Page

weeweeslap
Senior Member

USA
1077 Posts

Posted - 27 January 2007 :  14:52:15  Show Profile  Visit weeweeslap's Homepage  Send weeweeslap an AOL message  Send weeweeslap a Yahoo! Message
ok, I hate to be a pain again but we've encountered another problem. It seems with large file downloads, example is a 4.46 megs file, when downloaded it downloads as 0 kb, it uploads fine, ran it on the server and file executed fine but if we try to download it using the code above, it fails to download. Maybe you guys can help me out once more on this? Thanks!

coaster crazy
Go to Top of Page

pdrg
Support Moderator

United Kingdom
2897 Posts

Posted - 27 January 2007 :  15:42:47  Show Profile  Send pdrg a Yahoo! Message
debug steps
1) work out the filesize at which it fails (ie try with several files sized 2M, 2.5M, 3M, 3.5M etc) - just in case that sheds any light
2) any particular file extensions involved? Try some others.
3) are we certain all the paths and so forth from above are resolving correctly now?
4) are you certain the 0kb file isn't just a placeholder and waiting for the full file to download?
5) are the 0k files tryly empty? (use notepad or something to check)

These could help give some insight into what's going on, or throw up a useful lead later :)

hth, and good luck!
Go to Top of Page

weeweeslap
Senior Member

USA
1077 Posts

Posted - 27 January 2007 :  17:01:01  Show Profile  Visit weeweeslap's Homepage  Send weeweeslap an AOL message  Send weeweeslap a Yahoo! Message
1) Files up to 3991 kb dl'ed fine and opened fine, any and all files over 4206 kb fail to download correctly resulting at 0kb file size and can't be opened with their associated programs.
2) Any extensions, td6, zip, nlpack, nltrack, smpark, csa etc.
3) Yes all paths are resolving correctly.
4) Yes, I am certain.
5) Opened a couple of the 0kb ones in notepad, all revealed to be 100% empty, no text, nothing in the files.

coaster crazy

Edited by - weeweeslap on 27 January 2007 17:01:58
Go to Top of Page

pdrg
Support Moderator

United Kingdom
2897 Posts

Posted - 27 January 2007 :  17:18:29  Show Profile  Send pdrg a Yahoo! Message
Got it...well maybe...

http://www.developersdex.com/asp/message.asp?p=592&ID=%3C3E76261D-AC65-4401-9E3E-CD838352F498%40microsoft.com%3E

W2K3 has an IIS ASPBufferingLimit preset to 4Megs, it seems. Files over this size will be truncated automagically and you'll never be told.

See if this helps - it may well do! Let us know, could be a good lesson for us all here...

P :)
Go to Top of Page

pdrg
Support Moderator

United Kingdom
2897 Posts

Posted - 27 January 2007 :  17:20:57  Show Profile  Send pdrg a Yahoo! Message
PS - ftp may have similar problems with W2K3SSP1

http://www.developersdex.com/asp/message.asp?p=2675&ID=%3C%23w0bZJ9QGHA.1728%40TK2MSFTNGP11.phx.gbl%3E
Go to Top of Page
Page: of 4 Previous Topic Topic Next Topic  
Previous Page | Next Page
 New Topic  Topic Locked
 Printer Friendly
Jump To:
Snitz Forums 2000 © 2000-2021 Snitz™ Communications Go To Top Of Page
This page was generated in 0.83 seconds. Powered By: Snitz Forums 2000 Version 3.4.07