summaryrefslogtreecommitdiffstats
path: root/zarb-ml/mageia-dev/attachments/20121230/8de0fa69/attachment.html
blob: 1a6c56beddacba18aab84687c96a1a3c55f5b2e9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
<div class="gmail_quote">On 28 December 2012 00:17, Pascal Terjan <span dir="ltr">&lt;<a href="mailto:pterjan@gmail.com" target="_blank">pterjan@gmail.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
On Thu, Dec 27, 2012 at 10:55 AM, Guillaume Rousse<br>
&lt;<a href="mailto:guillomovitch@gmail.com">guillomovitch@gmail.com</a>&gt; wrote:<br>
&gt; Le 27/12/2012 11:29, Pascal Terjan a �crit :<br>
&gt;<br>
&gt;&gt;&gt; It seems like the systemd way of starting would be:<br>
&gt;&gt;&gt; systemctl start openssh.service<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; But, then produces an error:<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; [root@localhost /]# systemctl start openssh.service<br>
&gt;&gt;&gt; Running in chroot, ignoring request.<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; So, �Any thoughts on what is the recommended way, and I&#39;ll be happy to<br>
&gt;&gt;&gt; update the wiki to reflect this.<br>
&gt;&gt;<br>
&gt;&gt;<br>
&gt;&gt; Last time I tried, I gave up after various attempts and now went back<br>
&gt;&gt; to the basics: running &quot;sshd&quot; and killing it to stop it.<br>
&gt;&gt; Maybe I&#39;ll fetch some old initscript.<br>
&gt;<br>
&gt; I guess using a specific unit file, using builtin systemd chroot support,<br>
&gt; should help. See <a href="http://0pointer.de/blog/projects/changing-roots" target="_blank">http://0pointer.de/blog/projects/changing-roots</a> for<br>
&gt; details.<br>
<br>
Yes having an unit outside of the chroot with<br>
RootDirectoryStartOnly=yes would probably help (I had tried the &quot;full<br>
system&quot; chroot and couldn&#39;t get it to work and gave up after an hour)<br>
but this is annoying to not be able to start a daemon from inside the<br>
chroot which is what I usually want to do.<br>
</blockquote></div><br><br>Well, good to see I am not the only one that can&#39;t get the chroot to work anymore.<br>So, I suggest, for the minute, I edit the wiki to explain that the chroot does not work.<br>I am open to suggestions as to what it should recommend?� maybe using a full<br>
virtual machine?<br><br>What I have found so far is, using the two attached files, in the following locations:<br>/lib/systemd/system/sshd-mageia3.service<br>/usr/local/bin/setup-cauldron-chroot.sh<br><br>setup fstab: echo &#39;none /mnt/chroot/cauldron/dev/pts devpts defaults 0 0&#39; &gt;&gt; /etc/fstab<br>
<br>Then, the chroot sshd can be started, using:<br>systemctl enable sshd-mageia3.service<br>systemctl start sshd-mageia3.service<br><br>which will start a chroot, but.. it&#39;s not ideal..� It sees mount points from the host (/proc/mounts)<br>
and of course, processes.<br><br><br>The recommended approach according to systemd, appears to be systemd-nspawn.<br>This may be viable, when systemd-nspawn is updated beyond the version in Mageia 2.<br>It does not currently work, because dbus won&#39;t start, see bug: <br>
<a href="https://bugzilla.redhat.com/show_bug.cgi?id=795038">https://bugzilla.redhat.com/show_bug.cgi?id=795038</a>.�� The work around mentioned is<br>not supported in the version of systemd-nspawn that Mageia 2 uses.� This looks like<br>
it would work for Mageia3.<br><br>Glen<br><br><br><br><br><br><br><br><br>