Gentoo Archives: gentoo-dev

From: Fabian Groffen <grobian@g.o>
To: gentoo-dev@l.g.o
Subject: Re: [gentoo-dev] Google SOC 2008
Date: Wed, 27 Feb 2008 14:22:02
Message-Id: 20080227142158.GB315@gentoo.org
In Reply to: Re: [gentoo-dev] Google SOC 2008 by Roy Marples
1 On 27-02-2008 13:56:51 +0000, Roy Marples wrote:
2 >
3 > On Wed, 27 Feb 2008 13:29:15 +0100, Fabian Groffen <grobian@g.o>
4 > wrote:
5 > > Well... that's great! But a jail or a (ch)root is in general not the
6 > > same as a "prefix".
7 >
8 > No, but it's the same kettle of fish as chroots, jails and vps systems -
9 > basically
10 > there is a need to disable dependencies that provide what the host already
11 > does.
12
13 Ok, the host will for instance do "net", so "need net" should indeed not
14 fail. However I could imagine that "need net" would just get satisfied
15 or something, like by a dummy.
16
17 > We current have nojail for FreeBSD jails, novps for VServer/OpenVZ systems
18 > and
19 > a few others. I would be trivial to add another no for prefix :)
20
21 I just need the machinery of "runscript" as first thing, I suppose. If
22 we need a dozen of no* things for that, it probably indicates some
23 problem, but could work for me. I want a framework to start and stop
24 daemons in Prefix, and it feels obvious that we can reuse existing code
25 for that.
26
27 > > I have to look more closely at what openrc does
28 > > these days, but for the (ancient) version of baselayout we have in
29 > > prefix now, I recall that:
30 > > a) most of it didn't compile on Darwin and Solaris
31 >
32 > It compiles and works on Linux/glibc/uclibc, FreeBSD-6 and NetBSD-4.
33 > So it stands a fair chance of working on Darwin for sure.
34
35 Well... I've some experience here, and I'm not as sure as you ;)
36 Anyway, I concur the codebase has changed dramatically since, and
37 probably in favour of portability.
38
39 > I have no idea about Solaris, but it should work as it sports libkvm which
40 > we use to find processes.
41
42 Part of the summer of code project to me would be to 1) evaluate to what
43 extent this is all necessary in the Prefix equivalent and 2) create/fix
44 the code.
45
46 > > And maybe even a sort of init-level stuff, such that one can start all
47 > > services in the Prefix and stop them as well. That basically gets quite
48 > > useful once Prefix goes "privileged" and you could start sshd, slapd,
49 > > apache2, etc, etc. on privileged ports, and you really would like those
50 > > to be started as well in some correct order (on e.g. Solaris).
51 >
52 > If OpenRC compiles and /bin/sh points to a POSIX shell it should work as it
53 > stands.
54
55 Ok, then we already fail here.
56 /bin/sh is no way POSIX, it is just bourne, so that's where we come in
57 and simply use /usr/bin/env {sh,bash,posix-sh} or a full path to make
58 your assumption true.
59
60 > At present there is no need for the default interpreter to be changed, but
61 > there may
62 > be the need for Prefix.
63
64 See above. But that's trivial work, that we do all the time. For the
65 GSoC I see more challenges in the rest of the job and to make some
66 obvious examples.
67
68 But then again, it was just a mere suggestion. If everything is already
69 there then fine, but we still need someone (Google code or not) to do
70 it, as it's currently not. I'm not sure how far OpenRC actually can
71 deal with unprivileged installs, so that are just things we have to find
72 out along the way.
73
74
75 --
76 Fabian Groffen
77 Gentoo on a different level
78 --
79 gentoo-dev@l.g.o mailing list

Replies

Subject Author
Re: [gentoo-dev] Google SOC 2008 Roy Marples <roy@×××××××.name>
Re: [gentoo-dev] Google SOC 2008 Roy Marples <roy@×××××××.name>