On 12 June 2015 at 15:37, Robert Gifford <[email protected]> wrote: > Hello! > > I'm looking to mount a ram based filesystem as ext2. By registering the > filesystem with rump_pub_etfs_register as a block device within my > application, I am able to then make successful open, read and write calls. > (This device is simply a char array implemented at the rumpuser hypercall > level). I'm trying to mount the device to a new directory, /mnt. > > Calling mount from my application however, results in errno 22, or an > invalid argument according to errno.h for NetBSD. Making a unikernel with > the mount_ext2fs application and adding the device and directory in that > program results in the same error. > > An invalid argument error leads me to believe that I'm simply passing in > incorrect argument, but I can't spot anything that is off: > > mount(MOUNT_EXT2FS, "/mnt", 0, &args, size) > > The 0 represents no flags to be passed in. > args is a struct ufs_args which contains only the char pointer, fspec, which > I believe to be the location of the device you wish to mount: "/dev/paws" > > Am I missing some crucial step prior to mounting? I'm reaching out as I am > worried I am forgetting something important, but I will continue to walk > through the code with GDB.
Just to ask the obvious, as you didnt mention it, did you create an ext2 filesystem on it first? Justin
