<div dir="ltr"><div><div>Hey all,<br><br>I'm starting upgrades to old production servers to newer 64-bit Linux that runs systemd >= v195.<br><br>Serial consoles are always my 1st step.  Before upgrade it worked great.<br>
<br>After upgrade, with the new systemd-based config, I'm not having much luck so far.<br><br>I configured the grub conf:<br><br>serial --unit=0 --speed=57600 --word=8 --parity=no --stop=1<br>terminal --timeout=3 serial console<br>
title PRODUCTION<br> root (hd0,0)<br> kernel /vmlinuz root=/dev/sd1a noresume showopts x11failsafe vga=0x31a console=tty0 console=com1,vga<br> initrd /initrd<br><br>I installed the getty service on S0:<br><br>cat /etc/systemd/system/getty.target.wants/serial-getty@ttyS0.service<br>
    [Unit]<br>    Description=Serial Getty on %I<br>    Documentation=systemd-getty-generator<br>    BindsTo=dev-%i.device<br>    After=dev-%i.device systemd-user-sessions.service<br>    Before=getty.target<br>    IgnoreOnIsolate=yes<br>
<br>    [Service]<br>    ExecStart=-/sbin/agetty -s %I 57600 vt102<br>    Type=idle<br>    Restart=always<br>    RestartSec=0<br>    UtmpIdentifier=%I<br>    TTYPath=/dev/%I<br>    TTYReset=yes<br>    TTYVHangup=yes<br>    KillMode=process<br>
    IgnoreSIGPIPE=no<br>    KillSignal=SIGHUP<br><br>    [Install]<br>    WantedBy=getty.target<br><br><br>After a system boot the service is up:<br><br>systemctl status serial-getty@ttyS0.service<br>serial-getty@ttyS0.service - Serial Getty on ttyS0<br>
          Loaded: loaded (/etc/systemd/system/serial-getty@.service; enabled)<br>          Active: active (running) since Wed, 2013-07-10 10:55:13 PDT; 16min ago<br>            Docs: man:agetty(8)<br>                  man:systemd-getty-generator(8)<br>
        Main PID: 1043 (agetty)<br>          CGroup: name=systemd:/system/serial-getty@.service/ttyS0<br>                  └ 1043 /sbin/agetty -s ttyS0 57600 vt102<br><br>Jul 10 10:55:13 rosencrantz.lan systemd[1]: Starting Serial Getty on ttyS0...<br>
Jul 10 10:55:13 rosencrantz.lan systemd[1]: Started Serial Getty on ttyS0.<br><br>ps ax | grep S0<br> 1043 ttyS0    Ss+    0:00 /sbin/agetty -s ttyS0 57600 vt102<br><br>dmesg looks like the serial port is active:<br><br>dmesg | egrep -i "S0|serial|console|tty" | egrep -vi "usb"<br>
    [    0.000000] Command line: root=/dev/sd1a noresume showopts x11failsafe vga=0x31a console=tty0 console=com1,vga<br>    [    0.000000] Kernel command line: root=/dev/sd1a noresume showopts x11failsafe vga=0x31a console=tty0 console=com1,vga<br>
    [    0.000000] console [tty0] enabled<br>    [    0.218685] ACPI: (supports S0 S1 S3 S4 S5)<br>    [    1.228895] Console: switching to colour frame buffer device 160x64<br>    [    1.318499] Serial: 8250/16550 driver, 32 ports, IRQ sharing disabled<br>
    [    1.339563] 00:07: ttyS0 at I/O 0x3f8 (irq = 4) is a 16550A<br>    [   21.032996] systemd[1]: Expecting device dev-ttyS0.device...<br>    [   21.739832] systemd[1]: Starting Dispatch Password Requests to Console Directory Watch.<br>
    [   21.775883] systemd[1]: Started Dispatch Password Requests to Console Directory Watch.<br>    [   24.305690] systemd[1]: Starting Setup Virtual Console...<br>    [   25.384797] systemd[1]: Started Setup Virtual Console.<br>
    [   26.942274] systemd[1]: Found device /dev/ttyS0.<br>    [   32.493821] Console: switching to colour dummy device 80x25<br>    [   32.691960] Console: switching to colour frame buffer device 240x67<br>    [   41.849014] systemd[1]: Starting Console System Startup Logging...<br>
    [   42.550658] systemd[1]: Started Console System Startup Logging.<br><br></div>With that setup I get nothing out the serial port.  I probably have the grub cmd line wrong for using with systemd.  I could use some help getting this untangled.<br>
<br></div>Dave<br></div>