2
rated 0 times
[
2]
[
0]
/ answers: 1 / hits: 1440
/ 2 Years ago, sat, june 19, 2021, 1:13:21
I want to save output of command to a file that my current user do not have access to. But my user can have root access using sudo.
I'm running for example:
sudo crontab -l > /var/BackUp/crontab
-bash: sudo: Permission denied
But I can run just sudo crontab -l
So I think sudo relevant only to crontab command and as user do not have access to /var/BackUp/crontab
it gives such error.
Is it possible to write output to a file that requires root access under current user?
More From » sudo