LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 02-23-2017, 02:03 PM   #1
SaintDanBert
Senior Member
 
Registered: Jan 2009
Location: Austin, TX
Distribution: Mint-17.3 with Cinnamon & KDE
Posts: 1,684
Blog Entries: 3

Rep: Reputation: 105Reputation: 105
can't seem to create an ISO from a folder tree



APOLOGY IN ADVANCE
I know that I've posted several items about ISO images, but I continue to struggle. One reason includes my limited time to play-with/work-on new things at the expense of other "more important" efforts. I hope the moderators will be kind.

I know there is a loose nut in my end-user's chair, so I hope someone here can help me. This is Linux so I suppose that I could take apart the process for making my own distribution ISO, but I hope it does not come to that.

I'm trying to create an ISO file that contains a complete folder tree of files. I can create the tree of folders and files, no problem. I can launch k3b or brassero, but then I can't get a mountable ISO file as results.

One of my complaints is that these tools expect a DVD as output and complain if my folder tree contents are too large. Do I need a blu-ray writer utility?

Another complaint is that (blush) I can't seem to wrap around the options for the command line tools like genisoimage (still blushing).

For those inquiring minds, I have loads of reference material as document files in various formats. Depending on the document format, there may be associated image files. A few documents are "slide shows" with associated images and audio. (gulp) Video is right around the corner. (/gulp)

Thanks in advance,
~~~ 0;-Dan

Last edited by SaintDanBert; 02-23-2017 at 02:04 PM. Reason: typo &c
 
Old 02-23-2017, 02:49 PM   #2
szboardstretcher
Senior Member
 
Registered: Aug 2006
Location: Detroit, MI
Distribution: GNU/Linux systemd
Posts: 4,237

Rep: Reputation: 1654Reputation: 1654Reputation: 1654Reputation: 1654Reputation: 1654Reputation: 1654Reputation: 1654Reputation: 1654Reputation: 1654Reputation: 1654Reputation: 1654
If you aren't opposed to using the command line instead of some gui then this process should net you a good iso. We will try it on a small directory to test it out.

Code:
mkdir /mydir
mkdir /mnt/iso_mount
for i in {1..1000}; do dd if=/dev/urandom bs=1 count=10 of=/mydir/file$i; done
genisoimage -o my.iso -V my_volume_label -r /mydir
file my.iso
mount -t iso9660 -o loop my.iso  /mnt/iso_mount/
cd /mnt/iso_mount
ls
Notice the line 'file my.iso'.. that will return this:

Quote:
my.iso: # ISO 9660 CD-ROM filesystem data 'my_volume_label'
Which indicates it is a valid ISO.
 
1 members found this post helpful.
Old 02-23-2017, 03:11 PM   #3
SaintDanBert
Senior Member
 
Registered: Jan 2009
Location: Austin, TX
Distribution: Mint-17.3 with Cinnamon & KDE
Posts: 1,684

Original Poster
Blog Entries: 3

Rep: Reputation: 105Reputation: 105
Quote:
Originally Posted by szboardstretcher View Post
If you aren't opposed to using the command line instead of some gui then this process should net you a good iso. We will try it on a small directory to test it out.
...
So the for-loop uses dd to create a bunch of 10-block files for the test...

I want to use dd to snarf an entire USB stick or other external drive:
Code:
prompt$ sudo dd bs=4096 if={usb_device}  of=drive.img
Then create an ISO of what I get.

Thanks in advance,
~~~ 0;-Dan
 
Old 02-23-2017, 03:21 PM   #4
szboardstretcher
Senior Member
 
Registered: Aug 2006
Location: Detroit, MI
Distribution: GNU/Linux systemd
Posts: 4,237

Rep: Reputation: 1654Reputation: 1654Reputation: 1654Reputation: 1654Reputation: 1654Reputation: 1654Reputation: 1654Reputation: 1654Reputation: 1654Reputation: 1654Reputation: 1654
This is the only line you will need:

Code:
genisoimage -o my.iso -V my_volume_label -r /mydir
The rest was to demonstrate that it works. Here is a breakdown of what this line means:

Code:
# Name the outputted iso my.iso
-o my.iso
# Set the volume label to my_volume_label
-V my_volume_label
# Create the ISO using the files at /mydir
-r /mydir
So you would need to change those variables to fit your need.
 
Old 02-23-2017, 04:53 PM   #5
Shadow_7
Senior Member
 
Registered: Feb 2003
Distribution: debian
Posts: 4,057
Blog Entries: 1

Rep: Reputation: 864Reputation: 864Reputation: 864Reputation: 864Reputation: 864Reputation: 864Reputation: 864
Some guy had written a script to do an iso image from any linux install long ago. Or any debian based one it seems. Also seems like a lot of distros have "ways" of doing this in the distro now.

