Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I have a lftp file that I want to execute using the following command

lftp -f /usr/scripts/fileS.lftp

If I run this file I get Delaying before reconnect:

Now within this file (fileS.lftp) I have the following code

open -u username,password server
mput -E *
close

If I run open -u username,password server I get the following error Couldnt get a file descriptor referring to the console

I assume I need to allow a connection on the server I'm trying to connect to, how can I do this? Any help would be highly appreciated.

share|improve this question
add comment

1 Answer

I'm using this construct on a server:

(cat /root/1and1-ftp.txt ; echo "put $FNAME") | /usr/bin/lftp

Where /root/1and1-ftp.txt contains open -u user,pass host

I recall that I had some trouble getting -f some-file to work, so I'm doing this gross pipe thing.

share|improve this answer
    
Also, I'm doing "cat file" instead of "echo open (etc etc)" so that the password isn't visible on the command line. –  Bill Weiss Mar 29 '10 at 14:31
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.