error when mounting md0 invalid argument
David Christensen
dpchrist at holgerdanske.com
Fri May 31 21:33:35 UTC 2019
On 5/31/19 5:29 AM, David Mehler wrote:
> Hello,
>
> I've got a copy of the FreeBSD 12.0 memstick img file. I'm trying to
> mount it to make some changes to allow it to go serial terminal by
> default. I'm doing:
>
> mdconfig -a -t vnode -f path/to/img
> and have also added the -u0 option to that line as well.
>
> An mdconfig -l does indeed show /dev/md0 and file -s /dev/md0 shows
> dos/mbr imgage I believe that was. I then try:
>
> mount /dev/md0 /mnt
>
> and get invalid argument. Nothing in the logs. I've tried
> mount_msdosfs and mount_ufs same result invalid argument.
>
> Any suggestions appreciated.
>
> Thanks.
> Dave.
I wanted to make changes to:
FreeBSD-11.2-RELEASE-amd64-memstick.img
I burned the image to a USB flash drive and then mounted it:
2019-05-23 14:13:46 toor at ragnar ~
# camcontrol devlist | grep -i sandisk
<SanDisk SanDisk Cruzer 8.02> at scbus5 target 0 lun 0 (da0,pass5)
2019-05-23 14:16:27 toor at ragnar ~
# gpart show -p da0
=> 1 7913470 da0 MBR (3.8G)
1 1600 da0s1 !239 (800K)
1601 1505616 da0s2 freebsd [active] (735M)
1507217 6406254 - free - (3.1G)
2019-05-23 14:17:24 toor at ragnar ~
# gpart show -p da0s2
=> 0 1505616 da0s2 BSD (735M)
0 16 - free - (8.0K)
16 1505600 da0s2a freebsd-ufs (735M)
2019-05-23 14:17:53 toor at ragnar ~
# mount /dev/da0s2a /mnt
2019-05-23 14:18:04 toor at ragnar ~
# mount | grep da0s2a
/dev/da0s2a on /mnt (ufs, local)
The file system reads 100% full, but by working as root I can encroach
into the reserved space and make changes to the BSD installer:
2019-05-23 14:18:18 toor at ragnar ~
# cd /mnt/usr/libexec/bsdinstall
2019-05-23 14:19:58 toor at ragnar /mnt/usr/libexec/bsdinstall
# vi zfsboot
If you have more than a little content to add, the proper way would be
to start at the front end of whatever process creates the image. (I
haven't learn that, yet.)
David
More information about the freebsd-questions
mailing list