From nobody Wed May 4 00:44:28 2022 X-Original-To: bugs@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id A1C401ACB05D for ; Wed, 4 May 2022 00:44:29 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4KtJ4Y2535z4QlK for ; Wed, 4 May 2022 00:44:29 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2610:1c1:1:606c::50:1d]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 29283B9C for ; Wed, 4 May 2022 00:44:29 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org ([127.0.1.5]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id 2440iTgS008162 for ; Wed, 4 May 2022 00:44:29 GMT (envelope-from bugzilla-noreply@freebsd.org) Received: (from www@localhost) by kenobi.freebsd.org (8.15.2/8.15.2/Submit) id 2440iTRg008161 for bugs@FreeBSD.org; Wed, 4 May 2022 00:44:29 GMT (envelope-from bugzilla-noreply@freebsd.org) X-Authentication-Warning: kenobi.freebsd.org: www set sender to bugzilla-noreply@freebsd.org using -f From: bugzilla-noreply@freebsd.org To: bugs@FreeBSD.org Subject: [Bug 263765] panic: ffs_sync: modification on read-only filesystem Date: Wed, 04 May 2022 00:44:28 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Base System X-Bugzilla-Component: kern X-Bugzilla-Version: CURRENT X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Only Me X-Bugzilla-Who: markj@FreeBSD.org X-Bugzilla-Status: New X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: bugs@FreeBSD.org X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version rep_platform op_sys bug_status bug_severity priority component assigned_to reporter Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated List-Id: Bug reports List-Archive: https://lists.freebsd.org/archives/freebsd-bugs List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-bugs@freebsd.org MIME-Version: 1.0 ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1651625069; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=sdftZ8ngbEVMRb113APUigZtuaqwF1uBqNV+9gFaZ6Y=; b=WVW3Z1qHw45ybVnlFgppjqIDnyte2aOHf5NWBsp9DNQ+1/2vMcEt5MCEtNgQvy5tsKKlnr eefZ/RDcsMob14K5uFR/Ep14aSRRJ688aYUwVrqzIkQFiSVzO1aAG8t61io43rBAmKK4V7 XgWaJGKBI5l9GZrleRGh5lfz4jG/TEvPeHNRlkQA9yA2RXgs3slVXl12T8zWMikjPrRwdb hokZ9Ka4Ny2CHuCQuLPB4utrqSnVqfT06tLGenGp+C/eAIqgBVkzVfI3ZREM2+l00UYidm +WebwtAjkRAgnvilDReep2702xxwbX5Tr48fcvmBxA1rZZMgQzsP6zd69YF5dg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1651625069; a=rsa-sha256; cv=none; b=RtlQ9YDEeyAR2S7/VEKCBoilmTisv5RIfedsptO2TyRkoTA7Dcf+ezphGWT8M/yZGKOsH6 E8XuNkADC7cDigGZOjvSryN0wYTdsQlyqJtH9jm3Sv/CMwCDxu573ozD2wpAVd5x5bP5N6 VlSXYAiDmjI8mF1r0uDZc5KIihDkaSyeJ8mtfRtyIzjflqoRVqg/SXTNe6wkCVm/HCCSpa m8wDuAiwPLNk5B193DrMZtF/Lh95RzB96QYhmXwq2Rb/FLpu2SqNOMQ2xrLWvUoEAbXSQP ALW1BhOA/WrUNOFzanDWa7hiUz8U+oSqqY5tLfrPARGMlIpWktfn6GwR98l2Hg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D263765 Bug ID: 263765 Summary: panic: ffs_sync: modification on read-only filesystem Product: Base System Version: CURRENT Hardware: Any OS: Any Status: New Severity: Affects Only Me Priority: --- Component: kern Assignee: bugs@FreeBSD.org Reporter: markj@FreeBSD.org I was using a VM to test some code and crashed it many times. After a whil= e it consistently panics during boot, while upgrading the read-only root mount to read-write: Trying to mount root from ufs:gpt/rootfs [rw]...=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20 WARNING: / was not properly dismounted=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20 WARNING: /: mount pending error: blocks 367136 files 5=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20 No suitable dump device was found.=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20 Setting hostuuid: 4ff7a735-851c-7030-87f0-cf2c2b9ef44e.=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20 Setting hostid: 0x1c981ebb.=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20 Starting file system checks:=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20 WARNING: / was not properly dismounted=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20 panic: /: ffs_sync: modification on read-only filesystem=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20 cpuid =3D 1=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20 time =3D 1651623448=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20 KDB: stack backtrace:=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20 db_trace_self_wrapper() at db_trace_self_wrapper+0x2b/frame 0xfffffe007a140= 750=20=20 vpanic() at vpanic+0x17f/frame 0xfffffe007a1407a0=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20 panic() at panic+0x43/frame 0xfffffe007a140800=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20 ffs_sync() at ffs_sync+0x6e6/frame 0xfffffe007a1408a0=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20 vfs_write_suspend() at vfs_write_suspend+0x165/frame 0xfffffe007a1408f0=20= =20=20=20=20=20=20=20=20 vfs_write_suspend_umnt() at vfs_write_suspend_umnt+0x35/frame 0xfffffe007a140920 ffs_mount() at ffs_mount+0xa2b/frame 0xfffffe007a140a70=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20 vfs_domount_update() at vfs_domount_update+0x277/frame 0xfffffe007a140bf0= =20=20=20=20=20=20=20 vfs_domount() at vfs_domount+0x26b/frame 0xfffffe007a140d20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20 vfs_donmount() at vfs_donmount+0x878/frame 0xfffffe007a140dc0=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20 sys_nmount() at sys_nmount+0x69/frame 0xfffffe007a140e00=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20 amd64_syscall() at amd64_syscall+0x12e/frame 0xfffffe007a140f30=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20 fast_syscall_common() at fast_syscall_common+0xf8/frame 0xfffffe007a140f30= =20=20=20=20=20=20 --- syscall (378, FreeBSD ELF64, sys_nmount), rip =3D 0x28658b33e3da, rsp = =3D 0x286588ae7e38, rbp =3D 0x286588ae83a0 --- The problem appears to be that the fmod flag in the superblock got set, somehow: magic 19540119 (UFS2) last mounted time Mon May 2 21:00:40 2022 last modified time Mon May 2 21:00:52 2022 superblock location 65536 id [ 62658b45 0a5e546e ] ncg 82 size 13107200 blocks 12694551 bsize 32768 shift 15 mask 0xffff8000 fsize 4096 shift 12 mask 0xfffff000 frag 8 shift 3 fsbtodb 3 minfree 8% optim time symlinklen 120 maxbsize 32768 maxbpg 8192 maxcontig 2 contigsumsize 2 nbfree 1377660 ndir 4007 nifree 6527315 nffree 6053 bpg 20042 fpg 160336 ipg 80256 unrefs 0 nindir 4096 inopb 128 maxfilesize 2252349704110079 sbsize 4096 cgsize 32768 csaddr 5056 cssize 4096 sblkno 24 cblkno 32 iblkno 40 dblkno 5056 cgrotor 7 fmod 1 ronly 0 clean 0 metaspace 0 avgfpdir 64 avgfilesize 16384 flags unclean soft-updates=20 Running fsck from single-user mode fixed the problem, but it reappeared sev= eral times. I'm not really sure how fmod can end up set; it looks like it's cleared any time FFS updates the superblock. (But then why is it in the superblock at all?) I don't appear to have checksums enabled here, maybe enabling them would he= lp narrow down the problem. --=20 You are receiving this mail because: You are the assignee for the bug.=