!coeAONBrWyDJnYMbMi:nixos.org

NixOS System Operations

575 Members
About system administration for running NixOS systems in production. Declaratively manage your operations. | Room recommendations: #networking:nixos.org157 Servers

Load older messages


SenderMessageTime
24 Mar 2024
@elvishjerricco:matrix.orgElvishJerricco you partition the disk, then you use cryptsetup luksFormat, then you use cryptsetup open 23:47:48
@elvishjerricco:matrix.orgElvishJerriccoyou need to open them23:47:55
@conr:mozilla.orgconrso did i do it right or need to do it over?23:48:00
@elvishjerricco:matrix.orgElvishJerricco seems like you're probably good if you did luksFormat already 23:48:11
@conr:mozilla.orgconr so now i can create the zpool and point to the /sda1, sdb1, etc...? 23:48:46
@elvishjerricco:matrix.orgElvishJerriccono23:48:50
@elvishjerricco:matrix.orgElvishJerriccoagain23:48:52
@elvishjerricco:matrix.orgElvishJerriccofor the third time23:48:54
@elvishjerricco:matrix.orgElvishJerricco you need to open them with cryptsetup open 23:48:59
@conr:mozilla.orgconroh i'm sorry, yes. open them23:49:45
@conr:mozilla.orgconr
NAME          MAJ:MIN RM   SIZE RO TYPE  MOUNTPOINTS
sda             8:0    0  10.9T  0 disk
└─sda1          8:1    0  10.9T  0 part
  └─crypthdd1 254:3    0  10.9T  0 crypt
sdb             8:16   0  10.9T  0 disk
└─sdb1          8:17   0  10.9T  0 part
  └─crypthdd2 254:4    0  10.9T  0 crypt
sdc             8:32   0   1.8T  0 disk
└─sdc1          8:33   0   1.8T  0 part
  └─cryptssd1 254:5    0   1.8T  0 crypt
sdd             8:48   0   1.8T  0 disk
└─sdd1          8:49   0   1.8T  0 part
  └─cryptssd2 254:6    0   1.8T  0 crypt
nvme0n1       259:0    0 931.5G  0 disk
├─nvme0n1p1   259:1    0     1G  0 part  /boot
├─nvme0n1p2   259:2    0    32M  0 part
│ └─cryptkey  254:0    0    16M  0 crypt
├─nvme0n1p3   259:3    0    32G  0 part
│ └─cryptswap 254:1    0    32G  0 crypt [SWAP]
└─nvme0n1p4   259:4    0 898.5G  0 part
  └─cryptroot 254:2    0 898.5G  0 crypt
23:53:02
@conr:mozilla.orgconrok got it23:53:03
@elvishjerricco:matrix.orgElvishJerricco conr: yea so now you create a pool with those cryptssd1 devices and whatnot 23:55:31
25 Mar 2024
@conr:mozilla.orgconrcool. got it.00:06:06
@conr:mozilla.orgconr * cool. got it setup.00:06:16
@conr:mozilla.orgconr do i need to create a /etc/crypttab 00:27:40
@conr:mozilla.orgconri don't have one00:27:42
@hexa:lossy.networkhexaif this is a fresh install, nixos-generate-config should create hardware-configuration.nix with boot.inird.luks.devices entries00:29:32
@conr:mozilla.orgconri'm trying to just load it in level 2, not level 100:30:38
@elvishjerricco:matrix.orgElvishJerriccostage* 200:30:58
@elvishjerricco:matrix.orgElvishJerricco conr: Don't create /etc/crypttab. Just use the environment.etc option to have nixos create it. 00:31:22
@conr:mozilla.orgconrright stage 200:31:23
@conr:mozilla.orgconrok then add each value manually after?00:32:08
@conr:mozilla.orgconr * ok then add each disk manually after?00:32:16
@elvishjerricco:matrix.orgElvishJerricco
environment.etc.crypttab.text = ''
  cryptssd1 /dev/disk/by-uuid/asdfasdf /dev/mapper/cryptkey keyfile-size=8192
  cryptssd2 /dev/disk/by-uuid/wxyzwxya /dev/mapper/cryptkey keyfile-size=8192
'';
00:32:56
@elvishjerricco:matrix.orgElvishJerricco you don't need to edit /etc/crypttab at all. Just have nixos manage it like that 00:33:07
@conr:mozilla.orgconrooo i like it00:33:14
@conr:mozilla.orgconrWorked on the first try!00:49:02
@conr:mozilla.orgconr how to i make this work recursively? systemd.tmpfiles.rules = [ "d /mnt/data1 0755 conor users" ]; 01:28:26
@elvishjerricco:matrix.orgElvishJerricco conr: You can follow that line with another one like Z /mnt/data1 0755 conor users to recursively set the mode and ownership of a directory 01:32:53

Show newer messages


Back to Room ListRoom Version: 10