[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Create backup of system-connections on a USB stick



On Sun, 2014-06-01 at 06:29 +0200, Ralf Mardorf wrote:
> Assumed there's no data on the stick, IOW assumed you plan to copy to a  
> stick, then don't copy the directories and files directly, but write the  
> directories and files to a tar archive, so all the permissions are  
> preserved and you're free to compress the archive.
> 
> cd /path/to/dir/you/want/to/copy/
> tar --exclude=file_that_should_not_be_copied -czf /pa/th/backup_file.bak.tar.gz * .hidden_file
> 
> You should read some howtos about shell globbing, before you write data to  
> an archive.
> You should read some howtos about how to use tar, e.g. how to restore data  
> from the archive.

PS: Also read
man chown
man chmod


Reply to: