Marius Hofert writes: Hi, > What's the 'correct' approach to easily edit (change + save) such files? not sure whats the 'correct' approach, but there is tramp which allows you to do something like: 1. find-file as root ,--------------- | C-x C-f /sudo: `--------------- and then asks for a password ,----------------------------------- | Password for /sudo:root@localhost: `----------------------------------- to let you subsequently edit the file as root 2. or reopen dired buffer with sudo and thus open end edit files from that buffer as root ,------------------------------------------------------------------------------- | C-c C-s runs the command dired-toggle-sudo, which is an interactive autoloaded | compiled Lisp function in `dired-toggle-sudo.el'. | | It is bound to C-c C-s. | | (dired-toggle-sudo &optional SUDO-USER) | | Reopen current file or dired buffer with sudo. | | If SUDO-USER is nil assume root. | | If called with `universal-argument' (C-u), ask for username. `------------------------------------------------------------------------------- But I finally ended up to write a separate minimal init.el file and a small batch script that allow me to quickly open a root instance of emacs when I need it that warns me about being root while editing that I exit when I'm done with editing: ,--------------------------------------------- | -rwxr-xr-x 1 me users 125 26. Apr 09:44 esu `--------------------------------------------- with content: ,------------------------------------------------------ | #!/bin/sh | # start emacs as root | | exec sudo emacs -Q -bg black -fg wheat --no-splash -l | /home/me/.emacs.d/emacs-ESU-script.el `------------------------------------------------------ emacs-ESU-script.el: (it starts up pretty fast, but makes editing convenient, and has a nice red warning at the top of the buffer about editing as root)