Disk configuration for 'lore'
home |
airgap |
charisma |
verve |
trail |
commitment |
discernment |
lore
For more info see 'lore'.
PNY 1TB
TBA: serial number
/boot/efi
md0 (2GB)
swap (10GB)
md1 (150GB)
best (800GB)
PNY 1TB
TBA: serial number
/boot/efi
md0 (2GB)
swap (10GB)
md1 (150GB)
best (800GB)
Samsung 990 Pro 2TB
S6Z2NJ0TA15369X
fast (2TB)
Samsung 990 Pro 2TB
S6Z2NJ0TA15361M
fast (2TB)
Kioxiz 256GB
TBA: serial number
data:cache (256GB)
Kioxiz 256GB
TBA: serial number
data:cache (256GB)
sda (14.6TB)
2MKTESDB
data
sdb (14.6TB)
2BKRRZET
data
sdc (14.6TB)
2BKRHVRT
data
fstab
Device |
RAID |
Capacity |
File-system |
Mount |
md0 |
RAID1 |
2GB |
ext4 |
/boot |
md1 |
RAID1 |
150GB |
ext4 |
/ |
ZFS zpools
Pool |
RAID |
Capacity |
Compression |
Dedup |
best |
RAID1 |
800GB |
lz4 |
off |
fast |
RAID1 |
2TB |
lz4 |
on |
data |
RAID1 |
14.5TB |
zstd |
on |
ZFS datasets
These are the datasets we create on our zpools.
Dataset |
Mount |
Note |
best |
/best |
For 'xfer' and 'upload' NFS/SMB shares |
fast |
/fast |
|
fast/home |
/home |
|
fast/home/jj5 |
/home/jj5 |
|
fast/mysql |
/var/lib/mysql |
no compression, no dedup |
fast/scratch |
/fast/scratch |
no compression, no dedup |
fast/session |
/var/log/session |
|
fast/virt |
/fast/virt |
|
data |
/data |
|
data/archive |
/data/archive |
|
data/blob |
/data/blob |
|
data/host |
/data/host |
|
data/image |
/data/image |
no compression, dedup |
data/share |
/data/share |
|
data/temp |
/data/temp |
|
Commands
Initial setup on 2022-12-10
#!/bin/bash
set -euo pipefail;
BEST_1=PNY 1TB partition 5
BEST_2=PNY 1TB partition 5
FAST_DISK_1=/dev/disk/by-id/nvme-Samsung_SSD_990_PRO_2TB_S6Z2NJ0TA15369X
FAST_DISK_2=/dev/disk/by-id/nvme-Samsung_SSD_990_PRO_2TB_S6Z2NJ0TA15361M
DATA_DISK_1=/dev/disk/by-id/scsi-SATA_WDC_WUH721816AL_2MKTESDB
DATA_DISK_2=/dev/disk/by-id/scsi-SATA_WDC_WUH721816AL_2BKRRZET
DATA_DISK_3=/dev/disk/by-id/scsi-SATA_WDC_WUH721816AL_2BKRHVRT
DATA_CACHE_1=...256GB...
DATA_CACHE_2=...256GB...
apt install zfsutils-linux
zpool create \
-o ashift=14 -o autotrim=on \
-O acltype=posixacl -O compression=lz4 \
-O dnodesize=auto -O normalization=formD -O atime=off -O dedup=off \
-O xattr=sa \
best mirror ${BEST_1} ${BEST_2}
zpool create \
-o ashift=14 -o autotrim=on \
-O acltype=posixacl -O compression=lz4 \
-O dnodesize=auto -O normalization=formD -O atime=off -O dedup=on \
-O xattr=sa \
fast mirror ${FAST_DISK_1} ${FAST_DISK_2}
zpool create \
-O acltype=posixacl -O compression=zstd \
-O dnodesize=auto -O normalization=formD -O atime=off -O dedup=on \
-O xattr=sa \
data mirror ${DATA_DISK_1} ${DATA_DISK_2} ${DATA_DISK_3}
zpool add data cache ${DATA_CACHE_1}
zpool add data cache ${DATA_CACHE_2}
zfs create fast/scratch
zfs set dedup=off fast/scratch
zfs set compression=off fast/scratch
zfs create fast/home
zfs create fast/home/jj5
zfs create fast/mysql
zfs set dedup=off fast/mysql
zfs set compression=off fast/mysql
zfs set mountpoint=/var/lib/mysql fast/mysql
zfs create fast/virt
zfs create data/host
zfs create data/image
zfs set compression=off data/image
zfs create data/temp
zfs create data/archive
zfs create data/backup
zfs create data/blob
zfs create data/share
mv /home /home.bak
zfs set mountpoint=/home fast/home
chown jj5:jj5 /home/jj5
mv /home.bak/jj5/.[!.]* /home/jj5/
#mv /home.bak/jj5/* /home/jj5/