Re: anticipating the upstart migration
On Tue, Oct 10, 2006 at 05:25:57PM -0400, Eric Dorland wrote:
> Shouldn't it be possible to move the alternatives around in an atomic
> fashion? ln -sf bar foo.tmp ; mv foo.tmp foo . Or am I missing
> something?
- If you set up the alternatives in preinst, then there is a time when
the symlink exists but the pointed binary hasn't been unpacked yet ->
unbootable system.
- If you set up the alternatives in postinst, there is a time when there
is no /sbin/init at all -> unbootable system.
It's not enough to install a single link atomically. Unpacking
/sbin/init.upstart AND setting the /sbin/init symlink AND setting the
/etc/alternatives/init symlink _together_ would have to be atomic.
Gabor
--
---------------------------------------------------------
MTA SZTAKI Computer and Automation Research Institute
Hungarian Academy of Sciences
---------------------------------------------------------
Reply to: