# Boulette resize fs (lvextend, vgextend, initframfs)

**URL:** <https://www.debian-fr.org/t/boulette-resize-fs-lvextend-vgextend-initframfs/81728>\
**Category:** Support Debian\
**Created:** [Avril 8, 2020, 3:21 UTC](https://www.debian-fr.org/t/boulette-resize-fs-lvextend-vgextend-initframfs/81728 "2020-04-08T15:21:20Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Gen0x](https://www.debian-fr.org/user_avatar/www.debian-fr.org/gen0x/32/9089_2.png) [@Gen0x](https://www.debian-fr.org/u/Gen0x)\
**Post date:** [Avril 8, 2020, 3:21 UTC](https://www.debian-fr.org/t/boulette-resize-fs-lvextend-vgextend-initframfs/81728/1 "2020-04-08T15:21:20Z")

</div>

Bonjour à tous,

Je viens de faire une belle boulette sur une Debian 9 que j’utilise comme serveur de webapps pour le boulot.

J’ai un seul DD de 240GB dedans, j’ai voulu augmenter le fs /var à force qu’il sature à cause du nombre d’applis qui sont host sous /var/www et des multiples uploads.

J’ai utilisé la combinaison classique lvextend, dev/mapper/rootvg-var\_lv, resize2fs.

Mais dans la précipitation, je me suis aperçu d’une erreur trop tard.

Je suis à la base sous cette articulation :  
/dev/sda1 = swap  
/dev/sda5 = /usr, /var, /etc, /tmp, … = 227GB

Quand j’ai reboot, j’ai eu droit à un beau vg-root not found.  
Et à initframfs.

-blkid, j’ai désormais :  
/dev/sda1 = 227GB  
/dev/sda5 = 227GB

Pas moyen de remonter quoique ce soit…  
Je n’ai plus que fdisk et blkid qui fonctionnent en cmd.

Je viens graver une live Debian10, il y a moyen de remonter mes FS et tout récupérer ?  
Vu que je vais être en env.graphique, via diskmanager ?  
Ou un moyen de tout redéclarer et qu’il reboot ?

ps : j’ai essayé de le mount via ext2fs sous w32, il est bien sur en RAW mais pas moyen de faire quelque chose. Il ne le voit pas du tout. Je me grave un SystemRescueCd…

Merci d’avance pour votre aide, c’est la galère 🙂

---

<div class="post-metadata">

**Author:** ![PascalHambourg](https://www.debian-fr.org/user_avatar/www.debian-fr.org/pascalhambourg/32/5837_2.png) [@PascalHambourg](https://www.debian-fr.org/u/PascalHambourg)\
**Post date:** [Avril 8, 2020, 3:53 UTC](https://www.debian-fr.org/t/boulette-resize-fs-lvextend-vgextend-initframfs/81728/2 "2020-04-08T15:53:09Z")

</div>

> [@Gen0x](#):
>
> Mais dans la précipitation, je me suis aperçu d’une erreur trop tard.

Quelle erreur ? Difficile d’apporter un avis si on ne sait pas ce que tu as fait exactement.

> [@Gen0x](#):
>
> Je suis à la base sous cette articulation :  
> /dev/sda1 = swap  
> /dev/sda5 = /usr, /var, /etc, /tmp, … = 227GB

Pas clair. sda5 est le PV qui contient les volumes logiques ?

> [@Gen0x](#):
>
> -blkid, j’ai désormais :  
> /dev/sda1 = 227GB  
> /dev/sda5 = 227GB

Pas clair. blkid n’affiche pas de tailles. Qu’affiche-t-il exactement ? Qu’affiche fdisk -l /dev/sda ?

---

<div class="post-metadata">

**Author:** ![Gen0x](https://www.debian-fr.org/user_avatar/www.debian-fr.org/gen0x/32/9089_2.png) [@Gen0x](https://www.debian-fr.org/u/Gen0x)\
**Post date:** [Avril 8, 2020, 4:51 UTC](https://www.debian-fr.org/t/boulette-resize-fs-lvextend-vgextend-initframfs/81728/3 "2020-04-08T16:51:37Z")

</div>

Alors voilà pour le détail complet :

```nohighlight
/dev/sda1 = ext2 = 243MB
/dev/sda2 = extended = 232.65GB
/dev/sda5 = unknow not allocated
==============================

```

```nohighlight
Boot Info Script 8f991e4 + Boot-Repair extra info [Boot-Info 25oct2017]

============================= Boot Info Summary: ===============================

 => Syslinux MBR (5.00 and higher) is installed in the MBR of /dev/sda.
 => Syslinux MBR (5.00 and higher) is installed in the MBR of /dev/sdb.

sda1: __________________________________________________________________________

    File system: ext2
    Boot sector type: -
    Boot sector info: 
    Operating System:  
    Boot files: /grub/grub.cfg /grub/i386-pc/core.img

sda2: __________________________________________________________________________

    File system: Extended Partition
    Boot sector type: -
    Boot sector info: 

sdb1: __________________________________________________________________________

    File system: vfat
    Boot sector type: SYSLINUX 6.03
    Boot sector info: Syslinux looks at sector 16392 of /dev/sdb1 for its 
                       second stage. The integrity check of Syslinux failed. 
                       No errors found in the Boot Parameter Block.
    Operating System:  
    Boot files: /boot/grub/grub.cfg /syslinux.cfg /casper/vmlinuz.efi 
                       /EFI/BOOT/grubx64.efi /ldlinux.sys

============================ Drive/Partition Info: =============================

Drive: sda _____________________________________________________________________
Disk /dev/sda: 232.9 GiB, 250059350016 bytes, 488397168 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos

Partition Boot Start Sector End Sector # of Sectors Id System

/dev/sda1 * 2,048 499,711 497,664 83 Linux
/dev/sda2 501,758 488,396,799 487,895,042 5 Extended
Empty Partition.

Drive: sdb _____________________________________________________________________
Disk /dev/sdb: 3.8 GiB, 4026531840 bytes, 7864320 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos

Partition Boot Start Sector End Sector # of Sectors Id System

/dev/sdb1 * 2,048 7,864,319 7,862,272 c W95 FAT32 (LBA)

"blkid" output: ________________________________________________________________

Device UUID TYPE LABEL

/dev/loop0 squashfs   
/dev/sda1 ec8ef8ea-4abc-493c-80f8-714751476e6a ext2       
/dev/sdb1 98AA-6E5C vfat BOOT-REPAIR
/dev/zram0 a59c95ca-594c-4044-aec3-a1da9c16d316 swap       
/dev/zram1 bf8b2986-5fbf-47bb-a83a-ba234dccd959 swap       

========================= "ls -l /dev/disk/by-id" output: ======================

total 0
lrwxrwxrwx 1 root root 9 Apr 8 16:42 ata-VB0250EAVER_Z3TLRRSV -> ../../sda
lrwxrwxrwx 1 root root 10 Apr 8 16:42 ata-VB0250EAVER_Z3TLRRSV-part1 -> ../../sda1
lrwxrwxrwx 1 root root 10 Apr 8 16:42 ata-VB0250EAVER_Z3TLRRSV-part2 -> ../../sda2
lrwxrwxrwx 1 root root 9 Apr 8 16:42 usb-Generic_Flash_Disk_44D794C9-0:0 -> ../../sdb
lrwxrwxrwx 1 root root 10 Apr 8 16:42 usb-Generic_Flash_Disk_44D794C9-0:0-part1 -> ../../sdb1
lrwxrwxrwx 1 root root 9 Apr 8 16:42 wwn-0x5000c50063ed5e20 -> ../../sda
lrwxrwxrwx 1 root root 10 Apr 8 16:42 wwn-0x5000c50063ed5e20-part1 -> ../../sda1
lrwxrwxrwx 1 root root 10 Apr 8 16:42 wwn-0x5000c50063ed5e20-part2 -> ../../sda2

================================ Mount points: =================================

Device Mount_Point Type Options

/dev/loop0 /rofs squashfs (ro,noatime)
/dev/sdb1 /cdrom vfat (ro,noatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,errors=remount-ro)

============================= sda1/grub/grub.cfg: ==============================

--------------------------------------------------------------------------------
#
# DO NOT EDIT THIS FILE
#
# It is automatically generated by grub-mkconfig using templates
# from /etc/grub.d and settings from /etc/default/grub
#

### BEGIN /etc/grub.d/00_header ###
if [-s $prefix/grubenv]; then
  set have_grubenv=true
  load_env
fi
if ["${next_entry}"] ; then
   set default="${next_entry}"
   set next_entry=
   save_env next_entry
   set boot_once=true
else
   set default="0"
fi

if [x"${feature_menuentry_id}" = xy]; then
  menuentry_id_option="--id"
else
  menuentry_id_option=""
fi

export menuentry_id_option

if ["${prev_saved_entry}"]; then
  set saved_entry="${prev_saved_entry}"
  save_env saved_entry
  set prev_saved_entry=
  save_env prev_saved_entry
  set boot_once=true
fi

function savedefault {
  if [-z "${boot_once}"]; then
    saved_entry="${chosen}"
    save_env saved_entry
  fi
}
function load_video {
  if [x$feature_all_video_module = xy]; then
    insmod all_video
  else
    insmod efi_gop
    insmod efi_uga
    insmod ieee1275_fb
    insmod vbe
    insmod vga
    insmod video_bochs
    insmod video_cirrus
  fi
}

if [x$feature_default_font_path = xy] ; then
   font=unicode
else
insmod part_msdos
insmod lvm
insmod ext2
set root='lvmid/P20ejx-C5eO-0GcB-ZgF7-NpYi-kd7e-lRL0Cv/vX8JrX-u5ef-WlAN-joZ6-WmMc-DaWs-6Zg0iA'
if [x$feature_platform_search_hint = xy]; then
  search --no-floppy --fs-uuid --set=root --hint='lvmid/P20ejx-C5eO-0GcB-ZgF7-NpYi-kd7e-lRL0Cv/vX8JrX-u5ef-WlAN-joZ6-WmMc-DaWs-6Zg0iA' 489fe47d-7849-49ce-93d4-2f7d45843b87
else
  search --no-floppy --fs-uuid --set=root 489fe47d-7849-49ce-93d4-2f7d45843b87
fi
    font="/usr/share/grub/unicode.pf2"
fi

if loadfont $font ; then
  set gfxmode=auto
  load_video
  insmod gfxterm
  set locale_dir=$prefix/locale
  set lang=fr_FR
  insmod gettext
fi
terminal_output gfxterm
if ["${recordfail}" = 1] ; then
  set timeout=30
else
  if [x$feature_timeout_style = xy] ; then
    set timeout_style=menu
    set timeout=5
  # Fallback normal timeout code in case the timeout_style feature is
  # unavailable.
  else
    set timeout=5
  fi
fi
### END /etc/grub.d/00_header ###

### BEGIN /etc/grub.d/05_debian_theme ###
insmod part_msdos
insmod lvm
insmod ext2
set root='lvmid/P20ejx-C5eO-0GcB-ZgF7-NpYi-kd7e-lRL0Cv/vX8JrX-u5ef-WlAN-joZ6-WmMc-DaWs-6Zg0iA'
if [x$feature_platform_search_hint = xy]; then
  search --no-floppy --fs-uuid --set=root --hint='lvmid/P20ejx-C5eO-0GcB-ZgF7-NpYi-kd7e-lRL0Cv/vX8JrX-u5ef-WlAN-joZ6-WmMc-DaWs-6Zg0iA' 489fe47d-7849-49ce-93d4-2f7d45843b87
else
  search --no-floppy --fs-uuid --set=root 489fe47d-7849-49ce-93d4-2f7d45843b87
fi
insmod png
if background_image /usr/share/desktop-base/softwaves-theme/grub/grub-4x3.png; then
  set color_normal=white/black
  set color_highlight=black/white
else
  set menu_color_normal=cyan/blue
  set menu_color_highlight=white/blue
fi
### END /etc/grub.d/05_debian_theme ###

### BEGIN /etc/grub.d/10_linux ###
function gfxmode {
	set gfxpayload="${1}"
}
set linux_gfx_mode=
export linux_gfx_mode
menuentry 'Debian GNU/Linux' --class debian --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-simple-489fe47d-7849-49ce-93d4-2f7d45843b87' {
	load_video
	insmod gzio
	if [x$grub_platform = xxen]; then insmod xzio; insmod lzopio; fi
	insmod part_msdos
	insmod ext2
	set root='hd0,msdos1'
	if [x$feature_platform_search_hint = xy]; then
	  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos1 --hint-efi=hd0,msdos1 --hint-baremetal=ahci0,msdos1 ec8ef8ea-4abc-493c-80f8-714751476e6a
	else
	  search --no-floppy --fs-uuid --set=root ec8ef8ea-4abc-493c-80f8-714751476e6a
	fi
	echo	'Chargement de Linux 4.9.0-8-amd64…'
	linux	/vmlinuz-4.9.0-8-amd64 root=/dev/mapper/DARKMAUL--vg-root ro quiet
	echo	'Chargement du disque mémoire initial…'
	initrd	/initrd.img-4.9.0-8-amd64
}
submenu 'Options avancées pour Debian GNU/Linux' $menuentry_id_option 'gnulinux-advanced-489fe47d-7849-49ce-93d4-2f7d45843b87' {
	menuentry 'Debian GNU/Linux, avec Linux 4.9.0-8-amd64' --class debian --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-4.9.0-8-amd64-advanced-489fe47d-7849-49ce-93d4-2f7d45843b87' {
		load_video
		insmod gzio
		if [x$grub_platform = xxen]; then insmod xzio; insmod lzopio; fi
		insmod part_msdos
		insmod ext2
		set root='hd0,msdos1'
		if [x$feature_platform_search_hint = xy]; then
		  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos1 --hint-efi=hd0,msdos1 --hint-baremetal=ahci0,msdos1 ec8ef8ea-4abc-493c-80f8-714751476e6a
		else
		  search --no-floppy --fs-uuid --set=root ec8ef8ea-4abc-493c-80f8-714751476e6a
		fi
		echo	'Chargement de Linux 4.9.0-8-amd64…'
		linux	/vmlinuz-4.9.0-8-amd64 root=/dev/mapper/DARKMAUL--vg-root ro quiet
		echo	'Chargement du disque mémoire initial…'
		initrd	/initrd.img-4.9.0-8-amd64
	}
	menuentry 'Debian GNU/Linux, with Linux 4.9.0-8-amd64 (recovery mode)' --class debian --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-4.9.0-8-amd64-recovery-489fe47d-7849-49ce-93d4-2f7d45843b87' {
		load_video
		insmod gzio
		if [x$grub_platform = xxen]; then insmod xzio; insmod lzopio; fi
		insmod part_msdos
		insmod ext2
		set root='hd0,msdos1'
		if [x$feature_platform_search_hint = xy]; then
		  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos1 --hint-efi=hd0,msdos1 --hint-baremetal=ahci0,msdos1 ec8ef8ea-4abc-493c-80f8-714751476e6a
		else
		  search --no-floppy --fs-uuid --set=root ec8ef8ea-4abc-493c-80f8-714751476e6a
		fi
		echo	'Chargement de Linux 4.9.0-8-amd64…'
		linux	/vmlinuz-4.9.0-8-amd64 root=/dev/mapper/DARKMAUL--vg-root ro single 
		echo	'Chargement du disque mémoire initial…'
		initrd	/initrd.img-4.9.0-8-amd64
	}
	menuentry 'Debian GNU/Linux, avec Linux 4.9.0-6-amd64' --class debian --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-4.9.0-6-amd64-advanced-489fe47d-7849-49ce-93d4-2f7d45843b87' {
		load_video
		insmod gzio
		if [x$grub_platform = xxen]; then insmod xzio; insmod lzopio; fi
		insmod part_msdos
		insmod ext2
		set root='hd0,msdos1'
		if [x$feature_platform_search_hint = xy]; then
		  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos1 --hint-efi=hd0,msdos1 --hint-baremetal=ahci0,msdos1 ec8ef8ea-4abc-493c-80f8-714751476e6a
		else
		  search --no-floppy --fs-uuid --set=root ec8ef8ea-4abc-493c-80f8-714751476e6a
		fi
		echo	'Chargement de Linux 4.9.0-6-amd64…'
		linux	/vmlinuz-4.9.0-6-amd64 root=/dev/mapper/DARKMAUL--vg-root ro quiet
		echo	'Chargement du disque mémoire initial…'
		initrd	/initrd.img-4.9.0-6-amd64
	}
	menuentry 'Debian GNU/Linux, with Linux 4.9.0-6-amd64 (recovery mode)' --class debian --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-4.9.0-6-amd64-recovery-489fe47d-7849-49ce-93d4-2f7d45843b87' {
		load_video
		insmod gzio
		if [x$grub_platform = xxen]; then insmod xzio; insmod lzopio; fi
		insmod part_msdos
		insmod ext2
		set root='hd0,msdos1'
		if [x$feature_platform_search_hint = xy]; then
		  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos1 --hint-efi=hd0,msdos1 --hint-baremetal=ahci0,msdos1 ec8ef8ea-4abc-493c-80f8-714751476e6a
		else
		  search --no-floppy --fs-uuid --set=root ec8ef8ea-4abc-493c-80f8-714751476e6a
		fi
		echo	'Chargement de Linux 4.9.0-6-amd64…'
		linux	/vmlinuz-4.9.0-6-amd64 root=/dev/mapper/DARKMAUL--vg-root ro single 
		echo	'Chargement du disque mémoire initial…'
		initrd	/initrd.img-4.9.0-6-amd64
	}
}

### END /etc/grub.d/10_linux ###

### BEGIN /etc/grub.d/20_linux_xen ###

### END /etc/grub.d/20_linux_xen ###

### BEGIN /etc/grub.d/30_os-prober ###
### END /etc/grub.d/30_os-prober ###

### BEGIN /etc/grub.d/30_uefi-firmware ###
### END /etc/grub.d/30_uefi-firmware ###

### BEGIN /etc/grub.d/40_custom ###
# This file provides an easy way to add custom menu entries. Simply type the
# menu entries you want to add after this comment. Be careful not to change
# the 'exec tail' line above.
### END /etc/grub.d/40_custom ###

### BEGIN /etc/grub.d/41_custom ###
if [-f ${config_directory}/custom.cfg]; then
  source ${config_directory}/custom.cfg
elif [-z "${config_directory}" -a -f $prefix/custom.cfg]; then
  source $prefix/custom.cfg;
fi
### END /etc/grub.d/41_custom ###
--------------------------------------------------------------------------------

=================== sda1: Location of files loaded by Grub: ====================

           GiB - GB File Fragment(s)

   0.053322792 = 0.057254912 grub/grub.cfg 3
   0.056604385 = 0.060778496 grub/i386-pc/core.img 2
   0.038114548 = 0.040925184 vmlinuz-4.9.0-6-amd64 10
   0.122114182 = 0.131119104 vmlinuz-4.9.0-8-amd64 9
   0.114915848 = 0.123389952 initrd.img-4.9.0-6-amd64 14
   0.132517815 = 0.142289920 initrd.img-4.9.0-8-amd64 14

=========================== sdb1/boot/grub/grub.cfg: ===========================

--------------------------------------------------------------------------------

if loadfont /boot/grub/font.pf2 ; then
	set gfxmode=auto
	insmod efi_gop
	insmod efi_uga
	insmod gfxterm
	terminal_output gfxterm
fi

set menu_color_normal=white/black
set menu_color_highlight=black/light-gray

menuentry "Boot-Repair-Disk session" {
	set gfxpayload=keep
	linux	/casper/vmlinuz.efi file=/cdrom/preseed/lubuntu.seed boot=casper quiet splash --
	initrd	/casper/initrd.lz
}
--------------------------------------------------------------------------------

============================== sdb1/syslinux.cfg: ==============================

--------------------------------------------------------------------------------
DEFAULT loadconfig

LABEL loadconfig
  CONFIG /isolinux/isolinux.cfg
  APPEND /isolinux/
--------------------------------------------------------------------------------

=================== sdb1: Location of files loaded by Grub: ====================

           GiB - GB File Fragment(s)

            ?? = ?? boot/grub/grub.cfg 1

================= sdb1: Location of files loaded by Syslinux: ==================

           GiB - GB File Fragment(s)

            ?? = ?? syslinux.cfg 1
            ?? = ?? ldlinux.sys 1

ADDITIONAL INFORMATION :
=================== log of boot-repair 20200408_1642 ===================
boot-repair version : 4ppa62
boot-sav version : 4ppa62
boot-sav-extra version : 4ppa62
glade2script version : 3.2.3~ppa4
boot-repair is executed in live-session (Boot-Repair-Disk 64bit 1oct2017, zesty, Ubuntu, x86_64)
CPU op-mode(s): 32-bit, 64-bit
file=/cdrom/preseed/lubuntu.seed boot=casper initrd=/casper/initrd.lz quiet splash -- debian-installer/language=fr keyboard-configuration/layoutcode?=fr keyboard-configuration/variantcode?=oss
ls: cannot access '/home/usr/.config': No such file or directory

=================== os-prober:

=================== blkid:
/dev/sda1: UUID="ec8ef8ea-4abc-493c-80f8-714751476e6a" TYPE="ext2" PARTUUID="b269fceb-01"
/dev/sdb1: LABEL="BOOT-REPAIR" UUID="98AA-6E5C" TYPE="vfat" PARTUUID="0fc81078-01"
/dev/loop0: TYPE="squashfs"
/dev/zram0: UUID="a59c95ca-594c-4044-aec3-a1da9c16d316" TYPE="swap"
/dev/zram1: UUID="bf8b2986-5fbf-47bb-a83a-ba234dccd959" TYPE="swap"

=================== UEFI/Legacy mode:
This live-session is not in EFI-mode.
SecureBoot maybe enabled.

=================== PARTITIONS & DISKS:
sda1	: sda,	is-sepboot,	grubenv-ok	nogrub,	no-docgrub,	no-update-grub,	32,	no-boot,	no-os,	not--efi--part,	part-has-no-fstab,	part-has-no-fstab,	no-nt,	no-winload,	no-recov-nor-hid,	no-bmgr,	notwinboot,	nopakmgr,	nogrubinstall,	no---usr,	part-has-no-fstab,	not-sep-usr,	standard,	not-far,	notbiosboot, /mnt/boot-sav/sda1.

sda	: not-GPT,	BIOSboot-not-needed,	has-no-EFIpart, not-usb,	not-mmc, no-os,	2048 sectors * 512 bytes

=================== parted -lm:

BYT;
/dev/sda:250GB:scsi:512:512:msdos:ATA VB0250EAVER:;
1:1049kB:256MB:255MB:ext2::boot;
2:257MB:250GB:250GB:::;

BYT;
/dev/sdb:4027MB:scsi:512:512:msdos:Generic Flash Disk:;
1:1049kB:4027MB:4025MB:fat32::boot, lba;

BYT;
/dev/zram1:1002MB:unknown:4096:4096:loop:Unknown:;
1:0.00B:1002MB:1002MB:linux-swap(v1)::;

BYT;
/dev/zram0:1002MB:unknown:4096:4096:loop:Unknown:;
1:0.00B:1002MB:1002MB:linux-swap(v1)::;

=================== lsblk:
KNAME TYPE FSTYPE SIZE LABEL
loop0 loop squashfs 629,3M
sda disk 232,9G
sda1 part ext2 243M
sda2 part 1K
sdb disk 3,8G
sdb1 part vfat 3,8G BOOT-REPAIR
zram0 disk 955,6M
zram1 disk 955,6M

KNAME ROTA RO RM STATE MOUNTPOINT
loop0 1 1 0 /rofs
sda 1 0 0 running
sda1 1 0 0 /mnt/boot-sav/sda1
sda2 1 0 0
sdb 1 0 1 running
sdb1 1 0 1 /cdrom
zram0 0 0 0 [SWAP]
zram1 0 0 0 [SWAP]

=================== mount:
sysfs on /sys type sysfs (rw,nosuid,nodev,noexec,relatime)
proc on /proc type proc (rw,nosuid,nodev,noexec,relatime)
udev on /dev type devtmpfs (rw,nosuid,relatime,size=1896908k,nr_inodes=474227,mode=755)
devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
tmpfs on /run type tmpfs (rw,nosuid,noexec,relatime,size=391416k,mode=755)
/dev/sdb1 on /cdrom type vfat (ro,noatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,errors=remount-ro)
/dev/loop0 on /rofs type squashfs (ro,noatime)
/cow on / type overlay (rw,relatime,lowerdir=//filesystem.squashfs,upperdir=/cow/upper,workdir=/cow/work)
securityfs on /sys/kernel/security type securityfs (rw,nosuid,nodev,noexec,relatime)
tmpfs on /dev/shm type tmpfs (rw,nosuid,nodev)
tmpfs on /run/lock type tmpfs (rw,nosuid,nodev,noexec,relatime,size=5120k)
tmpfs on /sys/fs/cgroup type tmpfs (ro,nosuid,nodev,noexec,mode=755)
cgroup on /sys/fs/cgroup/unified type cgroup2 (rw,nosuid,nodev,noexec,relatime)
cgroup on /sys/fs/cgroup/systemd type cgroup (rw,nosuid,nodev,noexec,relatime,xattr,name=systemd)
pstore on /sys/fs/pstore type pstore (rw,nosuid,nodev,noexec,relatime)
cgroup on /sys/fs/cgroup/perf_event type cgroup (rw,nosuid,nodev,noexec,relatime,perf_event)
cgroup on /sys/fs/cgroup/net_cls,net_prio type cgroup (rw,nosuid,nodev,noexec,relatime,net_cls,net_prio)
cgroup on /sys/fs/cgroup/freezer type cgroup (rw,nosuid,nodev,noexec,relatime,freezer)
cgroup on /sys/fs/cgroup/cpuset type cgroup (rw,nosuid,nodev,noexec,relatime,cpuset)
cgroup on /sys/fs/cgroup/devices type cgroup (rw,nosuid,nodev,noexec,relatime,devices)
cgroup on /sys/fs/cgroup/blkio type cgroup (rw,nosuid,nodev,noexec,relatime,blkio)
cgroup on /sys/fs/cgroup/memory type cgroup (rw,nosuid,nodev,noexec,relatime,memory)
cgroup on /sys/fs/cgroup/cpu,cpuacct type cgroup (rw,nosuid,nodev,noexec,relatime,cpu,cpuacct)
cgroup on /sys/fs/cgroup/rdma type cgroup (rw,nosuid,nodev,noexec,relatime,rdma)
cgroup on /sys/fs/cgroup/hugetlb type cgroup (rw,nosuid,nodev,noexec,relatime,hugetlb)
cgroup on /sys/fs/cgroup/pids type cgroup (rw,nosuid,nodev,noexec,relatime,pids)
systemd-1 on /proc/sys/fs/binfmt_misc type autofs (rw,relatime,fd=26,pgrp=1,timeout=0,minproto=5,maxproto=5,direct,pipe_ino=12026)
mqueue on /dev/mqueue type mqueue (rw,relatime)
hugetlbfs on /dev/hugepages type hugetlbfs (rw,relatime,pagesize=2M)
debugfs on /sys/kernel/debug type debugfs (rw,relatime)
fusectl on /sys/fs/fuse/connections type fusectl (rw,relatime)
configfs on /sys/kernel/config type configfs (rw,relatime)
tmpfs on /tmp type tmpfs (rw,nosuid,nodev,relatime)
tmpfs on /run/user/999 type tmpfs (rw,nosuid,nodev,relatime,size=391412k,mode=700,uid=999,gid=999)
gvfsd-fuse on /run/user/999/gvfs type fuse.gvfsd-fuse (rw,nosuid,nodev,relatime,user_id=999,group_id=999)
/dev/sda1 on /mnt/boot-sav/sda1 type ext2 (rw,relatime,block_validity,barrier,user_xattr,acl)

=================== ls:
/sys/block/sda (filtered): alignment_offset bdi capability dev device discard_alignment events events_async events_poll_msecs ext_range holders inflight integrity power queue range removable ro sda1 sda2 size slaves stat subsystem trace uevent
/sys/block/sdb (filtered): alignment_offset bdi capability dev device discard_alignment events events_async events_poll_msecs ext_range holders inflight integrity power queue range removable ro sdb1 size slaves stat subsystem trace uevent
/dev (filtered): autofs block bsg btrfs-control bus char console core cpu cpu_dma_latency cuse disk dri ecryptfs fb0 fd full fuse hidraw0 hidraw1 hidraw2 hpet hugepages hwrng i2c-0 i2c-1 i2c-2 i2c-3 i2c-4 i2c-5 i2c-6 i2c-7 i2c-8 i2c-9 initctl input kfd kmsg kvm lightnvm log mapper mcelog mem memory_bandwidth mqueue net network_latency network_throughput null port ppp psaux ptmx pts random rfkill rtc rtc0 sda sda1 sda2 sdb sdb1 sg0 sg1 shm snapshot snd stderr stdin stdout uhid uinput urandom userio vfio vga_arbiter vhci vhost-net vhost-vsock zero
ls /dev/mapper: control

=================== df -Th:

Filesystem Type Size Used Avail Use% Mounted on
udev devtmpfs 1.9G 0 1.9G 0% /dev
tmpfs tmpfs 383M 5.9M 377M 2% /run
/dev/sdb1 vfat 3.8G 708M 3.1G 19% /cdrom
/dev/loop0 squashfs 630M 630M 0 100% /rofs
/cow overlay 1.9G 8.1M 1.9G 1% /
tmpfs tmpfs 1.9G 0 1.9G 0% /dev/shm
tmpfs tmpfs 5.0M 0 5.0M 0% /run/lock
tmpfs tmpfs 1.9G 0 1.9G 0% /sys/fs/cgroup
tmpfs tmpfs 1.9G 4.0K 1.9G 1% /tmp
tmpfs tmpfs 383M 4.0K 383M 1% /run/user/999
/dev/sda1 ext2 236M 63M 161M 29% /mnt/boot-sav/sda1

=================== fdisk -l:
Disk /dev/loop0: 629.3 MiB, 659873792 bytes, 1288816 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes

Disk /dev/sda: 232.9 GiB, 250059350016 bytes, 488397168 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0xb269fceb

Device Boot Start End Sectors Size Id Type
/dev/sda1 * 2048 499711 497664 243M 83 Linux
/dev/sda2 501758 488396799 487895042 232.7G 5 Extended

Disk /dev/sdb: 3.8 GiB, 4026531840 bytes, 7864320 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0x0fc81078

Device Boot Start End Sectors Size Id Type
/dev/sdb1 * 2048 7864319 7862272 3.8G c W95 FAT32 (LBA)

Disk /dev/zram0: 955.6 MiB, 1002020864 bytes, 244634 sectors
Units: sectors of 1 * 4096 = 4096 bytes
Sector size (logical/physical): 4096 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes

Disk /dev/zram1: 955.6 MiB, 1002020864 bytes, 244634 sectors
Units: sectors of 1 * 4096 = 4096 bytes
Sector size (logical/physical): 4096 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes

No OS or WinEFI system

**(zenity:6619): WARNING**: Error retrieving accessibility bus address: org.freedesktop.DBus.Error.ServiceUnknown: The name org.a11y.Bus was not provided by any .service files
Gtk-Message: GtkDialog mapped without a transient parent. This is discouraged.
/boot détecté. Veuillez vérifier les options.
ping: google.com: Temporary failure in name resolution

=================== Recommended repair
The default repair of the Boot-Repair utility will not act on the boot.

```

---

<div class="post-metadata">

**Author:** ![Gen0x](https://www.debian-fr.org/user_avatar/www.debian-fr.org/gen0x/32/9089_2.png) [@Gen0x](https://www.debian-fr.org/u/Gen0x)\
**Post date:** [Avril 8, 2020, 5:37 UTC](https://www.debian-fr.org/t/boulette-resize-fs-lvextend-vgextend-initframfs/81728/4 "2020-04-08T17:37:04Z")

</div>

Déjà, je remonte mon GRUB à partir de la liveCD.  
edit : le GRUB est bien remonté mais pour ma `/dev/sda2` :

```nohighlight
mount: /mnt: wrong fs type, bad option, bad superblock on /dev/sda2, missing codepage or helper program, or other error.

root@debian:~# fsck /dev/sda2
fsck from util-linux 2.33.1
e2fsck 1.44.5 (15-Dec-2018)
ext2fs_open2: Bad magic number in super-block
fsck.ext2: Superblock invalid, trying backup blocks...
fsck.ext2: Bad magic number in super-block while trying to open /dev/sda2

The superblock could not be read or does not describe a valid ext2/ext3/ext4
filesystem. If the device is valid and it really contains an ext2/ext3/ext4
filesystem (and not swap or ufs or something else), then the superblock
is corrupt, and you might try running e2fsck with an alternate superblock:
    e2fsck -b 8193 <device>
 or
    e2fsck -b 32768 <device>

Found a dos partition table in /dev/sda2

```

Via diskmanager je lui ai remis que c’était bien une partition Linux. Je vais voir ce que je peux en tirer avec Gparted.

```nohighlight
sfdisk -d /dev/sda > parts.txt
root@debian:~# cat parts.txt
label: **dos** <<<<<<<< grrr
label-id: 0xb269fceb
device: /dev/sda
unit: sectors

/dev/sda1 : start= 2048, size= 497664, type=83, bootable
/dev/sda2 : start= 501758, size= 487895042, type=8e

```

---

<div class="post-metadata">

**Author:** ![PascalHambourg](https://www.debian-fr.org/user_avatar/www.debian-fr.org/pascalhambourg/32/5837_2.png) [@PascalHambourg](https://www.debian-fr.org/u/PascalHambourg)\
**Post date:** [Avril 8, 2020, 9:18 UTC](https://www.debian-fr.org/t/boulette-resize-fs-lvextend-vgextend-initframfs/81728/5 "2020-04-08T21:18:49Z")

</div>

En fait de swap, /dev/sda1 est plutôt la partition /boot, et sa taille n’est pas 227 Gio mais 243 Mio (ce qui serait un peu faible pour une partition de swap). On va mettre ça sur le compte de la panique. De même que le fait d’avoir essayé de monter ou passer à fsck la partition étendue /dev/sda2. Même si c’était un volume physique LVM, ça ne marcherait pas. A ce jeu tu risques de détruire les données qui sont encore présentes.

Apparemment la partition logique /dev/sda5 qui servait de PV LVM qui a disparu. Je serais curieux de savoir comment, car il n’est pas possible que lvextend et resize2fs aient causé cela.

Changer le type de la partition étendue n’aidera pas. Tu as deux possibilités :

- soit tu recrées une partition logique à l’emplacement exact de l’ancienne
- soit tu supprimes la partition étendue et tu crées une partition primaire à l’emplacement exact de l’ancienne partition logique.

Important : lors de la création de la partition, si le programme propose d’effacer les méta-données présentes (ce qui est bon signe), il faut refuser.

Ma boule de cristal me dit que la partition disparue commençait au secteur 501760 (multiple de 2048 le plus proche de 501758, premier secteur de la partition étendue).  
Mais tu peux utiliser un programme de détection de partitions perdues comme testdisk ou gpart pour le vérifier.

Bonne chance.
