Sponsored Content
Top Forums Shell Programming and Scripting File System Check using shell script !!! Post 94188 by blowtorch on Wednesday 28th of December 2005 02:58:38 AM
Old 12-28-2005
Generally you can find what filesystems are mounted on what mount-point on your system by going through the /etc/mnttab file. The format for the file differs between systems, so go through the man page of your mnttab file to get the exact format. Once you get this list, you can do your tests (disk usage, touch, etc.)

One point to note is that you can mount a filesystem without making an entry in the /etc/mnttab file. But I dont think that those will be that common.

One question though, why cann't you use the df or similar command to find the mounted filesystems on your system?
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Script to Delete temp files and check file system

Hi all, new to the threads as well as Unix/Linux. I need to create a script that will delete any temporary files as well as check the files on the system for errors or corruption. This is what I have so far and I'm sure that I'm missing things or have the wrong commands. I'm not sure where to go... (3 Replies)
Discussion started by: Bwood1377
3 Replies

2. Shell Programming and Scripting

need to check the file using ftp in a shell script

i need to write a shell script.. connecting to another server using ftp and check whether the file ter.txt is exists there or not. i have written scirpt partially,as i new to Unix. ftp -inv $FTPHOST > $TEMPFILE1 2> $TEMPFILE1 << EOF user $FTPUSER $FTPPW binary prompt ${CD} ls *.txt... (11 Replies)
Discussion started by: KiranKumarKarre
11 Replies

3. Shell Programming and Scripting

Need to check for empty file in C shell script

I am running a C shell script. I have an output file from a previous step and I need to run "something" in the next step to check if the file is empty. If the file is empty, then the job script should finish EOJ. If the file is not empty then the job script should abend. Please help Thanks. (4 Replies)
Discussion started by: jclanc8
4 Replies

4. UNIX for Advanced & Expert Users

Check EOF char in Unix. OR To check file has been received completely from a remote system

Advance Thanks. (1) I would like to know any unix/Linux command to check EOF char in a file. (2) Or Any way I can check a file has been reached completely at machine B from machine A. Note that machine A ftp/scp the file to machine B at unknown time. (5 Replies)
Discussion started by: alexalex1
5 Replies

5. Shell Programming and Scripting

Script to check file system size

Dears, the output of this command df -h | tr -s ' ' | cut -f5 -d' ' is capacity 24% 0% 0% 0% 0% 1% 0% 24% 24% 0% 93% 1% (4 Replies)
Discussion started by: xxmasrawy
4 Replies

6. Shell Programming and Scripting

How to check file name format using shell script?

Hi, I am writting a script, which accepts input file as parameter. Input file name is aa_bb_cc_dd_ee.<ext> I need to check that input file name should be of 5 fileds. Please help me out. :confused: (7 Replies)
Discussion started by: Poonamol
7 Replies

7. Shell Programming and Scripting

Help with a shell script to check /var file system

deleting (0 Replies)
Discussion started by: fretagi
0 Replies

8. Shell Programming and Scripting

How to check the duplicancy of file using shell script?

Hi all, i am getting the file through sftp from a location in the name of 20141201_file.txt (iam getting the file on daily basis with date appended at the beginning) so before going to my actual process ,i want to check whether today files and yesterday file are same or not(which i used to... (3 Replies)
Discussion started by: hemanthsaikumar
3 Replies

9. UNIX for Dummies Questions & Answers

Need shell script to check file

Hi Experts, I am not good in writing script. Just stared.I am looking for shell script to check following parameters. 1) Number of files on remote Linux SUSE server.- Any directory and sub directory. 2) I should define number of files in script. Files should be variable. 3) Age of... (2 Replies)
Discussion started by: ApmPerfMonitor
2 Replies

10. UNIX for Beginners Questions & Answers

Shell Script to check a file

I'm required to write a simple shell script that when it runs it writes the output which is a simple barcode to a tmp flat file which I can do the bit I'm struggling with... The next time it runs I need to check the tmp output file to see if that barcode is in the output file and if it is send... (5 Replies)
Discussion started by: worky
5 Replies
quotaon(1M)						  System Administration Commands					       quotaon(1M)

NAME
quotaon, quotaoff - turn ufs file system quotas on and off SYNOPSIS
quotaon [-v] filesystem... quotaon -a [-v] quotaoff [-v] filesystem... quotaoff -a [-v] DESCRIPTION
quotaon turns on disk quotas for one or more ufs file systems. Before a file system may have quotas enabled, a file named quotas, owned by root, must exist in the root directory of the file system. See edquota(1M) for details on how to modify the contents of this file. quotaoff turns off disk quotas for one or more ufs file systems. The file systems specified must already be mounted. These commands update the mntopts field of the appropriate entries in /etc/mnttab to indicate when quotas are on or off for each file sys- tem. If quotas are on, the string quota will be added to mntopts; if quotas are off, the quota string is not present. filesystem must be either the mount point of a file system, or the block device on which the file system resides. OPTIONS
quotaon -a This option is normally used at boot time to enable quotas. It applies only to those file systems in /etc/vfstab which have ``rq'' in the mntopts field, are currently mounted ``rw'', and have a quotas file in the root directory. -v Display a message for each file system after quotas are turned on. quotaoff -a Force all file systems in /etc/mnttab to have their quotas disabled. -v Display a message for each file system affected. USAGE
See largefile(5) for the description of the behavior of quotaon and quotaoff when encountering files greater than or equal to 2 Gbyte ( 2 **31 bytes). FILES
/etc/mnttab mounted file systems /etc/vfstab list of default parameters for each file system ATTRIBUTES
See attributes(5) for descriptions of the following attributes: +-----------------------------+-----------------------------+ | ATTRIBUTE TYPE | ATTRIBUTE VALUE | +-----------------------------+-----------------------------+ |Availability |SUNWcsu | +-----------------------------+-----------------------------+ SEE ALSO
edquota(1M), quota(1M), quotacheck(1M), repquota(1M), mnttab(4), vfstab(4), attributes(5), largefile(5), quotactl(7I) SunOS 5.10 16 Sep 1996 quotaon(1M)
All times are GMT -4. The time now is 06:53 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy