Browse Source

Some filesystem optimisations for btrfs

Bob Mottram 8 years ago
parent
commit
81e06abc20

+ 2
- 2
src/freedombone-image-customise View File

@@ -1224,8 +1224,8 @@ function image_setup_utils {
1224 1224
     fi
1225 1225
     chroot "$rootdir" apt-get -yq install tripwire
1226 1226
 
1227
-    # mirroring
1228
-    # cmake
1227
+    # filesystem optimisations
1228
+    sed -i 's|btrfs subvol=@|btrfs defaults,subvol=@,compress=lzo,ssd|g' $rootdir/etc/fstab
1229 1229
 }
1230 1230
 
1231 1231
 function image_install_nodejs {

+ 4
- 0
src/freedombone-utils-filesystem View File

@@ -123,4 +123,8 @@ function defrag_filesystem {
123 123
     echo $'Defragmentation completed'
124 124
 }
125 125
 
126
+function optimise_filesystem {
127
+    sed -i 's|btrfs subvol=@|btrfs defaults,subvol=@,compress=lzo,ssd|g' /etc/fstab
128
+}
129
+
126 130
 # NOTE: deliberately no exit 0

+ 3
- 0
src/freedombone-utils-setup View File

@@ -663,6 +663,9 @@ function setup_utils {
663 663
     function_check separate_tmp_filesystem
664 664
     separate_tmp_filesystem 150
665 665
 
666
+    function_check optimise_filesystem
667
+    optimise_filesystem
668
+
666 669
     function_check disable_null_passwords
667 670
     disable_null_passwords
668 671