Posted in Linux/Unix/BSD -
I very occasionally need to support people with websites on servers other than those I manage. If the server is only accessible using FTP and I need to get a copy of the entire website, then I use the ncftpget command line tool to recursively download all the files and directories in one go.
ncftpget is part of the ncftp package.
On APT based Linux distros (e.g. Debian) you can install it like this:
apt-get install ncftp
On YUM based Linux distros (e.g. CentOS, RHEL) you can install it like this:
yum install ncftp
Use the command like so:
ncftpget -R -T -v -u [username] [hostname] [local path] [remote path]
-R tells ncftpget to download files and directories recursively
-T says not to try a tar download (it's never worked for me and results in the error "tar: This does not look like a tar archive" and "tar: Exiting with failure status due to previous errors". The actual files subsequently download just fine).
-v says to be verbose and show the download progress; you can omit this but it can be useful to see what's going on
-u specifies the username to use. Change [username] to the user to log in as
Replace [hostname] with the server to ftp to.
Replace [local path] to where you want to copy the files to.
Replace [remote path] to the path where the files are on the server you are connecting to.
Let's say our username is "chris", the server is 10.1.1.10, the path we want to save to locally is /tmp and we want to download files from the remote host from /httpdocs. Do this:
ncftpget -R -T -v -u chris 10.1.1.10 /tmp /httpdocs
You are then prompted for the password and the download starts.
제목 | 날짜 | ||
---|---|---|---|
491 | [Apm] 오토셋(autoset) 설치할 때 “MSVCR110.DLL” 문제 | 766 | 2015/08/29 |
490 | [웹 제작] 검색 엔진과 매개변수 | 348 | 2015/08/25 |
489 | [사이트관리] 홈페이지에 옐로아이디 카카오톡 링크 추가하기 | 197 | 2015/08/21 |
488 | [브라우저] [파이어폭스] jjDicTrans : 간단한 영한사전+번역 | 208 | 2015/08/12 |
487 | [윈도우] Windows 8.1 인증 | 110 | 2015/07/05 |
486 | [GitHub] 깃허브 오류 해결.. | 997 | 2015/06/29 |
485 | [웹 제작] 배너의 사이즈에 대해 | 306 | 2015/06/14 |
484 | [사이트관리] 경북대학교 정보전산원 서버 홈페이지 구축 시 phpmyadmin 설치 방법 | 586 | 2015/05/23 |
483 | [포토샵] 한글이 안써질때 : Shift + Alt + 마우스 오른쪽 클릭 | 2203 | 2015/01/26 |
482 | [파일관리/압축] 대용량 파일전송 프로그램(FileZilla Server, serio, Berrys Webshare) | 3412 | 2015/01/21 |
481 | [사무] 구글 앱스로 공통 업무 일지 공유하기 | 4608 | 2014/12/22 |
480 | [데스크탑/액세서리] 네이버 캡쳐 Strokesplus 를 이용하기 | 3056 | 2014/11/21 |