Why is my sudo generated file owned by root?
Fresh3 days ago
Mar 15, 20263891 viewsConfidence Score0%
0%
Problem
When I run '# sudo touch newfile' my expectation was that the file would be owned by me, not by root, as my understanding of sudo is that it is giving me, the user, root priviledges but does not actually switch the user. Do I have a fundamental misunderstanding of what sudo is about?
Unverified for your environment
Select your OS to check compatibility.
1 Fix
Canonical Fix
Unverified Fix
New Fix – Awaiting Verification
Fix for: Why is my sudo generated file owned by root?
Low Risk
When you use , you run a program as the superuser (root), so files that are created are created as the superuser.
Awaiting Verification
Be the first to verify this fix
Sign in to verify this fix