From nobody Wed Sep 13 13:02:10 2023 X-Original-To: freebsd-hackers@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 4Rm0wp5F2Qz4sXtr for ; Wed, 13 Sep 2023 13:02:34 +0000 (UTC) (envelope-from guy.helmer@gmail.com) Received: from mail-yw1-x1136.google.com (mail-yw1-x1136.google.com [IPv6:2607:f8b0:4864:20::1136]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1D4" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Rm0wn2PhSz3cZ8 for ; Wed, 13 Sep 2023 13:02:33 +0000 (UTC) (envelope-from guy.helmer@gmail.com) Authentication-Results: mx1.freebsd.org; dkim=pass header.d=gmail.com header.s=20221208 header.b=Lz3ZsglN; spf=pass (mx1.freebsd.org: domain of guy.helmer@gmail.com designates 2607:f8b0:4864:20::1136 as permitted sender) smtp.mailfrom=guy.helmer@gmail.com; dmarc=pass (policy=none) header.from=gmail.com Received: by mail-yw1-x1136.google.com with SMTP id 00721157ae682-59b50b4556eso56763717b3.1 for ; Wed, 13 Sep 2023 06:02:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1694610149; x=1695214949; darn=freebsd.org; h=to:date:message-id:subject:mime-version:from:from:to:cc:subject :date:message-id:reply-to; bh=Yib/unPWMHU4XLTmFbRRIdJlUBx51idGJArhsHmb7A4=; b=Lz3ZsglNBAz7JgXix5lJMDqFqHFbMn/CJypQ1KGS94PftgPnmNKgjRuiYiRzERsp9E V2vzdi/1eiZCyKdgMH93Tupo16anKziWVRh26+t5icmE76QGx3jRIx7VooZzsW+c2oaP tYSkG8oWc6bXCbhyDHNIzbdB+tv4y2aXabPQIsNNCDa5pnllDRN+HkUzg7QhPonMbVc4 g0xiB8nbT9tzAJSQePyFkUzVTn4wZEuP9xtX70g6zKhDGUlMhO5+J3AWknVxNl1G0SVZ SL5CzKNpo/1zDgdp8fyGTtb8RdtTx+QOYVnQe7hKUns1ec2icHK9UAOMYPi+BOmxV1zH vSiA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1694610149; x=1695214949; h=to:date:message-id:subject:mime-version:from:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=Yib/unPWMHU4XLTmFbRRIdJlUBx51idGJArhsHmb7A4=; b=eMrilVIvh+Fc+WR6S23QFoLypCL3l7hGv3ACdWRF55ED2JRSQ2CC372G3nrpbesQDD o+RU73ZVVrhXPIWeYURQrGx1rdL5JXT/cG0x5/Q4lMzs86ZvKGsBEUiaKvD38KMCKzoF kaZImjJYEMCq+BWG0LZDMeim34lSjoaIMlIjxuDILwp5NmR5S1idbmA30FGkdqI43tA9 vgG5bG1Ish54cEF93oJjJSr9p+xuLtk4XmVAd6M3b6skdiuKcNu1mUkum1g8vE2eF6Cn dAgM93XVA2/3eUbCVY+w4EW+uc31igBugVINLQhZudo/yTHlzvor7du/G3QwgI5nELU7 gkkw== X-Gm-Message-State: AOJu0Yzy6LcOROjJvq1PM+xe4nLca4C7vUhj+RxaBRGftxtKsGfIvVfO xW7+Ojl94+k+D3CQ7OzdQlK0tnwQKA8= X-Google-Smtp-Source: AGHT+IHBVpqqtfkc/lxUnOLa/YNghv7QgBRxOFTm7CV2j8LEpqINFJESNDZkRfDm6JfconXsJPNayg== X-Received: by 2002:a81:7b42:0:b0:58d:7ec3:16c4 with SMTP id w63-20020a817b42000000b0058d7ec316c4mr2229508ywc.34.1694610144839; Wed, 13 Sep 2023 06:02:24 -0700 (PDT) Received: from smtpclient.apple (1636571-static.amesiaaa.metronetinc.net. [217.180.226.49]) by smtp.gmail.com with ESMTPSA id z63-20020a818942000000b00583d1fa1fccsm3128144ywf.0.2023.09.13.06.02.23 for (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Wed, 13 Sep 2023 06:02:23 -0700 (PDT) From: Guy Helmer Content-Type: multipart/alternative; boundary="Apple-Mail=_90D0AFE5-F318-406F-BFEB-84041663F383" List-Id: Technical discussions relating to FreeBSD List-Archive: https://lists.freebsd.org/archives/freebsd-hackers List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-hackers@freebsd.org Mime-Version: 1.0 (Mac OS X Mail 16.0 \(3731.700.6\)) Subject: Unable to access GPT disk partitions - No such file or directory Message-Id: <0CAE8FD0-9F09-4CF6-A402-DF30B039DF23@gmail.com> Date: Wed, 13 Sep 2023 08:02:10 -0500 To: freebsd-hackers@freebsd.org X-Mailer: Apple Mail (2.3731.700.6) X-Spamd-Bar: --- X-Spamd-Result: default: False [-3.49 / 15.00]; NEURAL_HAM_LONG(-1.00)[-1.000]; NEURAL_HAM_MEDIUM(-1.00)[-1.000]; NEURAL_HAM_SHORT(-0.99)[-0.989]; MV_CASE(0.50)[]; DMARC_POLICY_ALLOW(-0.50)[gmail.com,none]; R_SPF_ALLOW(-0.20)[+ip6:2607:f8b0:4000::/36]; R_DKIM_ALLOW(-0.20)[gmail.com:s=20221208]; MIME_GOOD(-0.10)[multipart/alternative,text/plain]; TO_MATCH_ENVRCPT_ALL(0.00)[]; FROM_HAS_DN(0.00)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; PREVIOUSLY_DELIVERED(0.00)[freebsd-hackers@freebsd.org]; ARC_NA(0.00)[]; RCVD_IN_DNSWL_NONE(0.00)[2607:f8b0:4864:20::1136:from]; RCPT_COUNT_ONE(0.00)[1]; MID_RHS_MATCH_FROM(0.00)[]; TAGGED_FROM(0.00)[]; MLMMJ_DEST(0.00)[freebsd-hackers@freebsd.org]; DKIM_TRACE(0.00)[gmail.com:+]; TO_DN_NONE(0.00)[]; FREEMAIL_FROM(0.00)[gmail.com]; DWL_DNSWL_NONE(0.00)[gmail.com:dkim]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+,1:+,2:~]; RCVD_TLS_LAST(0.00)[]; ASN(0.00)[asn:15169, ipnet:2607:f8b0::/32, country:US]; FREEMAIL_ENVFROM(0.00)[gmail.com]; RCVD_COUNT_TWO(0.00)[2] X-Rspamd-Queue-Id: 4Rm0wn2PhSz3cZ8 --Apple-Mail=_90D0AFE5-F318-406F-BFEB-84041663F383 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=us-ascii Hi, looking for some advice to get some data back. I've had a FreeBSD 13 system (upgraded over the years from several = previous versions) on a VMware ESXi server suddenly loose access to its = UFS filesystems.=20 I cloned the disk image in the VMware server and have attached it to = another FreeBSD 13 virtual machine to try to recover access to the data = (I have old backups on a separate ZFS filesystem, but I'd sure like to = recover the current filesystem). There are no kernel messages about = problems with the virtual disk other than the expected boot messages: da2 at mpt0 bus 0 scbus2 target 2 lun 0 da2: Fixed Direct Access SCSI-2 device da2: 320.000MB/s transfers (160.000MHz, offset 127, 16bit) da2: Command Queueing enabled da2: 81920MB (167772160 512 byte sectors) da2: quirks=3D0x140 gpart shows its info: $ sudo gpart list da2 Geom name: da2 modified: false state: OK fwheads: 255 fwsectors: 63 last: 167772126 first: 34 entries: 128 scheme: GPT Providers: 1. Name: da2p1 Mediasize: 262144 (256K) Sectorsize: 512 Stripesize: 0 Stripeoffset: 20480 Mode: r0w0e0 efimedia: HD(1,GPT,76c936da-f200-11e4-b749-000c29d7feb4,0x28,0x200) rawuuid: 76c936da-f200-11e4-b749-000c29d7feb4 rawtype: 83bd6b9d-7f41-11dc-be0b-001560b84f0f label: gpboot1 length: 262144 offset: 20480 type: freebsd-boot index: 1 end: 551 start: 40 2. Name: da2p2 Mediasize: 4294967296 (4.0G) Sectorsize: 512 Stripesize: 0 Stripeoffset: 1048576 Mode: r0w0e0 efimedia: = HD(2,GPT,954100b0-f200-11e4-b749-000c29d7feb4,0x800,0x800000) rawuuid: 954100b0-f200-11e4-b749-000c29d7feb4 rawtype: 516e7cb6-6ecf-11d6-8ff8-00022d09712b label: gprootfs1 length: 4294967296 offset: 1048576 type: freebsd-ufs index: 2 end: 8390655 start: 2048 3. Name: da2p3 Mediasize: 4294967296 (4.0G) Sectorsize: 512 Stripesize: 0 Stripeoffset: 1048576 Mode: r0w0e0 efimedia: = HD(3,GPT,a2ed8c2e-f200-11e4-b749-000c29d7feb4,0x800800,0x800000) rawuuid: a2ed8c2e-f200-11e4-b749-000c29d7feb4 rawtype: 516e7cb5-6ecf-11d6-8ff8-00022d09712b label: gpswap1 length: 4294967296 offset: 4296015872 type: freebsd-swap index: 3 end: 16779263 start: 8390656 4. Name: da2p4 Mediasize: 77308345856 (72G) Sectorsize: 512 Stripesize: 0 Stripeoffset: 1048576 Mode: r0w0e0 efimedia: = HD(4,GPT,a84afad7-f200-11e4-b749-000c29d7feb4,0x1000800,0x8fff7df) rawuuid: a84afad7-f200-11e4-b749-000c29d7feb4 rawtype: 516e7cb6-6ecf-11d6-8ff8-00022d09712b label: gpusrfs1 length: 77308345856 offset: 8590983168 type: freebsd-ufs index: 4 end: 167772126 start: 16779264 Consumers: 1. Name: da2 Mediasize: 85899345920 (80G) Sectorsize: 512 Mode: r0w0e0 The /dev entries look OK to me: $ ls -l /dev/da2* crw-r----- 1 root operator 0x66 Sep 13 14:01 /dev/da2 crw-r----- 1 root operator 0x6c Sep 13 14:01 /dev/da2p1 crw-r----- 1 root operator 0x6d Sep 13 14:01 /dev/da2p2 crw-r----- 1 root operator 0x6e Sep 13 14:01 /dev/da2p3 crw-r----- 1 root operator 0x6f Sep 13 14:01 /dev/da2p4 $ ls -l /dev/gpt/ total 0 crw-r----- 1 root operator 0x75 Sep 13 14:01 gpboot1 crw-r----- 1 root operator 0x77 Sep 13 14:01 gprootfs1 crw-r----- 1 root operator 0x79 Sep 13 14:01 gpswap1 crw-r----- 1 root operator 0x7b Sep 13 14:01 gpusrfs1 However, any attempt to access the /dev entries fails with "No such file = or directory": $ sudo fsck /dev/da2p2 Can't open /dev/da2p2: No such file or directory $ sudo fsck /dev/da2p4 Can't open /dev/da2p4: No such file or directory $ sudo fsck /dev/gpt/gprootfs1=20 Can't open /dev/gpt/gprootfs1: No such file or directory $ sudo fsck /dev/gpt/gpusrfs1=20 Can't open /dev/gpt/gpusrfs1: No such file or directory I've never had an issue like this before and I can't find anything using = Google searches that resolves access to these disk devices. Any ideas? Thanks, Guy Helmer, Ph.D. --Apple-Mail=_90D0AFE5-F318-406F-BFEB-84041663F383 Content-Transfer-Encoding: quoted-printable Content-Type: text/html; charset=us-ascii
Hi, = looking for some advice to get some data = back.

I've had a FreeBSD 13 system (upgraded = over the years from several previous versions) on a VMware ESXi server = suddenly loose access to its UFS = filesystems. 

I cloned the disk image in = the VMware server and have attached it to another FreeBSD 13 virtual = machine to try to recover access to the data (I have old backups on a = separate ZFS filesystem, but I'd sure like to recover the current = filesystem). There are no kernel messages about problems with the = virtual disk other than the expected boot = messages:

da2 at mpt0 bus 0 scbus2 target 2 lun = 0
da2: <VMware Virtual disk 1.0> Fixed Direct Access = SCSI-2 device
da2: 320.000MB/s transfers (160.000MHz, offset = 127, 16bit)
da2: Command Queueing enabled
da2: = 81920MB (167772160 512 byte sectors)
da2: = quirks=3D0x140<RETRY_BUSY,STRICT_UNMAP>

gpa= rt shows its info:

$ sudo gpart list = da2
Geom name: da2
modified: false
state: = OK
fwheads: 255
fwsectors: 63
last: = 167772126
first: 34
entries: 128
scheme: = GPT
Providers:
1. Name: da2p1
  =  Mediasize: 262144 (256K)
   Sectorsize: = 512
   Stripesize: 0
  =  Stripeoffset: 20480
   Mode: = r0w0e0
   efimedia: = HD(1,GPT,76c936da-f200-11e4-b749-000c29d7feb4,0x28,0x200)
 =  rawuuid: 76c936da-f200-11e4-b749-000c29d7feb4
  =  rawtype: 83bd6b9d-7f41-11dc-be0b-001560b84f0f
  =  label: gpboot1
   length: = 262144
   offset: 20480
   type: = freebsd-boot
   index: 1
   end: = 551
   start: 40
2. Name: = da2p2
   Mediasize: 4294967296 = (4.0G)
   Sectorsize: 512
  =  Stripesize: 0
   Stripeoffset: = 1048576
   Mode: r0w0e0
  =  efimedia: = HD(2,GPT,954100b0-f200-11e4-b749-000c29d7feb4,0x800,0x800000)
&n= bsp;  rawuuid: = 954100b0-f200-11e4-b749-000c29d7feb4
   rawtype: = 516e7cb6-6ecf-11d6-8ff8-00022d09712b
   label: = gprootfs1
   length: 4294967296
  =  offset: 1048576
   type: = freebsd-ufs
   index: 2
   end: = 8390655
   start: 2048
3. Name: = da2p3
   Mediasize: 4294967296 = (4.0G)
   Sectorsize: 512
  =  Stripesize: 0
   Stripeoffset: = 1048576
   Mode: r0w0e0
  =  efimedia: = HD(3,GPT,a2ed8c2e-f200-11e4-b749-000c29d7feb4,0x800800,0x800000)
   rawuuid: = a2ed8c2e-f200-11e4-b749-000c29d7feb4
   rawtype: = 516e7cb5-6ecf-11d6-8ff8-00022d09712b
   label: = gpswap1
   length: 4294967296
  =  offset: 4296015872
   type: = freebsd-swap
   index: 3
   end: = 16779263
   start: 8390656
4. Name: = da2p4
   Mediasize: 77308345856 = (72G)
   Sectorsize: 512
  =  Stripesize: 0
   Stripeoffset: = 1048576
   Mode: r0w0e0
  =  efimedia: = HD(4,GPT,a84afad7-f200-11e4-b749-000c29d7feb4,0x1000800,0x8fff7df)
   rawuuid: = a84afad7-f200-11e4-b749-000c29d7feb4
   rawtype: = 516e7cb6-6ecf-11d6-8ff8-00022d09712b
   label: = gpusrfs1
   length: 77308345856
  =  offset: 8590983168
   type: = freebsd-ufs
   index: 4
   end: = 167772126
   start: = 16779264
Consumers:
1. Name: da2
  =  Mediasize: 85899345920 (80G)
   Sectorsize: = 512
   Mode: = r0w0e0

The /dev entries look OK to = me:
$ ls -l /dev/da2*
crw-r-----  1 root =  operator  0x66 Sep 13 14:01 /dev/da2
crw-r----- =  1 root  operator  0x6c Sep 13 14:01 = /dev/da2p1
crw-r-----  1 root  operator  0x6d = Sep 13 14:01 /dev/da2p2
crw-r-----  1 root  operator =  0x6e Sep 13 14:01 /dev/da2p3
crw-r-----  1 root =  operator  0x6f Sep 13 14:01 /dev/da2p4
$ ls -l = /dev/gpt/
total 0
crw-r-----  1 root =  operator  0x75 Sep 13 14:01 gpboot1
crw-r----- =  1 root  operator  0x77 Sep 13 14:01 = gprootfs1
crw-r-----  1 root  operator  0x79 = Sep 13 14:01 gpswap1
crw-r-----  1 root  operator =  0x7b Sep 13 14:01 gpusrfs1

However, = any attempt to access the /dev entries fails with "No such file or = directory":

$ sudo fsck = /dev/da2p2
Can't open /dev/da2p2: No such file or = directory
$ sudo fsck /dev/da2p4
Can't = open /dev/da2p4: No such file or directory
$ sudo = fsck /dev/gpt/gprootfs1 
Can't open /dev/gpt/gprootfs1: = No such file or directory
$ sudo fsck = /dev/gpt/gpusrfs1 
Can't open /dev/gpt/gpusrfs1: No such = file or directory

I've never had an issue = like this before and I can't find anything using Google searches that = resolves access to these disk devices. Any = ideas?

Thanks,
Guy Helmer, = Ph.D.

= --Apple-Mail=_90D0AFE5-F318-406F-BFEB-84041663F383--