How to remove hdd from LVM

NethServer Version: NethServer release 7.9.2009 (final)

Hello everybody.

A while ago I had to increase the system space to use Nextcloud, so I decided to add another HD to double the useful space.
Now I no longer use Nextcloud, I already deleted the files and wanted to remove the HD from the server.
but I don’t know how to do it safely.

I managed to resize the VolGroup, but I don’t see this as the only procedure for that, there seems to be one more step that I still haven’t found where to do…
I used this command successfully until I reached the desired size,

[root@router ~]# lvresize --size -100G /dev/VolGroup/lv_root

but, according to the image, the file system still insists on having 923GB.

Where am I going wrong??

================================

Para Aumentar pesquisa em portugues.

Olá a todos.

A tempos atras eu tive de aumentaqr o espaço do sistema para usar com o Nextcloud, entao resolvi colocar mais um HD para dobrar o espaço util.
Agora nao uso mais o Nextcloud, ja apaguei os arquivos e queria retirar o HD do server.
mas nao sei como fazer isso seguramente.

consegui redimensionar a o VolGroup, mas nao vejo isso como o unico procedimento para isso, parece ter mais um passo que ainda nao achei onde fazer…
usei este comando com sucesso até chegar no tamanho desejado,

[root@roteador ~]# lvresize --size -100G /dev/VolGroup/lv_root

mas, conforme a imagem o sistema de arquivos ainda insiste em ficar com 923GB.

Onde estou errando??

XFS isn’t shrinkable so you need to dump and restore the files to the shrinked volume but it didn’t work for me in a few tests.

Another way would be to reinstall Nethserver without the additional hard drive and restore from backup.

1 Like