Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
If I backup my home directory, will my hidden files be included which I want of course or do I need to add an option to tar
yes. Any .file (other than . and ..) will be backed up.
Quote:
Is this OK for a syntax
tar -cvphf /media/disk/myhome.tar /home/roy/
c create file
v verbose
p preserve permissions
h follow symlinks
f archive file
I would use rsync but I gotten error messages about preserving the permissions on the vfat partition via /media/disk
It depends on what you want.
Following symlinks can cause all kinds of problems - think about what would happen if you created a symbolic link with "ln -s / testlink". You would then be creating a tar of both the specific sub tree (/home/roy/) but would also include the files in /... which would eventually include the files in "/home/roy/". And you would never finish... Hopefully tar would recognize such an error.
I made a mistake, it wasn't the permissions. It was the symlinks that rsync had issues following to the vfat partition.
Here is a sample error message
rsync: symlink "/media/9C9E-A897/bin/qrencode" -> "../Downloads/build/qrencode-3.2.0/qrencode" failed: Operation not permitted (1)
I have some symlinks in my home directory. If my external drive were a linux filesystem, I wouldn't get those errors
I do need the symlinks to be followed, so I will have to use tar.
replace the -h with -S, but yes as firerat pointed out the vfat file system does not support proper permissions and can have issues with symlinks as it has no clue what to do with either.
i will typically just use scp vs rsync when moving data to vfat devices that have to be accessed by Linux and other OSs.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.