Resize Extended hdd into a Debian VM

RobertusIT

Member
Jul 13, 2021
68
0
11
38
Hi

i resized from Proxmox Gui, debian hdd vm, from 6GB to 7GB.
I do that when vm was off.
But when i started, space isn't increase.

Code:
root@servizi:~# resize2fs /dev/sda1
resize2fs 1.46.2 (28-Feb-2021)
The filesystem is already 1322496 (4k) blocks long.  Nothing to do!

I need to do another command into vm to have extended space?

Thanks
 
Hi

i resized from Proxmox Gui, debian hdd vm, from 6 to 7.
I do that when vm was off.
But when i started, space isn't increase.

Code:
root@servizi:~# resize2fs /dev/sda1
resize2fs 1.46.2 (28-Feb-2021)
The filesystem is already 1322496 (4k) blocks long.  Nothing to do!

I need to do another command into vm to extended space?

Thanks

The outputs from following commands might be helpful:
pve: lsblk
pve: qm config [vmid]
vm: lsblk
vm: df


Blockbridge : Ultra low latency all-NVME shared storage for Proxmox - https://www.blockbridge.com/proxmox


Code:
root@NUCi7:~# lsblk
NAME                         MAJ:MIN RM   SIZE RO TYPE MOUNTPOINT
sda                            8:0    0 223.6G  0 disk
└─sda1                         8:1    0 223.6G  0 part /mnt/SSD_250GB_USB
sdb                            8:16   0 931.5G  0 disk
└─sdb1                         8:17   0 931.5G  0 part /mnt/USB1TB
nvme0n1                      259:0    0 232.9G  0 disk
├─nvme0n1p1                  259:1    0  1007K  0 part
├─nvme0n1p2                  259:2    0   512M  0 part /boot/efi
└─nvme0n1p3                  259:3    0 232.4G  0 part
  ├─pve-swap                 253:0    0     8G  0 lvm  [SWAP]
  ├─pve-root                 253:1    0    25G  0 lvm  /
  ├─pve-data_tmeta           253:2    0   1.8G  0 lvm
  │ └─pve-data-tpool         253:4    0 179.7G  0 lvm
  │   ├─pve-data             253:5    0 179.7G  1 lvm
  │   ├─pve-vm--102--disk--0 253:6    0     5G  0 lvm
  │   ├─pve-vm--100--disk--0 253:7    0    32G  0 lvm
  │   ├─pve-vm--104--disk--0 253:8    0     5G  0 lvm
  │   ├─pve-vm--106--disk--0 253:9    0     5G  0 lvm
  │   ├─pve-vm--125--disk--0 253:10   0    32G  0 lvm
  │   ├─pve-vm--120--disk--0 253:11   0     7G  0 lvm
  │   ├─pve-vm--131--disk--0 253:12   0     5G  0 lvm
  │   ├─pve-vm--101--disk--0 253:13   0   110G  0 lvm
  │   ├─pve-vm--103--disk--0 253:14   0     5G  0 lvm
  │   └─pve-vm--202--disk--0 253:15   0     5G  0 lvm
  └─pve-data_tdata           253:3    0 179.7G  0 lvm
    └─pve-data-tpool         253:4    0 179.7G  0 lvm
      ├─pve-data             253:5    0 179.7G  1 lvm
      ├─pve-vm--102--disk--0 253:6    0     5G  0 lvm
      ├─pve-vm--100--disk--0 253:7    0    32G  0 lvm
      ├─pve-vm--104--disk--0 253:8    0     5G  0 lvm
      ├─pve-vm--106--disk--0 253:9    0     5G  0 lvm
      ├─pve-vm--125--disk--0 253:10   0    32G  0 lvm
      ├─pve-vm--120--disk--0 253:11   0     7G  0 lvm
      ├─pve-vm--131--disk--0 253:12   0     5G  0 lvm
      ├─pve-vm--101--disk--0 253:13   0   110G  0 lvm
      ├─pve-vm--103--disk--0 253:14   0     5G  0 lvm
      └─pve-vm--202--disk--0 253:15   0     5G  0 lvm


root@NUCi7:~# qm config 120
agent: 1
boot: order=scsi0;net0
cores: 2
description: RCLONE SYNCH DRIVE - DUCK DNS AGGIORNA DNS
memory: 2048
meta: creation-qemu=6.2.0,ctime=1658920692
name: SERVIZI-PA
net0: virtio=BE:81:F1:32:2B:F3,bridge=vmbr0,firewall=1
numa: 0
onboot: 1
ostype: l26
scsi0: local-lvm:vm-120-disk-0,discard=on,size=7G
scsihw: virtio-scsi-pci
smbios1: uuid=b426e511-23a6-4478-b43a-ceed9807699e
sockets: 2
vmgenid: efa66798-f9e0-4f0c-8bd6-2237303d6e07

Code:
root@servizi:~# lsblk
NAME   MAJ:MIN RM  SIZE RO TYPE MOUNTPOINT
sda      8:0    0    7G  0 disk
├─sda1   8:1    0    5G  0 part /
├─sda2   8:2    0    1K  0 part
└─sda5   8:5    0  975M  0 part [SWAP]
root@servizi:~# df
File system    1K-blocchi   Usati Disponib. Uso% Montato su
udev               998568       0    998568   0% /dev
tmpfs              202980    1892    201088   1% /run
/dev/sda1         5120760 5054252         0 100% /
tmpfs             1014884       0   1014884   0% /dev/shm
tmpfs                5120       0      5120   0% /run/lock
tmpfs              202976       0    202976   0% /run/user/0
root@servizi:~# df -h
File system     Dim. Usati Dispon. Uso% Montato su
udev            976M     0    976M   0% /dev
tmpfs           199M  1,9M    197M   1% /run
/dev/sda1       4,9G  4,9G       0 100% /
tmpfs           992M     0    992M   0% /dev/shm
tmpfs           5,0M     0    5,0M   0% /run/lock
tmpfs           199M     0    199M   0% /run/user/0

 
I have tried, without success.

There is 1gb unused, and 5gb used.
I can't resize 5gb partition to extend it , to 6gb.
You need to move the partition after it to the (new) end first, I think. And you might be using a MBR with an extended partition that needs to be resized first.
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!