init_chroot broken
David Naylor
naylor.b.david at gmail.com
Thu Apr 24 20:04:36 UTC 2008
Hi,
init_chroot appears to be broken when used with unionfs (it did work sometime
before RELENG_7 [definitely before the BETA's]). When using -current (with
the vaps patch :-) I get the following message before the system stops:
[...]
stat(c2d3fcc0,d3ceccfc,8,c0b094e7,c0bbc0a0,...) at stat+0x2f
syscall(d3cecd38) at syscall+0x2a3
Xint0x80_syscall() at Xint0x80_syscall+0x20
--- syscall (188, FreeBSD ELF32, stat), eip = 0x826fe23, esp = 0x9bfbfe9bc,
ebp = 0xbfbee98
I tracked the stop to line 320 of init.c:
if (chdir(kenv_value) != 0 || chroot(".") != 0)
Also, I have a init_script that sets up a few things, here it is:
PATH=/rescue
trap 'echo Recovery console: ; PATH=/rescue /rescue/csh -i ; exit' 1 2 3 6 15
mount -t cd9660 -o ro /dev/$(mdconfig -a -t vnode -f /base.uzip).uzip /base
MD=$(mdconfig -a -t malloc -s 32M)
newfs /dev/$MD
mount /dev/$MD /tmpfs
mount -t unionfs -o noatime -o copymode=transparent /tmpfs /base
Note:
o) /base.uzip is a mkuzip image of an iso of the base system
o) If the sets after MD=... are skipped then the system mounts cleanly
If I can only get tmpfs to work then this can become a really flexible live
CD :-) .....
If you require any further information (or my build scripts) please let me
know
Regards
David
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 187 bytes
Desc: This is a digitally signed message part.
Url : http://lists.freebsd.org/pipermail/freebsd-current/attachments/20080424/9df1f71e/attachment.pgp
More information about the freebsd-current
mailing list