Re: Systemd services (was Re: If Linux Is About Choice, Why Then ...)

2017-04-21 Thread Nicholas Geovanis
Like numerous linux users I have sometimes lamented coming to terms with
systemd. My belief is that it's a well-written collection of software which
is somewhat over-engineered. It fills a need, sure, though I've managed to
live and work without it for a long time (been using linux since 1994). And
who am I to question Torvalds and Co. on the subject of its suitability for
linux and the data center?

So the other day I was on a recently-built Amazon AWS EC2 instance, running
one of the AWS-branded linux AMIs, fixing things in /etc/init.d. Thinking
about how AWS might rule the world someday, since they already hold about
35-40% of the public cloud (
http://www.geekwire.com/2017/cloud-report-card-amazon-web-services-12b-juggernaut-microsoft-google-gaining/).
Then I had one of those "Duh!" moments: There must be on-the-order-of a
million of linux instances on the planet which are _not_ running systemd,
as AWS's own linux AMIs do not by default.

It seems to me that this data point has been completely ignored in the
years-long discussions about systemd's merits, flaws and suitability.

On Mon, Apr 17, 2017 at 4:34 PM, Jonathan Dowland  wrote:

> On Fri, Apr 14, 2017 at 03:17:00PM +0200, Nicolas George wrote:
> > Note: systemd is not for end-users, it is for system administrator and
> > distribution authors.
>
> {systemctl,journalctl,etc.} --user beg to differ.
>
>
> --
> ⢀⣴⠾⠻⢶⣦⠀
> ⣾⠁⢠⠒⠀⣿⡁ Jonathan Dowland
> ⢿⡄⠘⠷⠚⠋⠀ https://jmtd.net
> ⠈⠳⣄ Please do not CC me, I am subscribed to the list.
>


Re: Systemd services (was Re: If Linux Is About Choice, Why Then ...)

2017-04-17 Thread Jonathan Dowland
On Fri, Apr 14, 2017 at 03:17:00PM +0200, Nicolas George wrote:
> Note: systemd is not for end-users, it is for system administrator and
> distribution authors.

{systemctl,journalctl,etc.} --user beg to differ.


-- 
⢀⣴⠾⠻⢶⣦⠀ 
⣾⠁⢠⠒⠀⣿⡁ Jonathan Dowland
⢿⡄⠘⠷⠚⠋⠀ https://jmtd.net
⠈⠳⣄ Please do not CC me, I am subscribed to the list.


signature.asc
Description: Digital signature


Re: Re: Systemd services (was Re: If Linux Is About Choice, Why Then ...)

2017-04-16 Thread Laurent Bigonville

Greg Wooledge > wrote:

On Fri, Apr 14, 2017 at 03:17:00PM +0200, Nicolas George wrote:
> Le quintidi 25 germinal, an CCXXV, Greg Wooledge a écrit :
> > Some day there will be actual end-user-friendly systemd documentation
> > somewhere, consolidating all of these pieces of wisdom together.  I hope.
>
> Note: systemd is not for end-users, it is for system administrator and
> distribution authors.

The end users of systemd are Linux system administrators.  You and me.
The people on this mailing list.  That's us, the users.  That's why
it's called "debian-user".

If you'd prefer "Some day there will be a system administrator's guide
for systemd", that's an acceptable wording.

There is already extensive documentation about how to administrate systemd:

https://www.freedesktop.org/wiki/Software/systemd/#manualsanddocumentationforusersandadministrators

"The systemd for Administrators Blog Series" worth reading.


Re: Systemd services (was Re: If Linux Is About Choice, Why Then ...)

2017-04-14 Thread Joel Rees
On Fri, Apr 14, 2017 at 9:37 PM, Greg Wooledge  wrote:
> [...]
>Don't even get me started on sshd.service vs. ssh.service.  Do you
>have any idea how hard it is to notice that extra/missing "d", and
>figure out why things Simply Do Not Work?

Well, that demonstrates that the concept of tagging a "d" on the end
of a name to indicate the daemon part well predates systemd, and
probably should be reconsidered in a world where short names are no
longer required.

Not sure how that relates to the rest of the issues you are trying to
work through.

-- 
Joel Rees

I'm imagining I'm a novelist:
http://joel-rees-economics.blogspot.com/2017/01/soc500-00-00-toc.html
More of my delusions:
http://reiisi.blogspot.jp/p/novels-i-am-writing.html



Re: Systemd services (was Re: If Linux Is About Choice, Why Then ...)

2017-04-14 Thread Jonathan de Boyne Pollard
Greg Wooledge:
> Don't even get me started on sshd.service vs. ssh.service.  Do
> you have any idea how hard it is to notice that extra/missing “d”, 
> and figure out why things Simply Do Not Work?

* http://www.mail-archive.com/supervision@list.skarnet.org/msg01486.html

* https://unix.stackexchange.com/a/303302/5132

Yes.



Re: Systemd services (was Re: If Linux Is About Choice, Why Then ...)

2017-04-14 Thread Martin Read

On 14/04/17 14:17, Nicolas George wrote:

Le quintidi 25 germinal, an CCXXV, Greg Wooledge a écrit :

Some day there will be actual end-user-friendly systemd documentation
somewhere, consolidating all of these pieces of wisdom together.  I hope.


Note: systemd is not for end-users, it is for system administrator and
distribution authors.


systemd is absolutely for end-users, because:

* Some systemd-running systems are home desktop computers with a single 
physical user; in this case, the distinction between "administrator" and 
"user" may well only exist as a hallucination of the computer, with no 
basis in the external physical world. If the computer I'm typing this 
e-mail on breaks down, I have to fix it myself.


* systemd can, in any event, be used to manage service-like processes 
that form part of a user's login session, using unit files stored in 
that user's XDG Base Directories.




Re: Systemd services (was Re: If Linux Is About Choice, Why Then ...)

2017-04-14 Thread Greg Wooledge
On Fri, Apr 14, 2017 at 03:17:00PM +0200, Nicolas George wrote:
> Le quintidi 25 germinal, an CCXXV, Greg Wooledge a écrit :
> > Some day there will be actual end-user-friendly systemd documentation
> > somewhere, consolidating all of these pieces of wisdom together.  I hope.
> 
> Note: systemd is not for end-users, it is for system administrator and
> distribution authors.

The end users of systemd are Linux system administrators.  You and me.
The people on this mailing list.  That's us, the users.  That's why
it's called "debian-user".

If you'd prefer "Some day there will be a system administrator's guide
for systemd", that's an acceptable wording.



Re: Systemd services (was Re: If Linux Is About Choice, Why Then ...)

2017-04-14 Thread Dejan Jocic
On 14-04-17, Nicolas George wrote:
> Le quintidi 25 germinal, an CCXXV, Greg Wooledge a écrit :
> > Some day there will be actual end-user-friendly systemd documentation
> > somewhere, consolidating all of these pieces of wisdom together.  I hope.
> 
> Note: systemd is not for end-users, it is for system administrator and
> distribution authors.
> 
Actually, it should be for end-user too. On personal computer, that
end-user is system administrator. I also find that systemd is very well
documented. But it could be just me. Now, please carry on, enjoyed this
thread very much, learned thing, or two :)

