Re: lvm2 question

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




On 10/6/22 00:34, Todd Zullinger wrote:
Robert McBroom via users wrote:
Installed the server version of Fedora in a lvm physical
volume.
[...]
Quickly started running out of space.  Created a second
physical volume and used vgextend to add it to the volume
group.

~]# vgextend fedora_hpz440 /dev/nvme0n1p6

Increased the size of the logical volume with some of the
space of the second physical volume.

 ~]# lvextend -L +150G /dev/mapper/fedora_hpz440/root
Adding --resizefs to the lvextend command would do the
trick.  That calls fsadm to do the resizing, so you could
just run fsadm now to finish resizing the underlying
filesystem.  Something like:

    fsadm resize /dev/mapper/fedora_hpz440/root

Though it's worth reading fsadm(8) to check the options.  It
has a check command as well as --dry-run (-n) for use with
the resize command.

The fsadm command is a convenient tool to resize various
types of filesystems.  You could also use one of the tools
for your specific filesystem.  Fedora Server uses xfs, IIRC,
so xfs_growfs would be that tool.  For ext{2,3,4}, you can
use the resize2fs tool.

I'd use fsadm for its simplicity here.  And even better is
letting lvextend call it in the future. ;)

fsadm resize /dev/mapper/fedora_hpz440/root

did nothing.

Had some space so tried

lvextend -L +10G --resize /dev/mapper/fedora_hpz440/root

which worked.

Looking at the fsadm man page and on the web there seems to be some ambiguity on the proper format of the device name.

/dev/fedora_hpz440:
  total used in directory 0 available 4 MiB
  drwxr-xr-x.  2 root root   60 Oct  7 16:21 .
  drwxr-xr-x. 21 root root 4800 Oct  5 21:40 ..
  lrwxrwxrwx.  1 root root    7 Oct  7 16:21 root -> ../dm-0

different from

/dev/vg/lv/ in documentation.

Also
/dev/mapper:
  total used in directory 0 available 4 MiB
  drwxr-xr-x.  2 root root      80 Oct  7 16:21 .
  drwxr-xr-x. 21 root root    4800 Oct  5 21:40 ..
  crw-------.  1 root root 10, 236 Oct  5 21:39 control
  lrwxrwxrwx.  1 root root       7 Oct  7 16:21 fedora_hpz440-root -> ../dm-0

_______________________________________________
users mailing list -- users@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe send an email to users-leave@xxxxxxxxxxxxxxxxxxxxxxx
Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: https://lists.fedoraproject.org/archives/list/users@xxxxxxxxxxxxxxxxxxxxxxx
Do not reply to spam, report it: https://pagure.io/fedora-infrastructure/new_issue
[Index of Archives]     [Older Fedora Users]     [Fedora Announce]     [Fedora Package Announce]     [EPEL Announce]     [EPEL Devel]     [Fedora Magazine]     [Fedora Summer Coding]     [Fedora Laptop]     [Fedora Cloud]     [Fedora Advisory Board]     [Fedora Education]     [Fedora Security]     [Fedora Scitech]     [Fedora Robotics]     [Fedora Infrastructure]     [Fedora Websites]     [Anaconda Devel]     [Fedora Devel Java]     [Fedora Desktop]     [Fedora Fonts]     [Fedora Marketing]     [Fedora Management Tools]     [Fedora Mentors]     [Fedora Package Review]     [Fedora R Devel]     [Fedora PHP Devel]     [Kickstart]     [Fedora Music]     [Fedora Packaging]     [Fedora SELinux]     [Fedora Legal]     [Fedora Kernel]     [Fedora OCaml]     [Coolkey]     [Virtualization Tools]     [ET Management Tools]     [Yum Users]     [Yosemite News]     [Gnome Users]     [KDE Users]     [Fedora Art]     [Fedora Docs]     [Fedora Sparc]     [Libvirt Users]     [Fedora ARM]

  Powered by Linux