Как синхронизировать каталоги на двух разных внешних жестких дисках?

695
R S John

У меня есть несколько больших папок "cosmo_sim_9", "cosmo_sim_10" .... на одном из моих внешних жестких дисков и старая копия этого на другом внешнем жестком диске. Я хочу синхронизировать старые каталоги с новыми (рекурсивно), но без перезаписи уже существующих файлов (для экономии времени). Как я могу это сделать? Моя ОС - Fedora 20.

1
Какая операционная система? Adam 9 лет назад 0
Извините ... Я использую Fedora 20 R S John 9 лет назад 0
@RSJohn команда dd должна сделать свое дело. http://forums.fedoraforum.org/showthread.php?t=252973 Ben Plont 9 лет назад 0

1 ответ на вопрос

1
Adam

rsync is pretty much the default program to synchronize files between directories. Try a command along the lines of:

rsync -r --update --progress --dry-run 

That will tell you what would be copied and what wouldn't. The --update command only copies files when the source is newer than the destination. If it looks correct, then take off the --dry-run option. If it's not right, check the man page for rsync to see what I did wrong.

Here is the man page for rsync.