页次: 1
1. 从AUR下载ramroot.tar.gz
2. $ tar xzf ramroot.tar.gz
3. $ cd ramroot
4. $ makepkg
5. $ su -c "pacman -U ramroot-2.0.1-1-x86_64.pkg.tar.zst"
6. $ more /etc/mkinitcpio.conf
a. 确认 MODULES=(... lzo zram xfs) 如果用的文件系统是B-tree, 把xfs换成btrfs
b. 确认 HOOKS=(base udev ramroot autodetect modconf block filesystems keyboard fsck)
7. 修改mkinitcpio.conf后要执行 $ su -c "mkinitcpio -p linux"
8. 重新引导系统时会出现 “Load root file system to zram? [y/N]" 按<Y>回车就可以了。
Filesystem 1K-blocks Used Available Use% Mounted on
dev 10240 0 10240 0% /dev
run 15834944 1852 15833092 1% /run
/dev/zram0 7155932 5520548 1250516 82% /
cgroup_root 10240 0 10240 0% /sys/fs/cgroup
shm 15834944 16 15834928 1% /dev/shm
/dev/nvme0n1p4 16766976 1826476 14940500 11% /var/cache/pacman
/dev/nvme0n1p3 8378368 1791772 6586596 22% /home
/dev/nvme0n1p6 2086912 535832 1551080 26% /srv/http
/dev/nvme0n1p5 67076096 22782328 44293768 34% /var/opt
/dev/nvme0n1p7 2086912 104816 1982096 6% /var/lib/postgres
tmpfs 3166988 4 3166984 1% /run/user/xxxx
最近编辑记录 twobooks (2021-05-01 04:08:27)
离线
页次: 1