Subject: Re: [bug#30464] [PATCH 1/2] services: Add console-agetty-service.

From: Danny Milosavljevic <[email-masked]>
Date: Thu, 15 Feb 2018 16:41:35 +0100

Hi Ludo,

On Thu, 15 Feb 2018 15:40:14 +0100
[email-masked] (Ludovic Courtès) wrote:

> Could you explain the rationale?
> 
> The only difference is that this shepherd service depends on ‘syslogd’
> whereas the current agetty service doesn’t, right?

Yes, it's my inner OCD.

Right now, the agetty is started while the Linux kernel is still booting and
printing stuff to the console.  So you have two parties printing stuff
to the same console simultaneously.  That looks ... not nice.

What this would do is the getty would only be started (and printing stuff)
after syslogd.  The first thing syslogd does is it disables the Linux direct
console printing.

It doesn't make sense to have agetty itself depend on syslogd because
agetty can be (and usually is) used for modems etc which have nothing
to do with the local console.

> > +(define* (console-agetty-service config)
> > +  "Return a service to run agetty according to @var{config}, which specifies
> > +the tty to run, defaulting to the Linux console."
> > +  (service console-agetty-service-type config))  
> 
> In general we don’t provide such procedures any more and instead expose
> service types and configs directly.

Okay, I can remove that one and inline it at the (only) call site.