diff options
author | Julien Dessaux | 2023-10-04 10:58:05 +0200 |
---|---|---|
committer | Julien Dessaux | 2023-10-04 10:58:05 +0200 |
commit | b8c0c18ebf1eb38a9e8eb96474f8db02a6fddc6f (patch) | |
tree | 3d8fc81d0d39ae960d2b1ee698e58646675abbc1 /content/blog/nix | |
parent | Update Makefile to build future articles (diff) | |
download | www-b8c0c18ebf1eb38a9e8eb96474f8db02a6fddc6f.tar.gz www-b8c0c18ebf1eb38a9e8eb96474f8db02a6fddc6f.tar.bz2 www-b8c0c18ebf1eb38a9e8eb96474f8db02a6fddc6f.zip |
Fixed omission in last article
Diffstat (limited to '')
-rw-r--r-- | content/blog/nix/installing-nixos-on-a-vps.md | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/content/blog/nix/installing-nixos-on-a-vps.md b/content/blog/nix/installing-nixos-on-a-vps.md index 7948f31..7350fc1 100644 --- a/content/blog/nix/installing-nixos-on-a-vps.md +++ b/content/blog/nix/installing-nixos-on-a-vps.md @@ -24,6 +24,7 @@ Install your vps or compute instance normally using a Linux distribution (or any We are going to remount the partitions as the running OS as read only. In order to do that, we are going to shutdown nearly everything! If at some point you lose access to your system, just force reboot it and try again. Our goal is for those commands to run without an error: ```sh +swapoff -a mount -o remount,ro /boot mount -o remount,ro / ``` @@ -37,7 +38,13 @@ On most Linux you can list running services using `systemctl|grep running` and b - session-XX - user@0 (root) and any user@XX where XX is the uid you connected with -Everything else should be fair game, here is a list of what I shutdown on an oracle cloud compute before I could remount / read only: +Everything else should be fair game, what you are looking for are processus that keep files opened for writing. Those can be identified with: +- `lsof / | awk '$4 ~ /[0-9].*w/'` +- `fuser -v -m /` +- `ps aux` +- `systemctl|grep running` + +Here is a list of what I shutdown on an oracle cloud compute before I could remount / read only: ```sh systemctl stop smartd systemctl stop rpcbind @@ -77,6 +84,7 @@ systemctl stop serial-getty@ttyS0.service Remember, your success condition is to be able to run this without errors: ```sh +swapoff -a mount -o remount,ro /boot mount -o remount,ro / ``` |