RobertR
Posts: 6
Joined: Mon Mar 16, 2015 10:53 pm

Systemd Jessie errors

Mon Mar 16, 2015 11:00 pm

I've updated my Raspberry to Jessie and now I've a lot of errors during booting

[FAILED] Failed to start Login Service.
[FAILED] Failed to start LSB: Start and stop the mysql database server daemon
[FAILED] Failed to start LSB: Start NTP daemon.
[FAILED] Failed to start Avahi mDNS/DNS-SD Stack.

and finally it hangs afters
[OK] Started Permit User Sessions.

Look forward to your advise.

ktb
Posts: 1380
Joined: Fri Dec 26, 2014 7:53 pm

Re: Systemd Jessie errors

Tue Mar 17, 2015 4:32 am

Yes, it's a mess.

After struggling with getting it to work reliably with minimal services running, I gave up. I compiled the latest version of dbus just in case that was the main problem. That didn't make a difference. I haven't decided if compiling the latest systemd is worth it or not. The debian systemd bugs list seems to have enough important outstanding issues to avoid using it for now.

I've been using init=/lib/sysvinit/init in /boot/cmdline.txt instead of init=/bin/systemd.

If you're interested in trying to debug the issues, you can add systemd.debug-shell to cmdline.txt. That should open up a root shell (Ctrl+Alt+F9) which can help you check why things are hanging (systemctl list-jobs and systemctl list-units --failed). For fsck-ing the root file system, you can can boot with init=/bin/systemd systemd.unit=emergency.target in cmdline.txt.

itsmedoofer
Posts: 230
Joined: Wed Sep 25, 2013 8:43 am

Re: Systemd Jessie errors

Tue Mar 17, 2015 6:18 am

Dougie tried Jessie and came to the same conclusion, it's just not ready for prime time, too many issues with systemd...

RobertR
Posts: 6
Joined: Mon Mar 16, 2015 10:53 pm

Re: Systemd Jessie errors

Tue Mar 17, 2015 7:29 am

Thanks.

Adding init=/lib/sysvinit/init in /boot/cmdline.txt solved my boot problem.

Once I've some time I will have a look into debugging of Systemd.

diederik
Posts: 389
Joined: Wed Mar 26, 2014 11:17 pm

Re: Systemd Jessie errors

Tue Mar 17, 2015 2:50 pm

Do you have systemd-sysv installed?

ktb
Posts: 1380
Joined: Fri Dec 26, 2014 7:53 pm

Re: Systemd Jessie errors

Tue Mar 17, 2015 7:37 pm

diederik wrote:Do you have systemd-sysv installed?
I do.

RobertR
Posts: 6
Joined: Mon Mar 16, 2015 10:53 pm

Re: Systemd Jessie errors

Tue Mar 17, 2015 7:37 pm

diederik wrote:Do you have systemd-sysv installed?
Yes I have

Arto1234
Posts: 18
Joined: Mon Aug 25, 2014 4:28 pm

Re: Systemd Jessie errors

Sat Apr 18, 2015 6:02 pm

Thank you RobertR!
"Adding init=/lib/sysvinit/init in /boot/cmdline.txt solved my boot problem."

solved my problem too! :)

Arto

ktb
Posts: 1380
Joined: Fri Dec 26, 2014 7:53 pm

Re: Systemd Jessie errors

Wed Apr 29, 2015 7:05 am

I tried upgrading to Raspbian Jessie again after being encouraged from reading about other forum member's posts. At least a few people have said they are using it without problems. Unfortunately, systemd still malfunctions reliably for me. :(

Image
Image
Last edited by ktb on Wed Apr 29, 2015 9:22 am, edited 1 time in total.

User avatar
rpdom
Posts: 11563
Joined: Sun May 06, 2012 5:17 am
Location: Essex, UK

Re: Systemd Jessie errors

Wed Apr 29, 2015 7:22 am

I don't use systemd on jessie (yet - I've still got to learn how to use it properly). I have sysvinit and sysvinitcore installed. They work as expected.

User avatar
DougieLawson
Posts: 29776
Joined: Sun Jun 16, 2013 11:19 pm
Location: Basingstoke, UK
Contact: Website

Re: Systemd Jessie errors

Wed Apr 29, 2015 9:03 am

ktb wrote:I tried upgrading to Raspbian Jessie again after being encouraged from reading about other forum member's posts. At least a few people have said they are using it without problems. Unfortunately, systemd still malfunctions reliably for me. :(
I've got two systems running systemd, one of them (2B) failed a reboot yesterday when the shutdown didn't complete. Systemd on Jessie is not ready for prime time and certainly not ready for the new Raspberry Pi users.

I'm strongly resisting the urge to revert my Jessie systems (one B, on 2B) to sysvinit.

My home server (B+) is running Wheezy and it's sticking on it until at least April 2016 (Wheezy is still the LTS release until May 2018).
Microprocessor, Raspberry Pi & Arduino Hacker
Mainframe database troubleshooter
MQTT Evangelist
Twitter: @DougieLawson

Since 2012: 1B*5, 2B*2, B+, A+, Zero*2, 3B*3

Please post ALL technical questions on the forum. Do not send private messages.

towolf
Posts: 421
Joined: Fri Jan 18, 2013 2:11 pm

Re: Systemd Jessie errors

Wed Apr 29, 2015 11:18 am

[SNIP]

Had a mostly unused, vanilla but stripped-down Raspbian wheezy SD card. I didn’t want to try this on my main Rpi "server".

I changed s/wheezy/jessie in sources.list and did a dist-upgrade. It asked some questions during the upgrade, but nothing unusual for a dist-upgrade.

After reboot it came back up with no serious errors and I wanted to see what’s up with the services in terms of duplication.

/etc/init.d/networking, /etc/init.d/ifplugd, /etc/init.d/console-setup, /etc/init.d/keyboard-setup, /etc/init.d/kbd, /etc/init.d/ntp, /etc/init.d/rsyslog, /etc/init.d/dphys-swapfile, /etc/init.d/cron were all active and integrated into systemd startup with the SysV compatibility mode. They featured prominently at the top of "systemd-analyze blame" and slowed the bootup. I removed them all with "systemctl disable".

/etc/init.d/networking I replaced with systemd-networkd.service and the appropriate snippet in /etc/systemd/network

/etc/init.d/rsyslog I uninstalled and set the SystemD journal to "volatile" memory-only logging. I don’t need on-disk persistent logging.

/etc/init.d/ntp I replaced with systemd-timesyncd. It brings up time reliably when the interface is up and replaces fake-hwclock as well.

The console, keyboard, and swap things are unnecessary for me.


Now the Rpi B 1 boots in 11 seconds (and that includes bringing up the wifi with wpa_supplicant, without it would boot in 9s)

Code: Select all

towolf@snopai:~$ systemd-analyze 
Startup finished in 2.646s (kernel) + 9.033s (userspace) = 11.680s
towolf@snopai:~$ systemd-analyze blame
           999ms systemd-logind.service
           727ms systemd-udev-trigger.service
           527ms systemd-resolved.service
           450ms systemd-networkd.service
           435ms systemd-fsck-root.service
           367ms kmod-static-nodes.service
           357ms systemd-update-utmp-runlevel.service
           336ms dev-mqueue.mount
           279ms systemd-timesyncd.service
           267ms systemd-journal-flush.service
           254ms systemd-remount-fs.service
           243ms systemd-fsck@dev-mmcblk0p1.service
           216ms systemd-modules-load.service
           207ms sys-kernel-debug.mount
           181ms rc-local.service
           170ms systemd-tmpfiles-setup.service
           163ms systemd-tmpfiles-setup-dev.service
           163ms user@1001.service
           159ms systemd-update-utmp.service
           151ms systemd-sysctl.service
           148ms sys-kernel-config.mount
           136ms boot.mount
           116ms systemd-random-seed.service
           110ms systemd-udevd.service
            95ms systemd-tmpfiles-clean.service
            91ms tmp.mount
            85ms systemd-user-sessions.service
            58ms udev-finish.service
