L
L
Luan2021-11-11 18:52:52
LVM
Luan, 2021-11-11 18:52:52

How to reduce lvm size and transfer data?

An lvm partition was made on the ubuntu server during installation. Now, after the lapse of time, we understand that there is a bust in the place, and we wanted to free the disks. used pvmove /dev/sdf but gives an error:
No extents available for allocation
When this happens, the command sudo pvs -o+pv_used gives the following:

PV         VG        Fmt  Attr PSize    PFree Used
  /dev/sda   ubuntu-vg lvm2 a--  <127,00g    0  <127,00g
  /dev/sdb3  ubuntu-vg lvm2 a--   <34,00g    0   <34,00g
  /dev/sdb4  ubuntu-vg lvm2 a--   <21,00g    0   <21,00g
  /dev/sdc   ubuntu-vg lvm2 a--  <150,00g    0  <150,00g
  /dev/sdd   ubuntu-vg lvm2 a--   <90,00g    0   <90,00g
  /dev/sdf   ubuntu-vg lvm2 a--  <100,00g    0  <100,00g

At the same time, through the cockpit it shows that 281 GB out of 514 have been used.
What is needed to pull out the disks normally and why such a strange display of sizes?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
A
Alexander Karabanov, 2021-11-11
@karabanov

To reduce the size, you can boot from a USB flash drive and use it lvresize --resizefs --size -5G /patg/to/you/volumeto reduce (measure 5G to the desired size).

V
Vladimir, 2015-02-25
@telray

When is this function called?
It should also be something like this -
$(window).scroll(function(){fixGallery();});

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question