Signed-off-by: Nikolaos Karaolidis <nick@karaolidis.com>
This commit is contained in:
2025-09-13 19:20:30 +00:00
parent 615524070b
commit 6b38429bac
6 changed files with 94 additions and 71 deletions

View File

@@ -17,13 +17,13 @@ Remember to update [format.nix](format.nix).
### Adding a new drive
Create a `format.nix` containing the new disk layout. Do not include already existing disks in this file, nor the global pool.
```
parted /dev/sdd -- mklabel gpt
parted /dev/sdd -- mkpart primary 0% 100%
cryptsetup luksFormat /dev/sdd
cryptsetup open /dev/sdd storage2
disko -m "destroy" --yes-wipe-all-disks format.nix
disko -m "format" --yes-wipe-all-disks format.nix
btrfs device add /dev/mapper/storage2 /mnt/storage
btrfs balance start -dconvert=raid1 -mconvert=raid1 /mnt/storage
btrfs balance start -dconvert=raid1 -mconvert=raid1 /mnt/storage --bg
```
### Removing an old drive