What's the easiest way to resize the system drive?

  • I was originally running my OMV off of a 2GB USB drive. I recently picked up two new 4GB USB drives and used dd to clone my 2GB drive onto one of them. However, the cloned drive is still only using a 2GB partition. Strangely, the resize button in the OMV web interface is grayed out for that partition. What's the easiest way to resize the system drive to the full 4GB size?

    • Offizieller Beitrag

    Boot gparted-live on that system. You can install it to grub with no need for a usb stick with the openmediavault-backup plugin. Use systemrescuecd if they box is headless.

    omv 7.0.4-2 sandworm | 64 bit | 6.5 proxmox kernel

    plugins :: omvextrasorg 7.0 | kvm 7.0.10 | compose 7.1.2 | k8s 7.0-6 | cputemp 7.0 | mergerfs 7.0.3


    omv-extras.org plugins source code and issue tracker - github


    Please try ctrl-shift-R and read this before posting a question.

    Please put your OMV system details in your signature.
    Please don't PM for support... Too many PMs!

    • Offizieller Beitrag

    That actually may be a better method since your 2 gb usb stick might not have enough room for the gparted ISO file.

    omv 7.0.4-2 sandworm | 64 bit | 6.5 proxmox kernel

    plugins :: omvextrasorg 7.0 | kvm 7.0.10 | compose 7.1.2 | k8s 7.0-6 | cputemp 7.0 | mergerfs 7.0.3


    omv-extras.org plugins source code and issue tracker - github


    Please try ctrl-shift-R and read this before posting a question.

    Please put your OMV system details in your signature.
    Please don't PM for support... Too many PMs!

  • I ended up doing this entirely with GParted on another system (my OMV is headless). Put GParted on a USB drive, and booted my other system. I used dd to make a backup on my OMV system USB drive, and then first resized the logical partition containing the swap partition to take up all free space at the end of the drive, and then moved the swap partition to the end of the logical partition, before resizing the logical partition back down be just big enough to hold the swap. Then I resized my system partition to take all the free space.


    Seems to have gone off without a hitch, boots and runs fine.

  • Ok, this is my first time using gpart.
    When you said move the swap partition to the end of the drive, you mean move to the the right end or the bottom end of the logical partition?


    http://www.technikaffe.de/anle…rung_der_systemfestplatte

    Well, in my case, I had a lot of unallocated space at the end of the drive, and my objective was to expand the system partition to take up all of that space. My swap partition was contained in a logical partition and was between my system partition and the unallocated space, I believe this is standard.


    So, in order to get my system partition to fill up the unallocated space, I needed to first push the swap partition and the logical partition containing it to the end of the drive (the right), so that the unallocated space would be next to the system partition.

  • I would like to suggest to build a process to allow re-sizing of system drive within OMV - may be in version 3.0. I was using an SSD as a boot drive and OMV takes over the entire space after install. I was told to use gparted to re-size the system drive and free up space for data use. It works essentially but just extra steps one has to mindful. A friend of mine runs Unraid which runs fully off an USB drive and there are no data written to disk once system has booted. So, there are no concerns for frequent failures for USB drive as the case with OMV. But I really like OMV so far and going to keep it.

  • I need some help here guys.


    I gparted wrong size.


    Here's the scenario:


    1. Old hard drive is 1TB.
    2. New SSD is 120GB
    3. I gparted the old hdd logical partition to 118GB, and left the swap partition untouched, and the unallocated space is also not formatted.
    4. Next, I then used Clonezilla to clone the image from device to image.
    5. When I tried to restore from the image, it's tried to restore 1TB, instead 118GB. Therefore, it couldn't be restore.
    6. I then used GPart, and went back to clone the disk parts (individual partitions), when I tried to restore, it said no partition is found. In reality, the partitions are in my backup folder.
    7. I came back and tried a few method, and now, my OMV partition is 140GB used instead a few gig space used.


    Any advice?

    OMV v5.0
    Asus Z97-A/3.1; i3-4370
    32GB RAM Corsair Vengeance Pro

    • Offizieller Beitrag

    If you resized the OS partition to 118GB, the swap would have still been at the end of the disk. I would resize the OS partition to much smaller (unless you need it) and then move the swap to come right after the OS partition. When you use clonezilla, make sure to use ICDS in advanced options.

    omv 7.0.4-2 sandworm | 64 bit | 6.5 proxmox kernel

    plugins :: omvextrasorg 7.0 | kvm 7.0.10 | compose 7.1.2 | k8s 7.0-6 | cputemp 7.0 | mergerfs 7.0.3


    omv-extras.org plugins source code and issue tracker - github


    Please try ctrl-shift-R and read this before posting a question.

    Please put your OMV system details in your signature.
    Please don't PM for support... Too many PMs!

  • The problem is that the size in GPart unit count is different compare to Clonezilla.
    It's display as 118GB in GPart, but in Clonezilla, it's 127GB.
    Not only that, but when I clone, it's clone the un-allocated space too, which is about 700GB.
    I tried clone from device to image, it's clone the entire hdd, 1TB, but if I clone just the parttiions & try to restore it, then it's said there is no partition in my backup folder.
    Maybe I get some screenshots tonight, for better explanation.

    OMV v5.0
    Asus Z97-A/3.1; i3-4370
    32GB RAM Corsair Vengeance Pro

    • Offizieller Beitrag

    You are probably running into the difference between GiB and GB. I would make the OS partition smaller. You can always increase it after the clone.


    It clones the un-allocated space because it is in the middle. Screenshots would most likely help as well :)

    omv 7.0.4-2 sandworm | 64 bit | 6.5 proxmox kernel

    plugins :: omvextrasorg 7.0 | kvm 7.0.10 | compose 7.1.2 | k8s 7.0-6 | cputemp 7.0 | mergerfs 7.0.3


    omv-extras.org plugins source code and issue tracker - github


    Please try ctrl-shift-R and read this before posting a question.

    Please put your OMV system details in your signature.
    Please don't PM for support... Too many PMs!

  • You're correct, I wish I know this GiB and GB before I use GPart.
    I'll get some screenshots tonight.


    How do I move the un-allocated partition out of the way?


    Edit: see the attachment.
    OMV OS displaying 117GB is used it's incorrect b/c I use GParted to be 128GiB, but it's ended up as 130GB.


    Thanks in advance.

  • i had same problem, but i could fix it withe a formating ext4 in gpart. Maybe it helps you

    omv 6.x | 64 bit | omvextrasorg 6.x |
    used plugins: omv-extras | portainer | rsnapshot | antivirus
    used container: portainer/portainer | nextcloud/all-in-one | linuxserver/swag | paperless-ngx | jellyfin/jellyfin | lmscommunity/logitechmediaserver | adguard/adguardhome |

  • If you resized the OS partition to 118GB, the swap would have still been at the end of the disk. I would resize the OS partition to much smaller (unless you need it) and then move the swap to come right after the OS partition. When you use clonezilla, make sure to use ICDS in advanced options.

    I have a question: I have 1 TB nvme and would like to resize it to 25GB for system and all other space for something else.

    Before resizing:
    nvme0n1 259:2 0 931.5G 0 disk

    ├─nvme0n1p1 259:3 0 512M 0 part /boot/efi

    ├─nvme0n1p2 259:4 0 914.7G 0 part /

    └─nvme0n1p3 259:5 0 16.3G 0 part [SWAP]

    After resizing

    nvme0n1 259:2 0 931.5G 0 disk

    ├─nvme0n1p1 259:3 0 512M 0 part /boot/efi

    ├─nvme0n1p2 259:4 0 25G 0 part /

    ├─nvme0n1p3 259:5 0 16.3G 0 part [SWAP]

    └─nvme0n1p4 259:6 0 900G 0 part /


    How to do that in correct way? Because when I tried resize in gparted from systemrescue each system boot I got error that new partition nvme0n1p4 is missed, but it is in fstab file. So, I have to remove UUID of nvme0n1p4 from fstab and reboot.

Jetzt mitmachen!

Sie haben noch kein Benutzerkonto auf unserer Seite? Registrieren Sie sich kostenlos und nehmen Sie an unserer Community teil!