Created ZFS install/config script
This commit is contained in:
parent
421651ab4b
commit
8af4dd434e
1 changed files with 22 additions and 0 deletions
22
pre_setup.sh
Normal file
22
pre_setup.sh
Normal file
|
|
@ -0,0 +1,22 @@
|
|||
#!/bin/bash
|
||||
|
||||
apt update
|
||||
|
||||
## Setup ZFS
|
||||
ZFS_ROOT=/data
|
||||
|
||||
## Debian Setup
|
||||
codename=$(lsb_release -cs);echo "deb http://deb.debian.org/debian $codename-backports main contrib non-free"|sudo tee -a /etc/apt/sources.list
|
||||
apt update
|
||||
apt install dpkg-dev linux-headers-generic linux-image-generic
|
||||
apt install zfs-dkms zfsutils-linux
|
||||
|
||||
## Create ZFS Pool
|
||||
mkdir -p ${ZFS_ROOT}
|
||||
zpool create -m ${ZFS_ROOT} tank raidz <disk1> <disk2> <disk3> ...
|
||||
|
||||
zfs create tank/gitlab
|
||||
zfs create tank/home
|
||||
zfs create tank/jupyter
|
||||
zfs create tank/mineos
|
||||
zfs create tank/nextcloud
|
||||
Loading…
Add table
Add a link
Reference in a new issue