Thank you for your time.







Re: Systemd services (was Re: If Linux Is About Choice, Why Then ...)

2017-04-14 Thread Nicolas George
Le quintidi 25 germinal, an CCXXV, Greg Wooledge a écrit :
> Some day there will be actual end-user-friendly systemd documentation
> somewhere, consolidating all of these pieces of wisdom together.  I hope.

Note: systemd is not for end-users, it is for system administrator and
distribution authors.

> 1) To override parts of a distribution's systemd unit locally, you MUST
>use the foo.service.d/ method.  You can't just put the override bits
>into an /etc/systemd/system/foo.service file.  That would be too easy.

foo.service.d/*.confis for overriding bits.
/etc/systemd/system/foo.service is for overriding the whole file.

I find that fairly natural. Otherwise, how would you override the whole
file?

> 2) The files inside foo.service.d/ MUST end with a .conf suffix.  (Cf.
>the wheezy->jessie apache2 upgrade, and having to rename every single
>one of my virtual domain config files AND the symlinks to them.)

After having been bitten by old *.conf~ backup files left by an editor,
I must say I find that restriction quite useful.

> 3) foo.service.d/ must use the CANONICAL service name of whatever it is
>that you're trying to override.  This may not be the same as the
>Debian package name.  For example, the nfs-kernel-server package
>creates a systemd unit named nfs-server.service with an ALIAS of
>nfs-kernel-server.service.  If you try to create override files in
>nfs-kernel-server.service.d/ it will not work correctly.  They have
>to be in nfs-server.service.d/ instead.
> 
>Don't even get me started on sshd.service vs. ssh.service.  Do you
>have any idea how hard it is to notice that extra/missing "d", and
>figure out why things Simply Do Not Work?

On the other hand, if systemd were to read snippets of configuration
with a subtly different name, someone else (or maybe be even yourself!)
would have complained about wasted time because of a stale config
snippet that should not have been read.

I find that strict rules are usually more convenient in the long run.

Note that you can use "systemctl edit" to have an editor started on the
exact correct file.

Regards,

-- 
  Nicolas George


signature.asc
Description: Digital signature


Re: Systemd services (was Re: If Linux Is About Choice, Why Then ...)

2017-04-14 Thread Greg Wooledge
On Thu, Apr 13, 2017 at 10:01:25PM +0100, Jonathan de Boyne Pollard wrote:
> ... albeit poorly.  If one wants to run daemontools under systemd, svscanboot 
> is
> not the way; svscanboot is a thing of the past
> http://jdebp.eu./FGA/inittab-is-history.html#svscanboot , and was a source of
> problems long before systemd was invented.

Cool.  I wish my Google searching had stumbled upon that, when I was
trying to figure out how to do all that stuff.

> The world wants you to clean your screen
> http://unix.stackexchange.com/a/233855/5132 , and this is merely one of the 
> ways
> that it makes you do so.

Some day there will be actual end-user-friendly systemd documentation
somewhere, consolidating all of these pieces of wisdom together.  I hope.

My own contributions toward that effort have been riddled with failure and
confusion, for which I am sorry.  I'm honestly *trying*, but this stuff is
really opaque at times.

For instance, just this week I learned three new things:

1) To override parts of a distribution's systemd unit locally, you MUST
   use the foo.service.d/ method.  You can't just put the override bits
   into an /etc/systemd/system/foo.service file.  That would be too easy.

2) The files inside foo.service.d/ MUST end with a .conf suffix.  (Cf.
   the wheezy->jessie apache2 upgrade, and having to rename every single
   one of my virtual domain config files AND the symlinks to them.)

3) foo.service.d/ must use the CANONICAL service name of whatever it is
   that you're trying to override.  This may not be the same as the
   Debian package name.  For example, the nfs-kernel-server package
   creates a systemd unit named nfs-server.service with an ALIAS of
   nfs-kernel-server.service.  If you try to create override files in
   nfs-kernel-server.service.d/ it will not work correctly.  They have
   to be in nfs-server.service.d/ instead.

   Don't even get me started on sshd.service vs. ssh.service.  Do you
   have any idea how hard it is to notice that extra/missing "d", and
   figure out why things Simply Do Not Work?



Re: Systemd services (was Re: If Linux Is About Choice, Why Then ...)

2017-04-03 Thread deloptes
Kevin O'Gorman wrote:

> Are you sure?  On my system, this produces nothing at all.  But the
> directory
> exists and is populated.

It works great in jessie

$ systemd --version
systemd 215
+PAM +AUDIT +SELINUX +IMA +SYSVINIT +LIBCRYPTSETUP +GCRYPT +ACL
+XZ -SECCOMP -APPARMOR




Re: Systemd services (was Re: If Linux Is About Choice, Why Then ...)

2017-04-03 Thread Nicholas Geovanis
On Mon, Apr 03, 2017 at 09:36:16AM -0500, Tom Browder wrote:
> But I kind of understand why systemd, but I wish I could find a good
> cookbook description of how to add or modify a new process.

I like the "systemd vs. sysvinit" cheatsheet at
http://linoxide.com/linux-command/systemd-vs-sysvinit-cheatsheet/

.Nick

On Mon, Apr 3, 2017 at 11:14 AM, Kevin O'Gorman  wrote:

>
>
> On Mon, Apr 3, 2017 at 8:39 AM, Greg Wooledge  wrote:
>
>> On Mon, Apr 03, 2017 at 09:36:16AM -0500, Tom Browder wrote:
>> > But I kind of understand why systemd, but I wish I could find a good
>> > cookbook description of how to add or modify a new process.
>>
>> The first hurdle is learning the terminology that systemd uses.  It's
>> not exactly intuitive.
>>
>
>
>> [...]
>>
>> If you want to change your system's "run level" from graphical.target
>> to multi-user.target, run this command as root:
>>
>> # systemctl set-default multi-user.target
>>
>> To see a list of your available targets (assuming no major local changes),
>> use this command:
>>
>> $ find /lib/systemd/ -name '*.target'
>>
>>
> Are you sure?  On my system, this produces nothing at all.  But the
> directory
> exists and is populated.
>
>
>
> --
> Kevin O'Gorman
> #define QUESTION ((bb) || (!bb))   /* Shakespeare */
>
> Please consider the environment before printing this email.
>


