Home
Help
Search
Login
Register
OPNsense Forum
»
English Forums
»
General Discussion
»
How to move ZFS partition up?
« previous
next »
Print
Pages: [
1
]
Author
Topic: How to move ZFS partition up? (Read 2445 times)
Ice_Drake1
Newbie
Posts: 16
Karma: 0
How to move ZFS partition up?
«
on:
June 17, 2022, 02:22:55 am »
After starting with a fresh DVD installation of OPNsense, I noticed that the default partition setup is quite annoying to work with. See attached swap partition for details.
Out of 10 GB hard drive space, 8 GB is automatically allocated for swap and placed in front of the main ZFS partition while only 2 GB is allocated for it. Thus, I can't update my firmware without allocating more hard space to ZFS partition, which I can't unless I move the swap partition down and shrink it.
While I figure out how to remove the swap partition, I can't figure out how to move ZFS partition up.
«
Last Edit: June 17, 2022, 02:26:00 am by Ice_Drake1
»
Logged
Patrick M. Hausen
Hero Member
Posts: 6812
Karma: 572
Re: How to move ZFS partition up?
«
Reply #1 on:
June 17, 2022, 07:22:36 am »
You can only grow the partition if you add space at the end. 10 G is way too small for OPNsense unless you run the NanoBSD version. 40 G is recommended. You will have to save the config and reinstall with the NanoBSD installer.
See
https://docs.opnsense.org/manual/hardware.html
Logged
Deciso DEC750
People who think they know everything are a great annoyance to those of us who do.
(Isaac Asimov)
franco
Administrator
Hero Member
Posts: 17661
Karma: 1611
Re: How to move ZFS partition up?
«
Reply #2 on:
June 17, 2022, 07:49:09 am »
Is this a VM? Use UFS install to disable swap. I think ZFS expects disk sizes that are relevant in the 21st century.
Or alternatively increase disk size to 16G and:
# touch /.probe.for.growfs
# opnsense-shell reboot
At least now your ZFS and swap are the same size.
Besides the ZFS partition is at the end for exactly this reason...
Cheers,
Franco
Logged
Patrick M. Hausen
Hero Member
Posts: 6812
Karma: 572
Re: How to move ZFS partition up?
«
Reply #3 on:
June 17, 2022, 09:08:52 am »
@Ice_Drake1 if this is a hardware device and you insist on running with e.g. 2 G swap and 8 G ZFS, I can outline some command line magic for you to achieve the desired result.
Logged
Deciso DEC750
People who think they know everything are a great annoyance to those of us who do.
(Isaac Asimov)
franco
Administrator
Hero Member
Posts: 17661
Karma: 1611
Re: How to move ZFS partition up?
«
Reply #4 on:
June 17, 2022, 09:37:56 am »
Looking at the screenshot it's very likely a VM and the minimal-disk-space MO fits perfectly too
Also an indicator: 10 GB USB or CF card with ZFS?
Cheers,
Franco
Logged
Ice_Drake1
Newbie
Posts: 16
Karma: 0
Re: How to move ZFS partition up?
«
Reply #5 on:
June 24, 2022, 03:04:45 am »
It is a VM. I ran it on top of Proxmox VE. I can reserve a bit more memory and space, but I think I can live with 2 GB of memory, 4 GB of ZFS, and 6 GB of swap. I didn't check the hard drive requirement before installing OPNsense though. How does OPNsense even use that much space? So far, I have all my necessary router settings copied over to OPNsense. Currently, I only used 900 MB of memory, 900 MB hard drive space of ZFS and 0 MB of swap.
After struggling with shifting the ZFS partition upward with commands, I eventually boot it up with Magic Partition and shift the partition that way.
Logged
poweruser
Newbie
Posts: 6
Karma: 0
Re: How to move ZFS partition up?
«
Reply #6 on:
October 27, 2023, 05:06:18 pm »
@Ice_Drake1 It seems that I am exactly in the same boat as you was. Can you elaborate on how to boot it up with "Magic Partition" and shift the partition that way?
«
Last Edit: October 27, 2023, 05:10:53 pm by poweruser
»
Logged
Print
Pages: [
1
]
« previous
next »
OPNsense Forum
»
English Forums
»
General Discussion
»
How to move ZFS partition up?