Link to home
Start Free TrialLog in
Avatar of myrizvi
myrizvi

asked on

FTP Error (HP Unix 11)

Hi Experts,

Following script is giving error "553 Could not determine cwdir: No such file or directory." :

{

echo "cd testdlvry"
echo "mput /folder1/hold/TT*"

} | ftp -vi 122.20.39.51


while following is running perfectly:

{

echo "cd testdlvry"
echo "put /folder1/hold/TT1 /folder2/tmp/TT1"

}|ftp -vi 122.20.39.51


Any hint for solution?

Thanks.
Avatar of gheist
gheist
Flag of Belgium image

Do ftp> lcd /folder1/hold
and from there do an mput.
Avatar of myrizvi
myrizvi

ASKER

Hi gheist,

This lcd command is not working on HP UX.

I want to have script to "put" multiple files to remote server in one execution. Right now my script is doing it in a loop and using only "put" command to send files one by one (as mentioned above in second example). I want to use the unix ftp tool not any other 3rd party tool.
ASKER CERTIFIED SOLUTION
Avatar of gheist
gheist
Flag of Belgium image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of myrizvi

ASKER

Thanks Ghiest, enjoy the earned points.

The script now looks like this and working fine:

{

echo "cd testdlvry"
echo "lcd /folder1/hold"
echo "mput TT*"

} | ftp -vi 122.20.39.51