LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   FTP Login with linux to linux (https://www.linuxquestions.org/questions/linux-newbie-8/ftp-login-with-linux-to-linux-840924/)

zondvloed 10-28-2010 05:09 AM

FTP Login with linux to linux
 
Hi there,

Please dont flame me with 'google it' posts. I tried! But didnt find anything.

Here's what I want:
I have a file on serverA and need that file to be on serverB. It is compressed etc and I can login as root and other users in the FTP of serverA with filezilla. It uses port 22 and SFTP SSH ftp acces.

Now I want to log into the ftp with the command shell from serverB TO serverA.

If you dont understand my question, feel free to ask for more details.

Greetings zondvloed

alli_yas 10-28-2010 05:25 AM

Is Server A running an sftp server? This would be the first requirement if you want to use sftp to transfer a file from Server B to Server A.

If this is done; openssh should include an sftp client; so that you can do something like (on Server B):

Code:

# sftp user@serverAhostname
That will allow you to login to the sftp server on Server A; thereafter you can use "normal" ftp commands to send/receive files securely.

zondvloed 10-28-2010 05:32 AM

omg, that just did it! :D

That was what I was looking for. Nobody explained it anywhere because I didnt know what to search for. THANKS! :D

But how to recieve the file now.. hmm.. never did it before.. This maybe will be the biggest adventure of my life! LETS DO IT! :D

ehm.. any tips? Thanks btw

alli_yas 10-28-2010 05:36 AM

Hi

Do you want to receive a file on server B; FROM server A?

If so its fairly simple; you can do an sftp login as per my previous post; and thereafter:

Code:

# get /path/to/file/filename
It will retrieve the file and drop in the directory you're in when you execute the sftp login.

To learn/understand all of this I suggest you search for "Linux - FTP how to" - you'll probably get results that will guide you in installing/configuring an FTP server; an FTP client or both.

Remember an FTP server can be LOGGED INTO; versus an FTP client where you can ONLY use it to login to another FTP server.

The commonly use FTP servers/clients in Linux are vsftpd and proftpd. You can also google these.

repo 10-28-2010 05:39 AM

Here are some basic ftp commands, once you are connected:
http://www.cs.colostate.edu/helpdocs/ftp.html

Kind regards

alli_yas 10-28-2010 05:40 AM

@repo - Thanks, this is an excellent reference which I've also bookmarked :hattip:

zondvloed 10-28-2010 06:08 AM

Jeah! 5 mb/ps retrieving 5,5gb. ^^ works fine

thanks all.

Btw, offtopic; is there a faster way to cd ".." (go to the parent dir)?

alli_yas 10-28-2010 06:44 AM

Quote:

Btw, offtopic; is there a faster way to cd ".." (go to the parent dir)?
Can you maybe explain a bit more what you're trying to achieve exactly?

Glad you've solved your problem - please mark this thread as "Solved" (under Thread Tools).

zondvloed 10-29-2010 02:28 AM

go with cd to the parent map that you are in at the moment.

So if you are in /home/servers and want to go in to /home
To do that, i now always do; cd ".."

alli_yas 10-29-2010 02:42 AM

Hi

I don't think there's an "easier" way to do it. You could write a simple script but it will just as much typing/characters to move up a directory. In my opinion learn to get used to the "cd .." ;)

zondvloed 11-01-2010 03:14 AM

ah k, thanks m8!

Now this tread is DUBBLE SOLVED! ^^

alli_yas 11-01-2010 03:43 AM

Glad you've solved your problems ;)

Just a side note on LQ, please note its against the rules to use "text speak" - so please write your words in full (avoid saying things like "k" etc) :)


All times are GMT -5. The time now is 04:06 PM.