[Prev][Next][Index][Thread]

Re: questions on fsread



> To: oskit-users@fast.cs.utah.edu
> cc: pollack@srvr20.engin.umich.edu, dreeves@zip.eecs.umich.edu
> Subject: questions on fsread
> Date: Mon, 01 Feb 1999 21:21:16 -0500
> From: Naomaru Itoi <itoi@eecs.umich.edu>
> 
> ...
> So OSKit was compilied and installed fine.  Some example kernels,
> hello, diskpart and diskpart2 worked great.  Now I am trying fsread,
> but it dies when it tries to selects a partition. 
> 
> / is mounted on /dev/sda2.  So I went in fsread.c:
> #if 1
> # define DISK_NAME      "sda"           /* shaky */
> # define PART_NAME      "2"
> #else
> 
> It says "Couldn't find partition 2."
> 
> I also tried:
> #if 1
> # define DISK_NAME      "sd0"           /* shaky */
> # define PART_NAME      "b"
> #else
> 
> It says "fsread_ffs_open failed: Invalid argument (0x80070057)"
> 
> ...

I assume you are trying to read from a Linux FS?  There are a couple of
problems.  One is the the fsread library currently only knows how to parse
FreeBSD style slice/partition names.  I assume that /dev/sda2 in Linux refers
to the second DOS partition?  If that is the case, I think if you set
DISK_NAME to "sd0" and PART_NAME to "s2" you might get the right behavior.

Problem 2 is that fsread.c is currently hardwired to expect an FFS, aka BSD,
filesystem (are you begining to detect an OS bias here? :-).  If you change:

	CHECK(err, fsread_ffs_open, (part, filename, &fbio));

to:

	CHECK(err, fsread_ext2_open, (part, filename, &fbio));

you should get past that.

But I am just guessing from looking at the code.

=================================
To unsubscribe from this list, send a message with a body of "unsubscribe"
to oskit-users-request@flux.cs.utah.edu


Follow-Ups: