On 06/09/2023 10:41, Greg Wooledge wrote:

Just put "ALWAYS_SET_PATH yes" into /etc/default/su and the problem
is FIXED.  "su" will work properly again!

Greg, you provided a valid example when "su -" is undesirable, however in general "su -" is safer than just "su" since it resets some user specific environment variables like XDG_RUNTIME_DIR=/run/user/1000 that may cause creation of files that the original user can not overwrite them. So "su -" should have less unexpected effects.

Unfortunately, Debian DOESN'T CREATE THIS FILE BY DEFAULT.  People are
scared to create it themselves, because people have been "trained"
by years of Linux distribution handholding that if a program has
a configuration file, that file will *exist*, and will have helpful
comments in it, and they only have to find the file and edit it.
The idea of *creating* a configuration file that's missing is terrifying
for some people.

I find it more convenient when a configuration file may be created in addition to ones provided by the package. It makes changes more visible. It may be advantage or disadvantage if during package upgrade default configs are replaced without a query related to changed directives.

This particular settings is described in su(1) so can be discovered by users with reasonable amount of efforts. Certainly a configuration example may still be preferable for users.


Reply via email to