Port-atari archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: Testing sysinst.fs



On Sat, 8 Nov 2008, T. Makinen wrote:

On Fri, Nov 7, 2008 at 5:57 PM, David Brownlee <abs%netbsd.org@localhost> wrote:

       OK, found the issue. Would you believe it was an unmatched quote? :)

       Could you try http://mono.org/abs/sysinst2.fs.gz

       It should give you a message like

           "Mounted /dev/md2a read-write"

       before prompting for keyboard layout and running sysinst.

I tried this with Falcon, now there's different problem; after sysinst is
loaded, it starts to loop following messages:

erase ^H, werase ^W, kill ^U, intr ^C
mount: cannot open '/dev/md2a': no such file or directory
Unable to mount /dev/md2a read-write

I can break to sh shell with Cntr-C and there are only: md0a, md0c and md1a,
md1c devices in /dev ...

sysctl -n kern.root_device kern.root_partion returns
md2
0

I wonder why md2a does not exist in /dev, but it can be used as root device
to launch installer ?

I tried with fd0a device and it launches installer as assumed (I tried it to
the point when it prompts for keyboard layout).

        Could you try http://mono.org/abs/sysinst3.fs.gz ?

        OK, cue long explanation about device nodes and mountpoints
        (just skip any parts you already know :)

        /dev contains device special files, which are just there to
        provide a way for a userland program to pass a reference to
        a device into the kernel.

        Each device special file contains a major and minor numeric
        id, these index into a table in the kernel.

        Whether a device has an entry in /dev doesn't affect the
        kernel access to that device, but it does stop a userland
        program from passing the details of what device to access
        to the kernel.

        The root filesystem is a special case - it needs to be
        mounted before /dev can be accessed, so the kernel
        fakes up a rootdev device path when it mounts it before
        it starts running init.

        Its a special case again in that if there is no 'real' /dev/
        entry for the root filesystem there is no way for the mount
        command to tell the kernel to remount it read-write.

        Once the root filesystem (or any filesystem) is mounted
        read-write you can use the mknod(8) or MAKEDEV(8) commands
        to create files for any device nodes you want.

        <aside>
        Actually there is a cute way around this which is used by
        some installers - the mount_mfs(8) command will allocate
        a block of memory and mount it on a directory, so init(8)
        has a special test - if it cannot locate /dev/console it
        opens /dev/MAKEDEV, then runs mount_mfs(8) to mount a
        ramdisk on /dev, copies the old /dev/MAKEDEV (now hidden
        under the mountpoint but still readable as it has it open)
        to /dev/MAKEDEV and then runs it.

        This gives a read-only root filesystem, but a read-write
        /dev.  Now init can start up the system as normal.
        </aside>

        If you search for 'floppy' in /dev/MAKEDEV on a NetBSD/atari
        box you will see it only contains md0 and md1. I'll update
        the version in tree, and have built a new sysinst3.fs.gz :)

--
                David/absolute       -- www.NetBSD.org: No hype required --


Home | Main Index | Thread Index | Old Index