Re: Systemd services (was Re: If Linux Is About Choice, Why Then ...)

2017-04-03 Thread Joshua Schaeffer
On Mon, Apr 3, 2017 at 10:14 AM, Kevin O'Gorman  wrote:

>
>> To see a list of your available targets (assuming no major local changes),
>> use this command:
>>
>> $ find /lib/systemd/ -name '*.target'
>>
>>
> Are you sure?  On my system, this produces nothing at all.  But the
> directory
> exists and is populated.
>

What version of systemd do you have installed?

#systemd --version


Re: Systemd services (was Re: If Linux Is About Choice, Why Then ...)

2017-04-03 Thread Kevin O'Gorman
On Mon, Apr 3, 2017 at 8:39 AM, Greg Wooledge  wrote:

> On Mon, Apr 03, 2017 at 09:36:16AM -0500, Tom Browder wrote:
> > But I kind of understand why systemd, but I wish I could find a good
> > cookbook description of how to add or modify a new process.
>
> The first hurdle is learning the terminology that systemd uses.  It's
> not exactly intuitive.
>


> [...]
>
> If you want to change your system's "run level" from graphical.target
> to multi-user.target, run this command as root:
>
> # systemctl set-default multi-user.target
>
> To see a list of your available targets (assuming no major local changes),
> use this command:
>
> $ find /lib/systemd/ -name '*.target'
>
>
Are you sure?  On my system, this produces nothing at all.  But the
directory
exists and is populated.



-- 
Kevin O'Gorman
#define QUESTION ((bb) || (!bb))   /* Shakespeare */

Please consider the environment before printing this email.