<div dir="ltr"><div><div><div><div>Admins expect output when starting and stopping services. <br></div>This is even more important when there are runbooks and other processes involved.<br></div>The journalctl output is very messy (because it is a log). When you are on call and you have to deal with an issue at 3am in the morning, the messy output adds to the already high cognitive load.<br></div>As system engineers we used to be able write our own init scripts that would leave colourized and concise messages about particular sub-services of a service.<br></div>This would make it easy for admin on call to determine if everything OK or not.<br><div><div><br></div><div>What is even more annoying when start up fails, it just tells you that it failed and for more info to see the status or journalctl. Would it not be more logical dump the standard error into current tty and status instead of pointless message?<br><br></div><div>There needs to be a setting to pass through stdout and error to whatever the tty is used to invoke the systemctl. <br><br></div><div>Warning: rant follows!<br></div><div><br></div><div>I am yet to see a systems engineer that praised systemd. All I hear from my colleagues is swearing when they deal with systemd. What makes them angry? Inability to actually see what is going on. Has mysql actually failed to start or is it repairing tables after a crash? Who knows, systemd ate the output. Is the firewall script actually doing what is supposed to do or not, who knows, there is no way to pass that information directly without systemd hiding it. The only way to catch errors with bash scripts is using "set -e" (there is no eye balling it), which means even partial functionality now is a failure.<br><br>Even simple things like where is the bloody unit defined, is it in /etc/systemd/system/ or /lib/systemd/system/ or is it in /usr/lib/systemd/system/?. What about tail -f 1000 /var/log/messages | grep bla | awk .. Can't really do that any more, as journalctl does not support number of lines to follow from (and again, I could be wrong here, I have been wrong many times). <br><br></div><div>Why /lib/ for essentially config files? Isn't what /etc/ is for?<br><br></div><div>Then we have the whole "predictable" interface naming scheme, with names like enp35s0f1. Very "predictable" (they change!) and very "easy" to type in middle of night.<br></div><div><br></div><div>I would take simplicity over boot up times any day. How often do you think we reboot our servers? I have no problem with actual unit definitions and what systemd as init system trying to do. <br>I have a problem with binary logs that simply discard all information after the corruption (right where fiber channel dropped couple of packets and you needed to see those IO erros). <br>I have a problem where dhcp clients, ntp and resolvers are being reinvented for sake of it (and with whole bunch of new security holes). <br></div><div><br>What happen to do one thing and do it well philosophy?<br><br></div>Regards.<br><br></div><div>Sergei.<br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On 14 August 2017 at 21:20, Zhujiafa <span dir="ltr"><<a href="mailto:zhujiafa@huawei.com" target="_blank">zhujiafa@huawei.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">




<div>
<div style="font-size:15px"></div>
<div><span>
<div style="MARGIN:10px;FONT-FAMILY:verdana;FONT-SIZE:10pt">
<div><span style="color:rgb(0,0,0);background-color:rgba(0,0,0,0)"><span class="">"  With systemd all output is <wbr>"hidden",  "<br>
<br></span>
         He just wanted to <wbr>see more detailed boot <wbr>messages<br>
         too determine the xxxx.service is correct !</span></div>
