USER QUOTAS
Features:
1. Limits disk usage (blocks or inodes)
2. Tied to file systems (set on a per file system basis)
3. Can be configured for users and groups
Steps to enable quota support:
1. Enable quota support per file system in: /etc/fstab
• defaults,usrquota,grpquota
2. Remount the file system(s)
• mount -o remount /
• use 'mount' to confirm that 'usrquota,grpquota' support are enabled
3. Create quota database files and generate disk usage table
• quotacheck -mcug / - this creates /aquota.user & /aquota.group
• quotacheck -mavug
4. Assign quota policies
• edquota username - set blocks/inodes soft_limits hard_limit
• edquota student1 - sets quotas for user 'student1'
• export EDITOR=nano - to have edquota default to 'nano' editor
5. Check quotas
• quota username
Ex: quota student1
Note: place 'quotacheck -avug' in /etc/cron.*(hourly,daily)
6. Report on usage
• repquota -a - this reports on usage
Note: The blocks are measured in 1K increments. i.e. 20000 blocks is roughly 20MB
i m a rhce certified person. This blog contain RH033,RH133,RH233 practice,tasks,question,video,dumps,etc. use it and spread to your friends.. Also i am working as oracle database administrator. I am positing documents which could help you to administrate oracle database.
Showing posts with label linux. Show all posts
Showing posts with label linux. Show all posts
Thursday, December 31, 2009
SED-STREAM EDITOR
SED-STREAM EDITOR
Features:
1. Faciliates automated text editing
2. Supports RegExes (POSIX)
3. Like Awk, supports scripting using '-F' option
4. Supports input via: STDIN, pipe, file
Usage:
1. sed [options] 'instruction[s]' file[s]
2. sed -n '1p' grep1.txt - prints the first line of the file
3. sed -n '1,5p' grep1.txt - prints the first 5 lines of the file
4. sed -n '$p' grep1.txt - prints the last line of the file
5. sed -n '1,3!p' grep1.txt - prints ALL but lines 1-3
6. sed -n '/linux/p' grep1.txt - prints lines with 'linux'
7. sed -e '/^$/d' grep1.txt - deletes blank lines from the document
8. sed -e '/^$/d' grep1.txt > sed1.txt - deletes blank lines from the document
'grep1.txt' and creates 'sed1.txt'
9. sed -ne 's/search/replace/p' sed1.txt
10. sed -ne 's/linux/unix/p' sed1.txt
11. sed -i.bak -e 's/3/4' sed1.txt - this backs up the original file and creates
a new 'sed1.txt' with the modifications indicated in the command
Note:
1)Generally, to create new files, use output redirection, instead of
allowing sed to write to STDOUT
2)Sed applies each instruction to each line
Features:
1. Faciliates automated text editing
2. Supports RegExes (POSIX)
3. Like Awk, supports scripting using '-F' option
4. Supports input via: STDIN, pipe, file
Usage:
1. sed [options] 'instruction[s]' file[s]
2. sed -n '1p' grep1.txt - prints the first line of the file
3. sed -n '1,5p' grep1.txt - prints the first 5 lines of the file
4. sed -n '$p' grep1.txt - prints the last line of the file
5. sed -n '1,3!p' grep1.txt - prints ALL but lines 1-3
6. sed -n '/linux/p' grep1.txt - prints lines with 'linux'
7. sed -e '/^$/d' grep1.txt - deletes blank lines from the document
8. sed -e '/^$/d' grep1.txt > sed1.txt - deletes blank lines from the document
'grep1.txt' and creates 'sed1.txt'
9. sed -ne 's/search/replace/p' sed1.txt
10. sed -ne 's/linux/unix/p' sed1.txt
11. sed -i.bak -e 's/3/4' sed1.txt - this backs up the original file and creates
a new 'sed1.txt' with the modifications indicated in the command
Note:
1)Generally, to create new files, use output redirection, instead of
allowing sed to write to STDOUT
2)Sed applies each instruction to each line
Labels:
linux,
redhat linux,
redhat linux commands,
SED-STREAM EDITOR
Monday, December 28, 2009
KICKSTART CONFIGURATION
Features:
1. Hands-free, automated installation
2. Scripted installation
3. Script can be used on multiple systems
Note: 'system-config-kickstart' is NOT installed by default
Steps:
1. Open previously created 'anaconda-ks.cfg' file and modify
2. Define partitions accordingly
3. Confirm settings
4. Publish the 'ks.cfg' file to HTTP server
5. Install server using the following at the main menu:
'linux ks=http://192.168.75.100/ks.cfg'
Note: The following can be used to boot a kickstart installation:
1. boot.iso CD-ROM
2. First CD-ROM of the RH5 installation set
3. The DVD-ROM of the RH5 installation set
4. USB Pen/Stick - diskboot.img (use dd)
Features:
1. Hands-free, automated installation
2. Scripted installation
3. Script can be used on multiple systems
Note: 'system-config-kickstart' is NOT installed by default
Steps:
1. Open previously created 'anaconda-ks.cfg' file and modify
2. Define partitions accordingly
3. Confirm settings
4. Publish the 'ks.cfg' file to HTTP server
5. Install server using the following at the main menu:
'linux ks=http://192.168.75.100/ks.cfg'
Note: The following can be used to boot a kickstart installation:
1. boot.iso CD-ROM
2. First CD-ROM of the RH5 installation set
3. The DVD-ROM of the RH5 installation set
4. USB Pen/Stick - diskboot.img (use dd)
Subscribe to:
Posts (Atom)