1 |
On 5/26/13 4:58 PM, Ian Stakenvicius wrote: |
2 |
> The way it's being proposed (and please correct me if i'm wrong), the |
3 |
> wrapper is a direct replacement binary (small C program) for all init |
4 |
> systems, and would based on some configuration file or whatnot |
5 |
> determine and exec the init system it's supposed to -- and make any |
6 |
> other necessary changes too, such as switching /etc/inittab) |
7 |
|
8 |
The really minimal wrapper would be something like |
9 |
|
10 |
#!/bin/sh |
11 |
|
12 |
INIT=/bin/init |
13 |
|
14 |
if [[ -e /etc/switch-init ]]; then |
15 |
. /etc/switch-init |
16 |
fi |
17 |
|
18 |
exec ${INIT} |
19 |
|
20 |
With switch-init doing stuff needed, including remounting the rootfs rw |
21 |
if there are stuff to be changed and if we want stick to symlinks it |
22 |
could replace itself by a symlink. |
23 |
|
24 |
Yes, it would be that simple. |
25 |
|
26 |
lu |