Computer ???
| No. | 450 | ||||||||
| Name. | swindler | ||||||||
| Subject. | rsync | ||||||||
| Main Cate. | Linux | ||||||||
| Sub Cate. | |||||||||
| Date. | 2014-04-01 15:09 | ||||||||
| Hit. | 5543 (211.36.27.3) | ||||||||
| File. | |||||||||
| 1. rsync, xinetd 설치 - rpm -qa | grep rsync, rpm -qa | grep xinetd 설치 되어 있는지 확인 - 없으면 yum install rsync, yum install xinetd 2. rsync 서버 설정 - vi /etc/xinetd.d/rsync - disable 부분을 no 로 바꾼다. 3. rsync.conf 설정 - vi /etc/rsyncd.conf [pad] path = /home/project/pad/upload comment = pad uid = nobody gid = nobody use chroot = no read only = no hosts allow = 209.190.94.114 max connections = 3 timeout = 300 4. 서비스 재시작 - /etc/init.d/xinetd restart 5. 방화벽 확인 ** rsync는 873 포트를 이용하므로, 873포트를 iptables에서 열어준다 - /etc/sysconfig/iptables 에서 873포트 오픈 후 iptables restart rsync -avz /home/project/pad/upload/db_file/Panda.sql.zip root@1.1.1.1:/home/project/pad/upload/db_file rsync over ssh 를 사용하는 경우 원격지의 rsync 설정은 필요없다. 그냥 ssh를 통해서 전송하기 때문이다 rsync 주요 옵션 -n (--dry-run) : 실제 파일을 전송하지 않고, 테스트용으로 사용 -r (--recursive): 하위 디렉토리 포함 -l (--links) : 심볼링 링크 유지 -p (--perms): 권한 유지 -t (--times): 파일 시간 유지 -v (--verbose): 전송 상황과 결과 출력 -z (--compress): 전송내용 압축 --delete : 송신측에 없는 파일을 삭제 --exclude : 지정된 패턴을 제외 [바로가기 링크] : http://coolx.net/cboard/computer/450 |
|||||||||
|
|||||||||
| [Modify] [Delete] | [Reply] [List] | |

Copyright © 1999-2017, swindler. All rights reserved.
367,611 visitor ( 1999.1.8-2004.5.26 ), 2,405,771 ( -2017.01.31)