Possible rootcause of SFTP return error message "Script: No file matching '*.*' :
Have anyone know what (possible rootcause) caused the error
Below are more details
1) Version of WinSCP you are using
• Version 5.17.10 (Buid 11087)
2) Version of Microsoft Windows you are running WinSCP on
• Microsoft Windows Server 2012 R2 Datacenter (Version 6.3.9600 Build 9600)
System Type : x64-based PC
3) Transfer protocol
• SFTP
4) Script Format
• Batch file
Command of Batch file (See below example xxxx= example name of directory path ..... example of key name)
Log Messages (Error as below example xxxxx= example name of directory path)
Script: No file matching '*.*' found.
Status code: 1
Script: Exit code: 0
Below are more details
1) Version of WinSCP you are using
• Version 5.17.10 (Buid 11087)
2) Version of Microsoft Windows you are running WinSCP on
• Microsoft Windows Server 2012 R2 Datacenter (Version 6.3.9600 Build 9600)
System Type : x64-based PC
3) Transfer protocol
• SFTP
4) Script Format
• Batch file
Command of Batch file (See below example xxxx= example name of directory path ..... example of key name)
@echo off "C:\Users\AdminLocal\AppData\Local\Programs\WinSCP\WinSCP.com" ^ /log="C:\writable\path\to\log\WinSCP.log" /ini=nul ^ /command ^ "open sftp://......../ -hostkey=""........="" -privatekey=""......ppk""" ^ "lcd ""D:\xxx\xxxxx""" ^ "cd /xxxxxxx" ^ "get *.*" ^ "rm *.*" ^ "lcd ""xxxx\xxxx""" ^ "cd /xxxx" ^ "get *.*" ^ "rm *.*" ^ "lcd ""D:\xxx\xxxxx""" ^ "cd /xxxxx" ^ "get *.*" ^ "rm *.*" ^ "exit" set WINSCP_RESULT=%ERRORLEVEL% if %WINSCP_RESULT% equ 0 ( echo Success ) else ( echo Error ) exit /b %WINSCP_RESULT%
Log Messages (Error as below example xxxxx= example name of directory path)
< 2022-11-11 03:00:03.897 Script: No file matching '*.*' found. . 2022-11-11 03:00:03.897 Copying 0 files/directories to local directory "D:\xxxx\xxxx" - total size: 0 . 2022-11-11 03:00:03.897 PrTime: Yes; PrRO: No; Rght: rw-r--r--; PrR: No (No); FnCs: N; RIC: 0100; Resume: S (102400); CalcS: No; Mask: . 2022-11-11 03:00:03.897 TM: B; ClAr: No; RemEOF: No; RemBOM: No; CPS: 0; NewerOnly: No; EncryptNewFiles: Yes; ExcludeHiddenFiles: No; ExcludeEmptyDirectories: No; InclM: ; ResumeL: 0 . 2022-11-11 03:00:03.897 AscM: *.*html; *.htm; *.txt; *.php; *.php3; *.cgi; *.c; *.cpp; *.h; *.pas; *.bas; *.tex; *.pl; *.js; .htaccess; *.xtml; *.css; *.cfg; *.ini; *.sh; *.xml . 2022-11-11 03:00:03.897 Copying finished: Transferred: 0, Elapsed: 0:00:00, CPS: 0/s > 2022-11-11 03:00:03.897 Script: rm *.* . 2022-11-11 03:00:03.897 Listing directory "/xxxx". > 2022-11-11 03:00:03.897 Type: SSH_FXP_OPENDIR, Size: 27, Number: 6923 < 2022-11-11 03:00:03.929 Type: SSH_FXP_STATUS, Size: 27, Number: 6660 . 2022-11-11 03:00:03.929 Discarding reserved response < 2022-11-11 03:00:03.977 Type: SSH_FXP_HANDLE, Size: 13, Number: 6923 > 2022-11-11 03:00:03.978 Type: SSH_FXP_READDIR, Size: 13, Number: 7180 < 2022-11-11 03:00:04.038 Type: SSH_FXP_STATUS, Size: 31, Number: 7180 < 2022-11-11 03:00:04.038 Status code: 1 . 2022-11-11 03:00:04.038 Listing file "/xxxx/..". > 2022-11-11 03:00:04.038 Type: SSH_FXP_LSTAT, Size: 34, Number: 7431 < 2022-11-11 03:00:04.081 Type: SSH_FXP_ATTRS, Size: 55, Number: 7431 . 2022-11-11 03:00:04.081 ..;D;0;2021-09-09T05:08:02.000Z;3;"user" [0];"group" [0];rwxrwxrwx;1 > 2022-11-11 03:00:04.081 Type: SSH_FXP_CLOSE, Size: 13, Number: 7684 . 2022-11-11 03:00:04.081 ..;D;0;2021-09-09T05:08:02.000Z;3;"user" [0];"group" [0];rwxrwxrwx;1