From owner-freebsd-questions@freebsd.org Sat Mar 31 18:43:19 2018 Return-Path: Delivered-To: freebsd-questions@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 34D14F77294 for ; Sat, 31 Mar 2018 18:43:19 +0000 (UTC) (envelope-from jmvandette@securenet.net) Received: from ms.securenet.net (ms.securenet.net [205.236.147.20]) (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id CCFA070C07 for ; Sat, 31 Mar 2018 18:43:18 +0000 (UTC) (envelope-from jmvandette@securenet.net) Received: from ms.securenet.net (localhost [127.0.0.1]) by ms.securenet.net (Postfix) with ESMTP id A1EBF11DCA; Sat, 31 Mar 2018 14:43:11 -0400 (EDT) X-Virus-Scanned: by f-prot anti-virus, and clamav anti-virus at SecureNet Inc. Received: from ms.securenet.net ([127.0.0.1]) by ms.securenet.net (ms.securenet.net [127.0.0.1]) (amavisd-new, port 10001) with ESMTP id iHXcZx_GeIn7; Sat, 31 Mar 2018 14:43:09 -0400 (EDT) Received: from office.securenet.net (office.securenet.net [205.236.147.3]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by ms.securenet.net (Postfix) with ESMTPS id E496711DC5; Sat, 31 Mar 2018 14:43:09 -0400 (EDT) Received: from office.securenet.net (172.16.0.194) by office.securenet.net (172.16.0.194) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.1034.26; Sat, 31 Mar 2018 14:43:07 -0400 Received: from office.securenet.net ([fe80::fc2a:207d:850e:3424]) by office.securenet.net ([fe80::fc2a:207d:850e:3424%9]) with mapi id 15.01.1034.033; Sat, 31 Mar 2018 14:43:07 -0400 From: "Jean M. Vandette" To: Erich Dollansky CC: "freebsd-questions@freebsd.org" Subject: RE: gpart recovery FreeBSD 7.4 Thread-Topic: gpart recovery FreeBSD 7.4 Thread-Index: AdPH67s6+2Xno425Q4Gw3Y3ODMy5+wAZ1aOAAAgLB7AAClZQAAAIULXwABRMGwAAAW9JQA== Date: Sat, 31 Mar 2018 18:43:06 +0000 Message-ID: <3856200b233947ca939e1c5ffa152661@securenet.net> References: <6b89534c97b14e51b67581e34efac71c@securenet.net> <20180330221523.0b5f8fdd.freebsd.ed.lists@sumeritec.com> <20180331070140.00a1b6fa.freebsd.ed.lists@sumeritec.com> <20180331204056.619965d1.freebsd.ed.lists@sumeritec.com> In-Reply-To: <20180331204056.619965d1.freebsd.ed.lists@sumeritec.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.10.15.157] x-avg-scannedformalware-engineversion: 16.0.8039 4793/15529 510244 x-avg-scannedformalware-signature: 4A4B5170F951974E6149B20433C8AC4271433A3F2725FE646F916949AC978804 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 31 Mar 2018 18:43:19 -0000 Erich I used the recoverdisk root@central:/ # recoverdisk /dev/gpt/root /mnt2/root.img Bigsize =3D 1048576, medsize =3D 32768, minsize =3D 512 start size block-len state done re= maining % done 1072693248 1048576 1048576 0 1073741824 0 100.0= 0000 Completed root@central:/ # recoverdisk /dev/gpt/var /mnt2/var.img Bigsize =3D 1048576, medsize =3D 32768, minsize =3D 512 start size block-len state done = remaining % done 42948624384 1048576 1048576 0 42949672960 0 100.0= 0000 Completed I did newfs on the boot then it mounted seems it does not recognize the formatting of the partitions, I don't know if there is a way of making the machine think they are formatted without actually doing it. This disk used ufs1 not ufs2 I also tried fsdump but it barked about not finding the super= blocks either. When I did newfs -N -O1 on the root partition the results for supe= rblocks are very different 192, 524544, 1048896, 1573248 ufs2 64, 520256, 1040448, 1560640, 2080832 ufs1 also did dd of one file system to a file but I don't have other mount points ie disks to make copy. the recoverydisk with state 0 says it encountered no errors so it is seeing the data (I presume) just it is a binary file it seems. Now is the data us= able is another question. Using more or less I see a lot of binary gibberish so far. I don't know if there is a way to write the superblock information without = losing all the data if you or anyone knows I would appreciate the procedure. Did it once before or should say my mentor did it back on 3.1 and then was = able to fsck and mount the data. Regards Jean M. Vandette SecureNet Information Services Net-Vu Television Distribution Divisions 159272 Canada Inc. 283-100 Alexis Nihon Blvd St Laurent, Quebec H4M 2N7 514-744-4242 800-469-7774 514-744-1552 Fax IMPORTANT: Les informations contenues au pr=E9sent courriel ainsi que dans tout docume= nt annex=E9 sont de nature privil=E9gi=E9e et confidentielle et ne peuvent = =EAtre utilis=E9es que par la ou les personnes ou entit=E9s dont le nom par= a=EEt ci-dessus. Si le lecteur du pr=E9sent message n'est pas le destinatai= re pr=E9vu ou n'a pas =E9t=E9 mis en copie, il est par les pr=E9sentes pri= =E9 de noter qu'il est strictement interdit de divulguer, de distribuer de = copier ou d'utiliser de quelconque fa=E7on ce message ou ses annexes. Si ce= ux-ci vous ont =E9t=E9 transmis par m=E9garde, veuillez les effacer et nous= en aviser imm=E9diatement. This E-mail along with its attachments, if any, contain privileged and conf= idential information intended only for the use of the individuals or entiti= es named above. Any dissemination, distribution, copying or use of the same= by anyone other than the intended recipients is strictly prohibited. If yo= u have received this communication in error, please delete both E-mail and = attachments and notify us immediately. -----Original Message----- From: Erich Dollansky [mailto:freebsd.ed.lists@sumeritec.com] Sent: Saturday, March 31, 2018 8:41 AM To: Jean M. Vandette Cc: freebsd-questions@freebsd.org Subject: Re: gpart recovery FreeBSD 7.4 Hi, On Fri, 30 Mar 2018 23:34:08 +0000 "Jean M. Vandette" wrote: > Well I booted on 11.1 and the entire disk disappeared > Since I had the layout I was able to add the partitions > back but still cannot fsck or mount anything. I did not > newfs the partitions. So data should be still there... just need to > get to it. did you make a copy of the crucial parts of the media with dd or one of its friends? I tried the recoverdisk utility > > The layout seems to have changed however see below: Could it be that either GPT entries are faulty or the disk is dying and reports now a smaller size? Ok, a smaller size will result in a different behaviour. If you know the original layout, you should be able to read the GPT tables and compare them with what they should be. If you have the copy, just edit them with the values you want. When the values match, the partitions suddenly appear. I know, this is real hard core. Erich ? ------------------------------- Checked by AVG. Version: 16.0.8039 / Virus Database: 4793/15529 - Release D= ate: Sat Mar 31 09:04:00 2018. The message does not contain any threats. -------------------------------