TrueNAS Scale is a network-attached storage (NAS) product produced by iXsystems. Based on the Open ZFS file system, it runs on Linux and is compatible with virtualization hosts such as Proxmox.
Networking protocols supported by TrueNAS include SMB, NFS, iSCSI, rsync and SFTP.
Source: Wikipedia
Setup
VM Installation
- Create VM settings:
- Machine = q35, BIOS = Default
- Disk = 32GB, CPU cores = 12, CPU type = x86-64-v4, RAM = 32768
- Setup PCIe passthrough for the non-boot SDDs
lsblk -o NAME,FSTYPE,MOUNTPOINT,SIZE,MODELto identify proxmox’s boot drive, e.g. “nvme1n1”udevadm info /dev/nvme1n1to identify pci id, e.g “ID_PATH=pci-0000:02:00.0-nvme-1”- For all others, repeat:
- Proxmox: Hardware > Add > PCI Device
- Raw Device > Device = 0000:01:00.0, All Functions
- Add
- Proxmox: Options:
- Start at boot: Yes
- Start order: order=1
- Start VM
- UI at http://see-address-in-proxmox-console
Config Network & System
Network
- Map truenas=192.168.137.12=MAC in DHCP server
- Add DNS server and gateway (necessary when dhcp disabled)
System
- Services: Enable (NFS), SMART, SMB, SSH
- Disable Password Auth for SSH
Create Pools & Datasets
Storage: Create pool
- Dataset: RAIDZ1 layout
- Note: If using all drives, there can only be one pool
- Don’t enable encryption (if at least some of the datasets won’t be encrypted)
- Skip other optional steps (see https://youtu.be/3T5wBZOm4hY for details)
Datasets: Add dataset
- system (leave unencrypted)
- users
User Accounts
Credentials: Users: Add
- USER, UID: 1000
- Home dir: /mnt/main-pool/users, Perm rwx-----, “Create Home Directory”
- Upload main id_rsa.pub (and paste e.g. dockerhost’s id_rsa.pub)
- Shell: bash, “Allow all sudo commands”
Test user by ssh logging in. Create bash aliases (Linux Systems Setup).
Create another “sambaguest” user, without ssh key and without sudo permission.
Add alerts
- Add an email address to at least one admin user
- System > general settings > email > settings
- System > alert settings > alert services > edit email / add telegram
Create other Shares and Datasets
See Network Shares for technical details
Add Apps
Data Protection
Rsync
Credentials > Backup cred > SSH Connections > Add
- Name
- Setup Method: manual
- Host, Port, Username: those of the remote system to backup to
- Private key: Generate new (or choose existing keypair generated in Credentials > Backup cred > SSH Keypairs)
- Discover Remote Host Key
- Save
Data Protection > Rsync Task > Add