quota/install.sh

raw link view readme
1 parted -s /dev/sdc mklabel msdos
2
3 parted -s /dev/sdc unit MB mkpart primary ext4 1 256
4
5 mkfs.ext4 /dev/sdc1
6
7 mkdir -p /var/librarian
8
9 echo `blkid | grep sdc1 | awk '{ print $2 }'` /var/librarian ext4 defaults,usrquota 0 0 >> /etc/fstab
10
11 mount -a
12
13 yum install quota -y
14
15 quotacheck -u /var/librarian
16
17 quotaon -u /var/librarian
18
19 useradd librarian -m -s /bin/bash
20
21 #+ edquota is truly unhelpful since it's interactive
22 setquota -u librarian 500 1000 0 0 /var/librarian
23
24 chown librarian:librarian /var/librarian
25
26 quota librarian
27