Connections Fail Under "heavy" Load
Hello, I requested help when I first began using WinSCP a few weeks ago here: https://winscp.net/forum/viewtopic.php?t=7224
That comment was very helpful, but I decided to use FileWatcherUtilities to watch a folder then trigger a simple WinSCP script when a change was recorded. This worked very well for the first week, but now we have a few more people scanning at their own workstations at the end of the day and the connection fails each time I try to connect, causing the users to either scan again to retrigger the script or manually execute it using a ftp_script.bat file I put on their desktops.
The command string I am using is 'START /MIN winSCP.exe /console /script=ftp_script.txt'
The ftp_script.txt I am using is:
"""
# Automatically answer all prompts negatively not to stall
# the script on errors (off), set to 'continue' to ignore all errors.
option batch on
# Attempt reconnect in 3 seconds if connection fails
#option reconnecttime 3
# Disable overwrite confirmations that conflict with the previous
option confirm off
# Open connection to server
open ftp://[User1]:[PASSWORD]@[DOMAIN].com:21
# We put all files in directory to server working directory, and
# delete the local file after sending.
put -delete "C:\ABSOLUTE\PATH\TO\FOLDER\*" "/SUB-FOLDER/"
# Synchronize directories so 'keepuptodate' won't cause problems.
#synchronize both "C:\ABSOLUTE\PATH\TO\FOLDER"
# With the sync we can use 'uptodate' to keep the folders synced
#keepuptodate -delete "C:\ABSOLUTE\PATH\TO\FOLDER"
exit
"""
I have three clues.
One, our aggregate connection speed is a little slow at ~138 kBps down ~142 kBps up.
Two, when it begins to fail, the connection will not be allowed to set for a period of minutes. During this time I tried to log in by the commander GUI interface and was also rejected. Then I tried using the Filezilla client, just-in-case, it connected but after switching back to WinSCP commander GUI it failed again.
Three, the scanner creates temp files (e.g. [date_string].pd~ or [numbers].dat. The problem is these temp files cause the script to be executed multiple times. This is a problem, but because I had the same problem with the commander gui I think this is likely unrelated.
That's everything I can remember. I will post a log when the problem appears this afternoon.
Oh, I don't think it is the firewall because we generally have no problem connecting, and the FTP server is FileZilla because that is what the remote admin usually uses.
Any suggestions?
That comment was very helpful, but I decided to use FileWatcherUtilities to watch a folder then trigger a simple WinSCP script when a change was recorded. This worked very well for the first week, but now we have a few more people scanning at their own workstations at the end of the day and the connection fails each time I try to connect, causing the users to either scan again to retrigger the script or manually execute it using a ftp_script.bat file I put on their desktops.
The command string I am using is 'START /MIN winSCP.exe /console /script=ftp_script.txt'
The ftp_script.txt I am using is:
"""
# Automatically answer all prompts negatively not to stall
# the script on errors (off), set to 'continue' to ignore all errors.
option batch on
# Attempt reconnect in 3 seconds if connection fails
#option reconnecttime 3
# Disable overwrite confirmations that conflict with the previous
option confirm off
# Open connection to server
open ftp://[User1]:[PASSWORD]@[DOMAIN].com:21
# We put all files in directory to server working directory, and
# delete the local file after sending.
put -delete "C:\ABSOLUTE\PATH\TO\FOLDER\*" "/SUB-FOLDER/"
# Synchronize directories so 'keepuptodate' won't cause problems.
#synchronize both "C:\ABSOLUTE\PATH\TO\FOLDER"
# With the sync we can use 'uptodate' to keep the folders synced
#keepuptodate -delete "C:\ABSOLUTE\PATH\TO\FOLDER"
exit
"""
I have three clues.
One, our aggregate connection speed is a little slow at ~138 kBps down ~142 kBps up.
Two, when it begins to fail, the connection will not be allowed to set for a period of minutes. During this time I tried to log in by the commander GUI interface and was also rejected. Then I tried using the Filezilla client, just-in-case, it connected but after switching back to WinSCP commander GUI it failed again.
Three, the scanner creates temp files (e.g. [date_string].pd~ or [numbers].dat. The problem is these temp files cause the script to be executed multiple times. This is a problem, but because I had the same problem with the commander gui I think this is likely unrelated.
That's everything I can remember. I will post a log when the problem appears this afternoon.
Oh, I don't think it is the firewall because we generally have no problem connecting, and the FTP server is FileZilla because that is what the remote admin usually uses.
Any suggestions?