- Source server: server1.oric.no
- Destination server: server2.oric.no
- Execute as: root
target=server2.oric.no && rsync -vaz --delete /u01/app/myfiles ebsuser@$target:/u01/appThis will sync the entire "/u01/app/myfiles" folder + all subfolders.
The --delete flag in rsync ensures that files in the destination directory (ebsuser@$target:/u01/app) that are not present in the source directory (/u01/app/inst) are deleted. This helps keep the destination directory synchronized with the source directory.
No comments:
Post a Comment