Please note that VisualCron support is not actively monitoring this community forum. Please use our contact page for contacting the VisualCron support directly.


MikeF-LF
2021-06-29T04:41:05Z
We have a SFTP set up and we are on version 9.8.0 - previous 9.4.5 I think. When the job runs it logs into the SFTP server, and then we ask it to download the files. It takes a while to download the files and it does not error. When we check the files it either shows half the csv file or 0kb. No error is determined by Visual cron and it moves on to the next task.

I found this error in the log files

Err DownloadSFTPFiles->Download failed - resuming. Error: SBSocket.EElSocketError: Wrong socket state 0 in Receive
at SBSocket.TElSocket.Receive(Byte[]& Data, Int32 DataLen, Int32& Received)
at SBSocketClient.TElBaseSocketClient.DoReceive(Object Sender, Byte[]& Buffer, Int32 MaxSize, Int32& Written)
at SBSSHCommon.TElSSHClass.DoReceive(Byte[]& Buffer, Int32 MaxSize, Int32& Written)
at SBSSHClient.TElSSHClient.DataAvailable()
at SBSocketClient.TElBaseSocketClient.DataAvailable()
at SBSocketClient.TElBaseSocketClient.DoMessageLoop(Boolean NoPeek)
at SBSftpCommon.TSBSftpMessageLoopEvent.Invoke()
at SBSftp.TElSftpClient.OpenFile(String Filename, Int32 Modes, TElSftpFileAttributes Attributes)
at SBSftp.TElSftpClient.OpenFileSync(String Filename, Int32 Modes, TElSftpFileAttributes Attributes)
at SBSftp.TElSftpStream..ctor(TElSftpClient AOwner, String Filename, Int32 Modes)
at SBSftp.TElSftpClient.OpenStream(String Filename, Int32 Modes)
at VisualCronService.RemoteFileAPI.DownloadSFTPFile(ConnectionClientClass cc, Boolean bolKeepCreatedModifiedDate, FileStream wStream, RemoteFileInfoClass rfi, FileMode fm, TSBFileTransferMode tm, String strLocalFilePath, Int32& intTotalFiles, TaskProcessClass tpc, Boolean bolDebugging) in C:\git\code\VisualCronService\Connections\apiRemoteFile.vb:line 1800
at VisualCronService.RemoteFileAPI.DownloadSFTPFiles(TaskFoundationClass tf, ConnectionClientClass cc, ConnectionHandlerClass ch, String strConnectionId, List`1 files, String originalSaveFolder, FTPDownloadCommandClass downloadCommand, Int32& intTotalFiles, Boolean& active, VariableReplacerClass VR, TaskProcessClass tpc, Boolean

I found https://www.visualcron.c....aspx?g=posts&t=5038  on the forum but there is no resolution.

Could some one advise how to fix this?

The other thing is I have 2 other jobs that touch the same SFTP server and download different CSV files but do not have the issue for 1 of them. The other one is showing this issue as well where the file is cut in half or a small portion downloads or a 0kb file.

Please advise

Thanks
Mike


Sponsor
Forum information
Joey S
2021-07-13T16:04:21Z
There was a previous issue, I believe now resolved, in VC where VC would 'create' a file if it did not exist at the source

For example:

Task #1. Copy File A from Source X to Destination Y
If file A did not exist at the source, VC would act like it did and destination Y would receive a 'file" that was named correctly and was zero KB. Essentially VC was creating ghost files IF the source file did not exist.

v9.6.5 does not do this, I just tested it. But sometimes, even if you have the newest version, old tasks/jobs act the way the old version did when the job was created.

If this is your issue I think you have to remake the whole job or simply make a new job with one task and test it out. Run the new job first then run the old job and see what happens

If that does not solve it, I would clone the "good" job that does not exhibit this issue and replace the jobs not working.
MikeF-LF
2021-07-15T03:03:34Z
Thanks, Recreating it from scratch has worked.

Mike
Support
2021-07-15T07:15:26Z
Originally Posted by: MikeF-LF 

Thanks, Recreating it from scratch has worked.

Mike



Thanks for updating!
Michael
Support
http://www.visualcron.com 

Please like  VisualCron on facebook!
Scroll to Top