Chandan
    Thanks for your detailed explanation, but my requirement is a little 
different from what you have done here, I want to mount an IMG file, not an ISO 
file, and also I want to specify the mount offset during mounting.




Thanks!
Frank


-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Chandan Maddanna
Sent: 2007年12月12日 16:50
To: opensolaris-discuss@opensolaris.org
Subject: Re: [osol-discuss] Does Solaris has similar Linux command "mount -o"

Dear Frank,

I use this small script i had written for mounting iso images. hope it helps..

Save the below contents in a file called "mountiso.sh"

#!/usr/bin/bash
mkdir $2
lofiadm -a $1 /dev/lofi/1
mount -F hsfs -o ro /dev/lofi/1 $2 && echo -e "\n\t I have mounted $1 under the 
folder $2\n\n"


and then give this script file executable permission form command prompt.

#  chmod +x ./mountiso.sh

and use this script to mount iso images...


For example lets say you have an iso image called "/opt/testfile1.iso" and you 
want to mount it under /testfilecontents

Than use the script as follows :

#  ./mountiso.sh   /opt/testfile1.iso /testfilecontents


and you are done, you will have all the contents of the iso visible under 
/testfilecontents folder.


Best Regards,

-- Chandan Maddanna
 
 
This message posted from opensolaris.org
_______________________________________________
opensolaris-discuss mailing list
opensolaris-discuss@opensolaris.org
_______________________________________________
opensolaris-discuss mailing list
opensolaris-discuss@opensolaris.org

Reply via email to