File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed
Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -33,17 +33,17 @@ is_object_valid 'user' 'USER' "$user"
3333# Updating disk quota
3434# Had quota equals package value. Soft quota equals 90% of package value for warnings.
3535quota=$( get_user_value ' $DISK_QUOTA' )
36- soft=$(( quota * 1024 * 0 .90 ) )
37- hard=$(( quota * 1024 ) )
36+ soft=$( echo " $ quota * 1024 * 0.90" | bc | cut -f 1 -d . )
37+ hard=$( echo " $ quota * 1024" | bc | cut -f 1 -d . )
3838
3939# Searching home mount point
4040mnt=$( df -P /home | awk ' {print $6}' | tail -n1)
4141
4242# Checking unlinmited quota
4343if [ " $quota " = ' unlimited' ]; then
44- setquota $user 0 0 0 0 $mnt
44+ setquota $user 0 0 0 0 $mnt 2> /dev/null
4545else
46- setquota $user $soft $hard 0 0 $mnt
46+ setquota $user $soft $hard 0 0 $mnt 2> /dev/null
4747fi
4848
4949
You can’t perform that action at this time.
0 commit comments