https://en.wikipedia.org/wiki/Remastersys

Which forked to Respin it seems. Although PDK seems more along the lines of what I found many moons ago for this task. Although I never used it, it was a relatively simple bash script at the time. So maybe not pdk which seems to have a lot of python. So many options now. And not as simple as it once was with a new init system and bios options.

https://github.com/64studio/pdk
 
1 members found this post helpful.
Old 02-24-2017, 03:15 PM   #6
SaintDanBert
Senior Member
 
Registered: Jan 2009
Location: Austin, TX
Distribution: Mint-17.3 with Cinnamon & KDE
Posts: 1,684

Original Poster
Blog Entries: 3

Rep: Reputation: 105Reputation: 105
Quote:
Originally Posted by szboardstretcher View Post
This is the only line you will need:
Code:
genisoimage -o my.iso -V my_volume_label -r /mydir
The rest was to demonstrate that it works.
...
So you would need to change those variables to fit your need.
The part -r /mydir names a folder with a tree of files and folders below it. My previous 'dd' example resulted in a single file, drive.img.

If I name the top level folder -- mount point -- of the usb-device, the ISO will contain all of the file system "data" files and associated folders. Using 'dd' to create 'drive.img' gets all of the device bits in addition to the "data" files and folders. There are only rare times that I care about these extra details, but I need them when I do care.

Follow-up
I'm not a digital music guy, but is this similar or identical to what folks are doing when they talk about "ripping a CD" or otherwise putting CD music into an ISO file?


I guess the short answer says to use the device mount point as input to genisoimage and find a way to process the extra bits as the exception that they really are. That processing might involve making an ISO from a "drive.img" file.

Thanks in advance,
~~~ 0;-Dan

Last edited by SaintDanBert; 02-24-2017 at 03:20 PM.
 
Old 02-24-2017, 03:26 PM   #7
szboardstretcher
Senior Member
 
Registered: Aug 2006
Location: Detroit, MI
Distribution: GNU/Linux systemd
Posts: 4,237

Rep: Reputation: 1654Reputation: 1654Reputation: 1654Reputation: 1654Reputation: 1654Reputation: 1654Reputation: 1654Reputation: 1654Reputation: 1654Reputation: 1654Reputation: 1654
Quote:
I'm trying to create an ISO file that contains a complete folder tree of files.
An explanation like mine allows you to take a "folder tree of files" and put them into a file called an ISO. This is called 'making an ISO' as far as I know.

Quote:
I'm not a digital music guy, but is this similar or identical to what folks are doing when they talk about "ripping a CD" or otherwise putting CD music into an ISO file?
That is called "ripping a CD" and essentially means take a CDROM and all of its data and make an 'image' of it called an ISO file.

Huge difference between generating an ISO from a file list, and generating an ISO file from a dd image. You can read more about the differences with some google searching. Hope that gets you started in the right direction.
 
1 members found this post helpful.
Old 02-24-2017, 06:12 PM   #8
SaintDanBert
Senior Member
 
Registered: Jan 2009
Location: Austin, TX
Distribution: Mint-17.3 with Cinnamon & KDE
Posts: 1,684

Original Poster
Blog Entries: 3

Rep: Reputation: 105Reputation: 105
Well, I think that I found a solution:
Code:
prompt$  # first, install the package acetoneiso
sudo apt-get install acetoneiso
...

prompt$  # get some supporting utilities
prompt$  sudo apt-get install bchunk ccd2iso mdf2iso nrg2iso or sudo aptitude install bchunk ccd2iso mdf2iso nrg2iso
...

prompt$  # then make an ISO from your IMG
prompt$  ccd2iso source.img destination.iso
Once I've had a chance to play with this, I'll report back.
Follow-Up:
It seems that ccd2iso is looking for dot-img files that are something WinXX and Mac specific other than what I can create with
Code:
prompt$  dd ... of=/path/something.img

By the way, there appear to be many more features in acetoneiso. Again, I'll report back.

Thanks to all,
~~~ 0;-Dan

Last edited by SaintDanBert; 02-27-2017 at 01:36 PM.
 
  


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
[ANN] mk-slack64-multilib : A tool to create slackware64+multilib tree/iso phenixia2003 Slackware 5 12-28-2012 05:42 AM
create bootable iso from linux folder using windows AsimAli Linux From Scratch 2 11-15-2008 07:18 PM
Create bootable iso from linux folder using windows or boot from win bootloader AsimAli Linux - Newbie 1 11-15-2008 11:25 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 09:40 AM.

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