Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 6 Sep 2019 16:13:42 +0200
From:      Julien Cigar <julien@perdition.city>
To:        Polytropon <freebsd@edvax.de>
Cc:        freebsd-questions@freebsd.org
Subject:   Re: gpart bootcode for MBR + ZFS?
Message-ID:  <20190906141342.GJ38457@home.lan>
In-Reply-To: <20190906155834.685b57a2.freebsd@edvax.de>
References:  <20190906100649.GH38457@home.lan> <20190906115531.GI38457@home.lan> <20190906155834.685b57a2.freebsd@edvax.de>

next in thread | previous in thread | raw e-mail | index | archive | help

--yr/DzoowOgTDcSCF
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On Fri, Sep 06, 2019 at 03:58:34PM +0200, Polytropon wrote:
> On Fri, 6 Sep 2019 13:55:31 +0200, Julien Cigar wrote:
> > From what I understand I /boot/boot0 (or mbr) only provides stage 0, for
> > stage 1 and stage 2 I should use:
> > $> dd if=3D/boot/zfsboot of=3D/dev/ada1s1 count=3D1
> > $> dd if=3D/boot/zfsboot of=3D/dev/ada1s1a iseek=3D1 oseek=3D1024
> >=20
> > However I'm getting a "Operation not permitted" even with
> > kern.geom.debugflags=3D0x10 .. any idea?
>=20
> Judging by the prompt... are you doing this as root? $ suggests
> a non-root user, who of course is not permitted to write to a
> disk device file directly.

Yes, I'm doing this as root ..=20

I did the following:

$> gpart backup ada0 | gpart restore -F ada1
$> gpart backup ada0s1 | gpart restore -F ada1s1
$> zpool attach bootpool ada0s1a ada1s1a
$> zpool attach zroot ada0s1d ada1s1d
$> gpart bootcode -b /boot/mbr ada1
$> sysctl kern.geom.debugflags=3D0x10
$> dd if=3D/boot/zfsboot of=3D/dev/ada1s1 count=3D1
$> dd if=3D/boot/zfsboot of=3D/dev/ada1s1a iseek=3D1 oseek=3D1024

(last two steps failed)

I'm wondering if this is because ZFS is involved ..?
(although man 4 geom doesn't say anything about thatr)

Julien

>=20
>=20
> --=20
> Polytropon
> Magdeburg, Germany
> Happy FreeBSD user since 4.0
> Andra moi ennepe, Mousa, ...

--=20
Julien Cigar
Belgian Biodiversity Platform (http://www.biodiversity.be)
PGP fingerprint: EEF9 F697 4B68 D275 7B11  6A25 B2BB 3710 A204 23C0
No trees were killed in the creation of this message.
However, many electrons were terribly inconvenienced.

--yr/DzoowOgTDcSCF
Content-Type: application/pgp-signature; name="signature.asc"

-----BEGIN PGP SIGNATURE-----

iQIzBAABCgAdFiEE7vn2l0to0nV7EWolsrs3EKIEI8AFAl1yaZIACgkQsrs3EKIE
I8DwZhAA7fNbVqsHa0rJBDsVkWVV816D9Tk4QVbzNZl5hYAy3tWcHXG9oHuVfv7W
e/YL1wlN5W1ultK7oxy13EAm1EB4ivyahAz2H7nCmH0gJN1BNYRj8eXUAoyobiKd
C49wU72xZuumaIKc3eap7q/ZrllPfLvK6ifVcVZlqlomQEOI4NQaAc8kb9GywQnL
g202xBBWCIjkfJkoSn10WPtO3tbT7ATWslnUKFqu0nvySrO2keZbhlavHuUEW1yn
STXYNEy1ZZhQXs6TUQdMyLQPC1cvUzO2/YbUJ+doLCgKd2fuZt5TT1/yti4AYS0f
HtzG7kSKN/gp7gBwbPYgpQ76YmhvqYgT9fbaTlem1JszwtIZoo15gPIJcm+aQrzc
Dx07YFR+qM/nEhmBXC7Li/8cZWVHzbAWOPAvhEhZsn0BY7yR0HquuSC7LsF0KmCn
epxxbTAekFyJFg88unSGUEIGgI9NvOaIpOlS3YDCQ6Iw8vTd5Hvc6LctZKaSk9oz
zcwcmFR9c4/RnRkkSFk0OCV91i0HDPGKdMUT/u1kXPWHs7Uda1nhpEgWaaTQSvqD
N1nWTIh/jPTpbBygB7Y7ndhW8SiSuXAittZxT+GqmQCwwVt/vDxaoaQLRuuQZr0J
49vvfQq3VItHEJlV2IIaYF1WJzVAKzuAp3G5QPLtfg7FRQZrLaU=
=53Gp
-----END PGP SIGNATURE-----

--yr/DzoowOgTDcSCF--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20190906141342.GJ38457>