tech-kern archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: makesyscalls (moving forward)



On 2020-06-15 15:39, Kamil Rytarowski wrote:
On 15.06.2020 15:21, Johnny Billquist wrote:

Anyway. Who here does not modify their path at login anyway.

The path has to be readily available for pkgsrc users with unprepared
environment.

However if we install the utility into /usr/sys (similar to /usr/games),
we can use a full path to the program and it will be good enough (for
me). Are there other programs that would be moved to this directory?

Using explicit paths is sometimes a good idea no matter what.

Obviously I think something like config should be moved out.

I would tend to look at /sbin as where tools required to manage the system or get information which "normal" users commonly would not care about. /bin would be where things a large portion of ignorant users programs could be found. Even things like compilers would make sense to have there, as also things like passwd. However, ifconfig for example I would keep out. If can be used even by normal users, in order to look at interface details, but it's outside of what I think a naive user would go for. Same for arp.

However, things needed to build kernel and userland is neither normal user tools, nor system administration tools in the normal sense, so neither /bin, nor /sbin really feels like the right place.

/sys would make more sense, but I'm not totally clear about if there are aspects I haven't thought about yet.

(And I'm currently saying /bin, /sbin and so on, without adding the corresponding /usr/... paths. Traditionally, the things under root were things you expected to need to be able to do without even having file systems mounted and so on, and I like that distinction. So I guess most things related to system building would only need to be in /usr/sys, if that was the path we'd go for.)

I have got a feeling that too many programs already rely on specific
kernel internals so making a distinction would only confuse people and
impose unclear conditions what belongs where. fsdb(8) or crash(8) are
definitely not going to be very usable with mixed kernel and userland
versions.

Something we possibly agree upon is that makesyscalls(1) would not be a
tool for administer a computer/server, so /usr/sbin /sbin is not a good
place.

I agree that /sbin also does not feel natural for makesyscalls. If I were to have to choose between /bin or /sbin, I would however go for /sbin. I have less issues creating kindof weird views for a system admin, which I expect should know a little more about what he is doing and why, than an ignorant user, for which I think a cohesive and meaningful environment is the most important. As such, something like this under /bin would just be a very confusing and not useful tool for that user.

It all boils down to what the purpose of the different directories are. And I cannot agree that things under /sbin should somehow only be tools for root, or required that you are root. It is in a different directory than /bin so that it don't have to be in the path of various people. If we are not interested in that path separation/distinction then we do not need the separate directories at all. /sbin for tools that mainly system admin tools sits in, do make sense. Even hinted at, if you read sbin as system binaries.

But there are just some tools that are very specific to kernel development, and that is really a kind of binaries for which I don't think we have a good place right now. /libexec is another interesting place, but I consider that to be a place where binaries that are invoked by other binaries are located. And your description of your planned use of makesyscall makes it sound like you are planning to use it directly, and not just have it as a binary invoked by other tools...

  Johnny

--
Johnny Billquist                  || "I'm on a bus
                                  ||  on a psychedelic trip
email: bqt%softjar.se@localhost             ||  Reading murder books
pdp is alive!                     ||  tryin' to stay hip" - B. Idol


Home | Main Index | Thread Index | Old Index