public inbox for gentoo-dev@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-dev] rfc: adding sbin directories to PATH for all users
@ 2015-11-25 17:10 William Hubbs
  2015-11-25 17:24 ` Michael Orlitzky
                   ` (4 more replies)
  0 siblings, 5 replies; 25+ messages in thread
From: William Hubbs @ 2015-11-25 17:10 UTC (permalink / raw
  To: gentoo development

[-- Attachment #1: Type: text/plain, Size: 838 bytes --]

All,

I would like for us to discuss adding the sbin directories to PATH for
all users.

The only reason I can think of that we have removed them is cosmetic (it
removes things from tab completion), but I have also heard that having
those things in tab completion would be a good thing.

Another reason I am bringing this up is this bug [1]. On standard OSx,
there is no reason to hard code the path to sysctl like I'm being asked
to do in the patch associated with this bug, because the sbin
directories are always  in the path. In other words, it isn't worth the
effort to send this patch upstream, which means there will always be a
Gentoo-specific patch to dev-lang/go unless upstream finds another way
to do the test they are doing on OSx via sysctl.

Any ideas?

Thanks,

William

[1] https://bugs.gentoo.org/show_bug.cgi?id=558368

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 181 bytes --]

^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: [gentoo-dev] rfc: adding sbin directories to PATH for all users
  2015-11-25 17:10 [gentoo-dev] rfc: adding sbin directories to PATH for all users William Hubbs
@ 2015-11-25 17:24 ` Michael Orlitzky
  2015-11-25 17:36 ` Kristian Fiskerstrand
                   ` (3 subsequent siblings)
  4 siblings, 0 replies; 25+ messages in thread
From: Michael Orlitzky @ 2015-11-25 17:24 UTC (permalink / raw
  To: gentoo-dev

On 11/25/2015 12:10 PM, William Hubbs wrote:
> All,
> 
> I would like for us to discuss adding the sbin directories to PATH for
> all users.
> 
> 

The only thing that procps installs in /sbin is sysctl. Why? It works
when run as a normal user, as long as you don't try to change something
sacred. (In that regard, it's no different than, say, rm.)




^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: [gentoo-dev] rfc: adding sbin directories to PATH for all users
  2015-11-25 17:10 [gentoo-dev] rfc: adding sbin directories to PATH for all users William Hubbs
  2015-11-25 17:24 ` Michael Orlitzky
@ 2015-11-25 17:36 ` Kristian Fiskerstrand
  2015-11-25 18:05   ` Ulrich Mueller
  2015-11-25 18:14   ` [gentoo-dev] " William Hubbs
  2015-11-25 18:58 ` Mike Gilbert
                   ` (2 subsequent siblings)
  4 siblings, 2 replies; 25+ messages in thread
From: Kristian Fiskerstrand @ 2015-11-25 17:36 UTC (permalink / raw
  To: gentoo development

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA512

On 11/25/2015 06:10 PM, William Hubbs wrote:
> All,
> 
> I would like for us to discuss adding the sbin directories to PATH
> for all users.
> 

This sounds strange to me, if it should be executable by all users it
likely shouldn't be in sbin in the first place but in bin. In any
case; I don't see any good reason to change the traditional behavior
of sbin only being in path for root.

- -- 
Kristian Fiskerstrand
Public PGP key 0xE3EDFAE3 at hkp://pool.sks-keyservers.net
fpr:94CB AFDD 3034 5109 5618 35AA 0B7F 8B60 E3ED FAE3
-----BEGIN PGP SIGNATURE-----

iQEcBAEBCgAGBQJWVfF/AAoJECULev7WN52FKHkH/2z2lGrmC6jQn4+gAizDKX02
bHmuMK2j3TS5UZsA+YQSzTlT7OddlC2PGDvbuaGz5bZMcUMeaE9nTvr8EgkTRKEn
sAzTH8ojQtpk68+BlKMz1WjW46LWZWAcSxuaVTqNK5OIAy22eqrdv2kwKoupakv+
0GescG/kuLpx7uwlrzF5qrEQRyC+Ht4s71U+G0oWfb97Lh2iBn0aEyoxN1weWLDp
TYE/MzklKRrKrnikci6kXTewgfGQzIP64VZA+rdb8LOQaL5yTxxbUDjVN4HbMz2m
dZLNewKhwJUUYqupUGCIameKPtjBM3ianl+2BdzWcwUavVNuKBKEUFkj2VK/UBg=
=mvdt
-----END PGP SIGNATURE-----


^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: [gentoo-dev] rfc: adding sbin directories to PATH for all users
  2015-11-25 17:36 ` Kristian Fiskerstrand
@ 2015-11-25 18:05   ` Ulrich Mueller
  2015-11-25 18:17     ` Michał Górny
  2015-11-25 18:14   ` [gentoo-dev] " William Hubbs
  1 sibling, 1 reply; 25+ messages in thread
From: Ulrich Mueller @ 2015-11-25 18:05 UTC (permalink / raw
  To: gentoo-dev

[-- Attachment #1: Type: text/plain, Size: 788 bytes --]

>>>>> On Wed, 25 Nov 2015, Kristian Fiskerstrand wrote:

> On 11/25/2015 06:10 PM, William Hubbs wrote:
>> I would like for us to discuss adding the sbin directories to PATH
>> for all users.

> This sounds strange to me, if it should be executable by all users
> it likely shouldn't be in sbin in the first place but in bin. In any
> case; I don't see any good reason to change the traditional behavior
> of sbin only being in path for root.

+1

The sbin directories are separate from bin for the very reason that
binaries in there (which are only usable with elevated privileges) can
be excluded from normal users' PATH.

Users who for whatever reason want these directories in their PATH can
include them in their local settings, but as the general default it
makes no sense.

Ulrich

[-- Attachment #2: Type: application/pgp-signature, Size: 490 bytes --]

^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: [gentoo-dev] rfc: adding sbin directories to PATH for all users
  2015-11-25 17:36 ` Kristian Fiskerstrand
  2015-11-25 18:05   ` Ulrich Mueller
@ 2015-11-25 18:14   ` William Hubbs
  2015-11-25 18:31     ` Ulrich Mueller
  1 sibling, 1 reply; 25+ messages in thread
From: William Hubbs @ 2015-11-25 18:14 UTC (permalink / raw
  To: gentoo-dev

[-- Attachment #1: Type: text/plain, Size: 1150 bytes --]

On Wed, Nov 25, 2015 at 06:36:03PM +0100, Kristian Fiskerstrand wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA512
> 
> On 11/25/2015 06:10 PM, William Hubbs wrote:
> > All,
> > 
> > I would like for us to discuss adding the sbin directories to PATH
> > for all users.
> > 
> 
> This sounds strange to me, if it should be executable by all users it
> likely shouldn't be in sbin in the first place but in bin. In any
> case; I don't see any good reason to change the traditional behavior
> of sbin only being in path for root.
 
This behaviour is not really that traddditional. most *nix's I've seen
have the sbin directories in the path for all users.

I wanted to open the discussion, because the fact that we remove sbin
from paths was cited on the bug I referred to as a reason I should keep
the patch that the prefix team applied to dev-lang/go.

My opinion is prefix should either fix their paths (include /sbin) even
though they are running unprivileged, or it would be better even if they
found a way to do the same test that did not require access to sbin and
contributed that to Go upstream.

William


[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 181 bytes --]

^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: [gentoo-dev] rfc: adding sbin directories to PATH for all users
  2015-11-25 18:05   ` Ulrich Mueller
@ 2015-11-25 18:17     ` Michał Górny
  2015-11-25 19:18       ` Daniel Campbell
  0 siblings, 1 reply; 25+ messages in thread
From: Michał Górny @ 2015-11-25 18:17 UTC (permalink / raw
  To: Ulrich Mueller; +Cc: gentoo-dev

[-- Attachment #1: Type: text/plain, Size: 1192 bytes --]

On Wed, 25 Nov 2015 19:05:13 +0100
Ulrich Mueller <ulm@gentoo.org> wrote:

> >>>>> On Wed, 25 Nov 2015, Kristian Fiskerstrand wrote:  
> 
> > On 11/25/2015 06:10 PM, William Hubbs wrote:  
> >> I would like for us to discuss adding the sbin directories to PATH
> >> for all users.  
> 
> > This sounds strange to me, if it should be executable by all users
> > it likely shouldn't be in sbin in the first place but in bin. In any
> > case; I don't see any good reason to change the traditional behavior
> > of sbin only being in path for root.  
> 
> +1
> 
> The sbin directories are separate from bin for the very reason that
> binaries in there (which are only usable with elevated privileges) can
> be excluded from normal users' PATH.

Binaries like blkid, btrfs, getcap, sensors, swapon and various tools
from net-tools, iputils, wireless-tools... and I really have better
things to do than list all tools that landed in sbin for some fun
reason yet work for normal users.

But well, I'm the weird one wanting to be able to check how much free
space I've got without going through hoops.

-- 
Best regards,
Michał Górny
<http://dev.gentoo.org/~mgorny/>

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 949 bytes --]

^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: [gentoo-dev] rfc: adding sbin directories to PATH for all users
  2015-11-25 18:14   ` [gentoo-dev] " William Hubbs
@ 2015-11-25 18:31     ` Ulrich Mueller
  2015-11-25 18:38       ` William Hubbs
  0 siblings, 1 reply; 25+ messages in thread
From: Ulrich Mueller @ 2015-11-25 18:31 UTC (permalink / raw
  To: gentoo-dev

[-- Attachment #1: Type: text/plain, Size: 369 bytes --]

>>>>> On Wed, 25 Nov 2015, William Hubbs wrote:
 
> This behaviour is not really that traddditional. most *nix's I've
> seen have the sbin directories in the path for all users.

Traditional Unices didn't have /sbin at all. Instead, they used /etc
for such binaries. :)

(Some remnants of this can still be seen today, like /etc/rmt
installed by app-arch/tar.)

Ulrich

[-- Attachment #2: Type: application/pgp-signature, Size: 490 bytes --]

^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: [gentoo-dev] rfc: adding sbin directories to PATH for all users
  2015-11-25 18:31     ` Ulrich Mueller
@ 2015-11-25 18:38       ` William Hubbs
  2015-11-25 18:51         ` Ulrich Mueller
  0 siblings, 1 reply; 25+ messages in thread
From: William Hubbs @ 2015-11-25 18:38 UTC (permalink / raw
  To: gentoo-dev

[-- Attachment #1: Type: text/plain, Size: 653 bytes --]

On Wed, Nov 25, 2015 at 07:31:14PM +0100, Ulrich Mueller wrote:
> >>>>> On Wed, 25 Nov 2015, William Hubbs wrote:
>  
> > This behaviour is not really that traddditional. most *nix's I've
> > seen have the sbin directories in the path for all users.
> 
> Traditional Unices didn't have /sbin at all. Instead, they used /etc
> for such binaries. :)

From what I've read, the traditional difference between bin and sbin was
that sbin means static-bin and everything stored in there was to be able
to come up without libraries.

As mgorny was talking about earlier, a good chunk of what is in sbin
*can* be run by normal users.

William


[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 181 bytes --]

^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: [gentoo-dev] rfc: adding sbin directories to PATH for all users
  2015-11-25 18:38       ` William Hubbs
@ 2015-11-25 18:51         ` Ulrich Mueller
  2015-11-25 19:47           ` William Hubbs
  2015-11-25 20:12           ` splite-gentoo
  0 siblings, 2 replies; 25+ messages in thread
From: Ulrich Mueller @ 2015-11-25 18:51 UTC (permalink / raw
  To: gentoo-dev

[-- Attachment #1: Type: text/plain, Size: 459 bytes --]

>>>>> On Wed, 25 Nov 2015, William Hubbs wrote:

> From what I've read, the traditional difference between bin and sbin
> was that sbin means static-bin and everything stored in there was to
> be able to come up without libraries.

Source/reference for this?

> As mgorny was talking about earlier, a good chunk of what is in sbin
> *can* be run by normal users.

Then it shouldn't be in sbin, in the first place. That's a separate
discussion though.

Ulrich

[-- Attachment #2: Type: application/pgp-signature, Size: 490 bytes --]

^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: [gentoo-dev] rfc: adding sbin directories to PATH for all users
  2015-11-25 17:10 [gentoo-dev] rfc: adding sbin directories to PATH for all users William Hubbs
  2015-11-25 17:24 ` Michael Orlitzky
  2015-11-25 17:36 ` Kristian Fiskerstrand
@ 2015-11-25 18:58 ` Mike Gilbert
  2015-11-25 20:42   ` Anthony G. Basile
  2015-11-26 16:37   ` Peter Stuge
  2015-11-25 19:17 ` Nicolas Sebrecht
  2015-11-25 21:39 ` Andrew Savchenko
  4 siblings, 2 replies; 25+ messages in thread
From: Mike Gilbert @ 2015-11-25 18:58 UTC (permalink / raw
  To: Gentoo Dev

On Wed, Nov 25, 2015 at 12:10 PM, William Hubbs <williamh@gentoo.org> wrote:
> All,
>
> I would like for us to discuss adding the sbin directories to PATH for
> all users.

I support this idea. The distinction between bin and sbin is stupid.


^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: [gentoo-dev] rfc: adding sbin directories to PATH for all users
  2015-11-25 17:10 [gentoo-dev] rfc: adding sbin directories to PATH for all users William Hubbs
                   ` (2 preceding siblings ...)
  2015-11-25 18:58 ` Mike Gilbert
@ 2015-11-25 19:17 ` Nicolas Sebrecht
  2015-11-25 21:39 ` Andrew Savchenko
  4 siblings, 0 replies; 25+ messages in thread
From: Nicolas Sebrecht @ 2015-11-25 19:17 UTC (permalink / raw
  To: gentoo development; +Cc: Nicolas Sebrecht

On Wed, Nov 25, 2015 at 11:10:11AM -0600, William Hubbs wrote:

> I would like for us to discuss adding the sbin directories to PATH for
> all users.

Binaries that can run with user privileges could be symbolic linked to
/bin.

-- 
Nicolas Sebrecht


^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: [gentoo-dev] rfc: adding sbin directories to PATH for all users
  2015-11-25 18:17     ` Michał Górny
@ 2015-11-25 19:18       ` Daniel Campbell
  2015-11-25 19:23         ` Michał Górny
  0 siblings, 1 reply; 25+ messages in thread
From: Daniel Campbell @ 2015-11-25 19:18 UTC (permalink / raw
  To: gentoo-dev

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

On 11/25/2015 10:17 AM, Michał Górny wrote:
> On Wed, 25 Nov 2015 19:05:13 +0100 Ulrich Mueller <ulm@gentoo.org>
> wrote:
> 
>>>>>>> On Wed, 25 Nov 2015, Kristian Fiskerstrand wrote:
>> 
>>> On 11/25/2015 06:10 PM, William Hubbs wrote:
>>>> I would like for us to discuss adding the sbin directories to
>>>> PATH for all users.
>> 
>>> This sounds strange to me, if it should be executable by all
>>> users it likely shouldn't be in sbin in the first place but in
>>> bin. In any case; I don't see any good reason to change the
>>> traditional behavior of sbin only being in path for root.
>> 
>> +1
>> 
>> The sbin directories are separate from bin for the very reason
>> that binaries in there (which are only usable with elevated
>> privileges) can be excluded from normal users' PATH.
> 
> Binaries like blkid, btrfs, getcap, sensors, swapon and various
> tools from net-tools, iputils, wireless-tools... and I really have
> better things to do than list all tools that landed in sbin for
> some fun reason yet work for normal users.
> 
> But well, I'm the weird one wanting to be able to check how much
> free space I've got without going through hoops.
> 

Maybe I'm missing something, but `df` is in /bin. Do you use something
else to determine free space?

- -- 
Daniel Campbell - Gentoo Developer
OpenPGP Key: 0x1EA055D6 @ hkp://keys.gnupg.net
fpr: AE03 9064 AE00 053C 270C  1DE4 6F7A 9091 1EA0 55D6
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2

iQIcBAEBCAAGBQJWVgmJAAoJEAEkDpRQOeFwEQIQAIoen/Ay5+fjY3mJfZn7NCKs
jrhvtaj4ZOexQ2RPt7vW1HfihtueWXWZrnkpA3wnWl5xryv++S1G9WLn/2+I3uQc
y1D63z6Cu3pet+hDdCRM57oS3kdx9DMzjWIUpkohwdxal7MTnwGgh2K4oMotX3P2
npctie/gKwUEGLipqjsOR2pwt1dVSyx5NJPboUydhQW6lBghQoj0Cmcz46niqlva
aOGn93OcTlhySrwsVzbTWS6iJm0R3Ztm2oIkDmIikqJzEJA3UzKysWnlHqw8ZmPn
HEyAqOQ7mrgKliMTcJqFkhhieTPjMUK5L8UzA6gduucAb0XumrWt7I/i0CdRKiw5
VrQw48aCR0RIZx2V3qakRk/bVuPCaSDmXH31dxF0CEs1r4FXg4fBO8/ahjna7QC+
aimRxPLWKLStJQPdo4Lr7xF0JLDjdrT/oLBdqGp+Vz646AdXBHVfdBI+zxpGRgFj
SljKvnjv5+2BDvXAZvE+tImAPJVqV1YivHdo/htKSnJhWeFCVNwhS98SqLG+PJFa
QOvp0Mz/EflHKXiHfhB5QBfiVsNGoiti2EO8tP77IwBZ0WUvCotiZKVsqfydkxr3
QWxfaGgFIPmV9++xJ//AvSnCUmSBS+8jk3kBSlY6Gxju5t7QVu+Ulxv82dLooUO7
fABFJx4Jau7/8p2K1XMW
=Ym0P
-----END PGP SIGNATURE-----


^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: [gentoo-dev] rfc: adding sbin directories to PATH for all users
  2015-11-25 19:18       ` Daniel Campbell
@ 2015-11-25 19:23         ` Michał Górny
  2015-11-25 20:16           ` Mike Gilbert
  0 siblings, 1 reply; 25+ messages in thread
From: Michał Górny @ 2015-11-25 19:23 UTC (permalink / raw
  To: Daniel Campbell; +Cc: gentoo-dev

[-- Attachment #1: Type: text/plain, Size: 1604 bytes --]

On Wed, 25 Nov 2015 11:18:34 -0800
Daniel Campbell <zlg@gentoo.org> wrote:

> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA256
> 
> On 11/25/2015 10:17 AM, Michał Górny wrote:
> > On Wed, 25 Nov 2015 19:05:13 +0100 Ulrich Mueller <ulm@gentoo.org>
> > wrote:
> >   
> >>>>>>> On Wed, 25 Nov 2015, Kristian Fiskerstrand wrote:  
> >>   
> >>> On 11/25/2015 06:10 PM, William Hubbs wrote:  
> >>>> I would like for us to discuss adding the sbin directories to
> >>>> PATH for all users.  
> >>   
> >>> This sounds strange to me, if it should be executable by all
> >>> users it likely shouldn't be in sbin in the first place but in
> >>> bin. In any case; I don't see any good reason to change the
> >>> traditional behavior of sbin only being in path for root.  
> >> 
> >> +1
> >> 
> >> The sbin directories are separate from bin for the very reason
> >> that binaries in there (which are only usable with elevated
> >> privileges) can be excluded from normal users' PATH.  
> > 
> > Binaries like blkid, btrfs, getcap, sensors, swapon and various
> > tools from net-tools, iputils, wireless-tools... and I really have
> > better things to do than list all tools that landed in sbin for
> > some fun reason yet work for normal users.
> > 
> > But well, I'm the weird one wanting to be able to check how much
> > free space I've got without going through hoops.
> >   
> 
> Maybe I'm missing something, but `df` is in /bin. Do you use something
> else to determine free space?

btrfs fi df

-- 
Best regards,
Michał Górny
<http://dev.gentoo.org/~mgorny/>

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 949 bytes --]

^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: [gentoo-dev] rfc: adding sbin directories to PATH for all users
  2015-11-25 18:51         ` Ulrich Mueller
@ 2015-11-25 19:47           ` William Hubbs
  2015-11-25 20:53             ` Ulrich Mueller
  2015-11-25 20:12           ` splite-gentoo
  1 sibling, 1 reply; 25+ messages in thread
From: William Hubbs @ 2015-11-25 19:47 UTC (permalink / raw
  To: gentoo-dev

[-- Attachment #1: Type: text/plain, Size: 861 bytes --]

On Wed, Nov 25, 2015 at 07:51:55PM +0100, Ulrich Mueller wrote:
> >>>>> On Wed, 25 Nov 2015, William Hubbs wrote:
> 
> > From what I've read, the traditional difference between bin and sbin
> > was that sbin means static-bin and everything stored in there was to
> > be able to come up without libraries.
> 
> Source/reference for this?
 
 https://news.ycombinator.com/item?id=3519952

> > As mgorny was talking about earlier, a good chunk of what is in sbin
> > *can* be run by normal users.
> 
> Then it shouldn't be in sbin, in the first place. That's a separate
> discussion though.

 Also, there is another source that talks about why the split originally
 happened and why it meant basically nothing, even before the days of
 Linux.

 http://www.osnews.com/story/25556/Understanding_the_bin_sbin_usr_bin_usr_sbin_Split/

William


[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 181 bytes --]

^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: [gentoo-dev] rfc: adding sbin directories to PATH for all users
  2015-11-25 18:51         ` Ulrich Mueller
  2015-11-25 19:47           ` William Hubbs
@ 2015-11-25 20:12           ` splite-gentoo
  1 sibling, 0 replies; 25+ messages in thread
From: splite-gentoo @ 2015-11-25 20:12 UTC (permalink / raw
  To: gentoo-dev

On Wed, Nov 25, 2015 at 07:51:55PM +0100, Ulrich Mueller wrote:
> >>>>> On Wed, 25 Nov 2015, William Hubbs wrote:
>> From what I've read, the traditional difference between bin and sbin
>> was that sbin means static-bin and everything stored in there was to
>> be able to come up without libraries.
> 
> Source/reference for this?

Some of us are old enough to remember when it happened, sonny.  It was
Sun's idea.  Disks were expensive, so they wanted as much of the OS to be
mountable read-only via NFS as possible (remember diskless workstations?
no, you probably don't), so they moved /bin and /lib to /usr and replaced
them with symlinks.  /sbin was created to hold the necessary binaries
to get /usr mounted via NFS at boot.  They had to be statically-linked
because all the shared libraries were in /usr-- hence the "s" in "sbin".

If you really want a reference, here you go (page 7):

http://chiclassiccomp.org/docs/content/computing/Sun/800-1731-10_SunOS4.0ChangeNotes9May88.pdf

>> As mgorny was talking about earlier, a good chunk of what is in sbin
>> *can* be run by normal users.
> 
> Then it shouldn't be in sbin, in the first place. That's a separate
> discussion though.

Bollocks.  The whole "/sbin is for admins" meme is an after-the-fact
fabrication by those too young to remember the original purpose for it.
(Unfortunately, that included people at Sun.)

Now, get off my lawn.


^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: [gentoo-dev] rfc: adding sbin directories to PATH for all users
  2015-11-25 20:16           ` Mike Gilbert
@ 2015-11-25 20:15             ` Kristian Fiskerstrand
  2015-11-26 15:03               ` [gentoo-dev] " Duncan
  0 siblings, 1 reply; 25+ messages in thread
From: Kristian Fiskerstrand @ 2015-11-25 20:15 UTC (permalink / raw
  To: gentoo-dev; +Cc: Daniel Campbell

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA512

On 11/25/2015 09:16 PM, Mike Gilbert wrote:
> On Wed, Nov 25, 2015 at 2:23 PM, Michał Górny <mgorny@gentoo.org>
> wrote:
>> On Wed, 25 Nov 2015 11:18:34 -0800 Daniel Campbell
>> <zlg@gentoo.org> wrote:
>>> Maybe I'm missing something, but `df` is in /bin. Do you use
>>> something else to determine free space?
>> 
>> btrfs fi df
> 
> In thins case, upstream's build system installs everything in
> bindir, which I override to /sbin. I think that's where the ebuild
> was installing things when I inherited it from the previous
> maintainer.
> 
> If William's PATH proposal is not implemented, I would be happy to 
> move it all to /bin if so desired. Just file a bug.

If moving it in the first place, wouldn't it go to /usr/bin as not
being essential to system?


- -- 
Kristian Fiskerstrand
Public PGP key 0xE3EDFAE3 at hkp://pool.sks-keyservers.net
fpr:94CB AFDD 3034 5109 5618 35AA 0B7F 8B60 E3ED FAE3
-----BEGIN PGP SIGNATURE-----

iQEcBAEBCgAGBQJWVhbkAAoJECULev7WN52FBZMIAI4Lpt4/acpXIld2Y4s+dX+p
P5pzzrPtjy76JBxwlRr0eSqwktmZfgu/4gnZUfew1ihMPrezEpZa3ulLnvNyJEfL
vWfcmSFAetcY/Txi3liX7oDqvCdm2w6EU8ffE3GRxR6SRzg8EUPALo66l6hLEqOM
7DKdRNBCIOG5TLOHLt1WVq9nbcuePVbA46JCCWhTdF1MTV2eWXx45vT3OxRvZbkd
szHOezMBVg/YrSQcapWF6OaPw4qt9hcyPep/w284n9BE8mbP0eHCMFl0pJ3kMmwE
nsanXA8l4kOjsJPeX6FgO2G89AJib/0pEAMgjUlDtsVHmsPsrz3MxfhBNHATsXg=
=oZ3P
-----END PGP SIGNATURE-----


^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: [gentoo-dev] rfc: adding sbin directories to PATH for all users
  2015-11-25 19:23         ` Michał Górny
@ 2015-11-25 20:16           ` Mike Gilbert
  2015-11-25 20:15             ` Kristian Fiskerstrand
  0 siblings, 1 reply; 25+ messages in thread
From: Mike Gilbert @ 2015-11-25 20:16 UTC (permalink / raw
  To: Gentoo Dev; +Cc: Daniel Campbell

On Wed, Nov 25, 2015 at 2:23 PM, Michał Górny <mgorny@gentoo.org> wrote:
> On Wed, 25 Nov 2015 11:18:34 -0800
> Daniel Campbell <zlg@gentoo.org> wrote:
>> Maybe I'm missing something, but `df` is in /bin. Do you use something
>> else to determine free space?
>
> btrfs fi df

In thins case, upstream's build system installs everything in bindir,
which I override to /sbin. I think that's where the ebuild was
installing things when I inherited it from the previous maintainer.

If William's PATH proposal is not implemented, I would be happy to
move it all to /bin if so desired. Just file a bug.


^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: [gentoo-dev] rfc: adding sbin directories to PATH for all users
  2015-11-25 18:58 ` Mike Gilbert
@ 2015-11-25 20:42   ` Anthony G. Basile
  2015-11-26 16:37   ` Peter Stuge
  1 sibling, 0 replies; 25+ messages in thread
From: Anthony G. Basile @ 2015-11-25 20:42 UTC (permalink / raw
  To: gentoo-dev

On 11/25/15 1:58 PM, Mike Gilbert wrote:
> On Wed, Nov 25, 2015 at 12:10 PM, William Hubbs <williamh@gentoo.org> wrote:
>> All,
>>
>> I would like for us to discuss adding the sbin directories to PATH for
>> all users.
> I support this idea. The distinction between bin and sbin is stupid.
>
I'm okay with this.  Should we do the same for /usr/bin and /usr/sbin ?

-- 
Anthony G. Basile, Ph.D.
Gentoo Linux Developer [Hardened]
E-Mail    : blueness@gentoo.org
GnuPG FP  : 1FED FAD9 D82C 52A5 3BAB  DC79 9384 FA6E F52D 4BBA
GnuPG ID  : F52D4BBA



^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: [gentoo-dev] rfc: adding sbin directories to PATH for all users
  2015-11-25 19:47           ` William Hubbs
@ 2015-11-25 20:53             ` Ulrich Mueller
  2015-11-25 21:39               ` William Hubbs
  0 siblings, 1 reply; 25+ messages in thread
From: Ulrich Mueller @ 2015-11-25 20:53 UTC (permalink / raw
  To: gentoo-dev

[-- Attachment #1: Type: text/plain, Size: 668 bytes --]

>>>>> On Wed, 25 Nov 2015, William Hubbs wrote:

>> > From what I've read, the traditional difference between bin and sbin
>> > was that sbin means static-bin and everything stored in there was to
>> > be able to come up without libraries.
>> 
>> Source/reference for this?
 
> https://news.ycombinator.com/item?id=3519952

Hm, SunOS end of 1980s. Soon after (Solaris 2.0 ca. 1992) they
switched to the current meaning and had executables in /usr/sbin
"to be run only by system administrators":
https://docs.oracle.com/cd/E26505_01/html/816-5175/filesystem-5.html

Anyway, whatever the history is, I guess we should go with the current
FHS definition of sbin.

Ulrich

[-- Attachment #2: Type: application/pgp-signature, Size: 490 bytes --]

^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: [gentoo-dev] rfc: adding sbin directories to PATH for all users
  2015-11-25 20:53             ` Ulrich Mueller
@ 2015-11-25 21:39               ` William Hubbs
  0 siblings, 0 replies; 25+ messages in thread
From: William Hubbs @ 2015-11-25 21:39 UTC (permalink / raw
  To: gentoo-dev

[-- Attachment #1: Type: text/plain, Size: 844 bytes --]

On Wed, Nov 25, 2015 at 09:53:47PM +0100, Ulrich Mueller wrote:
> >>>>> On Wed, 25 Nov 2015, William Hubbs wrote:
> 
> >> > From what I've read, the traditional difference between bin and sbin
> >> > was that sbin means static-bin and everything stored in there was to
> >> > be able to come up without libraries.
> >> 
> >> Source/reference for this?
>  
> > https://news.ycombinator.com/item?id=3519952
> 
> Hm, SunOS end of 1980s. Soon after (Solaris 2.0 ca. 1992) they
> switched to the current meaning and had executables in /usr/sbin
> "to be run only by system administrators":
> https://docs.oracle.com/cd/E26505_01/html/816-5175/filesystem-5.html
 
Solaris was also the first *nix to adopt the /usr merge (/bin /sbin and
/usr/sbin all are just links to /usr/bin), but that's a topic for
another thread.

William


[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 181 bytes --]

^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: [gentoo-dev] rfc: adding sbin directories to PATH for all users
  2015-11-25 17:10 [gentoo-dev] rfc: adding sbin directories to PATH for all users William Hubbs
                   ` (3 preceding siblings ...)
  2015-11-25 19:17 ` Nicolas Sebrecht
@ 2015-11-25 21:39 ` Andrew Savchenko
  2015-11-26  3:58   ` Mike Gilbert
  4 siblings, 1 reply; 25+ messages in thread
From: Andrew Savchenko @ 2015-11-25 21:39 UTC (permalink / raw
  To: gentoo-dev

[-- Attachment #1: Type: text/plain, Size: 1125 bytes --]

On Wed, 25 Nov 2015 11:10:11 -0600 William Hubbs wrote:
> All,
> 
> I would like for us to discuss adding the sbin directories to PATH for
> all users.
> 
> The only reason I can think of that we have removed them is cosmetic (it
> removes things from tab completion), but I have also heard that having
> those things in tab completion would be a good thing.
> 
> Another reason I am bringing this up is this bug [1]. On standard OSx,
> there is no reason to hard code the path to sysctl like I'm being asked
> to do in the patch associated with this bug, because the sbin
> directories are always  in the path. In other words, it isn't worth the
> effort to send this patch upstream, which means there will always be a
> Gentoo-specific patch to dev-lang/go unless upstream finds another way
> to do the test they are doing on OSx via sysctl.
> 
> Any ideas?

+1. Just do it.

I add /sbin and /usr/sbin in PATH on all Gentoo setups for ages.
Too many useful tools are there. Though, add them after /bin
and /usr/sbin for non-priviledged users and before for root.

Best regards,
Andrew Savchenko

[-- Attachment #2: Type: application/pgp-signature, Size: 819 bytes --]

^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: [gentoo-dev] rfc: adding sbin directories to PATH for all users
  2015-11-25 21:39 ` Andrew Savchenko
@ 2015-11-26  3:58   ` Mike Gilbert
  0 siblings, 0 replies; 25+ messages in thread
From: Mike Gilbert @ 2015-11-26  3:58 UTC (permalink / raw
  To: Gentoo Dev

On Wed, Nov 25, 2015 at 4:39 PM, Andrew Savchenko <bircoph@gentoo.org> wrote:
> On Wed, 25 Nov 2015 11:10:11 -0600 William Hubbs wrote:
>> All,
>>
>> I would like for us to discuss adding the sbin directories to PATH for
>> all users.
>>
>> The only reason I can think of that we have removed them is cosmetic (it
>> removes things from tab completion), but I have also heard that having
>> those things in tab completion would be a good thing.
>>
>> Another reason I am bringing this up is this bug [1]. On standard OSx,
>> there is no reason to hard code the path to sysctl like I'm being asked
>> to do in the patch associated with this bug, because the sbin
>> directories are always  in the path. In other words, it isn't worth the
>> effort to send this patch upstream, which means there will always be a
>> Gentoo-specific patch to dev-lang/go unless upstream finds another way
>> to do the test they are doing on OSx via sysctl.
>>
>> Any ideas?
>
> +1. Just do it.
>
> I add /sbin and /usr/sbin in PATH on all Gentoo setups for ages.
> Too many useful tools are there. Though, add them after /bin
> and /usr/sbin for non-priviledged users and before for root.

Swapping the order is silly and should be pointless. If we are
installing different binaries with the same name in bin/sbin, that's a
bug that needs fixing.


^ permalink raw reply	[flat|nested] 25+ messages in thread

* [gentoo-dev] Re: rfc: adding sbin directories to PATH for all users
  2015-11-25 20:15             ` Kristian Fiskerstrand
@ 2015-11-26 15:03               ` Duncan
  2015-11-26 15:10                 ` Alan McKinnon
  0 siblings, 1 reply; 25+ messages in thread
From: Duncan @ 2015-11-26 15:03 UTC (permalink / raw
  To: gentoo-dev

Kristian Fiskerstrand posted on Wed, 25 Nov 2015 21:15:37 +0100 as
excerpted:

> On 11/25/2015 09:16 PM, Mike Gilbert wrote:
>> On Wed, Nov 25, 2015 at 2:23 PM, Michał Górny <mgorny@gentoo.org>
>> wrote:
>>> On Wed, 25 Nov 2015 11:18:34 -0800 Daniel Campbell <zlg@gentoo.org>
>>> wrote:
>>>> Maybe I'm missing something, but `df` is in /bin. Do you use
>>>> something else to determine free space?
>>> 
>>> btrfs fi df
>> 
>> In thins case, upstream's build system installs everything in bindir,
>> which I override to /sbin. I think that's where the ebuild was
>> installing things when I inherited it from the previous maintainer.
>> 
>> If William's PATH proposal is not implemented, I would be happy to move
>> it all to /bin if so desired. Just file a bug.
> 
> If moving it in the first place, wouldn't it go to /usr/bin as not being
> essential to system?

It's essential to system, as btrfs device scan is needed before mounting 
a multi-device btrfs, and btrfs check is a an fsck that may be needed to 
fix a broken btrfs /usr/ mount.

Else reiserfsck, e2fsck, fsck itself, and others, should be in /usr/sbin, 
not in /sbin/.

btrfs is the general userspace binary.  Subcommands such as check and 
device scan require device privs and don't normally work when run as 
ordinary users, but some subcommands such as filesystem df don't need 
device privs and work just fine when run as ordinary users.

(Not that I particularly care about the topic of the thread in general, 
as here: /sbin -> bin, /usr -> ., so all four locations, /bin, /sbin,
/usr/bin, /usr/sbin, point to the same single /bin, and I no longer have 
to worry about which dir something's in, unless I'm checking the 
canonical path as installed by the package, for which equery belongs 
works nicely.  But I'm a btrs user and upstream btrfs list regular so I 
care about that angle, thus this reply. =:^)

-- 
Duncan - List replies preferred.   No HTML msgs.
"Every nonfree program has a lord, a master --
and if you use the program, he is your master."  Richard Stallman



^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: [gentoo-dev] Re: rfc: adding sbin directories to PATH for all users
  2015-11-26 15:03               ` [gentoo-dev] " Duncan
@ 2015-11-26 15:10                 ` Alan McKinnon
  0 siblings, 0 replies; 25+ messages in thread
From: Alan McKinnon @ 2015-11-26 15:10 UTC (permalink / raw
  To: gentoo-dev

On 26/11/2015 17:03, Duncan wrote:
> Kristian Fiskerstrand posted on Wed, 25 Nov 2015 21:15:37 +0100 as
> excerpted:
> 
>> On 11/25/2015 09:16 PM, Mike Gilbert wrote:
>>> On Wed, Nov 25, 2015 at 2:23 PM, Michał Górny <mgorny@gentoo.org>
>>> wrote:
>>>> On Wed, 25 Nov 2015 11:18:34 -0800 Daniel Campbell <zlg@gentoo.org>
>>>> wrote:
>>>>> Maybe I'm missing something, but `df` is in /bin. Do you use
>>>>> something else to determine free space?
>>>>
>>>> btrfs fi df
>>>
>>> In thins case, upstream's build system installs everything in bindir,
>>> which I override to /sbin. I think that's where the ebuild was
>>> installing things when I inherited it from the previous maintainer.
>>>
>>> If William's PATH proposal is not implemented, I would be happy to move
>>> it all to /bin if so desired. Just file a bug.
>>
>> If moving it in the first place, wouldn't it go to /usr/bin as not being
>> essential to system?
> 
> It's essential to system, as btrfs device scan is needed before mounting 
> a multi-device btrfs, and btrfs check is a an fsck that may be needed to 
> fix a broken btrfs /usr/ mount.
> 
> Else reiserfsck, e2fsck, fsck itself, and others, should be in /usr/sbin, 
> not in /sbin/.
> 
> btrfs is the general userspace binary.  Subcommands such as check and 
> device scan require device privs and don't normally work when run as 
> ordinary users, but some subcommands such as filesystem df don't need 
> device privs and work just fine when run as ordinary users.
> 
> (Not that I particularly care about the topic of the thread in general, 
> as here: /sbin -> bin, /usr -> ., so all four locations, /bin, /sbin,
> /usr/bin, /usr/sbin, point to the same single /bin, and I no longer have 
> to worry about which dir something's in, unless I'm checking the 
> canonical path as installed by the package, for which equery belongs 
> works nicely.  But I'm a btrs user and upstream btrfs list regular so I 
> care about that angle, thus this reply. =:^)


Picking a random (i.e. most recent) post to reply to.

I don't really care what the default PATH is, I always set it to my
liking anyway. I understand all the historical arguments but I don't
think they matter too much these days anymore as times and OSes do change.

I feel that the / vs /usr split is rather pointless on modern systems,
but I do like the bin vs sbin split because it makes my life easier
(which is the entire point of any env var when you think about it). When
working as a user I'd rather not have my tab completion results
cluttered with apps I have to be root to use properly.

I vote to leave things as they are, and I also vote for showing people
who don;t like it how to change $PATH

-- 
Alan McKinnon
alan.mckinnon@gmail.com



^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: [gentoo-dev] rfc: adding sbin directories to PATH for all users
  2015-11-25 18:58 ` Mike Gilbert
  2015-11-25 20:42   ` Anthony G. Basile
@ 2015-11-26 16:37   ` Peter Stuge
  1 sibling, 0 replies; 25+ messages in thread
From: Peter Stuge @ 2015-11-26 16:37 UTC (permalink / raw
  To: gentoo-dev

Mike Gilbert wrote:
> > I would like for us to discuss adding the sbin directories to PATH for
> > all users.
> 
> I support this idea. The distinction between bin and sbin is stupid.

I support it too FWIW.


//Peter


^ permalink raw reply	[flat|nested] 25+ messages in thread

end of thread, other threads:[~2015-11-26 16:37 UTC | newest]

Thread overview: 25+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-11-25 17:10 [gentoo-dev] rfc: adding sbin directories to PATH for all users William Hubbs
2015-11-25 17:24 ` Michael Orlitzky
2015-11-25 17:36 ` Kristian Fiskerstrand
2015-11-25 18:05   ` Ulrich Mueller
2015-11-25 18:17     ` Michał Górny
2015-11-25 19:18       ` Daniel Campbell
2015-11-25 19:23         ` Michał Górny
2015-11-25 20:16           ` Mike Gilbert
2015-11-25 20:15             ` Kristian Fiskerstrand
2015-11-26 15:03               ` [gentoo-dev] " Duncan
2015-11-26 15:10                 ` Alan McKinnon
2015-11-25 18:14   ` [gentoo-dev] " William Hubbs
2015-11-25 18:31     ` Ulrich Mueller
2015-11-25 18:38       ` William Hubbs
2015-11-25 18:51         ` Ulrich Mueller
2015-11-25 19:47           ` William Hubbs
2015-11-25 20:53             ` Ulrich Mueller
2015-11-25 21:39               ` William Hubbs
2015-11-25 20:12           ` splite-gentoo
2015-11-25 18:58 ` Mike Gilbert
2015-11-25 20:42   ` Anthony G. Basile
2015-11-26 16:37   ` Peter Stuge
2015-11-25 19:17 ` Nicolas Sebrecht
2015-11-25 21:39 ` Andrew Savchenko
2015-11-26  3:58   ` Mike Gilbert

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox