0

Is it possible to create a linux user group that has all other rights just like the root user, with the exception that it can only read files in /var/log folder, but can not change or delete them? Of course such a user must not be able to change anything in /var/log with chown or chmod, but otherwise it must behave just like the real root user.

migrated from stackoverflow.com Dec 7 '13 at 3:26

This question came from our site for professional and enthusiast programmers.

  • /var and /var/log have normally read+execute permissions for all users, so any user should be ok. – fedorqui Dec 6 '13 at 15:37
  • yes, but user like a root can write to files in /var/log, and i want to avoid this - i want to reserve this "privilege" only to real root user. – Racket Noob Dec 6 '13 at 15:45
  • Yes, that's what I mean: with any other user you can go through these files without the option to write them. Or you mean to have a root user with privileges all around except on those dirs? – fedorqui Dec 6 '13 at 15:48
  • Yes, I mean to have a root user (or, better, "root user") with privileges all around except on those dirs! – Racket Noob Dec 6 '13 at 15:50
  • Yes, it's possible. Don't forget about groups. – Marcus Adams Dec 6 '13 at 19:10

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy