You are not logged in.

#1 2012-11-24 10:15:25

Registered: 2012-11-24
Posts: 4

Systemd and nssswitch/LDAP problem (5min boot) - drives me crazy

Since I've migrated to systemd my systems needs 5 minute to boot.

$ systemd-analyze blame
248259ms systemd-binfmt.service
248139ms systemd-tmpfiles-setup.service
  9084ms systemd-logind.service
  6637ms netcfg@ethernet-dhcp.service
   129ms systemd-udev-trigger.service
   114ms console-kit-daemon.service
    96ms systemd-remount-fs.service
    95ms mnt-data.mount
    90ms sys-kernel-debug.mount
    89ms console-kit-log-system-start.service
    87ms systemd-vconsole-setup.service
    80ms sys-fs-fuse-connections.mount
    73ms systemd-modules-load.service
    69ms systemd-sysctl.service
    56ms polkit.service
    53ms rpcbind.service
    52ms home.mount
    50ms dev-hugepages.mount
    46ms rc-local.service
    43ms nscd.service
    39ms systemd-udevd.service
    37ms dev-mqueue.mount
    19ms udisks2.service
    14ms proc-sys-fs-binfmt_misc.mount
    10ms tmp.mount
     7ms rtkit-daemon.service
     6ms upower.service
     3ms systemd-user-sessions.service

It seems stuff from systemd-binfmt.service and systemd-tmpfiles-setup.service is not able to play with my nss_ldap config. With the default nsswitch.conf booting is as fast as expected.

$ cat /etc/nsswitch.conf 
# Begin /etc/nsswitch.conf

#passwd: files
#group: files
#shadow: files

passwd: files ldap
group: files ldap
shadow: files ldap

publickey: files

hosts: files dns myhostname
networks: files

protocols: files
services: files
ethers: files
rpc: files ldap

netgroup: ldap [NOTFOUND=return] files

# End /etc/nsswitch.conf

I think those "services" do some uid / guid lookups which ends with NOT reaching the LDAP server due to no network at this stage. I tried to put the netconfig earlier in the boot but i went into troubles like

 systemd[1]: Walked on cycle path to netcfg@ethernet-dhcp.service/start

Any idea how to fix this issue ?

Last edited by jaykay2342 (2012-11-24 12:12:43)


#2 2012-11-24 10:51:32

Forum Fellow
Registered: 2008-08-01
Posts: 5,026

Re: Systemd and nssswitch/LDAP problem (5min boot) - drives me crazy

Can you please update your topic title to reflect the actual problem instead of "Systemd drives me crazy"? This helps people to identify your thread as something they can assist you with, right now the title suggests it's just a generic rant about systemd.

ᶘ ᵒᴥᵒᶅ


#3 2012-11-24 12:17:49

Registered: 2012-11-24
Posts: 4

Re: Systemd and nssswitch/LDAP problem (5min boot) - drives me crazy

Changed the title. but "Systemd drives me crazy" is still the truth  and reflect my problem somehow wink For sure that's not the technical layer problem.


#4 2012-11-25 14:04:07

Registered: 2012-11-24
Posts: 4

Re: Systemd and nssswitch/LDAP problem (5min boot) - drives me crazy

I found a workaround
I get Network early available with the following steps

Installed mkinitcpio-nfs-utils

Modified the /etc/mkinitcpio.conf

Added the module for the networkcard


Added "net" to the HOOKS

HOOKS="base udev autodetect pata scsi sata filesystems usbinput fsck net"

Run  mkinitcpio -p linux

Added kernel parameter ip

kernel /boot/vmlinuz-linux ip=:::::eth0:dhcp root=/dev/sda1 ro init=/usr/lib/systemd/systemd 


Board footer

Powered by FluxBB