From owner-freebsd-questions@freebsd.org Fri Jun 24 00:41:36 2016 Return-Path: Delivered-To: freebsd-questions@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 29C04B721A0 for ; Fri, 24 Jun 2016 00:41:36 +0000 (UTC) (envelope-from perikillo@gmail.com) Received: from mail-lf0-x229.google.com (mail-lf0-x229.google.com [IPv6:2a00:1450:4010:c07::229]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 8E7541510 for ; Fri, 24 Jun 2016 00:41:35 +0000 (UTC) (envelope-from perikillo@gmail.com) Received: by mail-lf0-x229.google.com with SMTP id q132so106155976lfe.3 for ; Thu, 23 Jun 2016 17:41:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to; bh=h03As0HjKnzKWN54os/S8bwv0hjz0c/rWT5cKgNcTVE=; b=GFesygUFX4eDKME7MjOAQiENBs0LQjYwjzQTUXL34iRtSBpCFUkBtGV2hgvdUr2CHo JMSUUb6zFoJm3amiPJ3TGpk5ME3UF4SEaE7QMjCfbKe2pdZVylKJePU0/KSYU9PWKNCf ArOwSjTgNMsBTFwkOkgOA5mLGrTPtLoaxDjjAVcQBt/Xqc5uyrY01QR4e5YJjB+7FGtj Qyr0jjVHB7jnndp/WJUvP+989Y6+55B/j9lTKckLNrJU4rnX76XLk6FSnt7p137mU7oi 7BNKWF/NPD16CXlmBSNZn9Lw9ZXiBWDa8FCCDHlIGY9W0QuSEb/jcxer6pea1g9uie7o GNrg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to; bh=h03As0HjKnzKWN54os/S8bwv0hjz0c/rWT5cKgNcTVE=; b=mzi2Ujkd9a5AeyM2iwXYrtNFbeaG9yRSdq84VJ+tyzNDcosK9+xOoDgFHYwNndMnFc Vnilhsu8Jy/GduqWMu83rhLvXXvESHOGFlXCldmuo9vq6Nf66tiaRIXwjxj3UF7u4/Bp Vmb/47ZCCfqkKOw3XmmJs6cWfx9aZPErgo0tSHbo7SdBNjHofQ9CLSzsivfuMKaJPKLX hOpHRPVIER8AZLEUI7mZGd55XngRjxyxztU7+upcw/Wj7ulE168+zc2n3+q85xq6QyH4 h+wZMSpFPAeBmYuvtFwEmoV+6bYhVfthRVCLhgFyJuS68VrjQEZ9u36lz8CWADKHytUV Rn7A== X-Gm-Message-State: ALyK8tIpZGqqzBe6pINwatW+2QBpW6j2MgikXy/7LUyBQNAisFkSEKSoyBKCR9fWswSb0jsH5mxx8BpL3cjM4A== X-Received: by 10.25.86.209 with SMTP id k200mr414151lfb.65.1466728893286; Thu, 23 Jun 2016 17:41:33 -0700 (PDT) MIME-Version: 1.0 Received: by 10.25.76.7 with HTTP; Thu, 23 Jun 2016 17:41:32 -0700 (PDT) In-Reply-To: <1466728696.778596880.0qwmo21g@frv35.fwdcdn.com> References: <1466717892.674545627.ai2dh1w6@frv35.fwdcdn.com> <1466725107.953028829.tc1fmx6e@frv35.fwdcdn.com> <1466728696.778596880.0qwmo21g@frv35.fwdcdn.com> From: perikillo Date: Thu, 23 Jun 2016 17:41:32 -0700 Message-ID: Subject: Re: Re[2]: Re[2]: Copy bootcode to mirror disk? To: FreeBSD Mailing List Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.22 X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 24 Jun 2016 00:41:36 -0000 gpart show => 34 976773101 ada0 GPT (466G) 34 6 - free - (3.0K) 40 128 1 freebsd-boot (64K) 168 2097152 2 freebsd-ufs (1.0G) 2097320 16777216 3 freebsd-ufs (8.0G) 18874536 16777216 4 freebsd-ufs (8.0G) 35651752 1048576 5 freebsd-ufs (512M) 36700328 1048576 6 freebsd-swap (512M) 37748904 939024231 - free - (448G) => 34 976773101 ada1 GPT (466G) 34 6 - free - (3.0K) 40 128 1 freebsd-boot (64K) 168 2097152 2 freebsd-ufs (1.0G) 2097320 16777216 3 freebsd-ufs (8.0G) 18874536 16777216 4 freebsd-ufs (8.0G) 35651752 1048576 5 freebsd-ufs (512M) 36700328 1048576 6 freebsd-swap (512M) 37748904 939024231 - free - (448G) gmirror status Name Status Components mirror/boot COMPLETE ada0p1 (ACTIVE) ada1p1 (ACTIVE) mirror/root COMPLETE ada0p2 (ACTIVE) ada1p2 (ACTIVE) mirror/usr COMPLETE ada0p3 (ACTIVE) ada1p3 (ACTIVE) mirror/var COMPLETE ada0p4 (ACTIVE) ada1p4 (ACTIVE) mirror/tmp COMPLETE ada0p5 (ACTIVE) ada1p5 (ACTIVE) mirror/swap COMPLETE ada0p6 (ACTIVE) ada1p6 (ACTIVE) On Thu, Jun 23, 2016 at 5:38 PM, Vladislav Prodan wrote: > > > Please show: > > gpart show > gmirror status > > > --- Original message --- > From: "perikillo" > Date: 24 June 2016, 02:53:34 > > > > > sysctl kern.geom.debugflags=16 > > kern.geom.debugflags: 0 -> 16 > > > > root@spam:~ # gpart bootcode -b /boot/pmbr -p /boot/gptboot -i 1 ada0 > > gpart: /dev/ada0p1: Operation not permitted > > > > On Thu, Jun 23, 2016 at 4:40 PM, Vladislav Prodan > > wrote: > > > > > > > > > > > > > > --- Original message --- > > > From: "perikillo" > > > Date: 24 June 2016, 01:58:05 > > > > > > > > > > > > > Thanks for your quick answer, I got this error: > > > > > > > > gpart bootcode -b /boot/pmbr -p /boot/gptboot -i 1 ada0 > > > > > > > > gpart: /dev/ada0p1: Operation not permitted > > > > > > > > Do I need remove first from mirror or some step before this? > > > > > > No. > > > > > > Try to enter in the console: > > > sysctl kern.geom.debugflags=16 > > > And then try again: > > > gpart bootcode -b /boot/pmbr -p /boot/gptboot -i 1 ada0 > > > > > > > > > > > > > > Thanks. > > > > > > > > On Thu, Jun 23, 2016 at 2:40 PM, Vladislav Prodan < > universite@ukr.net> > > > > wrote: > > > > > > > > > > > > > > > > > > > > > > > > --- Original message --- > > > > > From: "perikillo" > > > > > Date: 23 June 2016, 23:19:27 > > > > > > > > > > > > > > > > > > > > > Hi I have a server with 2 hard disk in mirror setup. > > > > > > > > > > > > My slices are: > > > > > > > > > > > > Code: > > > > > > root@spam:/boot # gpart show ada1 > > > > > > 34 976773101 ada1 GPT (466G) > > > > > > 34 6 - free - (3.0K) > > > > > > 40 128 1 freebsd-boot (64K) > > > > > > 168 2097152 2 freebsd-ufs (1.0G) > > > > > > 2097320 16777216 3 freebsd-ufs (8.0G) > > > > > > 18874536 16777216 4 freebsd-ufs (8.0G) > > > > > > 35651752 1048576 5 freebsd-ufs (512M) > > > > > > 36700328 1048576 6 freebsd-swap (512M) > > > > > > 37748904 939024231 - free - (448G) > > > > > > > > > > > > > > > > > > My mirror has ada0 ada1, ada0 var slice fails, them I decide to > > > replace > > > > > the > > > > > > whole disk and follow the instructions for that using gpart and > > > backup my > > > > > > current good disk layout into my new disk. > > > > > > > > > > > > gpart backup ada1 | gpart restore -F /dev/ada0 > > > > > > > > > > > > > > > > > > This create my slices, I forget each mirror slice and add each > slice > > > into > > > > > > the mirror again. > > > > > > > > > > > > Everything working, but looks like I forget to add the bootcode > to > > > my new > > > > > > disk because it won't boot. > > > > > > > > > > > > Now is booting from 2nd disk but need to boot from all hard > disk, if > > > ada1 > > > > > > fails I will have issues. > > > > > > > > > > > > > > > Install the GPT bootcode into the boot partition: > > > > > > > > > > # gpart bootcode -b /boot/pmbr -p /boot/gptboot -i 1 ada0 > > > > > > > > > > -- > > > > > Vladislav V. Prodan > > > > > System & Network Administrator > > > > > support.od.ua > > > > > > > > > > > > > > > > > > > > > > > > _______________________________________________ > > > > freebsd-questions@freebsd.org mailing list > > > > https://lists.freebsd.org/mailman/listinfo/freebsd-questions > > > > To unsubscribe, send any mail to " > > > freebsd-questions-unsubscribe@freebsd.org" > > > > > > > > > > > > > -- > > > Vladislav V. Prodan > > > System & Network Administrator > > > support.od.ua > > > > > > > > > > > > > > _______________________________________________ > > freebsd-questions@freebsd.org mailing list > > https://lists.freebsd.org/mailman/listinfo/freebsd-questions > > To unsubscribe, send any mail to " > freebsd-questions-unsubscribe@freebsd.org" > > > > > -- > Vladislav V. Prodan > System & Network Administrator > support.od.ua > > > >