LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 06-11-2009, 10:25 PM   #1
Sander-Rob
LQ Newbie
 
Registered: Jul 2008
Posts: 3

Rep: Reputation: 0
FTP Transfer


I have a CentOS machine I'm connected to via SSH. I need to FTP multiple directories and files over to another machine.

When I get to the 'put' command, how do I sent everything within a particular directory, and in turn it's child directories, to the FTP server?
 
Old 06-11-2009, 10:28 PM   #2
jamescondron
Member
 
Registered: Jul 2007
Location: Scunthorpe, UK
Distribution: Ubuntu 8.10; Gentoo; Debian Lenny
Posts: 961

Rep: Reputation: 70
man page. Though if ssh exists, why not use scp? FTP is notoriously insecure and almost completely outdated.
 
Old 06-11-2009, 10:33 PM   #3
Sander-Rob
LQ Newbie
 
Registered: Jul 2008
Posts: 3

Original Poster
Rep: Reputation: 0
I'm just transferring files between two machines on the same network.

Can I use SCP to connect to an FTP server? I've only used SCP to connect to another Linux machine. The FTP server I'm trying to connect to is on a Windows machine.
 
Old 06-11-2009, 10:34 PM   #4
jamescondron
Member
 
Registered: Jul 2007
Location: Scunthorpe, UK
Distribution: Ubuntu 8.10; Gentoo; Debian Lenny
Posts: 961

Rep: Reputation: 70
Oh, okay, fair enough. But still, the FTP man page should be the first place you look for this
 
Old 06-11-2009, 10:41 PM   #5
Sander-Rob
LQ Newbie
 
Registered: Jul 2008
Posts: 3

Original Poster
Rep: Reputation: 0
I looked through it. When I do the following, I get the sub-directories, but I don't get their subdirectories and/or contents.

Example:

# ftp 192.168.1.2
# mput
# directory/*

It then asks me to confirm sending the contents of directory/, but not /directory/child/ etc..

If I use 'ftp -i' it shouldn't ask me to confirm each file, but I don't see a location within the man file that says anything about recursively copying the contents of a directory. Am I missing something?
 
Old 06-12-2009, 12:57 AM   #6
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Rocky 9.2
Posts: 18,359

Rep: Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751
AFAIK, there's no recursive option on FTP. you could try either

1. mput */*

or

2, create an MS equiv of a tar file and put that. If you've got Cygwin on the MS box (or can put it on) that would work for tar.
Else some kind of zip file I think (me no use MS)
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Transfer using ftp command john_smith Linux - Newbie 7 12-03-2007 02:03 AM
Ftp freezes up during transfer GeneralChaos Slackware 2 10-04-2005 08:52 PM
FTP transfer jams! 3p0ch Linux - Networking 1 07-21-2005 08:07 AM
Auto FTP transfer madunix *BSD 0 02-29-2004 02:57 PM
FTP transfer speed twantrd Linux - General 0 04-08-2003 10:08 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 02:23 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration