1 |
On Friday 01 August 2014 10:29:17 Canek Peláez Valdés wrote: |
2 |
> On Fri, Aug 1, 2014 at 10:21 AM, Peter Humphrey <peter@××××××××××××.uk> |
3 |
wrote: |
4 |
> > On Friday 01 August 2014 10:00:40 Canek Peláez Valdés wrote: |
5 |
> >> ... just for completeness, systemd actually requires /etc/mtab as a |
6 |
> >> link to /proc/self/mounts, so don't be surprised if software in the |
7 |
> >> future in Linux just assumes that. |
8 |
> > |
9 |
> > Well, that seems to imply that you can't run a systemd chroot on a systemd |
10 |
> > or openrc host, no? |
11 |
> |
12 |
> If you want to "boot" a container with systemd-nspawn, then no, you |
13 |
> can't; you need mtab to be a symlink to /proc/self/mounts. If you |
14 |
> simply want to chroot to it, it doesn't matter; you will not be |
15 |
> running systemd anyway. |
16 |
> |
17 |
> > Because from inside the chroot, what /proc/self/mounts lists |
18 |
> > is inaccurate. |
19 |
> |
20 |
> In what sense is inaccurate? Inside my systemd-nspawn container: |
21 |
> |
22 |
> root@gentoo ~ # sort /etc/mtab | uniq |
23 |
> /run /var/run none rw,bind 0 0 |
24 |
> debugfs /sys/kernel/debug debugfs rw 0 0 |
25 |
> fusectl /sys/fs/fuse/connections fusectl rw 0 0 |
26 |
> hugetlbfs /dev/hugepages hugetlbfs rw 0 0 |
27 |
> mqueue /dev/mqueue mqueue rw 0 0 |
28 |
> tmpfs /tmp tmpfs rw,strictatime,mode=1777 0 0 |
29 |
> |
30 |
> That seems accurate to me. Sure, as Rich mentioned, there are |
31 |
> repetitions and other stuff, but nothing that a quick grep or sort |
32 |
> will not fix. |
33 |
|
34 |
I only meant that things mounted outside the chroot are listed inside it, even |
35 |
though they can't be accessed from there. |
36 |
|
37 |
I've solved the problem for myself anyway, for now, by constructing a suitable |
38 |
mtab by hand from outside the chroot for use within it. |
39 |
|
40 |
> > I wouldn't like to be the one who has to write a new installation handbook |
41 |
> > for systemd-only systems! :) |
42 |
> |
43 |
> We'll need to rewrote the whole thing when we switch to systemd anyway. |
44 |
|
45 |
Indeed. |
46 |
|
47 |
-- |
48 |
Regards |
49 |
Peter |