How do I change permanently change under the specific directory in Linux after I specified permissions with chown -R user:group .
?
For example, I changed owner and group with chown -R www-data:www-data .
After that, rsync running by root account.
But I don’t want to change files/directories during/after rsync which running by root.
On the other hands, I just keep it want to stay in www-data:www-data
owner:group whatever root changed the files.
I tried chown -R www-data:www-data "$TARGET_DIR"
after running rsync by root.
Cellularhacker is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.