Patrick Welche <prlw1@cam.ac.uk>
[netbsd-mini2440.git] / regress / sys / fs / lfs / newfs_fsck / mkfs_mount
blob722cada0f9d960bd3bd98c3a1aa0af32b09b23f5
1 #!/bin/sh
4 # Make an LFS on TMPIM, fsck it, and mount it on TMPMP.
7 BVND=/dev/${VND}
8 CVND=/dev/r${VND}
9 if [ "x$NEWFS_LFS_FLAGS" = "x" ]
10 then
11 NEWFS_LFS_FLAGS="-B 131072 -b 4096 -f 4096 -M 6"
14 echo "*** Creating a dummy directory tree at ${TMPMP} mounted on ${TMPIM}."
15 dd if=/dev/zero of=${TMPIM} count=5860
16 vnconfig -v ${BVND}${RPART} ${TMPIM}
17 disklabel -f ${SRCDIR}/disktab -rw ${VND} floppy288
18 newfs_lfs ${NEWFS_LFS_FLAGS} ${CVND}${MPART}
20 echo "*** Checking that fs made by newfs_lfs could be understood by fsck_lfs"
21 fsck_lfs -f -n ${CVND}${MPART} || exit 1
23 mkdir ${TMPMP}
24 mount -t lfs -o-N1 ${BVND}${MPART} ${TMPMP}