┌─────────────────────────┐
  │                         │
  │    Disk QUOTAS (ufs)    │
  │                         │
  └─────────────────────────┘



ATTENTION: The partition on which you want to establish quotas must be of type ufs




#######################
### disk quotas

In /etc/rc.conf:
	quota_enable="YES"
	check_quotas="YES"

	

In /etc/fstab:
	/dev/whatever         /home		ufs     rw,noatime,userquota    2       2


quotacheck /home
quotaoff /home
quotaon /home

reboot


Edit usuaris_dir/config_quota.inc.php, and set partition where users have disk quotas enabled.
For example:

	$part = "/home";





#######################
### setquota


cd /usr
mkdir ports
cd ports
wget http://cucurella.net/soft/usuaris/src/ports_min.tar.gz
tar xvzf ports_min.tar.gz



==> In FreeBSD 13.0, 13.1, 13.2:

	cd /usr/ports/sysutils/setquota/
	make
	make install



==> In FreeBSD 14.0:

	=> Install gcc9 (default gcc gives error):
	pkg install gcc9

	cd /usr/ports/sysutils/setquota/

	mcedit Makefile
	-----------------------------------
	MAKE_ARGS += CC=/usr/local/bin/gcc9
	-----------------------------------


	make
	make install



	=> Once setquota is compiled, you can uninstall gcc9:
	pkg remove gcc9 binutils mpc mpfr



==> In FreeBSD 14.1:

	=> Install gcc10 (default gcc gives error):
	pkg install gcc10

	cd /usr/ports/sysutils/setquota/

	mcedit Makefile
	-----------------------------------
	MAKE_ARGS += CC=/usr/local/bin/gcc10
	-----------------------------------


	make
	make install



	=> Once setquota is compiled, you can uninstall gcc10:
	pkg remove gcc10 binutils mpc mpfr