You are not logged in.

#1 2013-03-26 09:06:48

batot
Banned
From: Poland
Registered: 2012-08-15
Posts: 47

systemd Failed to get D-Bus connection

have this same error:

# systemctl -a
Failed to get D-Bus connection: No connection to service manager.

# systemctl enable syslog-ng.service
ln -s '/usr/lib/systemd/system/syslog-ng.service' '/etc/systemd/system/syslog.service'
ln -s '/usr/lib/systemd/system/syslog-ng.service' '/etc/systemd/system/multi-user.target.wants/syslog-ng.service'

[root@FX-8120 etc]# systemctl start syslog-ng
Failed to get D-Bus connection: No connection to service manager.
[root@FX-8120 etc]#

# uname -a
Linux FX-8120 3.8.4-1-ARCH #1 SMP PREEMPT Wed Mar 20 22:10:25 CET 2013 x86_64 GNU/Linux

# pacman -Q systemd
systemd 198-1

I can't remove  initscript becouse more demons don't work propely with systemd like network, cond, aiccu, cpufreq, spamd, teamspeak3-server, etc....
Have you any idea why don;t work statu option systemctl?

Offline

#2 2013-03-26 23:57:56

tomegun
Developer
From: France
Registered: 2010-05-28
Posts: 661

Re: systemd Failed to get D-Bus connection

Are you sure that systemd is running and that you are not booting with initscripts still? Do you have a folder named /sys/fs/cgroup/systemd ?

Offline

#3 2013-03-27 02:05:37

theodoiq
Member
From: Brazil
Registered: 2013-03-20
Posts: 31

Re: systemd Failed to get D-Bus connection

Hi!

I was with the same situation here, SOLVED in my case, for now. That's my steps:

1 -      Install "systemd" and append the following to your kernel parameters: init=/usr/lib/systemd/systemd (by editing your /boot/grub/menu.lst or in your /etc/lilo.conf).
         In my /boot/grub/menu.lst ->
                    kernel /vmlinuz-linux root=/dev/sda6 ro init=/usr/lib/systemd/systemd

    Once completed you may enable any desired services via the use of systemctl enable <service_name> (this roughly equates to what you included in the DAEMONS array, with different names.). In my case, I want KDM - my boot wasn't starting KDM automatically.

2 -     Reboot your system and verify that systemd is currently active by using the following command: cat /proc/1/comm. This should return the string systemd.

3 -     Make sure your hostname is set correctly under systemd: hostnamectl set-hostname myhostname.

4 -     Proceed to remove "initscripts" and "sysvinit" from your system and install "systemd-sysvcompat".

5 -    Optionally, remove the init=/usr/lib/systemd/systemd parameter as it is no longer needed. systemd-sysvcompat provides the default init.

I hope that works to you!

Offline

#4 2013-03-27 02:08:36

Max-P
Member
Registered: 2011-06-11
Posts: 164

Re: systemd Failed to get D-Bus connection

tomegun wrote:

Are you sure that systemd is running and that you are not booting with initscripts still? Do you have a folder named /sys/fs/cgroup/systemd ?

batot wrote:

I can't remove  initscript becouse more demons don't work propely with systemd

I guess not...

@batot: If you are still running initscripts, then systemd is not running and thus systemctl and others just won't work. You need to switch to systemd if you want to use systemctl.

By the way,

more demons don't work propely with systemd like network, cond, aiccu, cpufreq, spamd, teamspeak3-server, etc....

these are false. Arch provides some wrapper scripts that reads /etc/rc.conf and starts the DAEMON=() array and other old stuff just fine. I think systemd recognises rc.d scripts natively too, so you should be able to run them directly with systemd. systemd also support custom scripts in some folders somewhere with start/stop/restart commands, which means you can just copy the rc.d scripts there too if needed. Not to mention writing unit files is dead simple, it's a matter of like 7 lines, you can easily migrate those old rc scripts in less than an hour.

EDIT: Or do what theodoiq says, he explained the systemd-sysvcompat thing

Last edited by Max-P (2013-03-27 02:10:36)

Offline

#5 2013-04-10 07:55:48

batot
Banned
From: Poland
Registered: 2012-08-15
Posts: 47

Re: systemd Failed to get D-Bus connection

Thanks for help.
Max-P and tomegun  you have right systemd don't run properly.
# pacman -S systemd-sysvcompat
resolving dependencies...
looking for inter-conflicts...
:: systemd-sysvcompat and sysvinit are in conflict. Remove sysvinit? [y/N] y

Packages (2): sysvinit-2.88-9 [removal]  systemd-sysvcompat-200-1

Total Download Size:    0.00 MiB
Total Installed Size:   0.05 MiB
Net Upgrade Size:       -0.11 MiB

:: Proceed with installation? [Y/n]
:: Retrieving packages ...
systemd-sysvcompat-200-1-x86_64                                             4.9 KiB  4.74M/s 00:00 [###########################################################] 100%
(1/1) checking keys in keyring                                                                      [###########################################################] 100%
(1/1) checking package integrity                                                                    [###########################################################] 100%
(1/1) loading package files                                                                         [###########################################################] 100%
(1/1) checking for file conflicts                                                                   [###########################################################] 100%
(2/2) checking available disk space                                                                 [###########################################################] 100%
(1/1) removing sysvinit                                                                             [###########################################################] 100%
(1/1) installing systemd-sysvcompat                                                                 [###########################################################] 100%
[root@FX-8120 etc]#

reboot and work properly.
Very thanks for help.

But I don't understand why on two other archlinux enough just update by pacman work propery, but on third not.
thanks for all.

Offline

Board footer

Powered by FluxBB