From nobody Sun Jan 7 20:19:13 2024 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 4T7T761q6wz55ryq for ; Sun, 7 Jan 2024 20:19:14 +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 4T7T760L2Qz4n1K for ; Sun, 7 Jan 2024 20:19:14 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1704658754; 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: in-reply-to:in-reply-to:references:references; bh=YBtw6P3ODwq83lRBAokHjTP2yL0lc9HzGo5MOW8Cs24=; b=rfrs2tMN/Cmq7cII56zXKoFXfxmtGpvPqiwIac9YT/b0q6po2rdShqoSjiBgeIBxT+qYsq 99v+3B+DOuyv5ArwKvlq/Ykj2NCqYPdSCnhg+w7QqDFjXNs79qdXaRPmQtgcOKvkawps6h 3raRxo2RGvmxGHlsWKHnOQU0/NrNTVkqtc+CdBC6EBkruHOb3qsjdQMKzh5JB8pk09vMMH cMwt/dv7UxdsQnlFvjQ7piAfdgBOTHKRYqTiqTsvt03JVwaOGRRll8wWXCchMFtO21BodP 0D4UjZ3BQhouwED34vHPP8/Q+bQWXT6rifk8cvs8T9LFs/l86e9iGkmpzoYyFA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1704658754; a=rsa-sha256; cv=none; b=omElI6Bd5wiBWtzIwK3Cg5RQSRjAsRtfHNmZwuwmLLZrZP/idG4ahaIBJ7A2RTfZJed/Wy sRY9tU4pg/iHqqUDdB2sW7R7c9fDY6sbyGKmoaxayNqgOCsQek7scMrh5r4nXZfxoV9di/ Mh35XG6yRkH7o6BpkBl2zTep2jRTcKnntXgvTI9bN9dA5gnGlGDJnIWru3Ji1J749wE54s 9hO4qnxxyjFTR3JmQZEbzBGBoBk42TWDW8Iga+Da6L/fjoiT/UfgorSeFhbmyEOtHVsWWH 5oMJHOeeF+7X3Kzp15zbTki+7/VEuT2lzGZrHkLNKZnbXC/OtS5CRq91SiZXpQ== 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 4T7T756Ql3zf6K for ; Sun, 7 Jan 2024 20:19:13 +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 407KJDx0038666 for ; Sun, 7 Jan 2024 20:19:13 GMT (envelope-from bugzilla-noreply@freebsd.org) Received: (from www@localhost) by kenobi.freebsd.org (8.15.2/8.15.2/Submit) id 407KJDVr038665 for bugs@FreeBSD.org; Sun, 7 Jan 2024 20:19:13 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 276174] mkuzip creates images with an invalid startup script Date: Sun, 07 Jan 2024 20:19:13 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Base System X-Bugzilla-Component: bin X-Bugzilla-Version: 14.0-RELEASE X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Some People X-Bugzilla-Who: billblake2018@gmail.com X-Bugzilla-Status: New X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: bugs@FreeBSD.org X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: 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 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D276174 --- Comment #2 from Bill Blake --- These are the commands and the resulting script that is put at the start of each out.img file: > mkuzip -A zstd -o out.img in.img #!/bin/sh #Z4.0 Format (kldstat -qm g_uzip||kldload geom_uzip)>&-&&mount_cd9660 /dev/`mdconfig -af $0`.uzip $1 exit $? > mkuzip -A lzma -o out.img in.img #!/bin/sh #L3.0 n=3Duncompress m=3Dgeom_$n (kldstat -m $m 2>&-||kldload $m)>&-&&mount_cd9660 /dev/`mdconfig -af $0`.$n= $1 exit $? > mkuzip -A zlib -o out.img in.img #!/bin/sh #V2.0 Format (kldstat -qm g_uzip||kldload geom_uzip)>&-&&mount_cd9660 /dev/`mdconfig -af $0`.uzip $1 exit $? I can't speak to the kldstat/kldload stuff since I didn't actually run these scripts. However, look at the second example, which uses lzma. It tries to mount /dev/md*.uncompress. However, the mdconfig creates /dev/md*.uzip, so= the mount fails. (I did the commands manually to confirm that this sequence doe= sn't work.) The other two correctly use the .uzip device. But in all three cas= es, the mount is mount_cd9660, which won't work since the file systems actually created are ufs file systems. They need "mount -o ro" instead. (Again, manually confirmed.) Also, a nitpick: The mdconfig calls should have an option "-o ro". Where it matters is when the config'd image is on a read-only file system; mdconfig = will generate an error message without the read-only option, though it still con= figs the file. --=20 You are receiving this mail because: You are the assignee for the bug.=