<div>========================</div>
<div>ZhuJiafa</div>
<div>email: <a href="mailto:zhujiafa@huawei.com" style="font-size:10pt;line-height:1.5;background-color:window" target="_blank">zhujiafa@huawei.com</a><span style="font-size:10pt;color:rgb(0,0,0);line-height:1.5;background-color:rgba(0,0,0,0)"> </span></div>
<div><span style="font-size:10pt;color:rgb(0,0,0);line-height:1.5;background-color:rgba(0,0,0,0)">tel: <a href="tel:+86%20186%205165%202661" value="+8618651652661" target="_blank">+86 18651652661</a></span></div>
<span style="color:rgb(0,0,0);background-color:rgba(0,0,0,0)"></span></div>
</span></div>
<blockquote style="margin-top:0px;margin-bottom:0px;margin-left:0.5em">
<div> </div>
<div style="border:none;border-top:solid #b5c4df 1.0pt;padding:3.0pt 0cm 0cm 0cm">
<div style="PADDING-RIGHT:8px;PADDING-LEFT:8px;FONT-SIZE:12px;FONT-FAMILY:tahoma;COLOR:#000000;BACKGROUND:#efefef;PADDING-BOTTOM:8px;PADDING-TOP:8px">
<div><b>From:</b> <a href="mailto:vcaputo@pengaru.com" target="_blank">vcaputo@pengaru.com</a></div>
<div><b>Date:</b> 2017-08-12 02:57</div>
<div><b>To:</b> <a href="mailto:zhujiafa@huawei.com" target="_blank">Zhujiafa</a></div>
<div><b>CC:</b> <a href="mailto:h.reindl@thelounge.net" target="_blank">Reindl Harald</a>; <a href="mailto:systemd-devel@lists.freedesktop.org" target="_blank">
systemd-devel@lists.<wbr>freedesktop.org</a></div><div><div class="h5">
<div><b>Subject:</b> Re: [systemd-devel] Outputting STDOUT and STDERR to current $SSH_TTY</div>
</div></div></div>
</div><div><div class="h5">
<div>
<div class="m_-8297062355724644919FoxDiv20170814171631085747">
<p><font size="2">This is not recommended.  Forwarding is currently implemented<br>
synchronously in journald, and can have a very substantial negative<br>
impact on journald performance in general as a result.<br>
<br>
BTW: are we not averse to top-posting on systemd-devel?<br>
<br>
Regards,<br>
Vito Caputo<br>
<br>
<br>
On Fri, Aug 11, 2017 at 05:47:15AM +0000, Zhujiafa wrote:<br>
> add<br>
> " systemd.journald.forward_to_<wbr>console=1 "<br>
>  to your kernel  parameters.<br>
><br>
><br>
> ______________________________<wbr>__<br>
> ========================<br>
> ZhuJiafa<br>
> email: <a href="mailto:zhujiafa@huawei.com" target="_blank">zhujiafa@huawei.com</a><<a href="mailto:zhujiafa@huawei.com" target="_blank">mailto:<wbr>zhujiafa@huawei.com</a>><br>
> tel: <a href="tel:+86%20186%205165%202661" value="+8618651652661" target="_blank">+86 18651652661</a><br>
><br>
> From: Reindl Harald<<a href="mailto:h.reindl@thelounge.net" target="_blank">mailto:h.reindl@<wbr>thelounge.net</a>><br>
> Date: 2017-08-11 13:37<br>
> To: <a href="mailto:systemd-devel@lists.freedesktop.org" target="_blank">systemd-devel@lists.<wbr>freedesktop.org</a><<a href="mailto:systemd-devel@lists.freedesktop.org" target="_blank">mailto:<wbr>systemd-devel@lists.<wbr>freedesktop.org</a>><br>
> Subject: Re: [systemd-devel] Outputting STDOUT and STDERR to current $SSH_TTY<br>
><br>
><br>
><br>
> Am 11.08.2017 um 04:29 schrieb Sergei Franco:<br>
> > I am trying to retain behaviour of the startup scripts the same as sysvinit.<br>
> > For example, on sysv the script outputs feedback to the console when the<br>
> > stopping and starting is done via console.<br>
> > With systemd all output is "hidden", and to see the output you need to<br>
> > check the journal (or syslog if configured). There is no feedback.<br>
> ><br>
> > Is it possible to configure StandardOutput=tty (and StandardErrror)<br>
> > where TTYPath= is set to current $SSH_TTY env (be that<br>
> > /devpts/0,/dev/pts/1 or /dev/pts/n)?<br>
><br>
> no, because PID1 is a completly different process than any TTY<br>
> ______________________________<wbr>_________________<br>
> systemd-devel mailing list<br>
> <a href="mailto:systemd-devel@lists.freedesktop.org" target="_blank">systemd-devel@lists.<wbr>freedesktop.org</a><br>
> <a href="https://lists.freedesktop.org/mailman/listinfo/systemd-devel" target="_blank">https://lists.freedesktop.org/<wbr>mailman/listinfo/systemd-devel</a><br>
<br>
> ______________________________<wbr>_________________<br>
> systemd-devel mailing list<br>
> <a href="mailto:systemd-devel@lists.freedesktop.org" target="_blank">systemd-devel@lists.<wbr>freedesktop.org</a><br>
> <a href="https://lists.freedesktop.org/mailman/listinfo/systemd-devel" target="_blank">https://lists.freedesktop.org/<wbr>mailman/listinfo/systemd-devel</a><br>
<br>
</font></p>
</div>
</div>
</div></div></blockquote>
</div>

<br>______________________________<wbr>_________________<br>
systemd-devel mailing list<br>
<a href="mailto:systemd-devel@lists.freedesktop.org">systemd-devel@lists.<wbr>freedesktop.org</a><br>
<a href="https://lists.freedesktop.org/mailman/listinfo/systemd-devel" rel="noreferrer" target="_blank">https://lists.freedesktop.org/<wbr>mailman/listinfo/systemd-devel</a><br>
<br></blockquote></div><br></div>