• Re: Faking a TTY on a pipe/socketpair

    From rlhamil@rlhamil@smart.net (Richard L. Hamilton) to comp.unix.programmer on Tue Dec 3 05:29:51 2024
    From Newsgroup: comp.unix.programmer

    In article <vh9vgr$5bb$1@dont-email.me>,
    Muttley@dastardlyhq.com writes:
    There is a command line util (MacOS "say")* that I wish to use fork-exec'd from
    my own program and send data to it via a socket created by socketpair(). Unfortunately "say" behaves differently depending on whether its stdin is attached to a tty or not (and there's no cmd line option to prevent this). With the former it'll speak after every newline, with the latter not until it
    gets an EOF and I'd rather not do a fork-exec for each individual word or phrase that needs to be spoken.

    So my question is - is there a way to set up a pipe or socketpair** so that it appears to be a tty from the exec'd programs point of view, eg ttyname() returns non null?

    * The MacOS speech API is Objective-C only and completely obtuse.

    ** Yes I know about the master-slave ptm,pts approach and I have done that in
    the past but its complete overkill for this purpose.

    Thanks for any help



    Not on a Mac. Use "expect" which does the pts/pty stuff for you.

    (on a system where pipes are STREAMS based, it might be possible
    to come up with a module that made a pipe pretend on one side to be a tty;
    but you'd have to get into some nasty kernel coding to do that)
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Muttley@Muttley@DastardlyHQ.org to comp.unix.programmer on Tue Dec 3 08:20:51 2024
    From Newsgroup: comp.unix.programmer

    On Tue, 03 Dec 2024 05:29:51 GMT
    rlhamil@smart.net (Richard L. Hamilton) wibbled:
    In article <vh9vgr$5bb$1@dont-email.me>,
    Muttley@dastardlyhq.com writes:
    There is a command line util (MacOS "say")* that I wish to use fork-exec'd >from
    my own program and send data to it via a socket created by socketpair().
    Unfortunately "say" behaves differently depending on whether its stdin is >> attached to a tty or not (and there's no cmd line option to prevent this). >> With the former it'll speak after every newline, with the latter not until >it
    gets an EOF and I'd rather not do a fork-exec for each individual word or
    phrase that needs to be spoken.

    So my question is - is there a way to set up a pipe or socketpair** so that >> it appears to be a tty from the exec'd programs point of view, eg ttyname() >> returns non null?

    * The MacOS speech API is Objective-C only and completely obtuse.

    ** Yes I know about the master-slave ptm,pts approach and I have done that >in
    the past but its complete overkill for this purpose.

    Thanks for any help



    Not on a Mac. Use "expect" which does the pts/pty stuff for you.

    (on a system where pipes are STREAMS based, it might be possible
    to come up with a module that made a pipe pretend on one side to be a tty; >but you'd have to get into some nasty kernel coding to do that)

    I'm wondering on Linux if it would be enough on Linux to spoof ttyname() and isatty() using LD_PRELOAD. However it seems doing something similar on a Mac
    is the usual over complicated Apple hot mess.

    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Richard Kettlewell@invalid@invalid.invalid to comp.unix.programmer on Tue Dec 3 08:38:09 2024
    From Newsgroup: comp.unix.programmer

    rlhamil@smart.net (Richard L. Hamilton) writes:
    (on a system where pipes are STREAMS based, it might be possible to
    come up with a module that made a pipe pretend on one side to be a
    tty; but you'd have to get into some nasty kernel coding to do that)

    That seems like more work than just using a pty, which the OP already
    ruled out.
    --
    https://www.greenend.org.uk/rjk/
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From scott@scott@slp53.sl.home (Scott Lurndal) to comp.unix.programmer on Tue Dec 3 14:22:10 2024
    From Newsgroup: comp.unix.programmer

    rlhamil@smart.net (Richard L. Hamilton) writes:
    In article <vh9vgr$5bb$1@dont-email.me>,
    Muttley@dastardlyhq.com writes:
    There is a command line util (MacOS "say")* that I wish to use fork-exec'd from
    my own program and send data to it via a socket created by socketpair().
    Unfortunately "say" behaves differently depending on whether its stdin is >> attached to a tty or not (and there's no cmd line option to prevent this). >> With the former it'll speak after every newline, with the latter not until it
    gets an EOF and I'd rather not do a fork-exec for each individual word or
    phrase that needs to be spoken.

    So my question is - is there a way to set up a pipe or socketpair** so that >> it appears to be a tty from the exec'd programs point of view, eg ttyname() >> returns non null?

    * The MacOS speech API is Objective-C only and completely obtuse.

    ** Yes I know about the master-slave ptm,pts approach and I have done that in
    the past but its complete overkill for this purpose.

    Thanks for any help



    Not on a Mac. Use "expect" which does the pts/pty stuff for you.

    (on a system where pipes are STREAMS based, it might be possible
    to come up with a module that made a pipe pretend on one side to be a tty; >but you'd have to get into some nasty kernel coding to do that)

    SVR4.2 included the 'strtty' streams module to support similar
    scenarios, if I recall correctly.
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Lawrence D'Oliveiro@ldo@nz.invalid to comp.unix.programmer on Tue Dec 3 20:21:27 2024
    From Newsgroup: comp.unix.programmer

    On Tue, 3 Dec 2024 08:20:51 -0000 (UTC), Muttley wrote:

    I'm wondering on Linux if it would be enough on Linux to spoof ttyname()
    and isatty() using LD_PRELOAD. However it seems doing something similar
    on a Mac is the usual over complicated Apple hot mess.

    macOS may be a licensee of the rCLUnixrCY trademark, but it does not work the way people expect when they think of the term rCLUnixrCY.
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Muttley@Muttley@DastardlyHQ.org to comp.unix.programmer on Wed Dec 4 08:34:30 2024
    From Newsgroup: comp.unix.programmer

    On Tue, 3 Dec 2024 20:21:27 -0000 (UTC)
    Lawrence D'Oliveiro <ldo@nz.invalid> wibbled:
    On Tue, 3 Dec 2024 08:20:51 -0000 (UTC), Muttley wrote:

    I'm wondering on Linux if it would be enough on Linux to spoof ttyname()
    and isatty() using LD_PRELOAD. However it seems doing something similar
    on a Mac is the usual over complicated Apple hot mess.

    macOS may be a licensee of the rCLUnixrCY trademark, but it does not work the >way people expect when they think of the term rCLUnixrCY.

    Yes, it certainly has its quirks. Linux is far closer to the unix philosphy (ignoring systemd) despite not being an official unix.

    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Lawrence D'Oliveiro@ldo@nz.invalid to comp.unix.programmer on Thu Dec 5 02:11:04 2024
    From Newsgroup: comp.unix.programmer

    On Wed, 4 Dec 2024 08:34:30 -0000 (UTC), Muttley wrote:

    Linux is far closer to the unix philosphy (ignoring systemd) ...

    Which rCLunix philosophyrCY would that be?
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From gazelle@gazelle@shell.xmission.com (Kenny McCormack) to comp.unix.programmer on Thu Dec 5 06:44:12 2024
    From Newsgroup: comp.unix.programmer

    In article <vir23n$17csf$5@dont-email.me>,
    Lawrence D'Oliveiro <ldo@nz.invalid> wrote:
    On Wed, 4 Dec 2024 08:34:30 -0000 (UTC), Muttley wrote:

    Linux is far closer to the unix philosphy (ignoring systemd) ...

    Which "unix philosophy" would that be?

    Wouldn't it be easier to just use Google (or whatever search engine you
    favor) to find out what the Unix philosphy is?
    --
    Debating creationists on the topic of evolution is rather like trying to
    play chess with a pigeon --- it knocks the pieces over, craps on the
    board, and flies back to its flock to claim victory.
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Nicolas George@nicolas$george@salle-s.org to comp.unix.programmer on Thu Dec 5 08:01:03 2024
    From Newsgroup: comp.unix.programmer

    Lawrence D'Oliveiro , dans le message <vir23n$17csf$5@dont-email.me>, a
    |-crit-a:
    Which rCLunix philosophyrCY would that be?

    The one that leads to software that rCLwork the way people expect when they think of the term rCLUnixrCYrCY. I wonder who wrote the expression I quoted. --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Muttley@Muttley@DastardlyHQ.org to comp.unix.programmer on Thu Dec 5 08:19:46 2024
    From Newsgroup: comp.unix.programmer

    On Thu, 5 Dec 2024 02:11:04 -0000 (UTC)
    Lawrence D'Oliveiro <ldo@nz.invalid> wibbled:
    On Wed, 4 Dec 2024 08:34:30 -0000 (UTC), Muttley wrote:

    Linux is far closer to the unix philosphy (ignoring systemd) ...

    Which rCLunix philosophyrCY would that be?

    The one where init does a single task instead of spreading itself throughout the system after massive scope creep and hence isn't a huge attack vector for hackers and a single point of failure, plus doesn't use obtuse binary files for
    logging which require tools to read. init needed an upgrade for sure, but systemd isn't it.

    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From cross@cross@spitfire.i.gajendra.net (Dan Cross) to comp.unix.programmer on Thu Dec 5 13:15:03 2024
    From Newsgroup: comp.unix.programmer

    In article <viri3s$1ac00$1@news.xmission.com>,
    Kenny McCormack <gazelle@shell.xmission.com> wrote:
    In article <vir23n$17csf$5@dont-email.me>,
    Lawrence D'Oliveiro <ldo@nz.invalid> wrote:
    On Wed, 4 Dec 2024 08:34:30 -0000 (UTC), Muttley wrote:

    Linux is far closer to the unix philosphy (ignoring systemd) ...

    Which "unix philosophy" would that be?

    Wouldn't it be easier to just use Google (or whatever search engine you >favor) to find out what the Unix philosphy is?

    Why do people continue to try and engage with Lawrence in good
    faith? He's a rather obvious troll.

    - Dan C.

    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From gazelle@gazelle@shell.xmission.com (Kenny McCormack) to comp.unix.programmer on Thu Dec 5 13:57:20 2024
    From Newsgroup: comp.unix.programmer

    In article <vis90n$5d5$1@reader2.panix.com>,
    Dan Cross <cross@spitfire.i.gajendra.net> wrote:
    In article <viri3s$1ac00$1@news.xmission.com>,
    Kenny McCormack <gazelle@shell.xmission.com> wrote:
    In article <vir23n$17csf$5@dont-email.me>,
    Lawrence D'Oliveiro <ldo@nz.invalid> wrote:
    On Wed, 4 Dec 2024 08:34:30 -0000 (UTC), Muttley wrote:

    Linux is far closer to the unix philosphy (ignoring systemd) ...

    Which "unix philosophy" would that be?

    Wouldn't it be easier to just use Google (or whatever search engine you >>favor) to find out what the Unix philosphy is?

    Why do people continue to try and engage with Lawrence in good
    faith? He's a rather obvious troll.

    Yes, well, you make a good point. But it passes the time.

    One could argue that I wasn't exactly engaging in good faith.
    I was making the point that he wasn't arguing in good faith; his question
    is obvious trollery, not a legitimate question. If it *were* a legitimate question, then Googling would give him his answer. But it isn't, so it won't.,.
    --
    You are a dreadful man, Kenny, for all your ways are the ways of death.
    - Rick C Hodgin -

    (P.S. -> https://www.youtube.com/watch?v=sMmTkKz60W8)
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Muttley@Muttley@DastardlyHQ.org to comp.unix.programmer on Thu Dec 5 15:06:27 2024
    From Newsgroup: comp.unix.programmer

    On Thu, 5 Dec 2024 13:57:20 -0000 (UTC)
    gazelle@shell.xmission.com (Kenny McCormack) wibbled:
    In article <vis90n$5d5$1@reader2.panix.com>,
    Dan Cross <cross@spitfire.i.gajendra.net> wrote:
    is obvious trollery, not a legitimate question. If it *were* a legitimate >question, then Googling would give him his answer. But it isn't, so it >won't.,.

    To be fair, if google had the answer to everything no one would ever post on here again.

    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Lawrence D'Oliveiro@ldo@nz.invalid to comp.unix.programmer on Thu Dec 5 20:46:07 2024
    From Newsgroup: comp.unix.programmer

    On Thu, 5 Dec 2024 08:19:46 -0000 (UTC), Muttley wrote:

    On Thu, 5 Dec 2024 02:11:04 -0000 (UTC)
    Lawrence D'Oliveiro <ldo@nz.invalid> wibbled:

    On Wed, 4 Dec 2024 08:34:30 -0000 (UTC), Muttley wrote:

    Linux is far closer to the unix philosphy (ignoring systemd) ...

    Which rCLunix philosophyrCY would that be?

    The one where init does a single task instead of spreading itself
    throughout the system ...

    What rCLsingle taskrCY did init do?

    * Mount filesystems
    * Spawn syslog, cron
    * Spawn terminal login processes (getty)
    * Respawn terminated getty processes
    * Monitor other special stuff in inittab
    * Spawn random other services, without monitoring their state
    * Act as a general catch-all for orphaned processes when they terminate

    This was all before systemd came on the scene.
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Lawrence D'Oliveiro@ldo@nz.invalid to comp.unix.programmer on Thu Dec 5 20:45:36 2024
    From Newsgroup: comp.unix.programmer

    On Thu, 5 Dec 2024 08:19:46 -0000 (UTC), Muttley wrote:

    On Thu, 5 Dec 2024 02:11:04 -0000 (UTC)
    Lawrence D'Oliveiro <ldo@nz.invalid> wibbled:

    On Wed, 4 Dec 2024 08:34:30 -0000 (UTC), Muttley wrote:

    Linux is far closer to the unix philosphy (ignoring systemd) ...

    Which rCLunix philosophyrCY would that be?

    The one where init does a single task instead of spreading itself
    throughout the system ...

    What rCLsingle taskrCY did init do?

    * Mount filesystems
    * Spawn syslog, cron
    * Spawn terminal login processes (getty)
    * Respawn terminated getty processes
    * Monitor other special stuff in inittab
    * Spawn random other services, without monitoring their state
    * Act as a general catch-all for orphaned processes when they terminate

    This was all before systemd came on the scene.
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From scott@scott@slp53.sl.home (Scott Lurndal) to comp.unix.programmer on Thu Dec 5 21:06:41 2024
    From Newsgroup: comp.unix.programmer

    Lawrence D'Oliveiro <ldo@nz.invalid> writes:
    On Thu, 5 Dec 2024 08:19:46 -0000 (UTC), Muttley wrote:

    On Thu, 5 Dec 2024 02:11:04 -0000 (UTC)
    Lawrence D'Oliveiro <ldo@nz.invalid> wibbled:

    On Wed, 4 Dec 2024 08:34:30 -0000 (UTC), Muttley wrote:

    Linux is far closer to the unix philosphy (ignoring systemd) ...

    Which rCLunix philosophyrCY would that be?

    The one where init does a single task instead of spreading itself
    throughout the system ...

    What rCLsingle taskrCY did init do?

    Read a bunch of files and call the shell to execute them
    whenever the run-level changed and monitored the resulting
    processes for failure.

    And reaped zombies.
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Muttley@Muttley@DastardlyHQ.org to comp.unix.programmer on Fri Dec 6 10:28:15 2024
    From Newsgroup: comp.unix.programmer

    On Thu, 5 Dec 2024 20:45:36 -0000 (UTC)
    Lawrence D'Oliveiro <ldo@nz.invalid> wibbled:
    On Thu, 5 Dec 2024 08:19:46 -0000 (UTC), Muttley wrote:

    On Thu, 5 Dec 2024 02:11:04 -0000 (UTC)
    Lawrence D'Oliveiro <ldo@nz.invalid> wibbled:

    On Wed, 4 Dec 2024 08:34:30 -0000 (UTC), Muttley wrote:

    Linux is far closer to the unix philosphy (ignoring systemd) ...

    Which rCLunix philosophyrCY would that be?

    The one where init does a single task instead of spreading itself
    throughout the system ...

    What rCLsingle taskrCY did init do?

    Boot the system to usable state. You can't have that without filesystems, terminals or other important system daemons running.

    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Rainer Weikusat@rweikusat@talktalk.net to comp.unix.programmer on Fri Dec 6 17:01:49 2024
    From Newsgroup: comp.unix.programmer

    Lawrence D'Oliveiro <ldo@nz.invalid> writes:
    On Thu, 5 Dec 2024 08:19:46 -0000 (UTC), Muttley wrote:

    On Thu, 5 Dec 2024 02:11:04 -0000 (UTC)
    Lawrence D'Oliveiro <ldo@nz.invalid> wibbled:

    On Wed, 4 Dec 2024 08:34:30 -0000 (UTC), Muttley wrote:

    Linux is far closer to the unix philosphy (ignoring systemd) ...

    Which rCLunix philosophyrCY would that be?

    The one where init does a single task instead of spreading itself
    throughout the system ...

    What rCLsingle taskrCY did init do?

    * Mount filesystems
    * Spawn syslog, cron
    * Spawn terminal login processes (getty)
    * Respawn terminated getty processes
    * Monitor other special stuff in inittab
    * Spawn random other services, without monitoring their state
    * Act as a general catch-all for orphaned processes when they terminate

    This was all before systemd came on the scene.

    Originally, mainly two things: Execute a script to kick off userspace
    boot. Call wait in a loop in order to reap zombies.

    System V init is somewhat more complicated than that. It has a concept
    of numbered run levels and will run a configurable command in response
    to runlevel change request. On linux, that's usually the script
    /etc/init.d/rc. It also has some process monitoring capabilities: It can
    start programs depending on the current runlevel and restart them when
    they terminate. This is typically used to run getty processes for real
    or virtual terminals and serial lines connected to modems.

    Minus some handling of special situations (power failure, ctrl-alt-del
    on PCs), that's it. Anything beyond that is done by the rc script.

    One could argue that this is already a case of creature feep as process monitoring and restarting of terminated processes and many other
    process invocation management tasks can as well be provided
    by dedicated programs. There's no reason to hack all of this (or rather,
    some random subset of what could be provided here) into a single
    codebase save developer inertia: It's less work to add code to a file
    that's already compiled by some build system or to add a new file to a
    code base which already has a build system than to create lots of
    different, specialized tools.
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Lawrence D'Oliveiro@ldo@nz.invalid to comp.unix.programmer on Fri Dec 6 20:00:54 2024
    From Newsgroup: comp.unix.programmer

    On Fri, 6 Dec 2024 10:28:15 -0000 (UTC), Muttley wrote:

    On Thu, 5 Dec 2024 20:45:36 -0000 (UTC)
    Lawrence D'Oliveiro <ldo@nz.invalid> wibbled:

    What rCLsingle taskrCY did init do?

    Boot the system to usable state.

    What would you say systemd does that is not related to that?
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From John Ames@commodorejohn@gmail.com to comp.unix.programmer on Fri Dec 6 12:37:26 2024
    From Newsgroup: comp.unix.programmer

    On Fri, 6 Dec 2024 20:00:54 -0000 (UTC)
    Lawrence D'Oliveiro <ldo@nz.invalid> wrote:

    What would you say systemd does that is not related to that?

    QR codes?

    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From scott@scott@slp53.sl.home (Scott Lurndal) to comp.unix.programmer on Fri Dec 6 22:15:14 2024
    From Newsgroup: comp.unix.programmer

    John Ames <commodorejohn@gmail.com> writes:
    On Fri, 6 Dec 2024 20:00:54 -0000 (UTC)
    Lawrence D'Oliveiro <ldo@nz.invalid> wrote:

    What would you say systemd does that is not related to that?

    QR codes?


    DNS. Drives me nuts, the crappy resolver in SystemCrap doesn't
    work at all on a LAN which has a DNS server serving the local
    domain and forwarding to external DNS resolvers.
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Muttley@Muttley@dastardlyhq.com to comp.unix.programmer on Sat Dec 7 10:04:16 2024
    From Newsgroup: comp.unix.programmer

    On Fri, 6 Dec 2024 20:00:54 -0000 (UTC)
    Lawrence D'Oliveiro <ldo@nz.invalid> gabbled:
    On Fri, 6 Dec 2024 10:28:15 -0000 (UTC), Muttley wrote:

    On Thu, 5 Dec 2024 20:45:36 -0000 (UTC)
    Lawrence D'Oliveiro <ldo@nz.invalid> wibbled:

    What rCLsingle taskrCY did init do?

    Boot the system to usable state.

    What would you say systemd does that is not related to that?

    Networking, including DNS
    Graphics
    Logging
    systemd-boot

    Basically init should start the system, maintain some the running of
    some essential daemons and then leave well alone.

    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From gazelle@gazelle@shell.xmission.com (Kenny McCormack) to comp.unix.programmer on Sat Dec 7 15:00:50 2024
    From Newsgroup: comp.unix.programmer

    In article <vj16j0$30r12$1@dont-email.me>, <Muttley@dastardlyhq.com> wrote: ...
    What would you say systemd does that is not related to that?

    Networking, including DNS
    Graphics
    Logging
    systemd-boot

    Basically init should start the system, maintain some the running of
    some essential daemons and then leave well alone.

    I agree with you. But it underscores a major difference between two very different ways of thinking about computing, which can be described as "Unix-think" vs. "Windows-think".

    systemd represents nothing so much as the bringing of "Windows-think" to Unix.

    If one embraces "Windows-think", then systemd makes complete sense.

    In fact, systemd is a lot of like the original goal of MS's "dot net",
    which was to put a solid wall between the applications programmer and the actual operating system.
    --
    If Jeb is Charlie Brown kicking a football-pulled-away, Mitt is a '50s housewife with a black eye who insists to her friends the roast wasn't
    dry.
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Muttley@Muttley@dastardlyhq.com to comp.unix.programmer on Sat Dec 7 16:05:53 2024
    From Newsgroup: comp.unix.programmer

    On Sat, 7 Dec 2024 15:00:50 -0000 (UTC)
    gazelle@shell.xmission.com (Kenny McCormack) gabbled:
    In article <vj16j0$30r12$1@dont-email.me>, <Muttley@dastardlyhq.com> wrote: >....
    What would you say systemd does that is not related to that?

    Networking, including DNS
    Graphics
    Logging
    systemd-boot

    Basically init should start the system, maintain some the running of
    some essential daemons and then leave well alone.

    I agree with you. But it underscores a major difference between two very >different ways of thinking about computing, which can be described as >"Unix-think" vs. "Windows-think".

    systemd represents nothing so much as the bringing of "Windows-think" to Unix.

    If one embraces "Windows-think", then systemd makes complete sense.

    Yes, I've heard that said before and it does ring true. I guess we should be thankful that systemd still uses text based config but I wouldn't be surprised if some Windows like binary registry isn't somewhere on the horizon. Of course Poettering has worked for MS for a long time so one can see where all his bad ideas come from.


    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Kaz Kylheku@643-408-1753@kylheku.com to comp.unix.programmer on Sun Dec 8 03:51:34 2024
    From Newsgroup: comp.unix.programmer

    On 2024-12-07, Kenny McCormack <gazelle@shell.xmission.com> wrote:
    If one embraces "Windows-think", then systemd makes complete sense.

    Complete Windows-think would be if systemd ran all services in the same process, so that all services die if you have to kill it.
    --
    TXR Programming Language: http://nongnu.org/txr
    Cygnal: Cygwin Native Application Library: http://kylheku.com/cygnal
    Mastodon: @Kazinator@mstdn.ca
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Rainer Weikusat@rweikusat@talktalk.net to comp.unix.programmer on Mon Dec 9 16:24:21 2024
    From Newsgroup: comp.unix.programmer

    Muttley@dastardlyhq.com writes:
    On Fri, 6 Dec 2024 20:00:54 -0000 (UTC)
    Lawrence D'Oliveiro <ldo@nz.invalid> gabbled:
    On Fri, 6 Dec 2024 10:28:15 -0000 (UTC), Muttley wrote:

    On Thu, 5 Dec 2024 20:45:36 -0000 (UTC)
    Lawrence D'Oliveiro <ldo@nz.invalid> wibbled:

    What rCLsingle taskrCY did init do?

    Boot the system to usable state.

    What would you say systemd does that is not related to that?

    Networking, including DNS
    Graphics
    Logging
    systemd-boot

    Basically init should start the system, maintain some the running of
    some essential daemons and then leave well alone.

    There's no particular reason why init should implement process
    management. That init is the one program which cannot easily be replaced on
    a running system, is actually a good reason why it shouldn't.

    At least on Linux, arbitrary processes can become so-called subreapers
    for their descendant processes (prctl(2), PR_SET_CHILD_SUBREAPER). This
    means not only the already specious reason-| that only init can wait for processes trying to "break out of process management" by double-forking
    isn't really valid anymore.

    -| Well-behaved server programs shouldn't background themselves as whether or not a
    particular instance should run in the background depends on the reason
    why it was started. Ie, that's a system- and situation-specific policy decision. Backgrounding can easily be provided by a special tool for
    that.
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Jim Jackson@jj@franjam.org.uk to comp.unix.programmer on Mon Dec 9 20:28:31 2024
    From Newsgroup: comp.unix.programmer

    On 2024-12-05, Lawrence D'Oliveiro <ldo@nz.invalid> wrote:
    On Thu, 5 Dec 2024 08:19:46 -0000 (UTC), Muttley wrote:

    On Thu, 5 Dec 2024 02:11:04 -0000 (UTC)
    Lawrence D'Oliveiro <ldo@nz.invalid> wibbled:

    On Wed, 4 Dec 2024 08:34:30 -0000 (UTC), Muttley wrote:

    Linux is far closer to the unix philosphy (ignoring systemd) ...

    Which ???unix philosophy??? would that be?

    The one where init does a single task instead of spreading itself
    throughout the system ...

    What ???single task??? did init do?

    * Mount filesystems
    * Spawn syslog, cron
    * Spawn terminal login processes (getty)
    * Respawn terminated getty processes
    * Monitor other special stuff in inittab
    * Spawn random other services, without monitoring their state
    * Act as a general catch-all for orphaned processes when they terminate

    This was all before systemd came on the scene.

    Actually traditional Unix "init" didn't do ALL those things. Most tended
    to have the inittab config file. Even busybox's init has.

    I can't think of a pre-systemd init that mounted filesystems, or spawned things like syslog/cron. It ran other programs/systems that did most of system-bring-up and the process control stuff one of which was SysV
    initialise setup. Which, surprize though this might sound to some
    people, was, at the time, an improvement on the startup setups that had
    been common previously.





    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Jim Jackson@jj@franjam.org.uk to comp.unix.programmer on Mon Dec 9 20:38:59 2024
    From Newsgroup: comp.unix.programmer

    On 2024-12-07, Kenny McCormack <gazelle@shell.xmission.com> wrote:
    In article <vj16j0$30r12$1@dont-email.me>, <Muttley@dastardlyhq.com> wrote: ...
    What would you say systemd does that is not related to that?

    Networking, including DNS
    Graphics
    Logging
    systemd-boot

    Basically init should start the system, maintain some the running of
    some essential daemons and then leave well alone.

    I agree with you. But it underscores a major difference between two very different ways of thinking about computing, which can be described as "Unix-think" vs. "Windows-think".

    systemd represents nothing so much as the bringing of "Windows-think" to Unix.

    If one embraces "Windows-think", then systemd makes complete sense.

    In fact, systemd is a lot of like the original goal of MS's "dot net",
    which was to put a solid wall between the applications programmer and the actual operating system.


    Having just had a wee look at the Android init process, it looks as if
    it attempts to do the same.
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Lawrence D'Oliveiro@ldo@nz.invalid to comp.unix.programmer on Tue Dec 10 01:27:05 2024
    From Newsgroup: comp.unix.programmer

    On Mon, 9 Dec 2024 20:28:31 -0000 (UTC), Jim Jackson wrote:

    Actually traditional Unix "init" didn't do ALL those things.

    sysvinit certainly did. That is the usual standard of comparison, is it
    not?
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Richard Kettlewell@invalid@invalid.invalid to comp.unix.programmer on Tue Dec 10 08:50:20 2024
    From Newsgroup: comp.unix.programmer

    Jim Jackson <jj@franjam.org.uk> writes:
    On 2024-12-05, Lawrence D'Oliveiro <ldo@nz.invalid> wrote:
    What ???single task??? did init do?

    * Mount filesystems
    * Spawn syslog, cron
    * Spawn terminal login processes (getty)
    * Respawn terminated getty processes
    * Monitor other special stuff in inittab
    * Spawn random other services, without monitoring their state
    * Act as a general catch-all for orphaned processes when they terminate

    This was all before systemd came on the scene.

    Actually traditional Unix "init" didn't do ALL those things. Most
    tended to have the inittab config file. Even busybox's init has.

    Depends if you mean init=/sbin/init or init=the entire sysvinit system.
    If you(plural) are going talk about init systems then you need to agree
    terms.
    --
    https://www.greenend.org.uk/rjk/
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Muttley@Muttley@DastardlyHQ.org to comp.unix.programmer on Tue Dec 10 09:23:13 2024
    From Newsgroup: comp.unix.programmer

    On Tue, 10 Dec 2024 08:50:20 +0000
    Richard Kettlewell <invalid@invalid.invalid> wibbled:
    Jim Jackson <jj@franjam.org.uk> writes:
    On 2024-12-05, Lawrence D'Oliveiro <ldo@nz.invalid> wrote:
    What ???single task??? did init do?

    * Mount filesystems
    * Spawn syslog, cron
    * Spawn terminal login processes (getty)
    * Respawn terminated getty processes
    * Monitor other special stuff in inittab
    * Spawn random other services, without monitoring their state
    * Act as a general catch-all for orphaned processes when they terminate

    This was all before systemd came on the scene.

    Actually traditional Unix "init" didn't do ALL those things. Most
    tended to have the inittab config file. Even busybox's init has.

    Depends if you mean init=/sbin/init or init=the entire sysvinit system.
    If you(plural) are going talk about init systems then you need to agree >terms.

    Its probably fair to say that because the traditional init system uses
    shell scripts and hence can do anything you like they often did. But the
    core part should really just be limited to starting the machine and getting enough things running for a user to log on (or if its a black box to do its task).

    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Jim Jackson@jj@franjam.org.uk to comp.unix.programmer on Tue Dec 10 12:26:07 2024
    From Newsgroup: comp.unix.programmer

    On 2024-12-10, Muttley@DastardlyHQ.org <Muttley@DastardlyHQ.org> wrote:
    On Tue, 10 Dec 2024 08:50:20 +0000
    Richard Kettlewell <invalid@invalid.invalid> wibbled:
    Jim Jackson <jj@franjam.org.uk> writes:
    On 2024-12-05, Lawrence D'Oliveiro <ldo@nz.invalid> wrote:
    What ???single task??? did init do?

    * Mount filesystems
    * Spawn syslog, cron
    * Spawn terminal login processes (getty)
    * Respawn terminated getty processes
    * Monitor other special stuff in inittab
    * Spawn random other services, without monitoring their state
    * Act as a general catch-all for orphaned processes when they terminate >>>>
    This was all before systemd came on the scene.

    Actually traditional Unix "init" didn't do ALL those things. Most
    tended to have the inittab config file. Even busybox's init has.

    Depends if you mean init=/sbin/init or init=the entire sysvinit system.
    If you(plural) are going talk about init systems then you need to agree >>terms.

    Yes of course. But he did mention "init" which I take to mean pid 1.

    Its probably fair to say that because the traditional init system uses
    shell scripts and hence can do anything you like they often did. But the
    core part should really just be limited to starting the machine and getting enough things running for a user to log on (or if its a black box to do its task).

    Doesn't have to be shell scripts - init just launched programs, e.g.
    getty on serial lines, etc.

    I think Android init does quite a bit more.

    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Rainer Weikusat@rweikusat@talktalk.net to comp.unix.programmer on Tue Dec 10 21:01:56 2024
    From Newsgroup: comp.unix.programmer

    Lawrence D'Oliveiro <ldo@nz.invalid> writes:
    On Mon, 9 Dec 2024 20:28:31 -0000 (UTC), Jim Jackson wrote:

    Actually traditional Unix "init" didn't do ALL those things.

    sysvinit certainly did. That is the usual standard of comparison, is it
    not?

    It certainly didn't. sysvinit is a program. There source code is, for example, online
    here

    https://github.com/slicer69/sysvinit/blob/main/src/init.c

    and all this does is execute configurable other programs in a couple of different ways (mostly respawn, exec once and exec once and wait for it)
    in response to runlevel changes.
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Lawrence D'Oliveiro@ldo@nz.invalid to comp.unix.programmer on Tue Dec 10 20:55:05 2024
    From Newsgroup: comp.unix.programmer

    On Tue, 10 Dec 2024 09:23:13 -0000 (UTC), Muttley wrote:

    But the core part should really just be limited to starting the
    machine and getting enough things running for a user to log on (or
    if its a black box to do its task).

    One thing lacking from sysvinit is, while it can start a service, it
    cannot ensure the service was started properly, and it cannot perform
    reliable service shutdown. So the job of service management was really
    only half-done.
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Rainer Weikusat@rweikusat@talktalk.net to comp.unix.programmer on Tue Dec 10 22:02:25 2024
    From Newsgroup: comp.unix.programmer

    Lawrence D'Oliveiro <ldo@nz.invalid> writes:
    On Tue, 10 Dec 2024 09:23:13 -0000 (UTC), Muttley wrote:

    But the core part should really just be limited to starting the
    machine and getting enough things running for a user to log on (or
    if its a black box to do its task).

    One thing lacking from sysvinit is, while it can start a service, it
    cannot ensure the service was started properly, and it cannot perform reliable service shutdown. So the job of service management was really
    only half-done.

    sysvinit has no concept of 'service.'

    "Service started properly" is a pointless historical property because
    "service was running propery 1ms" ago doesn't mean "service is still
    running properly now" (that's one of the classic TOCTOU races everybody
    just loves to ignore).

    It's unclear what "reliable service shutdown" is supposed to mean. It's possible to stop a somehow monitored process (not service) reliably (or
    sort-of reliably) by killing it if it didn't terminate on its own
    within some amount of time after a SIGTERM was sent to it. This works
    perfectly with a special-purpose tool for that and doesn't need any
    giant wolpertingers implemented with hundredthousands of lines of overcomplicated C code.
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Muttley@Muttley@DastardlyHQ.org to comp.unix.programmer on Wed Dec 11 08:33:29 2024
    From Newsgroup: comp.unix.programmer

    On Tue, 10 Dec 2024 20:55:05 -0000 (UTC)
    Lawrence D'Oliveiro <ldo@nz.invalid> wibbled:
    On Tue, 10 Dec 2024 09:23:13 -0000 (UTC), Muttley wrote:

    But the core part should really just be limited to starting the
    machine and getting enough things running for a user to log on (or
    if its a black box to do its task).

    One thing lacking from sysvinit is, while it can start a service, it
    cannot ensure the service was started properly, and it cannot perform >reliable service shutdown. So the job of service management was really
    only half-done.

    It doesn't need to , it can just spawn off a script or some other program
    which does that which is entirely inline with the unix philosophy. Something Poettering never understood.

    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Lawrence D'Oliveiro@ldo@nz.invalid to comp.unix.programmer on Wed Dec 11 22:26:56 2024
    From Newsgroup: comp.unix.programmer

    On Wed, 11 Dec 2024 08:33:29 -0000 (UTC), Muttley wrote:

    On Tue, 10 Dec 2024 20:55:05 -0000 (UTC)
    Lawrence D'Oliveiro <ldo@nz.invalid> wibbled:

    One thing lacking from sysvinit is, while it can start a service, it
    cannot ensure the service was started properly, and it cannot perform
    reliable service shutdown. So the job of service management was really
    only half-done.

    It doesn't need to , it can just spawn off a script or some other
    program which does that which is entirely inline with the unix
    philosophy.

    Which is where the trouble starts.

    Something Poettering never understood.

    Poettering understands that services donrCOt just to be started, they also need to be managed and shut down cleanly.
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Jim Jackson@jj@franjam.org.uk to comp.unix.programmer on Wed Dec 11 22:40:30 2024
    From Newsgroup: comp.unix.programmer

    On 2024-12-11, Lawrence D'Oliveiro <ldo@nz.invalid> wrote:
    On Wed, 11 Dec 2024 08:33:29 -0000 (UTC), Muttley wrote:

    On Tue, 10 Dec 2024 20:55:05 -0000 (UTC)
    Lawrence D'Oliveiro <ldo@nz.invalid> wibbled:

    One thing lacking from sysvinit is, while it can start a service, it
    cannot ensure the service was started properly, and it cannot perform
    reliable service shutdown. So the job of service management was really
    only half-done.

    It doesn't need to , it can just spawn off a script or some other
    program which does that which is entirely inline with the unix
    philosophy.

    Which is where the trouble starts.

    Something Poettering never understood.

    Poettering understands that services don???t just to be started, they also need to be managed and shut down cleanly.

    My God, how did we all manage running services before systemd came along?
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Nicolas George@nicolas$george@salle-s.org to comp.unix.programmer on Wed Dec 11 23:34:39 2024
    From Newsgroup: comp.unix.programmer

    Jim Jackson , dans le message <slrnvlk56u.2qa.jj@iridium.wf32df>, a
    ocrita:
    My God, how did we all manage running services before systemd came along?

    Badly, with services that have crashed and nobody noticed for weeks.

    Some teams have been working on better replacement for SysV init, but
    without the industrial strength of Red Hat they could only stay niche.
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Alexis@flexibeast@gmail.com to comp.unix.programmer on Thu Dec 12 19:15:20 2024
    From Newsgroup: comp.unix.programmer

    Nicolas George <nicolas$george@salle-s.org> writes:

    Jim Jackson , dans le message <slrnvlk56u.2qa.jj@iridium.wf32df>, a
    |-crit-a:
    My God, how did we all manage running services before systemd came along?

    Badly, with services that have crashed and nobody noticed for weeks.

    Some teams have been working on better replacement for SysV init, but
    without the industrial strength of Red Hat they could only stay niche.

    Jonathan de Boyne Pollard, creator of the Nosh system[a], has written an article about "known problems with System 5 rc":

    https://jdebp.uk/FGA/system-5-rc-problems.html

    i've used runit and s6+66 on Void Linux, and on Gentoo am currently
    using OpenRC+s6 (the latter for providing user services, which are are
    still a work in progress under OpenRC[b]):

    https://wiki.gentoo.org/wiki/User:Flexibeast/guides/OpenRC_user_services_via_s6

    My own case is certainly niche, though s6 is extensively used for
    containers, via the s6-overlay project, which currently has ~3.8k stars
    on GitHub:

    https://github.com/just-containers/s6-overlay


    Alexis.


    [a] https://jdebp.uk/Softwares/nosh/

    [b] https://github.com/OpenRC/openrc/pull/723
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Lawrence D'Oliveiro@ldo@nz.invalid to comp.unix.programmer on Thu Dec 12 08:27:39 2024
    From Newsgroup: comp.unix.programmer

    On 11 Dec 2024 23:34:39 GMT, Nicolas George wrote:

    Some teams have been working on better replacement for SysV init, but
    without the industrial strength of Red Hat they could only stay niche.

    I wonder what you think Red HatrCOs business model could be in forcing competitors to adopt technology they developed without paying for it.
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Muttley@Muttley@DastardlyHQ.org to comp.unix.programmer on Thu Dec 12 08:39:07 2024
    From Newsgroup: comp.unix.programmer

    On Wed, 11 Dec 2024 22:26:56 -0000 (UTC)
    Lawrence D'Oliveiro <ldo@nz.invalid> wibbled:
    On Wed, 11 Dec 2024 08:33:29 -0000 (UTC), Muttley wrote:

    On Tue, 10 Dec 2024 20:55:05 -0000 (UTC)
    Lawrence D'Oliveiro <ldo@nz.invalid> wibbled:

    One thing lacking from sysvinit is, while it can start a service, it
    cannot ensure the service was started properly, and it cannot perform
    reliable service shutdown. So the job of service management was really
    only half-done.

    It doesn't need to , it can just spawn off a script or some other
    program which does that which is entirely inline with the unix
    philosophy.

    Which is where the trouble starts.

    The trouble is with any support scripts, not with init. I've written a
    number of init scripts with a lot of surrounding logic. God knows how I'd
    do that with systemd short of just getting it to call the exact same script which rather defeats the purpose of having systemd.

    Something Poettering never understood.

    Poettering understands that services donrCOt just to be started, they also >need to be managed and shut down cleanly.

    Poettering created the wrong solution to the wrong problem.

    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Muttley@Muttley@DastardlyHQ.org to comp.unix.programmer on Thu Dec 12 09:38:58 2024
    From Newsgroup: comp.unix.programmer

    On Thu, 12 Dec 2024 08:27:39 -0000 (UTC)
    Lawrence D'Oliveiro <ldo@nz.invalid> wibbled:
    On 11 Dec 2024 23:34:39 GMT, Nicolas George wrote:

    Some teams have been working on better replacement for SysV init, but
    without the industrial strength of Red Hat they could only stay niche.

    I wonder what you think Red HatrCOs business model could be in forcing >competitors to adopt technology they developed without paying for it.

    Dead Rat was the darling of the business community for a long time - even more so once IBM bought it. It was effectively a replacement for Solaris, HP-UX and AIX. So the other distros thought they needed to follow suite in order to pick up some of that market. Whether that worked or not I don't know, but its left us with this legacy of systemd infesting just about every mainstream distro.

    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Nicolas George@nicolas$george@salle-s.org to comp.unix.programmer on Thu Dec 12 11:46:49 2024
    From Newsgroup: comp.unix.programmer

    Alexis , dans le message <87bjxhnwpz.fsf@gmail.com>, a ocrita:
    My own case is certainly niche, though s6 is extensively used for
    containers, via the s6-overlay project, which currently has ~3.8k stars
    on GitHub:

    I am rather pleased to ear that s6 has some success, although I know all the ill its author thinks of containers.
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Lawrence D'Oliveiro@ldo@nz.invalid to comp.unix.programmer on Thu Dec 12 22:24:53 2024
    From Newsgroup: comp.unix.programmer

    On Thu, 12 Dec 2024 09:38:58 -0000 (UTC), Muttley wrote:

    So the other distros thought they needed to
    follow suite in order to pick up some of that market.

    Something you pulled out of your fevered imagination, no doubt.
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Lawrence D'Oliveiro@ldo@nz.invalid to comp.unix.programmer on Thu Dec 12 22:31:50 2024
    From Newsgroup: comp.unix.programmer

    On Thu, 12 Dec 2024 08:39:07 -0000 (UTC), Muttley wrote:

    On Wed, 11 Dec 2024 22:26:56 -0000 (UTC)
    Lawrence D'Oliveiro <ldo@nz.invalid> wrote:

    On Wed, 11 Dec 2024 08:33:29 -0000 (UTC), Muttley wrote:

    It doesn't need to , it can just spawn off a script or some other
    program which does that which is entirely inline with the unix
    philosophy.

    Which is where the trouble starts.

    The trouble is with any support scripts, not with init. I've written a
    number of init scripts with a lot of surrounding logic.

    IrCOm sure you have. Which means you are familiar with the wholesale copying and pasting of boilerplate from one script to the next. rCLWhat does this
    bit do?rCY rCLDonrCOt bother thinking too hard, just stick it in, just in case.rCY

    God knows how I'd do that with systemd ...

    Figure out what the directives do (theyrCOre all documented), and which settings will achieve the result you want. Most of the time, your service
    file will be very simple and very short, since all the common cases are already covered.

    rCLSimple things should be simple, and complex things should be possible.rCY
    -- Alan Kay

    He was talking about GUI design, but the same applies to systemd. And to a
    lot of other popular *nix software, while werCOre at it.

    Poettering understands that services donrCOt just to be started, they al
    so need to be managed and shut down cleanly.

    Poettering created the wrong solution to the wrong problem.

    Lots of sysadmins, and distro maintainers, and developers of service apps, disagree.

    Think of how simple it is to log error messages now: systemd automatically captures stderr, and shows it in your service status and in the journal.
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Muttley@Muttley@DastardlyHQ.org to comp.unix.programmer on Fri Dec 13 10:38:51 2024
    From Newsgroup: comp.unix.programmer

    On Thu, 12 Dec 2024 22:31:50 -0000 (UTC)
    Lawrence D'Oliveiro <ldo@nz.invalid> wibbled:
    On Thu, 12 Dec 2024 08:39:07 -0000 (UTC), Muttley wrote:
    The trouble is with any support scripts, not with init. I've written a
    number of init scripts with a lot of surrounding logic.

    IrCOm sure you have. Which means you are familiar with the wholesale copying >and pasting of boilerplate from one script to the next. rCLWhat does this >bit do?rCY rCLDonrCOt bother thinking too hard, just stick it in, just in >case.rCY

    Its a few lines of code and usually one just copies a simple rc file and
    starts from there.

    God knows how I'd do that with systemd ...

    Figure out what the directives do (theyrCOre all documented), and which

    Why TF would I want to have to leanr Yet Another Config Language when in
    shell script I have a turing complete language that can do anything with the system? You might as well say "Don't bother with that car, use this pushbike instead."

    Poettering created the wrong solution to the wrong problem.

    Lots of sysadmins, and distro maintainers, and developers of service apps, >disagree.

    Sheep exist even i open source. That other abortion poetrring wrote pulseaudio was shoved into every distro until people realised that all it did was
    remove the complexity of Alsa and add its own complexity in exchange. And
    being built on alsa it simply added another layer and hence delay into the sound system where you REALLY don't want delays.

    Think of how simple it is to log error messages now: systemd automatically >captures stderr, and shows it in your service status and in the journal.

    Oh wow, is there no end to its magical abilities!

    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Rainer Weikusat@rweikusat@talktalk.net to comp.unix.programmer on Fri Dec 13 11:42:18 2024
    From Newsgroup: comp.unix.programmer

    Lawrence D'Oliveiro <ldo@nz.invalid> writes:
    On Thu, 12 Dec 2024 08:39:07 -0000 (UTC), Muttley wrote:
    On Wed, 11 Dec 2024 22:26:56 -0000 (UTC)
    Lawrence D'Oliveiro <ldo@nz.invalid> wrote:

    On Wed, 11 Dec 2024 08:33:29 -0000 (UTC), Muttley wrote:

    It doesn't need to , it can just spawn off a script or some other
    program which does that which is entirely inline with the unix
    philosophy.

    Which is where the trouble starts.

    The trouble is with any support scripts, not with init. I've written a
    number of init scripts with a lot of surrounding logic.

    IrCOm sure you have. Which means you are familiar with the wholesale copying and pasting of boilerplate from one script to the next. rCLWhat does this bit do?rCY rCLDonrCOt bother thinking too hard, just stick it in, just in case.rCY

    Nobody but you can be familiar with what you are doing when being forced
    to write code.

    God knows how I'd do that with systemd ...

    Figure out what the directives do (theyrCOre all documented), and which settings will achieve the result you want. Most of the time, your service file will be very simple and very short, since all the common cases are already covered.

    rCLSimple things should be simple, and complex things should be possible.rCY
    -- Alan Kay

    According to an automated count (mostly perl -ne 'print $_, "\n" for
    /\w+=/g') the current version of systemd supports about 320
    directives and people still combine that with start scripts, be this
    because their use case still isn't supported or because they didn't want
    to be bothered with learning about all the details of this huge, rusted
    barbed wire obstacle just for solving a simple problem.

    The quote would thus more appropriate be:

    Make simple things hideously complicated and complicated things at all impossible.

    -- Lennart Poettering about "How to create problems for other people for one's
    own benefit."

    He was talking about GUI design, but the same applies to systemd. And to a lot of other popular *nix software, while werCOre at it.

    Poettering understands that services donrCOt just to be started, they al >>> so need to be managed and shut down cleanly.

    Poettering created the wrong solution to the wrong problem.

    Lots of sysadmins, and distro maintainers, and developers of service apps, disagree.

    Due to human nature, lots of people will always disagree with anything.
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From John Ames@commodorejohn@gmail.com to comp.unix.programmer on Fri Dec 13 07:42:07 2024
    From Newsgroup: comp.unix.programmer

    On Fri, 13 Dec 2024 10:38:51 -0000 (UTC)
    Muttley@DastardlyHQ.org wrote:

    That other abortion poetrring wrote pulseaudio was shoved into every
    distro until people realised that all it did was remove the
    complexity of Alsa and add its own complexity in exchange. And being
    built on alsa it simply added another layer and hence delay into the
    sound system where you REALLY don't want delays.

    This bears repeating. Why *anybody* decided to trust the judgement of
    the person who gave us the jankiest of all the incredibly janky *nix
    audio subsystems is beyond comprehension.

    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Jim Jackson@jj@franjam.org.uk to comp.unix.programmer on Fri Dec 13 20:07:58 2024
    From Newsgroup: comp.unix.programmer

    On 2024-12-11, Nicolas George <nicolas$george@salle-s.org> wrote:
    Jim Jackson , dans le message <slrnvlk56u.2qa.jj@iridium.wf32df>, a
    ?crit?:
    My God, how did we all manage running services before systemd came along?

    Badly, with services that have crashed and nobody noticed for weeks.

    People keep saying that. But in my experience services were run as
    efficiently as they seem to be run today. Perhaps the team I worked in
    knew what it was doing :-)

    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Jim Jackson@jj@franjam.org.uk to comp.unix.programmer on Fri Dec 13 20:15:16 2024
    From Newsgroup: comp.unix.programmer

    The trouble is with any support scripts, not with init. I've written a
    number of init scripts with a lot of surrounding logic.

    I???m sure you have. Which means you are familiar with the wholesale copying and pasting of boilerplate from one script to the next. ???What does this bit do???? ???Don???t bother thinking too hard, just stick it in, just in case.???

    Ah describing bad programming practice. The same thing happens when
    people just cut and paste anything without knowing what they are doing.


    God knows how I'd do that with systemd ...

    Figure out what the directives do (they???re all documented), and which settings will achieve the result you want.

    Nah, as you say above just cut and paste and not think about any diffiicult bits you need to read up on :-)

    Most of the time, your service
    file will be very simple and very short, since all the common cases are already covered.

    Poettering understands that services don???t just to be started, they al >>> so need to be managed and shut down cleanly.

    Actually a service should know how to shutdown itself cleanly and should document how that is achieved.

    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Lawrence D'Oliveiro@ldo@nz.invalid to comp.unix.programmer on Fri Dec 13 22:05:28 2024
    From Newsgroup: comp.unix.programmer

    On Fri, 13 Dec 2024 20:07:58 -0000 (UTC), Jim Jackson wrote:

    On 2024-12-11, Nicolas George <nicolas$george@salle-s.org> wrote:

    Jim Jackson , dans le message <slrnvlk56u.2qa.jj@iridium.wf32df>, a
    |-crit-a:

    My God, how did we all manage running services before systemd came
    along?

    Badly, with services that have crashed and nobody noticed for weeks.

    People keep saying that. But in my experience services were run as efficiently as they seem to be run today. Perhaps the team I worked in
    knew what it was doing :-)

    How many custom services were you running on a single machine, just out of curiosity?
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Lawrence D'Oliveiro@ldo@nz.invalid to comp.unix.programmer on Sat Dec 14 01:35:37 2024
    From Newsgroup: comp.unix.programmer

    On Fri, 13 Dec 2024 07:42:07 -0800, John Ames wrote:

    This bears repeating. Why *anybody* decided to trust the judgement of
    the person who gave us the jankiest of all the incredibly janky *nix
    audio subsystems is beyond comprehension.

    There was no reason why you had to. You could easily have created your own distro without any of his code in it, if you wanted to. Or become an aficionado of one of the existing distros that did exactly that.

    Open Source is all about choice. If you canrCOt stand the thought of people making different choices from you, you know what you can do.
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From rlhamil@rlhamil@smart.net (Richard L. Hamilton) to comp.unix.programmer on Sat Dec 14 08:48:00 2024
    From Newsgroup: comp.unix.programmer

    In article <vinp86$avd9$1@dont-email.me>,
    Lawrence D'Oliveiro <ldo@nz.invalid> writes:
    On Tue, 3 Dec 2024 08:20:51 -0000 (UTC), Muttley wrote:

    I'm wondering on Linux if it would be enough on Linux to spoof ttyname()
    and isatty() using LD_PRELOAD. However it seems doing something similar
    on a Mac is the usual over complicated Apple hot mess.

    macOS may be a licensee of the rCLUnixrCY trademark, but it does not work the
    way people expect when they think of the term rCLUnixrCY.

    It probably does as of the version of the formal specification they met
    to be allowed to use the trademark.

    Other features that are customary but not entirely standardized
    may be implemented differently if at all, possibly with different
    side-effects or complications.

    Pretty sure I've some time ago used the equivalent of LD_PRELOAD on
    macOS to wrap some existing library function, with very little change
    to the C code, but some change to compiler options, environment
    variables required, etc. For instance, one might need compiler flags
    -fPIC -dynamiclib

    which might be different from other platforms. And the environment variable
    for macOS instead of LD_PRELOAD (from the dyld man page) is
    DYLD_INSERT_LIBRARIES
    This is a colon separated list of additional dynamic libraries to
    load before the ones specified in the program. If instead, your
    goal is to substitute a library that would normally be loaded, use
    DYLD_LIBRARY_PATH or DYLD_FRAMEWORK_PATH instead.


    However I just tried this with some old preloadable modules (of
    suitable architecture), and it no longer seems to work. Not sure what
    else I have to do now. Maybe this changed/broke when most dynamic libraries were replaced by a pre-linked cache files that would map in in their entirety at reserved address(es). Faster, more secure, but maybe less flexible.
    Haven't googled enough yet to find the answer, if any.

    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From rlhamil@rlhamil@smart.net (Richard L. Hamilton) to comp.unix.programmer on Sat Dec 14 08:52:14 2024
    From Newsgroup: comp.unix.programmer

    In article <vit3dg$1quau$1@dont-email.me>,
    Lawrence D'Oliveiro <ldo@nz.invalid> writes:
    On Thu, 5 Dec 2024 08:19:46 -0000 (UTC), Muttley wrote:

    On Thu, 5 Dec 2024 02:11:04 -0000 (UTC)
    Lawrence D'Oliveiro <ldo@nz.invalid> wibbled:

    On Wed, 4 Dec 2024 08:34:30 -0000 (UTC), Muttley wrote:

    Linux is far closer to the unix philosphy (ignoring systemd) ...

    Which rCLunix philosophyrCY would that be?

    The one where init does a single task instead of spreading itself
    throughout the system ...

    What rCLsingle taskrCY did init do?

    * Mount filesystems
    * Spawn syslog, cron
    * Spawn terminal login processes (getty)
    * Respawn terminated getty processes
    * Monitor other special stuff in inittab
    * Spawn random other services, without monitoring their state
    * Act as a general catch-all for orphaned processes when they terminate

    This was all before systemd came on the scene.

    It spawned other processes, and where the idea of run levels existed,
    selected what to spawn based on those.

    It did not do tricky communication with processes, elaborately
    manipulate their initial environment, and except for adopting orphans
    and respawning processes, didn't do much at all to bother them during
    their lifespan unless the run level was changed.

    MacOS launchd is arguably even worse insofar as it also has things like
    Mach namespaces to deal with.
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From rlhamil@rlhamil@smart.net (Richard L. Hamilton) to comp.unix.programmer on Sat Dec 14 09:06:28 2024
    From Newsgroup: comp.unix.programmer

    In article <vj16j0$30r12$1@dont-email.me>,
    Muttley@dastardlyhq.com writes:
    On Fri, 6 Dec 2024 20:00:54 -0000 (UTC)
    Lawrence D'Oliveiro <ldo@nz.invalid> gabbled:
    On Fri, 6 Dec 2024 10:28:15 -0000 (UTC), Muttley wrote:

    On Thu, 5 Dec 2024 20:45:36 -0000 (UTC)
    Lawrence D'Oliveiro <ldo@nz.invalid> wibbled:

    What rCLsingle taskrCY did init do?

    Boot the system to usable state.

    What would you say systemd does that is not related to that?

    Networking, including DNS
    Graphics
    Logging
    systemd-boot

    Basically init should start the system, maintain some the running of
    some essential daemons and then leave well alone.


    On Solaris 10 and later, svc.startd does most spawning and respawning
    and such, and uses a "contract" mechanism to be able to keep track of
    and if needed kill off otherwise daemonized processes (sshd needs a
    compile time option so it only kills the listening sshd and not the
    children handling processes - which need to explicitly break their
    "contract", otherwise an admin restarting sshd over ssh will kick
    themselves out; but for the vast majority of other code, the contract
    mechanism does what one might hope with no modification needed to the
    code of what it controls)).

    But it still has init, although init does little more than start or
    control svc.startd (but you could configure it to start something
    outside of the control of svc.startd if you really wanted to).

    What's the point of svc.startd there? It with the relevant service configuration files can handle dependencies among services (processes
    or other actions) to be started, starting in parallel any whose
    dependencies are satisfied; with sufficient hardware threads, that can
    provide faster startup. And it can use the aforementioned contract
    mechanism to stay more in control, and will fix simple things by
    restarting, albeit not if they keep faulting too rapidly. It interacts
    with fault management (which also deals with hardware issues) to
    provide a consolidated handing of both daemon and hardware issues, for
    greater fault tolerance.

    For Solaris systems isolated enough that they didn't need regular security updates, I've seen uptimes in years, so they're probably doing something
    right (that they mostly have ECC RAM helps a lot, too). @home, I seldom
    get those uptimes, in part because I don't have UPS for everything. :-)

    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From rlhamil@rlhamil@smart.net (Richard L. Hamilton) to comp.unix.programmer on Sat Dec 14 09:09:20 2024
    From Newsgroup: comp.unix.programmer

    In article <vj1rp1$363i0$1@dont-email.me>,
    Muttley@dastardlyhq.com writes:
    On Sat, 7 Dec 2024 15:00:50 -0000 (UTC)
    gazelle@shell.xmission.com (Kenny McCormack) gabbled:
    In article <vj16j0$30r12$1@dont-email.me>, <Muttley@dastardlyhq.com> wrote: >>....
    What would you say systemd does that is not related to that?

    Networking, including DNS
    Graphics
    Logging
    systemd-boot

    Basically init should start the system, maintain some the running of
    some essential daemons and then leave well alone.

    I agree with you. But it underscores a major difference between two very >>different ways of thinking about computing, which can be described as >>"Unix-think" vs. "Windows-think".

    systemd represents nothing so much as the bringing of "Windows-think" to Unix.

    If one embraces "Windows-think", then systemd makes complete sense.

    Yes, I've heard that said before and it does ring true. I guess we should be thankful that systemd still uses text based config but I wouldn't be surprised
    if some Windows like binary registry isn't somewhere on the horizon. Of course
    Poettering has worked for MS for a long time so one can see where all his bad ideas come from.j

    AIX ("AIX Isn't uniX") has something like a registry, as I recall.

    Even on Solaris, although the configuration files may still mostly be text, there's a tendency toward commands that do the actual configuring. In a way, that's safer since they can offer sanity checks before changes actually take effect.
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Muttley@Muttley@dastardlyhq.com to comp.unix.programmer on Sat Dec 14 10:05:09 2024
    From Newsgroup: comp.unix.programmer

    On Fri, 13 Dec 2024 07:42:07 -0800
    John Ames <commodorejohn@gmail.com> gabbled:
    On Fri, 13 Dec 2024 10:38:51 -0000 (UTC)
    Muttley@DastardlyHQ.org wrote:

    That other abortion poetrring wrote pulseaudio was shoved into every
    distro until people realised that all it did was remove the
    complexity of Alsa and add its own complexity in exchange. And being
    built on alsa it simply added another layer and hence delay into the
    sound system where you REALLY don't want delays.

    This bears repeating. Why *anybody* decided to trust the judgement of
    the person who gave us the jankiest of all the incredibly janky *nix
    audio subsystems is beyond comprehension.

    Agreed. On a side note, its a shame the original authors of X didn't decide
    to do sound too or at least provide an API that others could build extensions to use because by the time X - or at least X11 - was adopted unix had moved on from cabinet sized servers to desktop workstations where sound mattered. It seems odd to me that graphics and sound are still totally seperate on unix
    but perhaps my formative years on 8 bit home micros where graphics and sound came bundled skew my opinion.

    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Muttley@Muttley@dastardlyhq.com to comp.unix.programmer on Sat Dec 14 10:06:29 2024
    From Newsgroup: comp.unix.programmer

    On Sat, 14 Dec 2024 08:48:00 GMT
    rlhamil@smart.net (Richard L. Hamilton) gabbled:
    However I just tried this with some old preloadable modules (of
    suitable architecture), and it no longer seems to work. Not sure what
    else I have to do now. Maybe this changed/broke when most dynamic libraries >were replaced by a pre-linked cache files that would map in in their entirety >at reserved address(es). Faster, more secure, but maybe less flexible. >Haven't googled enough yet to find the answer, if any.

    Probably something to do with security. Apple have really nailed MacOS down
    in recent releases. I looked at how to do it for recent versions and just decided I couldn't be bothered. Seemed to require putting macros in code and
    I just thought nah.

    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Muttley@Muttley@dastardlyhq.com to comp.unix.programmer on Sat Dec 14 10:09:16 2024
    From Newsgroup: comp.unix.programmer

    On Sat, 14 Dec 2024 08:52:14 GMT
    rlhamil@smart.net (Richard L. Hamilton) gabbled:
    In article <vit3dg$1quau$1@dont-email.me>,
    This was all before systemd came on the scene.

    It spawned other processes, and where the idea of run levels existed, >selected what to spawn based on those.

    It did not do tricky communication with processes, elaborately
    manipulate their initial environment, and except for adopting orphans

    Which to anyone except poettering and his fanboys its quite obvious it doesn't need to as a wrapper script can do that quite nicely.

    MacOS launchd is arguably even worse insofar as it also has things like
    Mach namespaces to deal with.

    And XML config. Ugh. Why people persist with the hideousness that is XML when the much clearer json is pretty much standard now beats the hell out of me.

    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Janis Papanagnou@janis_papanagnou+ng@hotmail.com to comp.unix.programmer on Sat Dec 14 12:24:27 2024
    From Newsgroup: comp.unix.programmer

    On 14.12.2024 10:09, Richard L. Hamilton wrote:

    AIX ("AIX Isn't uniX") [...]

    Since I've never heard that I was tempted to ask whether that's
    true or a joke; a quick look into the Web suggested "Advanced
    Interactive eXecutive". - I admit your interpretation is nicer.

    Janis

    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Jim Jackson@jj@franjam.org.uk to comp.unix.programmer on Sat Dec 14 15:20:25 2024
    From Newsgroup: comp.unix.programmer

    On 2024-12-13, Lawrence D'Oliveiro <ldo@nz.invalid> wrote:
    On Fri, 13 Dec 2024 20:07:58 -0000 (UTC), Jim Jackson wrote:

    On 2024-12-11, Nicolas George <nicolas$george@salle-s.org> wrote:

    Jim Jackson , dans le message <slrnvlk56u.2qa.jj@iridium.wf32df>, a
    ??crit??:

    My God, how did we all manage running services before systemd came
    along?

    Badly, with services that have crashed and nobody noticed for weeks.

    People keep saying that. But in my experience services were run as
    efficiently as they seem to be run today. Perhaps the team I worked in
    knew what it was doing :-)

    How many custom services were you running on a single machine, just out of curiosity?

    What do you mean by custom? There were database services, web-based
    services, information servers other than web all running on 2 big
    servers. The infrastructure services (file servers, DNS, NTP, DHCP,
    boot servers, automatic backup etc etc) were split between 2 servers
    with backup and failover. not sure how you'd classify our mail service,
    as infrastructure or custom, but it was far from bog-standard.


    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Rainer Weikusat@rweikusat@talktalk.net to comp.unix.programmer on Sat Dec 14 20:16:08 2024
    From Newsgroup: comp.unix.programmer

    Lawrence D'Oliveiro <ldo@nz.invalid> writes:
    On Fri, 13 Dec 2024 07:42:07 -0800, John Ames wrote:
    This bears repeating. Why *anybody* decided to trust the judgement of
    the person who gave us the jankiest of all the incredibly janky *nix
    audio subsystems is beyond comprehension.

    There was no reason why you had to. You could easily have created your own distro without any of his code in it, if you wanted to. Or become an aficionado of one of the existing distros that did exactly that.

    Open Source is all about choice. If you canrCOt stand the thought of people making different choices from you, you know what you can do.

    If these people get paid by $big_name_companies, there's exactly nothing individuals can do about that. Unless they happen to be rich enough that
    they can waste a ton of money on their hobbies and then, they'd still
    need to get a competent work force from somewhere.
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Lawrence D'Oliveiro@ldo@nz.invalid to comp.unix.programmer on Sat Dec 14 22:26:08 2024
    From Newsgroup: comp.unix.programmer

    On Sat, 14 Dec 2024 15:20:25 -0000 (UTC), Jim Jackson wrote:

    On 2024-12-13, Lawrence D'Oliveiro <ldo@nz.invalid> wrote:

    On Fri, 13 Dec 2024 20:07:58 -0000 (UTC), Jim Jackson wrote:

    On 2024-12-11, Nicolas George <nicolas$george@salle-s.org> wrote:

    Jim Jackson , dans le message <slrnvlk56u.2qa.jj@iridium.wf32df>, a
    ??crit??:

    My God, how did we all manage running services before systemd came
    along?

    Badly, with services that have crashed and nobody noticed for weeks.

    People keep saying that. But in my experience services were run as
    efficiently as they seem to be run today. Perhaps the team I worked in
    knew what it was doing :-)

    How many custom services were you running on a single machine, just out
    of curiosity?

    What do you mean by custom?

    Code that you had to write substantially from scratch, as opposed to configuring standard DBMS, Web, directory, MTA, DNS etc.

    I ask because the standard services will already have their startup requirements worked out, because your own would require you to create your
    own startup scripts. Which is where the trouble would often start, with sysvinit.
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Lawrence D'Oliveiro@ldo@nz.invalid to comp.unix.programmer on Sat Dec 14 22:28:36 2024
    From Newsgroup: comp.unix.programmer

    On Sat, 14 Dec 2024 08:52:14 GMT, Richard L. Hamilton wrote:

    MacOS launchd is arguably even worse insofar as it also has things like
    Mach namespaces to deal with.

    Linux has namespaces. Everything, just about, is isolatable in its own namespace: mounted filesystems, network interfaces, processes, user IDs,
    even the system time and hostname. Put them all together, and you get containers.

    And yes, launchd was an inspiration for systemd.
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Muttley@Muttley@dastardlyhq.com to comp.unix.programmer on Sun Dec 15 12:43:21 2024
    From Newsgroup: comp.unix.programmer

    On Sat, 14 Dec 2024 20:16:08 +0000
    Rainer Weikusat <rweikusat@talktalk.net> gabbled:
    Lawrence D'Oliveiro <ldo@nz.invalid> writes:
    On Fri, 13 Dec 2024 07:42:07 -0800, John Ames wrote:
    This bears repeating. Why *anybody* decided to trust the judgement of
    the person who gave us the jankiest of all the incredibly janky *nix
    audio subsystems is beyond comprehension.

    There was no reason why you had to. You could easily have created your own >> distro without any of his code in it, if you wanted to. Or become an
    aficionado of one of the existing distros that did exactly that.

    Open Source is all about choice. If you canrCOt stand the thought of people >> making different choices from you, you know what you can do.

    If these people get paid by $big_name_companies, there's exactly nothing >individuals can do about that. Unless they happen to be rich enough that
    they can waste a ton of money on their hobbies and then, they'd still
    need to get a competent work force from somewhere.

    The sort of idiots who make those "why don't you write your own" remarks probably still live with and are financed by mum and dad so don't see the
    issue with spending months rolling your own system. Plus they seem to have
    some kind of believe that you shouldn't criticise something unless you have
    the ability to replicate it youself which means no one should ever comment on any music, films, TV, food etc they disliked unless they could make a hollywood blockbuster, album, whatever themselves. Its a very juvenile attitude.

    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Rainer Weikusat@rweikusat@talktalk.net to comp.unix.programmer on Sun Dec 15 21:25:36 2024
    From Newsgroup: comp.unix.programmer

    Muttley@dastardlyhq.com writes:
    On Sat, 14 Dec 2024 20:16:08 +0000
    Rainer Weikusat <rweikusat@talktalk.net> gabbled:
    Lawrence D'Oliveiro <ldo@nz.invalid> writes:
    On Fri, 13 Dec 2024 07:42:07 -0800, John Ames wrote:
    This bears repeating. Why *anybody* decided to trust the judgement of
    the person who gave us the jankiest of all the incredibly janky *nix
    audio subsystems is beyond comprehension.

    There was no reason why you had to. You could easily have created your own >>> distro without any of his code in it, if you wanted to. Or become an
    aficionado of one of the existing distros that did exactly that.

    Open Source is all about choice. If you canrCOt stand the thought of people
    making different choices from you, you know what you can do.

    If these people get paid by $big_name_companies, there's exactly nothing >>individuals can do about that. Unless they happen to be rich enough that >>they can waste a ton of money on their hobbies and then, they'd still
    need to get a competent work force from somewhere.

    The sort of idiots who make those "why don't you write your own" remarks probably still live with and are financed by mum and dad so don't see the issue with spending months rolling your own system.

    I actually did. By the time when systemd started to become a serious
    nuisance, I had just started to work on a different product. The
    previous had been an (ARM9-based) UTM appliance and I actually wrote an
    own init for that. I was determined to avoid doing that again but still
    needed more process management than sysvinit + rc provided.

    I started this as sort-of a conscious anti-systemd experiment. The idea
    was that, whenever I needed some process management feature, I'd write a (fairly small) C program to provide that and find out how far this would
    get me. That was about fifteen years ago. I've meanwhile accumulated 38
    of these C program with a total size of 5690 lines of code and that's
    enough for all of my process management needs and I'm dealing with some
    more complicated stuff then people just running web servers.

    This is arguably not open source but the copyright belongs to my
    employer. OTOH, if it were, mainstream Linux distributions wouldn't use
    it, not the least because many people just love complicated stuff (like systemd).

    Plus they seem to have some kind of believe that you shouldn't
    criticise something unless you have the ability to replicate it
    youself which means no one should ever comment on any music, films,
    TV, food etc they disliked unless they could make a hollywood
    blockbuster, album, whatever themselves. Its a very juvenile attitude.

    Indeed.
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Muttley@Muttley@DastardlyHQ.org to comp.unix.programmer on Mon Dec 16 08:16:28 2024
    From Newsgroup: comp.unix.programmer

    On Sun, 15 Dec 2024 21:25:36 +0000
    Rainer Weikusat <rweikusat@talktalk.net> wibbled:
    employer. OTOH, if it were, mainstream Linux distributions wouldn't use
    it, not the least because many people just love complicated stuff (like >systemd).

    True. Far too many people think complicated = clever. What they don't understand is that really smart people have the ability to make complicated stuff simple for the user. Sadly not an ability Poettering has.

    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Geoff Clare@geoff@clare.See-My-Signature.invalid to comp.unix.programmer on Mon Dec 16 14:05:44 2024
    From Newsgroup: comp.unix.programmer

    Richard L. Hamilton wrote:

    In article <vinp86$avd9$1@dont-email.me>,
    Lawrence D'Oliveiro <ldo@nz.invalid> writes:
    On Tue, 3 Dec 2024 08:20:51 -0000 (UTC), Muttley wrote:

    I'm wondering on Linux if it would be enough on Linux to spoof ttyname() >>> and isatty() using LD_PRELOAD. However it seems doing something similar
    on a Mac is the usual over complicated Apple hot mess.

    macOS may be a licensee of the "Unix" trademark, but it does not work the >> way people expect when they think of the term "Unix".

    It probably does as of the version of the formal specification they met
    to be allowed to use the trademark.

    It is certified as conforming to "UNIX 03", which is so named because
    the certification program was launched in 2003, although by coincidence
    the corresponding version of The Single UNIX Specification (SUS) is
    version 3. There have since been SUSv4 (2008) and SUSv5 (2024) so
    macOS is two versions behind. (AIX and Solaris are/were certified to
    SUSv4; there is no certification program yet for SUSv5.)

    SUSv3/4 included dlopen(), dlsym() and dlclose() but no other
    requirements related to dynamic linking. SUSv5 adds the ability to
    build shared libraries and dynamic executables using the c17 utility,
    but doesn't specify how their loading can be controlled with
    environment variables.

    The things Lawrence said don't work on macOS the way people expect
    UNIX to work are almost certainly all, just like LD_PRELOAD, not
    specified by SUS. (Otherwise macOS would fail some of the tens of
    thousands of tests it has to pass in order for each new macOS version
    to be certified.)
    --
    Geoff Clare <netnews@gclare.org.uk>
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From John Ames@commodorejohn@gmail.com to comp.unix.programmer on Mon Dec 16 07:55:19 2024
    From Newsgroup: comp.unix.programmer

    On Sat, 14 Dec 2024 01:35:37 -0000 (UTC)
    Lawrence D'Oliveiro <ldo@nz.invalid> wrote:
    There was no reason why you had to. You could easily have created
    your own distro without any of his code in it, if you wanted to. Or
    become an aficionado of one of the existing distros that did exactly
    that.
    Have done - been running Devuan since 2016.
    Open Source is all about choice. If you canrCOt stand the thought of
    people making different choices from you, you know what you can do.
    The fact that people are free to make stupid choices does not mean that
    other people aren't allowed to call out stupidity where they see it.
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Lawrence D'Oliveiro@ldo@nz.invalid to comp.unix.programmer on Mon Dec 16 19:51:36 2024
    From Newsgroup: comp.unix.programmer

    On Mon, 16 Dec 2024 08:16:28 -0000 (UTC), Muttley wrote:

    Far too many people think complicated = clever.

    You mean, clever like struggling with complicated workarounds to clunky, ancient init systems that donrCOt actually handle service management very well, when more modern ones solve long-standing problems in a much simpler
    and more elegant fashion?
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Lawrence D'Oliveiro@ldo@nz.invalid to comp.unix.programmer on Mon Dec 16 20:15:02 2024
    From Newsgroup: comp.unix.programmer

    On Mon, 16 Dec 2024 07:55:19 -0800, John Ames wrote:

    The fact that people are free to make stupid choices does not mean that
    other people aren't allowed to call out stupidity where they see it.

    Notice that all the complaints seem to go in one direction, not the other?
    We only see systemd-haters complaining about those using it, you donrCOt see systemd users complaining about those who donrCOt?
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From John Ames@commodorejohn@gmail.com to comp.unix.programmer on Mon Dec 16 12:44:55 2024
    From Newsgroup: comp.unix.programmer

    On Mon, 16 Dec 2024 20:15:02 -0000 (UTC)
    Lawrence D'Oliveiro <ldo@nz.invalid> wrote:
    Notice that all the complaints seem to go in one direction, not the
    other? We only see systemd-haters complaining about those using it,
    you donrCOt see systemd users complaining about those who donrCOt?
    That would likely be because systemd users are getting what they want,
    and aren't being pushed onto sysvinit by distro maintainers.
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Jim Jackson@jj@franjam.org.uk to comp.unix.programmer on Mon Dec 16 23:03:46 2024
    From Newsgroup: comp.unix.programmer

    On 2024-12-14, Lawrence D'Oliveiro <ldo@nz.invalid> wrote:
    On Sat, 14 Dec 2024 15:20:25 -0000 (UTC), Jim Jackson wrote:

    On 2024-12-13, Lawrence D'Oliveiro <ldo@nz.invalid> wrote:

    On Fri, 13 Dec 2024 20:07:58 -0000 (UTC), Jim Jackson wrote:

    On 2024-12-11, Nicolas George <nicolas$george@salle-s.org> wrote:

    Jim Jackson , dans le message <slrnvlk56u.2qa.jj@iridium.wf32df>, a
    ??crit??:

    My God, how did we all manage running services before systemd came >>>>>> along?

    Badly, with services that have crashed and nobody noticed for weeks.

    People keep saying that. But in my experience services were run as
    efficiently as they seem to be run today. Perhaps the team I worked in >>>> knew what it was doing :-)

    How many custom services were you running on a single machine, just out
    of curiosity?

    What do you mean by custom?

    Code that you had to write substantially from scratch, as opposed to configuring standard DBMS, Web, directory, MTA, DNS etc.


    Ok I've done specific network monitoring stuff from scratch - back in
    the day, when SNMP was a new thing. But it was easier to control than
    other stuff because I (and a couple of others) wrote it - we knew it -
    so what's difficult? We even transitioned it from pre-SYS-V init to
    SYS-V init, and I remember no difficulties.


    I ask because the standard services will already have their startup requirements worked out, because your own would require you to create your own startup scripts. Which is where the trouble would often start, with sysvinit.
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Jim Jackson@jj@franjam.org.uk to comp.unix.programmer on Mon Dec 16 23:07:37 2024
    From Newsgroup: comp.unix.programmer

    On 2024-12-16, Lawrence D'Oliveiro <ldo@nz.invalid> wrote:
    On Mon, 16 Dec 2024 07:55:19 -0800, John Ames wrote:

    The fact that people are free to make stupid choices does not mean that
    other people aren't allowed to call out stupidity where they see it.

    Notice that all the complaints seem to go in one direction, not the other? We only see systemd-haters complaining about those using it, you don???t see systemd users complaining about those who don???t?

    No. But I think some of us get a bit pissed at some people making out
    that previous inits were (almost) unworkable - which is palpably false.
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Lawrence D'Oliveiro@ldo@nz.invalid to comp.unix.programmer on Tue Dec 17 02:37:24 2024
    From Newsgroup: comp.unix.programmer

    On Mon, 16 Dec 2024 23:07:37 -0000 (UTC), Jim Jackson wrote:

    ... I think some of us get a bit pissed at some people making out
    that previous inits were (almost) unworkable - which is palpably false.

    Do you understand what a rCLstrawmanrCY argument is?
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Lawrence D'Oliveiro@ldo@nz.invalid to comp.unix.programmer on Tue Dec 17 02:39:51 2024
    From Newsgroup: comp.unix.programmer

    On Mon, 16 Dec 2024 23:03:46 -0000 (UTC), Jim Jackson wrote:

    Ok I've done specific network monitoring stuff from scratch - back in
    the day, when SNMP was a new thing. But it was easier to control than
    other stuff because I (and a couple of others) wrote it - we knew it -
    so what's difficult? We even transitioned it from pre-SYS-V init to
    SYS-V init, and I remember no difficulties.

    Anything with this <https://www.phoronix.com/news/Facebook-systemd-2018>
    level of complexity?
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Muttley@Muttley@DastardlyHQ.org to comp.unix.programmer on Tue Dec 17 08:34:54 2024
    From Newsgroup: comp.unix.programmer

    On Mon, 16 Dec 2024 19:51:36 -0000 (UTC)
    Lawrence D'Oliveiro <ldo@nz.invalid> wibbled:
    On Mon, 16 Dec 2024 08:16:28 -0000 (UTC), Muttley wrote:

    Far too many people think complicated = clever.

    You mean, clever like struggling with complicated workarounds to clunky, >ancient init systems that donrCOt actually handle service management very >well, when more modern ones solve long-standing problems in a much simpler >and more elegant fashion?

    Sure, but we're talking about systemd.

    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Muttley@Muttley@DastardlyHQ.org to comp.unix.programmer on Tue Dec 17 08:35:51 2024
    From Newsgroup: comp.unix.programmer

    On Tue, 17 Dec 2024 02:37:24 -0000 (UTC)
    Lawrence D'Oliveiro <ldo@nz.invalid> wibbled:
    On Mon, 16 Dec 2024 23:07:37 -0000 (UTC), Jim Jackson wrote:

    ... I think some of us get a bit pissed at some people making out
    that previous inits were (almost) unworkable - which is palpably false.

    Do you understand what a rCLstrawmanrCY argument is?

    Is it irony week again?

    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Rainer Weikusat@rweikusat@talktalk.net to comp.unix.programmer on Tue Dec 17 17:27:37 2024
    From Newsgroup: comp.unix.programmer

    Lawrence D'Oliveiro <ldo@nz.invalid> writes:
    On Mon, 16 Dec 2024 08:16:28 -0000 (UTC), Muttley wrote:
    Far too many people think complicated = clever.

    You mean, clever like struggling with complicated workarounds to clunky, ancient init systems that donrCOt actually handle service management very well, when more modern ones solve long-standing problems in a much simpler and more elegant fashion?

    The systemd-252 codebase which is used for Debian 12 is composed of
    (sloccount) 690,648 lines of code. That's anything but simple.
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Rainer Weikusat@rweikusat@talktalk.net to comp.unix.programmer on Tue Dec 17 17:28:41 2024
    From Newsgroup: comp.unix.programmer

    Lawrence D'Oliveiro <ldo@nz.invalid> writes:
    On Mon, 16 Dec 2024 07:55:19 -0800, John Ames wrote:
    The fact that people are free to make stupid choices does not mean that
    other people aren't allowed to call out stupidity where they see it.

    Notice that all the complaints seem to go in one direction, not the other? We only see systemd-haters complaining about those using it, you donrCOt see systemd users complaining about those who donrCOt?

    Hmm ... what do you think you are doing here?

    :-)
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Lawrence D'Oliveiro@ldo@nz.invalid to comp.unix.programmer on Tue Dec 17 19:44:20 2024
    From Newsgroup: comp.unix.programmer

    On Tue, 17 Dec 2024 08:34:54 -0000 (UTC), Muttley wrote:

    On Mon, 16 Dec 2024 19:51:36 -0000 (UTC) Lawrence D'Oliveiro
    <ldo@nz.invalid> wibbled:

    On Mon, 16 Dec 2024 08:16:28 -0000 (UTC), Muttley wrote:

    Far too many people think complicated = clever.

    You mean, clever like struggling with complicated workarounds to clunky, >>ancient init systems that donrCOt actually handle service management very >>well, when more modern ones solve long-standing problems in a much
    simpler and more elegant fashion?

    Sure, but we're talking about systemd.

    Why, what were you talking about?
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Lawrence D'Oliveiro@ldo@nz.invalid to comp.unix.programmer on Tue Dec 17 19:45:06 2024
    From Newsgroup: comp.unix.programmer

    On Tue, 17 Dec 2024 08:35:51 -0000 (UTC), Muttley wrote:

    On Tue, 17 Dec 2024 02:37:24 -0000 (UTC) Lawrence D'Oliveiro
    <ldo@nz.invalid> wibbled:

    On Mon, 16 Dec 2024 23:07:37 -0000 (UTC), Jim Jackson wrote:

    ... I think some of us get a bit pissed at some people making out that
    previous inits were (almost) unworkable - which is palpably false.

    Do you understand what a rCLstrawmanrCY argument is?

    ItrCOs when you try to tear down a false argument that the other side never made.
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Richard Kettlewell@invalid@invalid.invalid to comp.unix.programmer on Tue Dec 17 19:48:51 2024
    From Newsgroup: comp.unix.programmer

    Jim Jackson <jj@franjam.org.uk> writes:
    Lawrence D'Oliveiro <ldo@nz.invalid> wrote:
    On Mon, 16 Dec 2024 07:55:19 -0800, John Ames wrote:
    The fact that people are free to make stupid choices does not mean
    that other people aren't allowed to call out stupidity where they
    see it.

    Notice that all the complaints seem to go in one direction, not the
    other? We only see systemd-haters complaining about those using it,
    you don???t see systemd users complaining about those who don???t?

    No. But I think some of us get a bit pissed at some people making out
    that previous inits were (almost) unworkable - which is palpably false.

    rCyUnworkablerCO may be an exaggeration, but the practical issues and functionality gaps were real; even if you didnrCOt personally experience
    them, other people did. I think there were at least ten different
    attempts to come up with something better in the free software world
    alone. Meanwhile the commercial Unixes largely got their act together
    long before Linux did.

    Whether systemd was the best possible design, or just the best option available, is another question, and perhaps more opinion-based.
    --
    https://www.greenend.org.uk/rjk/
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Lawrence D'Oliveiro@ldo@nz.invalid to comp.unix.programmer on Tue Dec 17 20:45:16 2024
    From Newsgroup: comp.unix.programmer

    On Tue, 17 Dec 2024 19:48:51 +0000, Richard Kettlewell wrote:

    Whether systemd was the best possible design, or just the best option available, is another question, and perhaps more opinion-based.

    There were, and are, other open-source choices available. Nobody is
    holding a gun to anybodyrCOs head.
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Rainer Weikusat@rweikusat@talktalk.net to comp.unix.programmer on Tue Dec 17 20:54:11 2024
    From Newsgroup: comp.unix.programmer

    Richard Kettlewell <invalid@invalid.invalid> writes:
    Jim Jackson <jj@franjam.org.uk> writes:
    Lawrence D'Oliveiro <ldo@nz.invalid> wrote:
    On Mon, 16 Dec 2024 07:55:19 -0800, John Ames wrote:
    The fact that people are free to make stupid choices does not mean
    that other people aren't allowed to call out stupidity where they
    see it.

    Notice that all the complaints seem to go in one direction, not the
    other? We only see systemd-haters complaining about those using it,
    you don???t see systemd users complaining about those who don???t?

    No. But I think some of us get a bit pissed at some people making out
    that previous inits were (almost) unworkable - which is palpably false.

    rCyUnworkablerCO may be an exaggeration, but the practical issues and functionality gaps were real; even if you didnrCOt personally experience them, other people did. I think there were at least ten different
    attempts to come up with something better in the free software world
    alone. Meanwhile the commercial Unixes largely got their act together
    long before Linux did.

    Practical issue and functionality gaps and generally, a load of useless
    mess, were real in the rc systems mainstream Linux distributions had conventionally layered atop of sysvinit. These could have been addressed
    in a variety of ways but basically, nobody _working for RedHat_ ever
    tried until systemd. Then, RedHat drove the pretty much universal switch
    to it, just as it had already driven the switch to sysvinit and to glibc
    2 (known as libc6 in Linuxland) before.

    Whether systemd was the best possible design, or just the best option available,

    or possibly neither of both. It was the RedHat option available and
    that's what caused its universal adoption (combined with an extremely aggressive and extremely unpleasant propaganda campaign by systemd
    fanbois --- but without RedHat, these wouldn't have accomplished
    anything).

    BTW, on of the first things I learnt about systemd after I had to
    support it was that it still uses pid files.
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From gazelle@gazelle@shell.xmission.com (Kenny McCormack) to comp.unix.programmer on Tue Dec 17 22:00:10 2024
    From Newsgroup: comp.unix.programmer

    In article <vjsnsr$1t88k$2@dont-email.me>,
    Lawrence D'Oliveiro <ldo@nz.invalid> wrote:
    On Tue, 17 Dec 2024 19:48:51 +0000, Richard Kettlewell wrote:

    Whether systemd was the best possible design, or just the best option
    available, is another question, and perhaps more opinion-based.

    There were, and are, other open-source choices available. Nobody is
    holding a gun to anybodys head.

    As you well know, in a way, they are. In many circles, you can't get any support unless you are running the "approved" stuff, which means running systemd. Also, there are apps that depend on systemd, so if you want to
    run GreatNewApp_2.0, you need to adopt systemd.
    --
    The only thing Trump's made great again is Saturday Night Live.
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Jim Jackson@jj@franjam.org.uk to comp.unix.programmer on Wed Dec 18 21:19:09 2024
    From Newsgroup: comp.unix.programmer

    On 2024-12-17, Lawrence D'Oliveiro <ldo@nz.invalid> wrote:
    On Mon, 16 Dec 2024 23:03:46 -0000 (UTC), Jim Jackson wrote:

    Ok I've done specific network monitoring stuff from scratch - back in
    the day, when SNMP was a new thing. But it was easier to control than
    other stuff because I (and a couple of others) wrote it - we knew it -
    so what's difficult? We even transitioned it from pre-SYS-V init to
    SYS-V init, and I remember no difficulties.

    Anything with this <https://www.phoronix.com/news/Facebook-systemd-2018> level of complexity?

    Of course not - what a silly question. And the interesting thing was
    that their set up is SO complicated systemd is only a part of their
    solutions, which is sort of obvious. I'd have been more interested in a comparison of previous set up v. current with systemd.

    Their process for non-stop upgrades was a fairly standard one of old
    service handing over to new and having to notify and co-operate with
    systemd because systemd handles new connections. Previously I suspect
    their processes handled incoming connections directly and there would
    have been process-process link to do the hand over. Which one works out
    easier to program and manage I'm not sure. But given they'd gone for a solution Centos which had systemd init they had to adapt to it.

    Anyway it was interesting thanks for the pointer.
    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From scott@scott@slp53.sl.home (Scott Lurndal) to comp.unix.programmer on Wed Dec 18 22:16:36 2024
    From Newsgroup: comp.unix.programmer

    Jim Jackson <jj@franjam.org.uk> writes:


    Their process for non-stop upgrades was a fairly standard one of old
    service handing over to new and having to notify and co-operate with
    systemd because systemd handles new connections. Previously I suspect
    their processes handled incoming connections directly and there would
    have been process-process link to do the hand over. Which one works out >easier to program and manage I'm not sure. But given they'd gone for a >solution Centos which had systemd init they had to adapt to it.

    Modern non-stop systems route new connections at a higher level (e.g. netscaler)
    for both load balancing and resiliancy. systemd is not (thankfully)
    involved in that at all.

    --- Synchronet 3.21d-Linux NewsLink 1.2
  • From Jim Jackson@jj@franjam.org.uk to comp.unix.programmer on Wed Dec 18 22:25:15 2024
    From Newsgroup: comp.unix.programmer

    On 2024-12-18, Scott Lurndal <scott@slp53.sl.home> wrote:
    Jim Jackson <jj@franjam.org.uk> writes:


    Their process for non-stop upgrades was a fairly standard one of old >>service handing over to new and having to notify and co-operate with >>systemd because systemd handles new connections. Previously I suspect >>their processes handled incoming connections directly and there would
    have been process-process link to do the hand over. Which one works out >>easier to program and manage I'm not sure. But given they'd gone for a >>solution Centos which had systemd init they had to adapt to it.

    Modern non-stop systems route new connections at a higher level (e.g. netscaler)
    for both load balancing and resiliancy. systemd is not (thankfully)
    involved in that at all.

    Indeed, and for over 20 years. But, the talk did describe the adaptations needed for running a non-stop service on top of systemd on a single box.

    --- Synchronet 3.21d-Linux NewsLink 1.2