2

Ubuntu Server and here is what I have:

When running lsblk I get this

fd0                   2:0    1     4K  0 disk
sda                   8:0    0  1000G  0 disk
├─sda1                8:1    0   487M  0 part /boot
├─sda2                8:2    0     1K  0 part
└─sda5                8:5    0 199.5G  0 part
  ├─mail03--vg-root 252:0    0 126.3G  0 lvm  /
  └─mail03--vg-swap 252:1    0  65.8G  0 lvm  [SWAP]
sdb                   8:16   0   500G  0 disk
sr0                  11:0    1   667M  0 from

When running df -h I get this

Filesystem                   Size  Used Avail Use% Mounted on
udev                         4.4G     0  4.4G   0% /dev
tmpfs                        900M   97M  803M  11% /run
/dev/mapper/mail03--vg-root  125G  114G  4.2G  97% /
tmpfs                        4.4G  4.0K  4.4G   1% /dev/shm
tmpfs                        5.0M   44K  5.0M   1% /run/lock
tmpfs                        4.4G     0  4.4G   0% /sys/fs/cgroup
/dev/sda1                    472M  108M  340M  25% /boot
tmpfs                        900M     0  900M   0% /run/user/1000

sda has 1000G but the partition mounted on / has only 125G

Is it possible to extend the /dev/mapper/mail03--vg-root filesystem ?

If not can you help me please how to mount space from sda ?

I also don't want to lose any data from /dev/mapper/mail03--vg-root

Thanks !

user2692663
  • 21
  • 1
  • 3
  • Are you using Ubuntu Server or a GUI? – Logan Feb 17 '22 at 16:49
  • 1
    Try and avoid pictures of text. Include the actual text in the question. – David Feb 17 '22 at 16:52
  • @Jeff Ubuntu server – user2692663 Feb 17 '22 at 16:54
  • @David Sorry it's my first posted question, I'll try to edit it – user2692663 Feb 17 '22 at 16:55
  • @User2692663 Okay. For a possible answer, view this thread: https://askubuntu.com/questions/390769/how-do-i-resize-partitions-using-command-line-without-using-a-gui-on-a-server This talks about resizing partitions, which seems to be what you want to do. – Logan Feb 17 '22 at 16:55
  • @Jeff Thanks, I took a look there but still I am not sure what to run, I also don't want to lose any data from /dev/mapper/mail03--vg-root – user2692663 Feb 17 '22 at 17:05
  • `/dev/mapper/mail03--vg-root` means this is a LVM volume. Try to follow e.g. [Resize Ubuntu LV](https://askubuntu.com/questions/1374495) – ridgy Feb 17 '22 at 17:45
  • @ridgy I am very glad that it doesn't use RAID. I think RAID would more difficult to find a decent solution... – Logan Feb 17 '22 at 18:53

1 Answers1

0

Try running sudo resize2fs /dev/sda1 25G and replace /dev/sda1 with the path to your drive. Also, replace 25G with the size that you want. If you want it to make up the entire 1000G, replace 25G with 1000G. It may not allow it, because of other partitions (ex. SWAP) on the disk that take up other space. If it doesn't allow it, use the GNOME disks utility to view remaining free space and resize in regards to that. Hope this helps.

Logan
  • 472
  • 3
  • 22