System Administration
cancel
Showing results for 
Search instead for 
Did you mean: 

display mount options of filesystems

SOLVED
Go to solution
support_billa
Valued Contributor

display mount options of filesystems

hello,

 

i try to get the mount options of a mounted filesystem :

 

Display mount options on current mounted filesystems

 

with this white paper there a lot of options :

 

HP-UX VxFS mount options for Oracle Database environments

 

with mount -v and mount -p it is not easy to parse

 

i found this command :


/usr/sam/lbin/fslist: illegal option -- ?
Usage: fslist -p [mntDir|dev]
       fslist -P -p [mntDir|dev]
       fslist -d <isRootFs|isFsMounted|getFsType|isFsRdOnly|canFsBeRemoved> -p <mntDir|dev>
       @(#)fslist (fsweb) Build Date: 19:54:22 Jun 22 2012

/usr/sam/lbin/fslist -p /mount_point
/mount_point|vxfs|-|ioerror=mwdisable,largefiles,mincache=direct,delaylog,convosync=direct,cio,dev=8000101b|/dev/vgtest/db1|9.0 GB|9663676416.0|1.7 GB|7.3 GB|81%|81|Wed Jan  2 15:32:59 2013|Tue Jan 22 15:46:59 2013|yes|no|yes|no|no|yes|no|56512|56496|none


mount -p  |grep "db01"
/dev/vgtest/db1 /mount_point vxfs  ioerror=mwdisable,largefiles,mincache=direct,delaylog,convosync=direct,cio,dev=8000101b   0 0


mount -v |grep "db01"
/dev/vgtest/db1 on /mount_point type vxfs ioerror=mwdisable,largefiles,mincache=direct,delaylog,convosync=direct,cio,dev=8000101b on Wed Jan  2 15:32:59 2013

 

those are possible options :
mount [-F vxfs] [-eQrV]
                [-o [rw|ro][,crw]
                [remount]
                [quota]
                [suid|nosuid]
                [log|delaylog|tmplog]
                [datainlog|nodatainlog]
                [snapof=primary_special,[snapsize=blocks]]
                [convosync={direct|dsync|closesync|delay|unbuffered}]
                [mincache={direct|dsync|closesync|tmpcache|unbuffered}]
                [blkclear]
                [qio|noqio]
                [largefiles|nolargefiles]
                [ckpt=ckpt_name]
                [mntlock=id]
                [cluster]
                [seconly]
                [ioerror={mwdisable|wdisable|nodisable|mdisable|disable}]
                [logiosize=size]
                [cio]
                [tranflush]
                [nomtime]
                [noatime]
                [stackfs=stackfs_name] ] {special | mount_point}

 

what are about this options :

 

actual : ioerror=mwdisable,largefiles,mincache=direct,delaylog,convosync=direct,cio,dev=8000101b

 

ioerror=mwdisable

dev=8000101b

 

i can't use "," as FS (field separator) to split the options because "convosync=direct,cio" is one option

 

regards

 

5 REPLIES
Patrick Wallek
Honored Contributor
Solution

Re: display mount options of filesystems

For an explanation of the  mount options see the 'mount_vxfs' man page.  There is a section on the 'ioerror' options.  The value of mwdisable is the default value.

 

The last 6 characters of the dev= value appear to be the minor number of the logical volume.

 

For example:

 

# mount -v
/dev/vgbig/lvol6 on /var/tmp/Training type vxfs nosuid,ioerror=mwdisable,largefiles,delaylog,dev=40010006 on Fri Nov 16 17:47:20 2012

/dev/vg00/lvol5 on /home type vxfs nosuid,ioerror=mwdisable,largefiles,delaylog,dev=40000005 on Fri Nov 16 17:47:24 2012
# ll /dev/vg00/lvol5
brw-r-----   1 root       sys         64 0x000005 Oct 29  2009 /dev/vg00/lvol5

# ll /dev/vgbig/lvol6
brw-r-----   1 root       sys         64 0x010006 Mar 15  2012 /dev/vgbig/lvol6

 

Duncan Edmonstone
Honored Contributor

Re: display mount options of filesystems

>> The last 6 characters of the dev= value appear to be the minor number of the logical volume

 

and the first 2 characters are the device major number of the logical volume in hex -i.e. 64 in decimal is 0x40 in hex - for a brief explanation of what device IDs are for see here:

 

https://h20392.www2.hp.com/portal/swdepot/displayProductInfo.do?productNumber=DEVICEID

 

Device IDs have been part of the core OS since 11iv2


HTH

Duncan
Duncan Edmonstone
Honored Contributor

Re: display mount options of filesystems

oh and also...

 

>> i can't use "," as FS (field separator) to split the options because "convosync=direct,cio" is one option

 

no it isn't... cio isn't part of the convosync=direct option - they are entirely seperate


HTH

Duncan
support_billa
Valued Contributor

Re: display mount options of filesystems

 

>> i can't use "," as FS (field separator) to split the options because "convosync=direct,cio" is one option

 

>>> no it isn't... cio isn't part of the convosync=direct option - they are entirely seperate

 

i found "cio" in the mount option, it was a mistake of me .

support_billa
Valued Contributor

Re: display mount options of filesystems

i suppress "ioerror" and "dev" with following "awk" , this will display the mount options :

 

example :

 

MNT_OPT="ioerror=mwdisable,largefiles,mincache=direct,delaylog,convosync=direct,cio,dev=8000101b"

echo "${MNT_OPT}" | \
awk '{ mnt_opt=""
       max_arr = split ($0,arr,","); 
       for (i=1; i<=max_arr; i++)
       { 
	 if ( arr[i] !~ /^ioerror|^dev/ )
	 {
	   i==1 ? col="" : col=","
           length(mnt_opt) == 0 ? col="" : col=","
	   mnt_opt = mnt_opt col arr[i]
         }
       }
     }
     END { print mnt_opt }'