Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I just installed CentOS and found a couple of updates using yum check-updates.

  1. How can I do backups for all the files on each update? For example, rpm or udev.

    I tried:

    cp -Rp /where-it-is-located /to-where-i-want
    

    It works, but:

  2. How do I know which files or directories to backup?
share|improve this question

migrated from stackoverflow.com Jan 13 '12 at 1:16

This question came from our site for professional and enthusiast programmers.

1 Answer 1

Backing up system binaries and non-user-editable configuration files is not standard practice on Linux. The assumption is, the updates are tested and work well, so there is minimal risk in applying updates. On the other hand, if the updates happen to break something, the system won't be bootable/usable and you'll have to do some manual data recovery by mounting the drive in another system or booting from another OS anyway. You do back up your sensitive non-replaceable data (i.e., all data on the OS other than things you can replace easily as a free download), right? :)

If you insist on backing up the operating system files, there are robust backup solutions such as Amanda and Bacula. But there's no simple, foolproof way to back up yum transactions and revert them on command. Especially since yum likes to occasionally clean up its rpm cache, so over time you lose old versions of rpms that are obsolete. This is done to save disk space.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.