Browse Source

Avoid 100MB reserved space in private ext4 partition

The ext4 reserved space is necessary for root partitions, but in the
private.img data partition, it is wasted space (accessible only to root
processes), which means losing 100 MB of the default 2GB.

From mkfs.ext4 man page: "-m reserved-blocks-percentage Specify the
percentage of the filesystem blocks reserved for the super-user." ...
"The default percentage is 5%."
Marek Marczykowski-Górecki 9 years ago
parent
commit
54755ac444
1 changed files with 1 additions and 0 deletions
  1. 1 0
      vm-systemd/misc-post.sh

+ 1 - 0
vm-systemd/misc-post.sh

@@ -14,6 +14,7 @@ INTERFACE=eth0 /usr/lib/qubes/setup-ip
 
 if [ -e /dev/xvdb -a ! -e /etc/this-is-dvm ] ; then
     resize2fs /dev/xvdb 2> /dev/null || echo "'resize2fs /dev/xvdb' failed"
+    tune2fs -m 0 /dev/xvdb
     mount /rw
 
     if ! [ -d /rw/home ] ; then