Error getting name of current remote directory
Hello,
I am using WinSCP version 6.1.2 on a Windows Server 2019 Datacenter server. On October 18, our WinSCP script started failing when connecting to a vendor's SFTP server to upload files. The same issue occurs when I use the WinSCP GUI and attempt things manually. The same issue occurs using multiple versions of the WinSCP GUI on a Windows 10 computer.
The remote SFTP server accepts my username and password, but then immediately gives an error saying:
According to my WinSCP logs, the remote server is a Cerberus FTP Server 11.2.6.0. I tried using SCP instead of the SFTP protocol but apparently the remote server does not support SCP.
The vendor reports that the FileZilla SFTP application is able to successfully connect and transfer files via SFTP.
I am using WinSCP version 6.1.2 on a Windows Server 2019 Datacenter server. On October 18, our WinSCP script started failing when connecting to a vendor's SFTP server to upload files. The same issue occurs when I use the WinSCP GUI and attempt things manually. The same issue occurs using multiple versions of the WinSCP GUI on a Windows 10 computer.
The remote SFTP server accepts my username and password, but then immediately gives an error saying:
After I close out that error prompt a few times, it ends with the error "Error getting name of current remote directory" and I have a blank right half of the commander-style screen (screen shots attached).Cannot get real path for '.'.
The file path does not exist or is invalid.
Error code: 10
Error message from server (en-US): Unable to resolve path
According to my WinSCP logs, the remote server is a Cerberus FTP Server 11.2.6.0. I tried using SCP instead of the SFTP protocol but apparently the remote server does not support SCP.
The vendor reports that the FileZilla SFTP application is able to successfully connect and transfer files via SFTP.
. 2023-11-10 07:37:53.535 -------------------------------------------------------------------------- . 2023-11-10 07:37:53.535 WinSCP Version 6.1.2 (Build 13797 2023-09-19) (OS 10.0.17763 – Windows Server 2019 Datacenter) . 2023-11-10 07:37:53.535 Configuration: HKCU\Software\Martin Prikryl\WinSCP 2\ . 2023-11-10 07:37:53.535 Log level: Normal . 2023-11-10 07:37:53.535 Local account: CCSD\tf_admin . 2023-11-10 07:37:53.535 Working directory: C:\xfer_scripts . 2023-11-10 07:37:53.535 Process ID: 1836 . 2023-11-10 07:37:53.551 Ancestor processes: WinSCP, cmd, explorer, ... . 2023-11-10 07:37:53.551 Command-line: "C:\xfer_scripts\WinSCP-6.1.2-Portable\WinSCP.exe" /console=6.1.2 /consoleinstance=_13232_848 "/console" "/script=C:\xfer_scripts\review360_script-2.txt" "/log=c:\xfer_scripts\log.txt" . 2023-11-10 07:37:53.551 Time zone: Current: GMT-5, Standard: GMT-5 (Eastern Standard Time), DST: GMT-4 (Eastern Daylight Time), DST Start: 3/12/2023, DST End: 11/5/2023 . 2023-11-10 07:37:53.551 Login time: Friday, November 10, 2023 7:37:53 AM . 2023-11-10 07:37:53.551 -------------------------------------------------------------------------- . 2023-11-10 07:37:53.551 Script: Retrospectively logging previous script records: > 2023-11-10 07:37:53.551 Script: option confirm off < 2023-11-10 07:37:53.551 Script: confirm off > 2023-11-10 07:37:53.551 Script: option batch on < 2023-11-10 07:37:53.551 Script: batch on > 2023-11-10 07:37:53.551 Script: open CharlestonCountySchoolDistrict:***@ftp.psiwaresolutions.com . 2023-11-10 07:37:53.551 -------------------------------------------------------------------------- . 2023-11-10 07:37:53.551 Session name: <username redacted>@ftp.psiwaresolutions.com (Ad-Hoc site) . 2023-11-10 07:37:53.551 Host name: ftp.psiwaresolutions.com (Port: 22) . 2023-11-10 07:37:53.551 User name: <username redacted> (Password: Yes, Key file: No, Passphrase: No) . 2023-11-10 07:37:53.551 Tunnel: No . 2023-11-10 07:37:53.551 Transfer Protocol: SFTP (SCP) . 2023-11-10 07:37:53.551 Ping type: Off, Ping interval: 30 sec; Timeout: 15 sec . 2023-11-10 07:37:53.551 Disable Nagle: No . 2023-11-10 07:37:53.551 Proxy: None . 2023-11-10 07:37:53.551 Send buffer: 262144 . 2023-11-10 07:37:53.551 Compression: No . 2023-11-10 07:37:53.551 Bypass authentication: No . 2023-11-10 07:37:53.551 Try agent: Yes; Agent forwarding: No; KI: Yes; GSSAPI: Yes . 2023-11-10 07:37:53.551 GSSAPI: KEX: No; Forwarding: No; Libs: gssapi32,sspi,custom; Custom: . 2023-11-10 07:37:53.551 Ciphers: aes,chacha20,aesgcm,3des,WARN,des,blowfish,arcfour; Ssh2DES: No . 2023-11-10 07:37:53.551 KEX: ntru-curve25519,ecdh,dh-gex-sha1,dh-group18-sha512,dh-group17-sha512,dh-group16-sha512,dh-group15-sha512,dh-group14-sha1,rsa,WARN,dh-group1-sha1 . 2023-11-10 07:37:53.551 SSH Bugs: Auto,Auto,Auto,Auto,Auto,Auto,Auto,Auto,Auto,Auto . 2023-11-10 07:37:53.551 Simple channel: Yes . 2023-11-10 07:37:53.551 Return code variable: Autodetect; Lookup user groups: Auto . 2023-11-10 07:37:53.551 Shell: default . 2023-11-10 07:37:53.551 EOL: LF, UTF: Auto . 2023-11-10 07:37:53.551 Clear aliases: Yes, Unset nat.vars: Yes, Resolve symlinks: Yes; Follow directory symlinks: No . 2023-11-10 07:37:53.551 LS: ls -la, Ign LS warn: Yes, Scp1 Comp: No; Exit code 1 is error: No . 2023-11-10 07:37:53.551 SFTP Bugs: Auto,Auto . 2023-11-10 07:37:53.551 SFTP Server: default . 2023-11-10 07:37:53.551 Local directory: default, Remote directory: home, Update: Yes, Cache: Yes . 2023-11-10 07:37:53.551 Cache directory changes: Yes, Permanent: Yes . 2023-11-10 07:37:53.551 Recycle bin: Delete to: No, Overwritten to: No, Bin path: . 2023-11-10 07:37:53.551 DST mode: Unix . 2023-11-10 07:37:53.551 -------------------------------------------------------------------------- < 2023-11-10 07:37:53.551 Script: Searching for host... . 2023-11-10 07:37:53.566 Looking up host "ftp.psiwaresolutions.com" for SSH connection . 2023-11-10 07:37:53.613 Connecting to 54.210.46.187 port 22 . 2023-11-10 07:37:53.645 Connected to 54.210.46.187 < 2023-11-10 07:37:53.645 Script: Connecting to host... . 2023-11-10 07:37:53.645 We claim version: SSH-2.0-WinSCP_release_6.1.2 . 2023-11-10 07:37:53.645 Connected to 54.210.46.187 . 2023-11-10 07:37:53.660 Remote version: SSH-2.0-CerberusFTPServer_11.0 . 2023-11-10 07:37:53.660 Using SSH protocol version 2 . 2023-11-10 07:37:53.676 Have a known host key of type rsa2 . 2023-11-10 07:37:53.691 Doing ECDH key exchange with curve nistp256, using hash SHA-256 . 2023-11-10 07:37:53.770 Host key fingerprint is: . 2023-11-10 07:37:53.770 ssh-rsa 2048 SHA256:eT405UXuSy+vpixAtS7OkjVrOhoeY3qUodo6Coeoxbg < 2023-11-10 07:37:53.770 Script: Authenticating... . 2023-11-10 07:37:53.770 Host key matches cached key . 2023-11-10 07:37:53.770 Initialised AES-256 SDCTR (AES-NI accelerated) [aes256-ctr] outbound encryption . 2023-11-10 07:37:53.770 Initialised HMAC-SHA-256 outbound MAC algorithm . 2023-11-10 07:37:53.785 Initialised AES-256 SDCTR (AES-NI accelerated) [aes256-ctr] inbound encryption . 2023-11-10 07:37:53.785 Initialised HMAC-SHA-256 inbound MAC algorithm ! 2023-11-10 07:37:53.801 Using username "<username redacted>". < 2023-11-10 07:37:53.801 Script: Using username "<username redacted>". . 2023-11-10 07:37:53.832 Server offered these authentication methods: password,publickey . 2023-11-10 07:37:53.832 Prompt (password, "SSH password", <no instructions>, "&Password: ") . 2023-11-10 07:37:53.832 Using stored password. < 2023-11-10 07:37:53.832 Script: Authenticating with pre-entered password. . 2023-11-10 07:37:53.832 Sent password . 2023-11-10 07:37:53.848 Access granted . 2023-11-10 07:37:53.848 Opening main session channel . 2023-11-10 07:37:53.863 Opened main channel . 2023-11-10 07:37:53.895 Started a shell/command < 2023-11-10 07:37:53.895 Script: Authenticated. . 2023-11-10 07:37:53.895 -------------------------------------------------------------------------- . 2023-11-10 07:37:53.895 Using SFTP protocol. . 2023-11-10 07:37:53.895 Doing startup conversation with host. < 2023-11-10 07:37:53.895 Script: Starting the session... > 2023-11-10 07:37:53.895 Type: SSH_FXP_INIT, Size: 5, Number: -1 < 2023-11-10 07:37:53.910 Type: SSH_FXP_VERSION, Size: 176, Number: -1 . 2023-11-10 07:37:53.910 SFTP version 6 negotiated. . 2023-11-10 07:37:53.910 Server requests EOL sequence "\r\n". . 2023-11-10 07:37:53.910 Server software: Cerberus FTP Server 11.2.6.0 (110206000) by Cerberus, LLC . 2023-11-10 07:37:53.910 Server support information (supported2): . 2023-11-10 07:37:53.910 Attribute mask: 2BD, Attribute bits: FF, Open flags: 7 . 2023-11-10 07:37:53.910 Access mask: 3, Open block vector: 0, Block vector: 0, Max read size: 0 . 2023-11-10 07:37:53.910 Attribute extensions (0) . 2023-11-10 07:37:53.910 Extensions (2) . 2023-11-10 07:37:53.910 check-file . 2023-11-10 07:37:53.910 copy-file > 2023-11-10 07:37:53.910 Type: SSH_FXP_EXTENDED, Size: 63, Number: 200 < 2023-11-10 07:37:53.926 Type: SSH_FXP_STATUS, Size: 40, Number: 200 . 2023-11-10 07:37:53.926 We will use UTF-8 strings as it is mandatory with SFTP version 4 and newer . 2023-11-10 07:37:53.926 Getting current directory name. . 2023-11-10 07:37:53.926 Getting real path for '.' > 2023-11-10 07:37:53.926 Type: SSH_FXP_REALPATH, Size: 11, Number: 272 < 2023-11-10 07:37:53.941 Type: SSH_FXP_STATUS, Size: 44, Number: 272 < 2023-11-10 07:37:53.941 Status code: 10, Message: 272, Server: Unable to resolve path, Language: en-US * 2023-11-10 07:37:53.941 (ECommand) Error getting name of current remote directory. * 2023-11-10 07:37:53.941 Cannot get real path for '.'. * 2023-11-10 07:37:53.941 The file path does not exist or is invalid. * 2023-11-10 07:37:53.941 Error code: 10 * 2023-11-10 07:37:53.941 Error message from server (en-US): Unable to resolve path < 2023-11-10 07:37:53.941 Script: Error getting name of current remote directory. < 2023-11-10 07:37:53.941 Cannot get real path for '.'. < 2023-11-10 07:37:53.941 The file path does not exist or is invalid. < 2023-11-10 07:37:53.941 Error code: 10 < 2023-11-10 07:37:53.941 Error message from server (en-US): Unable to resolve path . 2023-11-10 07:37:53.957 Startup conversation with host finished. < 2023-11-10 07:37:53.957 Script: Session started. < 2023-11-10 07:37:53.957 Script: Active session: [1] <username redacted>@ftp.psiwaresolutions.com . 2023-11-10 07:37:53.957 Script: Failed > 2023-11-10 07:37:53.957 Script: option transfer ascii < 2023-11-10 07:37:53.957 Script: transfer ascii > 2023-11-10 07:37:53.957 Script: put G:\Exports\Review360\*.txt < 2023-11-10 07:37:53.957 Script: Using configured transfer settings different from factory defaults. . 2023-11-10 07:37:53.957 Getting current directory name. . 2023-11-10 07:37:53.957 Getting real path for '.' > 2023-11-10 07:37:53.957 Type: SSH_FXP_REALPATH, Size: 11, Number: 528 < 2023-11-10 07:37:53.973 Type: SSH_FXP_STATUS, Size: 44, Number: 528 < 2023-11-10 07:37:53.973 Status code: 10, Message: 528, Server: Unable to resolve path, Language: en-US * 2023-11-10 07:37:53.973 (ECommand) Error getting name of current remote directory. * 2023-11-10 07:37:53.973 Cannot get real path for '.'. * 2023-11-10 07:37:53.973 The file path does not exist or is invalid. * 2023-11-10 07:37:53.973 Error code: 10 * 2023-11-10 07:37:53.973 Error message from server (en-US): Unable to resolve path < 2023-11-10 07:37:53.973 Script: Error getting name of current remote directory. < 2023-11-10 07:37:53.973 Cannot get real path for '.'. < 2023-11-10 07:37:53.973 The file path does not exist or is invalid. < 2023-11-10 07:37:53.973 Error code: 10 < 2023-11-10 07:37:53.973 Error message from server (en-US): Unable to resolve path . 2023-11-10 07:37:53.973 Copying 7 files/directories to remote directory "" - total size: 111,806,755 . 2023-11-10 07:37:53.973 PrTime: Yes; PrRO: No; Rght: rw-r--r--; PrR: No (No); FnCs: N; RIC: 0100; Resume: N (102400); CalcS: No; Mask: . 2023-11-10 07:37:53.973 TM: A; ClAr: No; RemEOF: No; RemBOM: No; CPS: 0; NewerOnly: No; EncryptNewFiles: Yes; ExcludeHiddenFiles: No; ExcludeEmptyDirectories: No; InclM: ; ResumeL: 0 . 2023-11-10 07:37:53.973 AscM: *.*html; *.htm; *.txt; *.php; *.php3; *.cgi; *.c; *.cpp; *.h; *.pas; *.bas; *.tex; *.pl; *.js; .htaccess; *.xtml; *.css; *.cfg; *.ini; *.sh; *.xml . 2023-11-10 07:37:53.973 Getting current directory name. . 2023-11-10 07:37:53.973 Getting real path for '.' > 2023-11-10 07:37:53.973 Type: SSH_FXP_REALPATH, Size: 11, Number: 784 < 2023-11-10 07:37:53.988 Type: SSH_FXP_STATUS, Size: 44, Number: 784 < 2023-11-10 07:37:53.988 Status code: 10, Message: 784, Server: Unable to resolve path, Language: en-US * 2023-11-10 07:37:53.988 (ECommand) Error getting name of current remote directory. * 2023-11-10 07:37:53.988 Cannot get real path for '.'. * 2023-11-10 07:37:53.988 The file path does not exist or is invalid. * 2023-11-10 07:37:53.988 Error code: 10 * 2023-11-10 07:37:53.988 Error message from server (en-US): Unable to resolve path < 2023-11-10 07:37:53.988 Script: Error getting name of current remote directory. < 2023-11-10 07:37:53.988 Cannot get real path for '.'. < 2023-11-10 07:37:53.988 The file path does not exist or is invalid. < 2023-11-10 07:37:53.988 Error code: 10 < 2023-11-10 07:37:53.988 Error message from server (en-US): Unable to resolve path . 2023-11-10 07:37:53.988 File: 'G:\Exports\Review360\Course.txt' [2023-11-09T22:00:43.405Z] [7002525] . 2023-11-10 07:37:54.004 Copying "G:\Exports\Review360\Course.txt" to remote directory started. . 2023-11-10 07:37:54.004 Ascii transfer mode selected. . 2023-11-10 07:37:54.004 Opening remote file. > 2023-11-10 07:37:54.004 Type: SSH_FXP_OPEN, Size: 32, Number: 1027 < 2023-11-10 07:37:54.020 Type: SSH_FXP_STATUS, Size: 22, Number: 1027 < 2023-11-10 07:37:54.020 Status code: 4, Message: 1027, Server: , Language: en-US > 2023-11-10 07:37:54.020 Type: SSH_FXP_LSTAT, Size: 23, Number: 1287 < 2023-11-10 07:37:54.035 Type: SSH_FXP_STATUS, Size: 55, Number: 1287 < 2023-11-10 07:37:54.035 Status code: 2, Message: 1287, Server: The requested file does not exist, Language: en-US * 2023-11-10 07:37:54.035 (ETerminal) General failure (server should provide error description). * 2023-11-10 07:37:54.035 Error code: 4 * 2023-11-10 07:37:54.035 Error message from server (en-US): * 2023-11-10 07:37:54.035 * 2023-11-10 07:37:54.035 Common reasons for the Error code 4 are: * 2023-11-10 07:37:54.035 - Renaming a file to a name of already existing file. * 2023-11-10 07:37:54.035 - Creating a directory that already exists. * 2023-11-10 07:37:54.035 - Moving a remote file to a different filesystem (HDD). * 2023-11-10 07:37:54.035 - Uploading a file to a full filesystem (HDD). * 2023-11-10 07:37:54.035 - Exceeding a user disk quota. . 2023-11-10 07:37:54.035 Asking user: . 2023-11-10 07:37:54.035 Cannot create remote file 'Course.txt'. ("General failure (server should provide error description). . 2023-11-10 07:37:54.035 Error code: 4 . 2023-11-10 07:37:54.035 Error message from server (en-US): . 2023-11-10 07:37:54.035 . 2023-11-10 07:37:54.035 Common reasons for the Error code 4 are: . 2023-11-10 07:37:54.035 - Renaming a file to a name of already existing file. . 2023-11-10 07:37:54.035 - Creating a directory that already exists. . 2023-11-10 07:37:54.035 - Moving a remote file to a different filesystem (HDD). . 2023-11-10 07:37:54.035 - Uploading a file to a full filesystem (HDD). . 2023-11-10 07:37:54.035 - Exceeding a user disk quota.") < 2023-11-10 07:37:54.035 Script: Cannot create remote file 'Course.txt'. < 2023-11-10 07:37:54.035 Script: General failure (server should provide error description). < 2023-11-10 07:37:54.035 Error code: 4 < 2023-11-10 07:37:54.035 Error message from server (en-US): < 2023-11-10 07:37:54.035 Common reasons for the Error code 4 are: < 2023-11-10 07:37:54.035 - Renaming a file to a name of already existing file. < 2023-11-10 07:37:54.035 - Creating a directory that already exists. < 2023-11-10 07:37:54.035 - Moving a remote file to a different filesystem (HDD). < 2023-11-10 07:37:54.035 - Uploading a file to a full filesystem (HDD). < 2023-11-10 07:37:54.035 - Exceeding a user disk quota. . 2023-11-10 07:37:54.051 Answer: Abort * 2023-11-10 07:37:54.051 (ESkipFile) Cannot create remote file 'Course.txt'. * 2023-11-10 07:37:54.051 General failure (server should provide error description). * 2023-11-10 07:37:54.051 Error code: 4 * 2023-11-10 07:37:54.051 Error message from server (en-US): * 2023-11-10 07:37:54.051 * 2023-11-10 07:37:54.051 Common reasons for the Error code 4 are: * 2023-11-10 07:37:54.051 - Renaming a file to a name of already existing file. * 2023-11-10 07:37:54.051 - Creating a directory that already exists. * 2023-11-10 07:37:54.051 - Moving a remote file to a different filesystem (HDD). * 2023-11-10 07:37:54.051 - Uploading a file to a full filesystem (HDD). * 2023-11-10 07:37:54.051 - Exceeding a user disk quota. . 2023-11-10 07:37:54.051 Copying finished: Transferred: 0, Elapsed: 0:00:00, CPS: 0/s . 2023-11-10 07:37:54.051 Script: Failed > 2023-11-10 07:37:54.051 Script: close . 2023-11-10 07:37:54.051 Closing connection. . 2023-11-10 07:37:54.051 Sending special code: 1 . 2023-11-10 07:37:54.082 Main session channel closed . 2023-11-10 07:37:54.082 All channels closed