Messages in this thread | | | From | Denis Vlasenko <> | Subject | Unwritable device nodes on ro nfs | Date | Mon, 13 Sep 2004 15:51:29 +0300 |
| |
Hi,
I am moving away from devfs. I have a problem booting with ro nfs root fs.
I initialize network and mount nfs using an initrd, then pivot_root into nfs mountpoint:
... mount -n -t devfs none /new_root/dev cd /new_root # making sure we dont keep /dev busy exec <dev/console >dev/console 2>&1 pivot_root . old_root ... exec \ chroot . \ sh -c \ 'umount -n /old_root; exec /bin/env - $INIT'
I removed "mount -n -t devfs" line and now "exec >dev/console" fails because /new_root is ro-mounted nfs. ro-mounted local fs (reiser3) works fine.
Shall I jump thru the hoops, mount a ramfs on top of new_root/dev, populate it with device nodes, etc?
I don't want to do this, I want to hand a 'clean' state to secondary $INIT.
I can close all descriptors (exec <&- >&- 2>&-) before I exec $INIT, and have $INIT deal with that. This avoid the problem of >/dev/console.
But I lose the ability to boot with INIT=/bin/sh then. sh doesn't expect to have stdio closed at startup. Not good.
What is a 'right thing' to do in this situation? -- vda
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| |