LinuxQuestions.org
Support LQ: Use code LQ3 and save $3 on Domain Registration
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 09-22-2010, 09:31 PM   #1
iBasher
LQ Newbie
 
Registered: Sep 2010
Posts: 16

Rep: Reputation: 0
How do I make a mountable image of directories


Hi guys! I'm a newbie and am learning bash. I have a couple of directories that I want to turn into an image. For example:

Quote:
/usr/dir1
/usr/dir2
I want to end up with two imgs (dir1.img and dir2.img). I wanna be able to type in:
Quote:
mkdir /usr/dir1
mount dir1.img /usr/dir1
How can I do that? If I can't use mount than what should I use?
 
Old 09-22-2010, 09:40 PM   #2
Tinkster
Moderator
 
Registered: Apr 2002
Location: in a fallen world
Distribution: slackware by choice, others too :} ... android.
Posts: 23,066
Blog Entries: 11

Rep: Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910
Hi, welcome to LQ!

Have a read of
Code:
man mount
/loop

Cheers,
Tink
 
Old 09-23-2010, 01:11 AM   #3
prayag_pjs
Senior Member
 
Registered: Feb 2008
Location: Pune - India
Distribution: Fedora,RedHat,CentOS,Gentoo
Posts: 1,138
Blog Entries: 4

Rep: Reputation: 147Reputation: 147
You mean to say an ISO image;

if so then

To create an ISO image:
Code:
mkisofs -o dir1.iso /usr/dir1
To mount an ISO image
Code:
mount -o loop dir1.iso /usr/dir1

Last edited by prayag_pjs; 09-23-2010 at 01:13 AM.
 
Old 09-26-2010, 10:35 PM   #4
iBasher
LQ Newbie
 
Registered: Sep 2010
Posts: 16

Original Poster
Rep: Reputation: 0
Thanks I'll try both
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Zoneminder alternative image directories metallica1973 Linux - Software 2 08-26-2013 03:58 PM
how to edit a disk image to make it mountable woody weaver Linux - General 4 11-09-2009 05:19 PM
PHP calling image directories jus71n742 Programming 3 01-24-2009 02:42 AM
Create a mountable disk image of Windows partition tnine9 Linux - Desktop 3 08-10-2008 08:13 PM
Slackware 11.0 CD2 ISO image mountable, but physical CD not gargamel Slackware 16 10-27-2006 08:13 PM


All times are GMT -5. The time now is 12:56 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration