On 07.06.20 02:42, Keith bainbridge wrote:
On 7/6/20 8:30 am, Marco Möller wrote:
I would easily agree with you concerning not to log into a graphical
session as the user root. But Dolphin is also not running with sudo
prepended.
And here I was thinking that the dolphin issue ran here for several
days, just a few weeks ago.
And yes - not good idea to log into any GUI. My experience is I can't -
I guess by design
Yes, design options exist. However, I never tried out if the user root
could be blocked by the graphical session manager only, in the case of
KDE usually sddm is in use. But I know that the login of user root can
be blocked in general: when nowadays installing Debian, then there is
offered to keep the root account deactivated, which is achieved by
simply not assigning it a password but to leave the root's password
empty and then activating the sudo mechanism for the during installation
created normal user. Then the login as user root is disabled in general,
not applying only to GUI login but also to text terminal login. As a
consequence it is always required to log in as a normal user and using
the command sudo would be the way to run commands with root permissions.
The deactivation of the root account could also be achieved later on,
any time, not only during installation of the system, by changing the
password of user root to an empty string. But I am afraid that you then
will have to care yourself to set up sudo properly when still possible
to do so as user root.
Interestingly, although having disabled the root account during
installation and having sudo automatically configured during
installation, it by default appears to still be allowed to run command
"sudo su -", which still lets you run a root terminal once you have been
logged in as the normal user and knowing the user's password needed to
use sudo! So, for repetitive work requiring root permissions it at least
is not necessary to prepend sudo to all root commands again and again -
but this is still not reaching the comfort like running Dolphin with
root permissions would do, and Dolphin also resists to start up when
called from such root xterminal running in the normal user session.
Reminding on the question of the OP:
If in need to handle files with root permissions, I simply use sudo and
CLI commands. Remember the above mentioned comfort option to invoke a
root terminal by command 'sudo su -'. Then, besides on the CLI running
nano, cp, rm and mv, maybe having available mc, using the command chown
should be considered as well. If I am pretty sure (this is of course
important) that it will not do any harm to change the ownership of files
or directories to the group and name of my normal user, then chown is
fast to do and afterwards I can continue to work with Dolphin as my
normal user.