ProgrammingThis forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Remember: "*.txt" has a script metacharacter in it
Try single-quoting the "mdelete" and "mput", and see if that helps:
Code:
'mdelete *.txt'
'mput *.txt'
I haven't actually tried it, so I can't guarantee that it'll work.
But to the extent I believe the problem is "metacharacters", I hope it'll at least point you in the right direction.
'Hope that helps .. PSM
Thanks Paulsm,
I tried this, but I am getting the below error
Quote:
220 (vsFTPd 2.0.5)
530 Please login with USER and PASS.
530 Please login with USER and PASS.
KERBEROS_V4 rejected as an authentication type
331 Please specify the password.
230 Login successful.
200 Switching to Binary mode.
Interactive mode on.
250 Directory successfully changed. ?Invalid command
?Invalid command
221 Goodbye.
what about using a for loop to avoid the metacharacters entirely? Though it's not a straight up ftp command, so you might have to work over your function a bit? We normally use scp/rsync/ssh etc for moving files around, makes things somewhat easier, but you might be stuck with ftp.
what about using a for loop to avoid the metacharacters entirely? Though it's not a straight up ftp command, so you might have to work over your function a bit? We normally use scp/rsync/ssh etc for moving files around, makes things somewhat easier, but you might be stuck with ftp.
Something like this possibly (untested):
Code:
for i in *.txt;
do
mput $i
done
Hi Kaos,
Thanks but I am looking for consecutive commands in ftp.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.