FTP and SocketTime Out?
John Patten
johnpatten at mac.com
Tue Apr 18 17:07:37 EDT 2006
Update...
FWIW...
The long delay required in making the inital FTP connetion from the Windows XP appears to be related to the Windows OS only. I tried the same thing from a Mac and the stack connected within 2-4 seconds.
Thanks!
John Patten
SUSD
------------------------------
Message: 11
Date: Tue, 18 Apr 2006 10:52:22 -0700
From: John Patten <johnpatten at mac.com>
Subject: Re: FTP asnd SocketTime Out?
To: use-revolution at lists.runrev.com
Message-ID: <1244443.1145382742693.JavaMail.johnpatten at mac.com>
Content-Type: text/plain; charset=ISO-8859-1
Hi Andre...
I added the LibURLSetFTPMode "active" in front of the ftp calls, but no luck.
The process was working fine until Friday afternoon, that's when our network people began installing the new server. I also remember a Microsoft Update that happened Friday too.
I guess it could be one of those two things...couldn't have been something I did... LOL.
Thanks!
John Patten
SUSD
------------------------------------------------snip-------------------------------------------
Message: 17
Date: Tue, 18 Apr 2006 13:30:58 -0300
From: Andre Garzia <soapdog at mac.com>
Subject: Re: FTP and SocketTime Out?
To: How to use Revolution <use-revolution at lists.runrev.com>
Message-ID: <29691255-35A4-4E16-A94D-F9762112D1C7 at mac.com>
Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed
John,
Hi there! :-)
Maybe switching from passive connection to active connection will
help, some server behaves better using active connections.
Try inserting this before any FTP command in your script
LibURLSetFTPMode "active"
get back to us after that! :D
Cheers
andre
On Apr 18, 2006, at 1:22 PM, John Patten wrote:
> Thanks for tips Alex...
>
> I went ahead and ping'd the servers. By IP the pings are all good
> times (3ms). However, FTP clients are also very slow in their
> initial connecion too.
>
> I do have access to another Mac FTP server. I noticed when I
> connect by domain name, it errors out with a "500 Connection
> refused (Winsock error #10061)." However, IP address will work but
> only after the long connection.
>
> The script I'm using in my stack is lifted from, I believe, one of
> Andre's examples.
>
> Here it is:
>
> --------------------------------------------------
> on mouseUp
> put "ftp://ftpUser:ftppassword@10.58.1.7/Users/ftpuser/Sites/
> ftpusersite/" into tServer
>
> --Here's where I had to put the socket interval. I didn't even set
> the timeout interval before.
> set the socketTimeoutInterval to 100000
>
> libURLSetFTPListCommand "NLST"
>
> put URL tServer into tData
> replace crlf with cr in tData
> replace lf with cr in tData
>
>
>
>
> libURLSetFTPListCommand "LIST"
> put URL tServer into tLongData
>
> repeat with x = 1 to the number of lines of tData
> get line x of tData
> get lineoffset(it, tLongData)
> if char 1 of line it of tLongData is "d" or char 1 of line x of
> tLongData is "1" then
> put line x of tData & cr after theMenuItems
> else
> end if
> end repeat
>
> put theMenuItems into button "country"
> Set the label of cd btn "Country" to "Country"
> show button "Country"
> end mouseUp
More information about the use-livecode
mailing list