backing up shadow files with rsync?

Robert Moskowitz rgm at htt-consult.com
Wed Feb 16 17:29:19 UTC 2011


On 02/16/2011 10:07 AM, Armelius Cameron wrote:
> On Wednesday, February 16, 2011 09:23:56 am Robert Moskowitz wrote:
>> How would you back up /etc/passwd and its shadow file (and the same for
>> /etc/groups) using rsync?
> Why can't you just rsync the whole /etc directory ? That what I do.

Well I was 'cherry picking'. /etc has ~2300 files for 46Mb.

If I use the --backup and NOT the --backup-dir I will probably only see 
a one-time hit of lots of files.

>> In my case, I have a USB drive to back stuff up to.  I already have a
>> cron job, backing up /home
>>
>> And then, for my documentation, how would I restore the shadow files?
> Just copy it back from the backup ?
>
> Am I missing something from your questions ?

It was could you access the password shadow file as root, and a bit of 
looking, I see you can.




More information about the users mailing list