towolf@snopai:~$ systemd-analyze critical-chain
The time after the unit is active or started is printed after the "@" character.
The time the unit takes to start is printed after the "+" character.

graphical.target @8.466s
└─multi-user.target @8.446s
  └─wpa_supplicant@wlan0.service @8.401s
    └─sys-subsystem-net-devices-wlan0.device @8.360s

I already knew SystemD from Archlinux ARM on my other Rpi. It’s way spiffier and more efficient than old style SysV Debian.

Dunno what happens when installing random, heavy services though. This is with stripped-down console-only Jessie.

texy
Forum Moderator
Forum Moderator
Posts: 4997
Joined: Sat Mar 03, 2012 10:59 am
Location: Berkshire, England

Re: Systemd Jessie errors

Wed Apr 29, 2015 1:28 pm

towolf I have removed the unnecessary "verbal attack mode" sentence from your post - please play nice, this is a family oriented forum..........
Texy
Various male/female 40- and 26-way GPIO header for sale here ( IDEAL FOR YOUR PiZero ):
https://www.raspberrypi.org/forums/viewtopic.php?f=93&t=147682#p971555

towolf
Posts: 421
Joined: Fri Jan 18, 2013 2:11 pm

Re: Systemd Jessie errors

Wed Apr 29, 2015 1:54 pm

Ugh, sorry about referencing the concept that describes a self-congratulatory geometry.

On Reddit this has become somewhat a "terminus technicus" for some kind of a cabbalistic echo chamber.

No "attack" intended.

ktb
Posts: 1380
Joined: Fri Dec 26, 2014 7:53 pm

Re: Systemd Jessie errors

Thu Apr 30, 2015 7:50 am

I haven't tested this much, but It seems that removing cgroup_enable=memory from cmdline.txt allows the boot sequence to finish for me.

It still seems that there are a handful of services which fail consistently, but at least it finishes booting and I can log in normally.

Update: Nevermind, I still have intermittent issues with various services failing and preventing me from logging in. Ugh.

Update 2: I give up again. systemd, you're the worst.

tpylkko
Posts: 325
Joined: Tue Oct 14, 2014 5:21 pm

Re: Systemd Jessie errors

Thu Apr 30, 2015 10:44 am

But are these problems specific to Raspbian? Because Debian 8 w/systemd on RPi2 seems to have no such problems and this was even when it was still testing and not stable.

ktb
Posts: 1380
Joined: Fri Dec 26, 2014 7:53 pm

Re: Systemd Jessie errors

Thu Apr 30, 2015 10:50 am

tpylkko wrote:But are these problems specific to Raspbian? Because Debian 8 w/systemd on RPi2 seems to have no such problems and this was even when it was still testing and not stable.
Yes, they appear to be.

I've used systemd with...
Arch Linux on Pi2B - no problems
Debian Jessie (Aliendeb) on Pi2B - no problems
Ubuntu MATE 15.04 on Pi2B - no problems
Xubuntu 15.04 on a Mac Mini - no problems

I'm just frustrated. I know that systemd can work well.

towolf
Posts: 421
Joined: Fri Jan 18, 2013 2:11 pm

Re: Systemd Jessie errors

Thu Apr 30, 2015 11:24 am

ktb, what did you even do to get into this mess? I didn’t have to change anything in /boot/cmdline? Init (pid 1) is transparently replaced by the link /sbin/init -> /lib/systemd/systemd, is it not? I merely dist-upgraded and didn’t have to compile anything.

This is my vanilla /boot/cmdline

Code: Select all

dwc_otg.lpm_enable=0 console=ttyAMA0,115200 console=tty1 ro root=/dev/mmcblk0p2 rootfstype=ext4 elevator=deadline rootwait

ktb
Posts: 1380
Joined: Fri Dec 26, 2014 7:53 pm

Re: Systemd Jessie errors

Thu Apr 30, 2015 11:29 am

towolf wrote:ktb, what did you even do to get into this mess? I didn’t have to change anything in /boot/cmdline? Init (pid 1) is transparently replaced by the link /sbin/init -> /lib/systemd/systemd, is it not? I merely dist-upgraded and didn’t have to compile anything.

This is my vanilla /boot/cmdline

