You are not logged in.
Pages: 1
I just upgraded to Beowulf and found that /sbin is not on the system path for root.
This is surely a bug?
It means you cannot run fdisk etc.
Last edited by devian (2020-06-08 12:21:32)
Offline
Refer to the "Changes in su" in the release notes: https://files.devuan.org/devuan_beowulf … _notes.txt
rolfie
Offline
Ah, my bad. Thank you. :-)
Offline
Hello:
Would have been mine also ... 8⁷ |
I did not have /etc/default/su and generating the file and adding ALWAYS SET PATH yes did not work.
What did work was ...
root@devuan2:/home/groucho# export PATH=$PATH:~/usr/local/sbin
root@devuan2:/home/groucho# $echo $PATH
bash: /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/root/usr/local/sbin: No such file or directory
root@devuan2:/home/groucho#
Got it from https://wiki.debian.org/EnvironmentVariables:
--- snip ---
... after doing su, your PATH may not contain directories like /sbin, and many system administration commands will fail. There are several workarounds:
...
Put the system administration directories (/sbin, /usr/sbin, /usr/local/sbin) in your regular account's PATH (see EnvironmentVariables for help with this).
--- snip ---
BTW: whatever the reason for the change in how su works, I hope it is a good/justified one and not another one of Poettering's wet dreams. It is a PITA.
A.
Last edited by Altoid (2020-09-04 16:53:33)
Offline
I did not have /etc/default/su and generating the file and adding ALWAYS SET PATH yes did not work.
That seems to be an error in the release notes, ALWAYS_SET_PATH yes should be added to /etc/login.defs.
Or just call su correctly:
su -
^ The - is important
whatever the reason for the change in how su works, I hope it is a good/justified one and not another one of Poettering's wet dreams. It is a PITA.
See https://bugs.debian.org/cgi-bin/bugrepo … bug=905409
tl;dr: /bin/su used to be supplied by the login package but it is now supplied by the util-linux package.
And is it really such a PITA to add a - after the command?
Brianna Ghey — Rest In Power
Offline
Hello:
... seems to be an error ...
... should be added to /etc/login.defs.
I see.
... call su correctly:
su -
^ The - is important.
Of course it is.
su won't work as intended expected without it.
Q:
Why not just get rid of the old su and let the output be command not found?
Now we have sudo, su and su - ...
Thanks for the link.
... a PITA to add a - after the command?
Yes.
I forget to do it because I am very much used to su.
And I don't like sudo although it is convenient if properly used/configured.
Cheers,
A.
Offline
Why not just get rid of the old su and let the output be command not found?
Because su can be used for things other than obtaining a root shell. Read man su
Brianna Ghey — Rest In Power
Offline
Hello:
Because su can be used for things other ...
I see.
Read man su
Yes, my use of su is rather limited to the basics, so I really have quite a bit of reading to do.
That's what you get from arriving to Linuxland late in life. 8^7
Thanks for your input.
Cheers,
A.
Offline
Pages: 1