LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
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 09-22-2006, 06:08 AM   #1
garion
Member
 
Registered: Nov 2003
Posts: 35

Rep: Reputation: 15
mkisofs and directory relocation


Hi All!

Apparently I am missing something basic. I am trying to make a backup of number of data directories to DVD. I know that growisofs can pass parameters to mkisofs, but I would like to do things in two steps, so I am first calling mkisofs myself. I would like to include the full paths to the directories, but it seems that mkisofs is simply adding each specified directory onto the root.

The command I have looks like this:

mkisofs ${OPTIONS} -o ${DVD_DIR}/dvd_backup.iso -path-list ${PATH_LIST_FILE}

where

OPTIONS="-V Backup -volset $NOW -disable-deep-relocation -J -l -f -r -joliet-long"

and the ${PATH_LIST_FILE} contains:

/data/BACKUPS/config_backup.current.tgz
/data/MYSQL/dumps
/data/home/garion/Data
/data/home/garion/Mail
/data/home/garion/.kde

When I mount the ISO image to look at the contents, I see that the contents of these directories are in the root of the ISO FS. What I would like is to have the directories /data/MYSQL/dumps, /data/home/garion/Data, etc on the DVD.

When I add the -graft-points option and change the include list to things like this:

/data/MYSQL/dumps=/data/MYSQL/dumps

then obviously the directories are created as I expect. I was wondering if there was a simple option to mkisofs that says to create the directories "as is" without having to add the graft points like this.

- garion
 
Old 09-22-2006, 11:32 PM   #2
unreal128
Member
 
Registered: Jun 2003
Distribution: SuSE, Slackware, Gentoo
Posts: 207

Rep: Reputation: 30
The ${PATH_LIST_FILE} variable must not have any breaks in it; the argument must be one continuous line;
Code:
${PATH_LIST_FILE}="/data/BACKUPS/config_backup.current.tgz /data/MYSQL/dumps /data/home/garion/Data"
If you need it to reference a file, then make sure you strip all return carriages or new lines. If I am not understanding the question correctly, please try to restate for me or just post the code.
 
Old 09-23-2006, 03:53 AM   #3
garion
Member
 
Registered: Nov 2003
Posts: 35

Original Poster
Rep: Reputation: 15
Thanks for the reply.

${PATH_LIST_FILE} is actually a file which contains a list of the paths to include, with one file name or directory on each line. I guess I should have said that the ${PATH_LIST_FILE} variable contains the name of the file which contains the list of files and directories I want on the DVD.

The mkisofs says that the option "-path-list" is "A file containing a list of pathspec directories and filenames". I was not aware that you can have a list of the files to add following the -path-list option, which your post seems to imply as the shell would expand "-path-list ${PATH_LIST_FILE}" on the command line to:

mkisofs -V Backup_20060923.1527 -volset 20060923.1527 -J -l -f -r -D -joliet-long -o /data_SAVE/XFER/DVD_BACKUP/dvd_backup.iso -path-list /data/BACKUPS/config_backup.current.tgz /data/MYSQL/dumps /data/home/garion/Data

Which returns:

mkisofs: No such file or directory. Invalid node -

My assumption is that mkisofs is trying to read config_backup.current.tgz for the list of files, and thus cannot find a directory "node". Now I am even more confused.

What I am trying to do is have the full paths of the files directories copied to the DVD "as is" without being relocated to the root of the DVD. Using graft points works and is a viable solution if all else fails. I was looking at the mkisofs man-page and it has:

-D Do not use deep directory relocation, and instead just pack them in the way we see them.

I assumed that it meant to put them onto the DVD "as is". So, without having to specify graft points, is there a way to add the full path of the directories?
 
Old 09-24-2006, 06:35 PM   #4
unreal128
Member
 
Registered: Jun 2003
Distribution: SuSE, Slackware, Gentoo
Posts: 207

Rep: Reputation: 30
As a test, just specify one file instead of many. If that works then try enclosing the filenames in quotes...
-path-list "/data/BACKUPS/config_backup.current.tgz /data/MYSQL/dumps /data/home/garion/Data"

Post back the entire set of error messages; even try running the command in verbose mode if possible.
 
Old 09-25-2006, 10:19 AM   #5
garion
Member
 
Registered: Nov 2003
Posts: 35

Original Poster
Rep: Reputation: 15
saturn:/data/BACKUPS # mkisofs -V Backup_20060923.1527 -volset 20060923.1527 \
-J -l -f -r -D -joliet-long -o /data_SAVE/XFER/DVD_BACKUP/dvd_backup.iso \ -path-list /data/BACKUPS/config_backup.current.tgz
mkisofs: Warning: -follow-links does not always work correctly; be careful.
INFO: ISO-8859-1 character encoding detected by locale settings.
Assuming ISO-8859-1 encoded filenames on source filesystem,
use -input-charset to override.
mkisofs: No such file or directory. Invalid node -

The only option I found related to the verbosity was -quiet, which turns down the verbosity.
 
Old 09-26-2006, 12:55 AM   #6
unreal128
Member
 
Registered: Jun 2003
Distribution: SuSE, Slackware, Gentoo
Posts: 207

Rep: Reputation: 30
Try running the command like this; replace pathlistfilename.txt with the name of the file that contains your copy directories.
Code:
mkisofs -V Backup_20060923.1527 -volset 20060923.1527 -J -l -f -r -D -joliet-long -o /data_SAVE/XFER/DVD_BACKUP/dvd_backup.iso -path-list /pathlistfilename.txt
 
Old 10-02-2006, 05:54 AM   #7
garion
Member
 
Registered: Nov 2003
Posts: 35

Original Poster
Rep: Reputation: 15
I hate to appear ungrateful, but with the exception using the -D instead of -disable-deep-relocation and the order of the options, I see no difference between the last command and the command I was using at the very beginning. The result is the same. Unless I use the -graft-points option and specify the graft-points in the -path-list file, then the contents of the directories specified end up in the root directory of the CD. From what I see, we have basically gone full-circle. I have the same command I did at the beginning and I am not getting the complete paths.

Last edited by garion; 10-02-2006 at 05:58 AM.
 
  


Reply



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
mkisofs/max directory depth otoomet Linux - Software 0 12-21-2004 12:19 PM
mkisofs guldo Linux - Software 14 08-10-2004 01:58 PM
where is my mkisofs? slack66 Linux - Newbie 2 07-14-2004 02:27 AM
keeping the directory structure with mkisofs bignester Linux - Software 1 06-29-2003 12:11 PM
mkisofs Serena Linux - Newbie 1 04-24-2002 05:23 PM

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

All times are GMT -5. The time now is 01:31 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
Open Source Consulting | Domain Registration