Gentoo Archives: gentoo-user

From: "Canek Peláez Valdés" <caneko@×××××.com>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] problems getting systemd to work
Date: Fri, 16 May 2014 17:42:24
Message-Id: CADPrc838nWSXAVCJ4ZS_btQowja6dO8EFH-0E1RzST3FgbOq=A@mail.gmail.com
In Reply to: Re: [gentoo-user] problems getting systemd to work by covici@ccs.covici.com
1 On Fri, May 16, 2014 at 12:17 PM, <covici@××××××××××.com> wrote:
2 [snip]
3 >> I don't understand the current situation .So now you get ALL your
4 >> volumes activated, or not?
5 >
6 > Yep, they are all activated and they all get mounted.
7
8 Cool, one problem less.
9
10 >> > Now for some systemd problems. The root file system was read only when
11 >> > I logged in, but I could remount it rw -- not sure why this was
12 >> > happening.
13 >>
14 >> Set systemd.log_level=debug in your command line, and post the exit
15 >> from journalctl -b.
16 >
17 > I had debug in the command line by itself, would that make the correct
18 > log_level? The file is quite large, should I send it to you privately?
19
20 I don't think is necessary, I may have found the real problem (see below).
21
22 >> > Some units did start, but most did not. Whenever I tried to
23 >> > start one manually, I got a message like the following:
24 [snip]
25 >> > No matter what unit I tried to start I would get such a message about
26 >> > the service.mount.
27 >>
28 >> That sounds like a problem with the cgroups hierarchy (which uses a
29 >> virtual filesystem). I don't remember seeing a problem like that
30 >> before.
31 >>
32 >> > Also, even though my network names were correct, they did not come up,
33 >> > but I will try to look in the logs to see why not.
34 > I wrote a service file to start my network adaptors, here it is:
35 > network@.service
36 >
37 >
38 > [Unit]
39 > Description=Network Connectivity for %i
40 > Wants=network.target
41 > Before=network.target
42 > BindsTo=sys-subsystem-net-devices-%i.device
43 > After=sys-subsystem-net-devices-%i.device
44 > [Service]
45 > Type=oneshot
46 > RemainAfterExit=yes
47 > EnvironmentFile=/etc/conf.d/network@%i
48 > ExecStart=/usr/bin/ip link set dev %i up
49 > ExecStart=/usr/bin/ip addr add ${address}/${netmask} broadcast ${broadcast} dev %i
50 > ExecStart=/bin/bash -c 'test -n ${gateway} && /usr/bin/ip route add default via
51 > ${gateway}'
52 > ExecStart=/bin/bash -c 'test -f /etc/conf.d/postup@%i.sh&&/bin/bash /etc/conf.d/postup@%i.sh
53 > ExecStop=/usr/bin/ip addr flush dev %i
54 > ExecStop=/usr/bin/ip link set dev %i down
55 > [Install]
56 > WantedBy=network.target
57
58 Did you enabled network@×××××.service? Also, WantedBy=network.target
59 doesn't do what you probably think it does (check [1]... and BTW, I
60 forgot my last footnote, is now on [2]).
61
62 I would use WantedBy=multi-user.target.
63
64 >> systemd will not (AFAIK) start your network, and before the 209 or 210
65 >> version it needed helper program (NetwokrManager, connman, ip,
66 >> ifconfig, etc.) to do it. Now it includes networkd, but you need to
67 >> set up .network files (like .service files) to configure it. See [1].
68 >>
69 >> > So we have made some progress, but still a long way to go yet. Note
70 >> > also, that I am not booting into a display manager, just a regular
71 >> > console.
72 >> >
73 >> >
74 >> > What a lot of work just to get the system booted!
75 >>
76 >> Well, you have a setup that is not, by any means, simple. Also, in my
77 >> experience old LVM configurations seem to cause a lot of troubles to
78 >> bring to what systemd expects.
79 >>
80 >> John, could you also post here your kernel config? Those cgroups
81 >> errors *may* be related to some missing functionality from the kernel.
82
83 [snip kernel config]
84
85 John, your kernel is incorrectly configured to be used by systemd.
86 When you installed systemd, a warning should have appeared about some
87 missing configure options; you either didn't saw or ignored those
88 warnings. Install systemd again so you can see them.
89
90 From what I can tell, you are missing *AT LEAST* the following options:
91
92 CONFIG_AUTOFS4_FS
93 CONFIG_DMIID
94 CONFIG_FANOTIFY
95 CONFIG_INOTIFY_USER
96 CONFIG_PROC_FS
97 CONFIG_SYSFS
98
99 John, if you don't set them, systemd *CANNOT WORK PROPERLY*. They are
100 mandatory. I'm surprised you are able to boot to a semi-working state.
101
102 Yes, migrating to systemd is a lot of work. But if you don't see (or
103 ignore) your system messages, that work gets multiplied several times.
104
105 Reconfigure, recompile, and reinstall your kernel (don't forget to
106 reinstall the modules!), regenerate your initramfs, update lilo (if I
107 remember correctly, you need to run lilo -something-or-another every
108 time you change kernel and/or initramfs), and try again.
109
110 Regards
111
112 [1] http://www.freedesktop.org/wiki/Software/systemd/NetworkTarget/
113 [2] http://www.freedesktop.org/software/systemd/man/systemd.network.html
114 --
115 Canek Peláez Valdés
116 Profesor de asignatura, Facultad de Ciencias
117 Universidad Nacional Autónoma de México

Replies

Subject Author
Re: [gentoo-user] problems getting systemd to work covici@××××××××××.com