start on A and B

Mildred ml.mildred593 at online.fr
Sun Apr 22 10:01:48 BST 2007


Le Sun 22/04/2007 à 01:02 Gabriel C à écrit:
> Mildred wrote:
> 
> > Then I hope my work will be usable for any ArchLinux installation.
>   
> 
> Well I think you don't realize you have to setup 'your own' repo and
> and maintain a lot packages yourself  *forever*
> ( including the initramfs scripts , udev and a lot other core
> packages ) while 'ArchLinux' devels won't support upstart.

Well, I don't thing I'll do this because i don't have much time and
there are others projects I want to be involved in. But I think I'll
post my startup scripts and anyone who will want to test them will be
able to do so. Then if someone really want to create a repository for
upstart, it will be easier because some of the startup will already
exists.
Anyway, I actually do this for me, then I'll share it.

> port *every* rc script to upstart ( and no compat mode won't work on 
> ArchLinux )

Why the compat mode can't work ? Maybe it is the built-in compat mode
in upstart. But it is still possible to call /etc/rc.multi that will
call in order all the daemons specified in /etc/rc.conf.
The only problem is to avoid starting twice the same daemon. It can be
done manually or with lock files (the way ArchLinux do it actually).
When a daemon start, create a file somewhere in /var, and when the
daemon stop, delete the file.

The problem with that is that the code to do it is always the same and
is located in /etc/rc.d/functions. So to use it you have to always put
two lines in your scripts :
	. /etc/rc.d/functions
	{add|rm}_daemon daemonname
I tried to setup an upstart script that would do that automatically
based on events but I think that created a loop and I had strange
errors messages. I will figure this out later.

For /etc/rc.sysinit that do all the basic still (check disks, load
modules and so on), I think it is enough to call it directly for the
moment (well, until the other part does not work well enough).

> fix a lot daemons to work with upstart
> replace the rc.conf with something may work with upstart
> etc etc

Why ?
There is just the DAEMONS line that won't be used (it set the daemons
startup order) and upstart will be used instead. The others part
(network configuration, hostname, modules and modules blacklist,
keymap ... can be used directly

> > Also, is it possible to have clearer boot messages. i mean instead
> > of the verbose default upstart output (approximately 5 lines by
> > service a startup) i would prefer tu have a something better with
> > colors. For example on startup having a single line per service
> > with either OK or FAIL tags (in green or red) to tell if it was
> > successful or not, and the same when services stop.
> 
> Add wrappers for start/stop ? just check retval ...

$RETVAL (or is it $retval, anyways I'll do tests) is a variable that
wou can use to check if the return value of the daemon is correct or
not that you can use in port-stop, right ? i didn't found much
documentation.
I thought that it could be easier to set up a task that would start
each time a daemon is started or stopped, and will output a line on the
terminal. The only problem I see is that it will be mixed with the
normal upstart output.
Anyway, it is not a priority.

Mildred

-- 
Mildred       <xmpp:mildred at jabber.fr> <http://mildred632.free.fr/>
Clef GPG :    <hkp://pgp.mit.edu> ou <http://mildred632.free.fr/gpg_key>
Fingerprint : 197C A7E6 645B 4299 6D37 684B 6F9D A8D6 [9A7D 2E2B]



More information about the upstart-devel mailing list