Cannot List Directory & No Such File or Directory Error

Advertisement

Grit
Guest

Cannot List Directory & No Such File or Directory Error

While creating some automated scripts with WINSCP, I've encountered a problem with a specific SFTP site that has me bewildered. There are no issues whatsoever when using the WINSCP gui (winscp.exe) - however I'm trying to use winscp.com.

After navigating away from the root directory of the SFTP site, the "ls" command no longer functions, and simply throws an error message "Directory X does not exist".

Additionally, and more troublesome is the fact that I cannot navigate or pull files from specific directories. Again, a similar error message "Cannot get real path for X" is thrown.

In the log file you will note that I can navigate to "/prod/wim_out/lincoln", but I cannot navigate to "/prod/wim_out/cornerfeedfiles" and several other folders.

These directories are set-up with identical permissions, and FTP clients can access them with no problem. It's only when I use command-line options and scripts that this problem is encountered.

Any help that can be provided is appreciated.
Description: Session log

Reply with quote

Advertisement

martin
Site Admin
martin avatar
Joined:
Posts:
27,271
Location:
Prague, Czechia

Re: Cannot List Directory & No Such File or Directory Error

Can you attach a log file from GUI showing listing of the /prod directory?

Reply with quote

Grit
Guest

FYI - I tried with an older version of WinSCP (5.5.6) and the same problem was present. I've also tried from different computers in different networks.

It's a third-party FTP site, so I'm limited in what I can look at there.

Reply with quote

martin
Site Admin
martin avatar
Joined:
Posts:
27,271
Location:
Prague, Czechia

In GUI, you enter /Prod path, while in script you use /prod. Note that most servers are case-sensitive.

Reply with quote

Grit
Guest

Well that was simple. Turns out that you're right.

If I use improper case with a cd command, I'm still able to navigate through folders up to a specific point where it starts to fail. However, I can't list the contents in those directories unless I used the proper case to begin with.

It's a little bit counter-intuitive, but using the correct case seems to be the solve. And I could have sworn I tested that. Oh well.



Thanks!

Reply with quote

Advertisement

You can post new topics in this forum