Mirror Website Directory Over FTP

(0 votes, average 0 out of 5)

You can easily mirror the contents of a directory over FTP using the lftp program on Linux. To connect, create a configuration file for lftp that specifies the credentials for the ftp server, the directory on the remote ftp server that you want to download files from, and where you want to place them on the local machine:

1
2
3
4
5
6
set ftp:anon-user "ftpusername"
set ftp:anon-pass "ftppassword"
set ftp:ssl-allow no
open remote-ftp-server.com
mirror -c /remote/directory/ /local/directory/to/put/files/in
exit

Save this script on your local machine, e.g. /tmp/ftp-mirror . Now, run lftp in a screen session in order to make sure that the transfer continues even if you get disconnected:

1
2
screen
lftp -f /tmp/ftp-mirror

Your file transfer will start and once completed you will have a local mirror of all of the files on your ftp server.

Partner Links:
 
Related Articles

» How to Change Microphone Settings in Windows Vista/7

For various reasons, you may want to change microphone settings in Windows.    For instance, a webcam microphone may be the default microphone instead of a USB dedicated microphone, or your volume settings may be too low.  Changing these settings is simple and easy in Windows 7 (note that these instructions also apply for Vista users).1.  Navigate to the Control Panel (Start button -> Control Panel).  Click on the "Hardware and Sound" link in green.2.  Click on...

» HTTP 1.1 Response Status Codes

When a request is sent to a web server, the web server will return a HTTP (HyperText Transfer Protocol) status code. These status codes are listed in five different categories, listed below:1XX - Informational2XX - Success3XX - Redirection4XX - Client Error5XX - Server ErrorThe complete list of status codes are listed below. All status codes are listed for the HTTP/1.1 standard.CodeNameDescription100ContinueThe server has received the request headers and the client should send the request body...

» How to Set Emacs to Word Wrap on Vertical Split

By default, using C-x 3 in emacs splits the window vertically into two buffers.  This is very convenient, but for some reason it disables word wrap (even when word wrap is set in the options).  To enable word wrap on a vertical split, add the following to your .emacs file (typically located in your home directory):;; Word wrap on vertical split(setq truncate-partial-width-windows nil)Alternatively you can enter the same command during your current session if you don't want this to be...