Code: Select all

dwc_otg.lpm_enable=0 console=ttyAMA0,115200 console=tty1 ro root=/dev/mmcblk0p2 rootfstype=ext4 elevator=deadline rootwait
At the moment:

Code: Select all

dwc_otg.lpm_enable=0 console=ttyAMA0,115200 console=tty1 root=/dev/sda1 rootfstype=ext4 elevator=deadline rootdelay=10 rootwait usbhid.mousepoll=0 init=/lib/sysvinit/init
Or trying to boot normally with systemd:

Code: Select all

dwc_otg.lpm_enable=0 console=ttyAMA0,115200 console=tty1 root=/dev/sda1 rootfstype=ext4 elevator=deadline rootdelay=10 rootwait usbhid.mousepoll=0
The only apparent differences between us are that I'm not running the same services as you (I'm probably running more than you are), my root file system is on an external hard drive, and I still have wheezy sources in /etc/apt/sources.list. I did make sure to purge all residual configs.

joro
Posts: 5
Joined: Fri May 15, 2015 10:52 pm

Re: Systemd Jessie errors

Fri May 15, 2015 11:16 pm

tpylkko wrote:But are these problems specific to Raspbian? Because Debian 8 w/systemd on RPi2 seems to have no such problems and this was even when it was still testing and not stable.
I am using Jessie on two laptops without issues, and I am using another distro using systemd, namely Arch Linux, on my main Raspberrypi server. So, today, when I upgraded my second raspberrypi, which is running Raspbian from Wheezy to Jessie, this was the first time I saw systemd fail (and fail big time, in fact). It seems that the first thing to fail is dbus and the other failures are aftereffects, because dbus takes suspiciously long to start. Finally it is reported as having started successfully, but then, systemctl reports it as failed (unfortunately without any further details). I've tried the command line parameter enablign cgroups, but this hasin't affected the situation.

joro
Posts: 5
Joined: Fri May 15, 2015 10:52 pm

Re: Systemd Jessie errors

Sat May 16, 2015 9:40 pm

Just for the record, I have submitted a bug report about this to Debian, https://bugs.debian.org/cgi-bin/bugrepo ... bug=785484

joro
Posts: 5
Joined: Fri May 15, 2015 10:52 pm

[SOLVED] Re: Systemd Jessie errors

Mon May 18, 2015 1:25 pm

The Debian systemd maintainer, Michael Biebl had the solution: Obviously cgmanager somehow messed with systemd. I removed cgmanager, cgroup-bin, cgroup-tools, after which systemd works just fine..

ktb
Posts: 1380
Joined: Fri Dec 26, 2014 7:53 pm

Re: [SOLVED] Re: Systemd Jessie errors

Mon May 18, 2015 6:23 pm

joro wrote:The Debian systemd maintainer, Michael Biebl had the solution: Obviously cgmanager somehow messed with systemd. I removed cgmanager, cgroup-bin, cgroup-tools, after which systemd works just fine..
Yea, that should work just fine provided you don't want the root file system on an external USB hard drive.

viewtopic.php?f=66&t=109379

ktb
Posts: 1380
Joined: Fri Dec 26, 2014 7:53 pm

Re: Systemd Jessie errors

Sun Jun 07, 2015 2:00 pm

Update: I'm no longer having file corruption problems after shutdown/reboot while using systemd with Raspbian Jessie.

The reason might be this fix: https://bugs.debian.org/cgi-bin/bugrepo ... bug=784720

Tom_A
Posts: 272
Joined: Fri Dec 06, 2013 8:34 am

Re: Systemd Jessie errors

Mon Jun 08, 2015 9:46 pm

I keep debating installing Jessie, but I'm wondering what stability is like when you disable Systemd. For those who are using Jessie without Systemd, what is the user experience like? Do you prefer it to Wheezy? What have you noticed that has been added? Do you find performance to be better? I know that Systemd is supposed to have better performance, for example, quicker booting, (assuming it actually works) but have there been any other performance improvements not related to Systemd?

Return to “Raspbian”

Who is online

Users browsing this forum: No registered users and 14 guests