Results 1 to 4 of 4

Thread: Using FTP to move folders and contents

  1. #1
    Join Date
    Oct 2008
    Location
    Cambridge, MA
    Beans
    41
    Distro
    Ubuntu 10.04 Lucid Lynx

    Using FTP to move folders and contents

    How can you use ftp in the command line to move folders and their contents, ie recursively.

    When I run:
    sftp username@adress
    cd directory/thatIwant/
    put dir_that_I_want_to_transfer/. .
    It gives me the error:
    skipping non-regular file dir_that_I_want_to_transfer/.
    Any ideas?

  2. #2
    Join Date
    Apr 2006
    Beans
    118

    Re: Using FTP to move folders and contents

    You could create a directory and then change to that directory and use put *

  3. #3
    Join Date
    Jun 2006
    Beans
    2,310
    Distro
    Ubuntu 14.04 Trusty Tahr

    Re: Using FTP to move folders and contents

    A few methods come to mind: rsync, wget, scp, lftp, ncftp, and ftp (the last three all using put and get, as kilroy423 stated), you could tar the entire contents of each directory and send like that, etc., etc. All of those have recursive switches of some kind you can use, most in the form of dash-r. The wget utility has recursive and mirror switches that I find useful. If you like the gui then gftp is nice; if you like using a browser, then FireFTP works well
    Code:
    man rsync
    man wget
    man scp
    man lftp
    man ncftp

  4. #4
    Join Date
    Oct 2008
    Location
    Cambridge, MA
    Beans
    41
    Distro
    Ubuntu 10.04 Lucid Lynx

    Re: Using FTP to move folders and contents

    Quote Originally Posted by ciscosurfer View Post
    A few methods come to mind: rsync, wget, scp, lftp, ncftp, and ftp (the last three all using put and get, as kilroy423 stated), you could tar the entire contents of each directory and send like that, etc., etc. All of those have recursive switches of some kind you can use, most in the form of dash-r. The wget utility has recursive and mirror switches that I find useful. If you like the gui then gftp is nice; if you like using a browser, then FireFTP works well
    Code:
    man rsync
    man wget
    man scp
    man lftp
    man ncftp
    Yeah, I was using scp, but it was a very large amount of data in a large tree of folders that was behind a firewall that made it tricky to use wget and I just thought ftp would be faster. I just didn't want to manually or create a script to reproduce the tree, but just hoped there was a recursive method. Thanks for the advice though.

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •