리눅스 쿼터(quata)설정 및 설명
디스크 쿼터
1)커널에서 쿼터 지원여부 확인
[root@netdosapro44 ~]# cat /var/log/dmesg | grep quota
VFS: Disk quotas dquot_6.5.1
2)/etc/fstab에 쿼터 옵션 추가
# This file is edited by fstab-sync - see 'man fstab-sync' for details
LABEL=/ / ext3 defaults.usrquota 1 1
LABEL=/boot1 /boot ext3 defaults 1 2
none /dev/pts devpts gid=5,mode=620 0 0
none /dev/shm tmpfs defaults 0 0
LABEL=/home /home ext3 defaults 1 2
none /proc proc defaults 0 0
none /sys sysfs defaults 0 0
LABEL=/tmp /tmp ext3 defaults 1 2
LABEL=/usr1 /usr ext3 defaults 1 2
LABEL=/var1 /var ext3 defaults 1 2
LABEL=SWAP-hda11 swap swap defaults 0 0
/dev/hdc /media/cdrom auto pamconsole,ro,exec,noauto,managed 0 0
3)쿼터 파티션 재설정
[root@netdosapro44 ~]# mount -o remount /
[root@netdosapro44 ~]# mount
/dev/hda10 on / type ext3 (rw,usrquota)
none on /proc type proc (rw)
none on /sys type sysfs (rw)
none on /dev/pts type devpts (rw,gid=5,mode=620)
usbfs on /proc/bus/usb type usbfs (rw)
/dev/hda7 on /boot type ext3 (rw)
none on /dev/shm type tmpfs (rw)
/dev/hda13 on /home type ext3 (rw)
/dev/hda12 on /tmp type ext3 (rw)
/dev/hda8 on /usr type ext3 (rw)
/dev/hda9 on /var type ext3 (rw)
none on /proc/sys/fs/binfmt_misc type binfmt_misc (rw)
sunrpc on /var/lib/nfs/rpc_pipefs type rpc_pipefs (rw)
[root@netdosapro44 ~]#
4)쿼터 데이터베이스 파일 만들기 및 퍼미션 추가
[root@netdosapro44 ~]# touch /aquota.user
[root@netdosapro44 ~]# cd /
[root@netdosapro44 /]# chmod 600 /aquota.user
[root@netdosapro44 /]#
5)쿼터 상태 체크
[root@netdosapro44 /]# quotacheck -avugm
quotacheck: WARNING - Quotafile //aquota.user was probably truncated. Can't save quota settings...
quotacheck: Scanning /dev/hda10 [/] quotacheck: Old group file not found. Usage will not be substracted.
done
quotacheck: Checked 3910 directories and 10070 files
6)쿼터 활성화
root@netdosapro44 /]# quotaon /
7)계정 용량 제한하기
[root@netdosapro44 /]# adduser soul1
[root@netdosapro44 /]# ls /home
lost+found pcs soul soul1
[root@netdosapro44 /]# edquota soul1
Disk quotas for user soul1 (uid 502):
Filesystem blocks soft hard inodes soft hard
/dev/hda10 0 0 0 0 0 0
(참고)
blocks : 현제 사용자가 사용 중인 총 블럭수 (용량)
soft : 사용자가 실제로 사용할수 있는 계정용량
hard : 하드로 할당된 용량 범위 내까지 소프트 용량을 사용할수 있게 함
inodes : 총 파일의 갯수
8)유예 기간(grace period)
Grace period before enforcing soft limits for users:
Time units may be: days, hours, minutes, or seconds
Filesystem Block grace period Inode grace period
/dev/hda10 7days 7days
~
9)쿼터 설정 사용 확인
[root@netdosapro44 /]# repquota -a
*** Report for user quotas on device /dev/hda10
Block grace time: 7days; Inode grace time: 7days
Block limits File limits
User used soft hard grace used soft hard grace
----------------------------------------------------------------------
root -- 282620 0 0 13949 0 0
news -- 388 0 0 28 0 0
rpm -- 84 0 0 1 0 0
10) 사용자 자신 쿼터 용량 확인
[root@netdosapro44 /]# su soul1
[soul1@netdosapro44 /]$ quota
Disk quotas for user soul1 (uid 502): none
[soul1@netdosapro44 /]$
11)쿼터 설정을 다른 사용자와 동일하게 설정하기
-soul2 를 soul1 처럼 용량 설정
[root@netdosapro44 /]# edquota -p soul1 soul2
[root@netdosapro44 /]# repquota -a
*** Report for user quotas on device /dev/hda10
Block grace time: 7days; Inode grace time: 7days
Block limits File limits
User used soft hard grace used soft hard grace
----------------------------------------------------------------------
root -- 282620 0 0 13949 0 0
news -- 388 0 0 28 0 0
rpm -- 84 0 0 1 0 0
[root@netdosapro44 /]#
게시판 목록
프로그램
| 번호 | 제목 | 글쓴이 | 날짜 | 조회 |
|---|---|---|---|---|
| 530 |
|
19년 전 | 1248 | |
| 529 |
|
19년 전 | 1435 | |
| 528 |
|
19년 전 | 1986 | |
| 527 |
사랑과우정
|
19년 전 | 2398 | |
| 526 | 19년 전 | 2880 | ||
| 525 |
|
19년 전 | 2314 | |
| 524 |
|
19년 전 | 1819 | |
| 523 | 19년 전 | 7065 | ||
| 522 |
|
19년 전 | 3742 | |
| 521 | 19년 전 | 2360 | ||
| 520 | 19년 전 | 2409 | ||
| 519 | 19년 전 | 2915 | ||
| 518 |
|
19년 전 | 5804 | |
| 517 |
|
19년 전 | 5575 | |
| 516 |
|
19년 전 | 2282 | |
| 515 |
|
19년 전 | 3326 | |
| 514 | 19년 전 | 2882 | ||
| 513 | 19년 전 | 2233 | ||
| 512 |
개발자관리자
|
19년 전 | 2741 | |
| 511 |
개발자관리자
|
19년 전 | 1599 | |
| 510 |
개발자관리자
|
19년 전 | 1762 | |
| 509 |
개발자관리자
|
19년 전 | 1876 | |
| 508 |
개발자관리자
|
19년 전 | 2022 | |
| 507 |
개발자관리자
|
19년 전 | 1702 | |
| 506 |
개발자관리자
|
19년 전 | 1826 | |
| 505 |
개발자관리자
|
19년 전 | 1792 | |
| 504 |
개발자관리자
|
19년 전 | 1868 | |
| 503 |
개발자관리자
|
19년 전 | 1532 | |
| 502 |
개발자관리자
|
19년 전 | 2672 | |
| 501 | 19년 전 | 2022 | ||
| 500 | 19년 전 | 3250 | ||
| 499 | 19년 전 | 3279 | ||
| 498 | 19년 전 | 2538 | ||
| 497 | 19년 전 | 2613 | ||
| 496 | 19년 전 | 2467 | ||
| 495 | 19년 전 | 2712 | ||
| 494 | 19년 전 | 2690 | ||
| 493 | 19년 전 | 3205 | ||
| 492 | 19년 전 | 2917 | ||
| 491 | 19년 전 | 5341 | ||
| 490 |
|
19년 전 | 2140 | |
| 489 |
|
19년 전 | 2223 | |
| 488 |
|
19년 전 | 2031 | |
| 487 |
|
19년 전 | 1958 | |
| 486 |
|
19년 전 | 1959 | |
| 485 |
|
19년 전 | 2166 | |
| 484 |
|
19년 전 | 3231 | |
| 483 |
|
19년 전 | 3118 | |
| 482 |
|
19년 전 | 2873 | |
| 481 |
|
19년 전 | 2572 | |
| 480 |
|
19년 전 | 2645 | |
| 479 |
|
19년 전 | 2321 | |
| 478 |
|
19년 전 | 2347 | |
| 477 |
개발자관리자
|
19년 전 | 1612 | |
| 476 |
개발자관리자
|
19년 전 | 2322 | |
| 475 |
개발자관리자
|
19년 전 | 2673 | |
| 474 |
개발자관리자
|
19년 전 | 2676 | |
| 473 |
개발자관리자
|
19년 전 | 2990 | |
| 472 | 19년 전 | 2753 | ||
| 471 | 19년 전 | 1755 | ||
| 470 | 19년 전 | 1848 | ||
| 469 |
|
19년 전 | 2753 | |
| 468 |
|
19년 전 | 2241 | |
| 467 |
|
19년 전 | 4012 | |
| 466 |
|
19년 전 | 2534 | |
| 465 | 19년 전 | 2397 | ||
| 464 | 19년 전 | 3543 | ||
| 463 |
|
19년 전 | 3114 | |
| 462 |
|
19년 전 | 2259 | |
| 461 |
|
19년 전 | 3057 | |
| 460 |
|
19년 전 | 2259 | |
| 459 |
|
19년 전 | 3133 | |
| 458 |
|
19년 전 | 3554 | |
| 457 |
|
19년 전 | 5228 | |
| 456 |
|
19년 전 | 3151 | |
| 455 |
스마일미디어
|
19년 전 | 3141 | |
| 454 |
스마일미디어
|
19년 전 | 2743 | |
| 453 |
스마일미디어
|
19년 전 | 2482 | |
| 452 |
스마일미디어
|
19년 전 | 2738 | |
| 451 |
스마일미디어
|
19년 전 | 2460 | |
| 450 |
스마일미디어
|
19년 전 | 2589 | |
| 449 |
스마일미디어
|
19년 전 | 2379 | |
| 448 |
스마일미디어
|
19년 전 | 2702 | |
| 447 | 19년 전 | 2970 | ||
| 446 |
스마일미디어
|
19년 전 | 3254 | |
| 445 |
스마일미디어
|
19년 전 | 7056 | |
| 444 |
스마일미디어
|
19년 전 | 5176 | |
| 443 |
스마일미디어
|
19년 전 | 2442 | |
| 442 |
스마일미디어
|
19년 전 | 5185 | |
| 441 |
스마일미디어
|
19년 전 | 3120 | |
| 440 |
|
19년 전 | 2488 | |
| 439 | 19년 전 | 2180 | ||
| 438 | 19년 전 | 3578 | ||
| 437 |
|
19년 전 | 2875 | |
| 436 |
|
19년 전 | 3259 | |
| 435 |
|
19년 전 | 2902 | |
| 434 | 19년 전 | 3398 | ||
| 433 |
sjsjin
|
19년 전 | 2730 | |
| 432 |
sjsjin
|
19년 전 | 3467 | |
| 431 |
sjsjin
|
19년 전 | 2432 |
댓글 작성
댓글을 작성하시려면 로그인이 필요합니다.
로그인하기