How can i list Solaris External storages?

Hi

how can i list Solaris external storage's only, ie SAN,

# for fs in `mount -p | egrep 'ufs|zfs|vxfs' | awk '{print $3}'`; do df -h $fs | sed 's/%//g' | grep -v capacity; done

/dev/dsk/c2t5000C5003C31721Bd0s0    30G    18G    12G    61    /
/dev/dsk/c2t60060160B9612E00636A2F0D094AE211d0s3    15G   6.8G   7.8G    47    /comsaps-root
/dev/dsk/c2t5000C5003C31721Bd0s5   148G    24G   122G    17    /comsdir
/dev/dsk/c2t60060160B9612E00A49FB80CFC49E211d0s3    15G   6.5G   8.1G    45    /comsdb-root
/dev/dsk/c2t5000C5003C31721Bd0s6    66G    11G    55G    17    /export/home
/dev/dsk/c2t60060160B9612E00636A2F0D094AE211d0s0    84G    15G    68G    18    /comsaps-root/root/comsapps
/dev/dsk/c2t60060160B9612E00A49FB80CFC49E211d0s0   192G   149G    41G    79    /comsdb-root/root/data1
/dev/dsk/c2t60060160B9612E0096CF5723FC49E211d0s0   197G    56G   139G    29    /comsdb-root/root/orabkp

is there any other way to achieve this. the output is also listing local HDD

thanks & Regards,
Ben

Store the disk of "/" (minus the dXsX at the end), and search for other disks.

mount -p | awk '($3=="/") {disk=$1; sub("d[0-9]+s[0-9]+$","",disk)} ($4~/^(ufs|zfs|vxfs)$/ && $1!~"^"disk) {print $3}'

Got error

root@globaldev6 # mount -p | awk '($3=="/") {disk=$1; sub("d[0-9]+s[0-9]+$","",disk)} ($4~/^(ufs|zfs|vxfs)$/ && $1!~"^"disk) {print $3}'
awk: syntax error near line 1
awk: illegal statement near line 1
awk: syntax error near line 1
awk: bailing out near line 1

Use nawk or /usr/xpg4/bin/awk! (/usr/bin/awk does not know sub() )

HI

that also gives me error like -p option is nor there with mount.

i have achieved that same with below command:

root@globaldev6 # luxadm probe | grep -v "Node WWN:" | awk -F\/ 'NR>3{print $4}'|sed 's/..$//g'
c3t600D0231000BE73D1C9ED0B453F185C2d0
c3t600D0231000BE73D4A2C042D18A2E641d0
c3t600D0231000BE73D6D42C80D77B8DDF0d0
c3t600D0231000BE73D194D85CA4D102795d0
c3t600D0231000BE73D435D27657C919F6Ed0
c3t600D0231000BE73D5482A3BE75F412FCd0
c3t600D0231000BE73D5619FDD6500CF273d0
c3t600D0231000BE73D37672E311947B18Cd0

Hmm, you gave us the mount -p.
It should work in Solaris 8 and later.