I'm writing a backup script in BASH on a linux machine (gentoo)
The script will backup all folders in a certain directory.
The folders will have varying privileges and belong to different users and groups.
In order to make sure my backup script has read privileges to all the the files and folders I'm tempted to run the backup script as root.
Is this safe? Are there any specific techniques to achieve this without root privileges?