On Mon, Jan 4, 2021 at 11:09 AM André Isidro da Silva <andreisi...@tecnico.ulisboa.pt> wrote: > > I'm sure it used to be one, but indeed it seems that a TYPE is missing > in /dev/sda10; gparted says it's unknown. > It seems there is no trace of the fs. I'm trying to recall any other > operations I might have done, but if it was something else I can't > remember what could have been. I used cfdisk, to resize another > partition, also tried to do a 'btrfs device add' with this missing one > (to solve the no space left in another one), otherwise it was mount /, > mount /home (/dev/sda10), umount, repeat. Oh well. > > [sudo blkid] > > /dev/sda1: UUID="03ff3132-dfc5-4dce-8add-cf5a6c854313" BLOCK_SIZE="4096" > TYPE="ext4" PARTLABEL="LINUX" > PARTUUID="a6042b9f-a3fe-49e2-8dc5-98a818454b6d" > > /dev/sdb4: UUID="5c7201df-ff3e-4cb7-8691-8ef0c6c806ed" > UUID_SUB="bb677c3a-6270-420f-94ce-f5b89f2c40d2" BLOCK_SIZE="4096" > TYPE="btrfs" PARTUUID="be4190e4-8e09-4dfc-a901-463f3e162727" > > /dev/sda10: PARTLABEL="HOME" > PARTUUID="6045f3f0-47a7-4b38-a392-7bebb7f654bd" > > [sudo btrfs insp dump-s -F /dev/sda10] > > superblock: bytenr=65536, device=/dev/sda10 > --------------------------------------------------------- > csum_type 0 (crc32c) > csum_size 4 > csum 0x00000000 [DON'T MATCH] > bytenr 0 > flags 0x0 > magic ........ [DON'T MATCH] > fsid 00000000-0000-0000-0000-000000000000 > metadata_uuid 00000000-0000-0000-0000-000000000000 > label > generation 0 > root 0 > sys_array_size 0 > chunk_root_generation 0 > root_level 0 > chunk_root 0 > chunk_root_level 0 > log_root 0 > log_root_transid 0 > log_root_level 0 > total_bytes 0 > bytes_used 0 > sectorsize 0 > nodesize 0 > leafsize (deprecated) 0 > stripesize 0 > root_dir 0 > num_devices 0 > compat_flags 0x0 > compat_ro_flags 0x0 > incompat_flags 0x0 > cache_generation 0 > uuid_tree_generation 0 > dev_item.uuid 00000000-0000-0000-0000-000000000000 > dev_item.fsid 00000000-0000-0000-0000-000000000000 [match] > dev_item.type 0 > dev_item.total_bytes 0 > dev_item.bytes_used 0 > dev_item.io_align 0 > dev_item.io_width 0 > dev_item.sector_size 0 > dev_item.devid 0 > dev_item.dev_group 0 > dev_item.seek_speed 0 > dev_item.bandwidth 0 > dev_item.generation 0 > > This as nothing to do with btrfs anymore, but: do you think a tool like > foremost can recover the files, it'll be a mess, but better then nothing > and I've used it before in a ntfs.
No idea. You could scan the entire drive for the Btrfs magic, which is inside the superblock. It will self identify its offset, the first superblock is the one you want, which is offset 65536 (64KiB) from the start of the block device/partition. And that superblock also says the device size. -- Chris Murphy