At Sun, 11 Apr 2021 21:13:44 +0000 (UTC), RVP <rvp%SDF.ORG@localhost> wrote: Subject: Re: one remaining mystery about the FreeBSD domU failure on NetBSD XEN3_DOM0 > > I've run into this before. This is a NetBSD vs. FreeBSD UFS issue. Create > a UFS v1 FS on FreeBSD if you want to write it on NetBSD: > > newfs -O1 /dev/... > > Otherwise, you get that "Invalid quota magic number" error because newfs > creates a UFSv2 FS on FreeBSD. While that wasn't exactly my goal (I just wanted to see from the NetBSD side if the FreeBSD side was actually writing sensible things and not missing anything or mixing anything up or corrupting anything), it could indeed help me in doing that. Anyway this does something slightly different (and better, or worse) on the FreeBSD side, but still ends up with a corrupted filesystem, as seen from both sides, though maybe not so bad from NetBSD's point of view: xbd1: 30720MB <Virtual Block Device> at device/vbd/2064 on xenbusb_front0 xbd1: attaching as da1 xbd1: features: flush xbd1: synchronize cache commands enabled. GEOM: new disk da1 # newfs -O1 /dev/da1 /dev/da1: 30720.0MB (62914560 sectors) block size 32768, fragment size 4096 using 121 cylinder groups of 254.00MB, 8128 blks, 32512 inodes. super-block backups (for fsck_ffs -b #) at: 64, 520256, 1040448, 1560640, 2080832, 2601024, 3121216, 3641408, 4161600, 4681792, 5201984, 5722176, 6242368, 6762560, 7282752, 7802944, 8323136, 8843328, 9363520, 9883712, 10403904, 10924096, 11444288, 11964480, 12484672, 13004864, 13525056, 14045248, 14565440, 15085632, 15605824, 16126016, 16646208, 17166400, 17686592, 18206784, 18726976, 19247168, 19767360, 20287552, 20807744, 21327936, 21848128, 22368320, 22888512, 23408704, 23928896, 24449088, 24969280, 25489472, 26009664, 26529856, 27050048, 27570240, 28090432, 28610624, 29130816, 29651008, 30171200, 30691392, 31211584, 31731776, 32251968, 32772160, 33292352, 33812544, 34332736, 34852928, 35373120, 35893312, 36413504, 36933696, 37453888, 37974080, 38494272, 39014464, 39534656, 40054848, 40575040, 41095232, 41615424, 42135616, 42655808, 43176000, 43696192, 44216384, 44736576, 45256768, 45776960, 46297152, 46817344, 47337536, 47857728, 48377920, 48898112, 49418304, 49938496, 50458688, 50978880, 51499072, 52019264, 52539456, 53059648, 53579840, 54100032, 54620224, 55140416, 55660608, 56180800, 56700992, 57221184, 57741376, 58261568, 58781760, 59301952, 59822144, 60342336, 60862528, 61382720, 61902912, 62423104 # mount /dev/da1 mount: /dev/da1: unknown special file or file system # mount /dev/da1 /mnt # df Filesystem 512-blocks Used Avail Capacity Mounted on /dev/ufs/FreeBSD_Install 782968 737016 -16680 102% / devfs 2 2 0 100% /dev tmpfs 65536 616 64920 1% /var tmpfs 40960 8 40952 0% /tmp /dev/da1 61915512 16 56962256 0% /mnt # ls -l /mnt total 8 drwxrwxr-x 2 root operator 512 Apr 11 21:45 .snap # cp /COPYRIGHT /mnt/ # ls -l /mnt/ total 24 drwxrwxr-x 2 root operator 512 Apr 11 21:45 .snap -r--r--r-- 1 root wheel 6177 Apr 11 21:46 COPYRIGHT # pax -X -rw -pe / /mnt # ls -l /mnt total 1120 -rw-r--r-- 2 root wheel 1089 Oct 23 05:56 .cshrc -rw-r--r-- 2 root wheel 470 Oct 23 05:56 .profile drwxrwxr-x 2 root operator 512 Apr 11 21:52 .snap -r--r--r-- 1 root wheel 6177 Oct 23 05:56 COPYRIGHT -r--r--r-- 1 root wheel 7226 Oct 23 05:57 ERRATA.HTML -r--r--r-- 1 root wheel 3273 Oct 23 05:57 ERRATA.TXT -r--r--r-- 1 root wheel 252351 Oct 23 05:57 HARDWARE.HTML -r--r--r-- 1 root wheel 117568 Oct 23 05:57 HARDWARE.TXT -r--r--r-- 1 root wheel 23882 Oct 23 05:57 README.HTML -r--r--r-- 1 root wheel 14316 Oct 23 05:57 README.TXT -r--r--r-- 1 root wheel 36431 Oct 23 05:57 RELNOTES.HTML -r--r--r-- 1 root wheel 12343 Oct 23 05:57 RELNOTES.TXT drwxr-xr-x 2 root wheel 1024 Oct 23 05:55 bin drwxr-xr-x 9 root wheel 1536 Oct 23 05:57 boot dr-xr-xr-x 2 root wheel 512 Apr 11 19:02 dev -r--r--r-- 1 root wheel 6985 Oct 23 05:57 docbook.css drwxr-xr-x 25 root wheel 2048 Oct 23 06:04 etc drwxr-xr-x 5 root wheel 1536 Oct 23 05:55 lib drwxr-xr-x 3 root wheel 512 Oct 23 05:55 libexec drwxr-xr-x 2 root wheel 512 Oct 23 05:55 media drwxr-xr-x 2 root wheel 512 Oct 23 05:57 mnt drwxr-xr-x 2 root wheel 512 Oct 23 05:55 net dr-xr-xr-x 2 root wheel 512 Oct 23 05:55 proc drwxr-xr-x 2 root wheel 512 Oct 23 05:55 rescue drwxr-xr-x 2 root wheel 512 Oct 23 05:56 root drwxr-xr-x 2 root wheel 2560 Oct 23 05:56 sbin drwxrwxrwt 2 root wheel 512 Apr 11 21:52 tmp drwxr-xr-x 13 root wheel 512 Oct 23 05:57 usr drwxr-xr-x 2 root wheel 512 Apr 11 19:04 var # umount /mnt # fsck /dev/da1 ** /dev/da1 ** Last Mounted on /mnt ** Phase 1 - Check Blocks and Sizes PARTIALLY TRUNCATED INODE I=325128 SALVAGE? [yn] n PARTIALLY TRUNCATED INODE I=877864 SALVAGE? [yn] n PARTIALLY TRUNCATED INODE I=877866 SALVAGE? [yn] n PARTIALLY TRUNCATED INODE I=877879 SALVAGE? [yn] ^C ***** FILE SYSTEM MARKED DIRTY ***** Back on the NetBSD side: <NetBSD> # xl block-detach fbsd-test 2064 <NetBSD> # fsck /dev/mapper/rscratch-fbsd--test.0 ** /dev/mapper/rscratch-fbsd--test.0 ** Last Mounted on /mnt ** Phase 1 - Check Blocks and Sizes ** Phase 2 - Check Pathnames ** Phase 3 - Check Connectivity ** Phase 4 - Check Reference Counts ** Phase 5 - Check Cyl groups FREE BLK COUNT(S) WRONG IN SUPERBLK SALVAGE? [yn] n SUMMARY INFORMATION BAD SALVAGE? [yn] n BLK(S) MISSING IN BIT MAPS SALVAGE? [yn] n 12076 files, 91642 used, 7647797 free (293 frags, 955938 blocks, 0.0% fragmentation) ***** UNRESOLVED INCONSISTENCIES REMAIN ***** -- Greg A. Woods <gwoods%acm.org@localhost> Kelowna, BC +1 250 762-7675 RoboHack <woods%robohack.ca@localhost> Planix, Inc. <woods%planix.com@localhost> Avoncote Farms <woods%avoncote.ca@localhost>
Attachment:
pgpcEfskTIxyS.pgp
Description: OpenPGP Digital Signature