Jump to content

mount ISO files as virtual driver


aze
 Share

Recommended Posts

hi all! i´m trying to mount a iso image in ml9.1:

 

[root@192 hosts]# mount -o loop -t iso9660 /mnt/win_e/aa-20030513.iso /mnt/virtual

mount: mount point /mnt/virtual does not exist

 

what should i do~to make it work? thanks!

Link to comment
Share on other sites

Before you do the above (which looks fine) you just need to mkdir /mnt/virtual

As it stands you will only be able to access it as root.

 

If thats OK for your purpose then go ahead but be advised most CD apps (XCDRoast) for instance specifically wanr you about running as root.

 

If its a one off (this isn't elegant and for this situaiton only).

chmod 777 /mnt/virtual and add under options -o loop,user

 

Im at work on windows so you might wanna check this with the man mount :-)

Link to comment
Share on other sites

Here are 3 aliases I define for dealing with CD's and ISO images.. Put them in a file, chmod 755 it, and stick in your /etc/profile.d folder. They will always be available..

 

# ISO aliases

# mountiso isofile.iso mountpoint

# cd2iso isofile.iso

# makeiso isofile.iso directorytoISO

function mountiso() { mount -t iso9660 -o loop -rw $1 $2; cd $2; }

function cd2iso() { dd if=/dev/hdb of=$1; }

function makeiso() { mkisofs -r -J -o $1 $2; } function

Link to comment
Share on other sites

none of them are aliases! they are functions!!

 

~$ help alias                                                                      

alias: alias [-p] [name[=value] ... ]

   `alias' with no arguments or with the -p option prints the list

   of aliases in the form alias NAME=VALUE on standard output.

   Otherwise, an alias is defined for each NAME whose VALUE is given.

   A trailing space in VALUE causes the next word to be checked for

   alias substitution when the alias is expanded.  Alias returns

   true unless a NAME is given for which no alias has been defined.

~$ help function

function: function NAME { COMMANDS; } or NAME () { COMMANDS; }

   Create a simple command invoked by NAME which runs COMMANDS.

   Arguments on the command line along with NAME are passed to the

   function as $0 .. $n.

I couldn't resist :roll:

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

×
×
  • Create New...