Hi, Bob McGowan wrote: > One question, what I would like to see is a duplicated directory/file > hierachy on the destination. I have lists of file names in groups just > short of 25G, but I can't find an easy way to send the file names to > any of the programs and have them maintain the hierarchy. They just > dump all the files in the root of the destination. > > I did manage this for a few files with 'xorriso -update_r' option used > once per file name and with the full destination path and file name > listed: > > xorriso -update_r /home/me/topdir/file /topdir/file ... > > But doing this for thousands of files doesn't seem like it is a > manageable or robust solution.
It's not unfeasible. man xorriso says: -options_from_file fileaddress Read quoted input from fileaddress and execute it like dialog lines. Empty lines and lines which begin by # are ignored. Normally one line should hold one xorriso command and all its parameters. Nevertheless lines may be concatenated by a trailing backslash. See also section "Command processing", paragraph "Quoted input". That paragraph says: Quoted input converts whitespace-separated text into words. The double quotation mark " and the single quotation mark ' can be used to enclose whitespace and make it part of words (e.g. of file names). Each mark type can enclose the marks of the other type. A trailing backslash \ outside quotations or an open quotation cause the next input line to be appended. [...] So you may quote whitespace like blanks, tabs or newline characters like in the shell: -update_r "/home/me/topdir/filename with blanks" "/topdir/filename with blanks" ...more.update_r.commands... Since you seem not to strive for adding sessions to already existing ISO 9660 filesystems, you may also use -map or -map_single : -map "/home/me/topdir/filename with blanks" "/topdir/filename with blanks" ...more.map.commands... about which the man page says: -map disk_path iso_rr_path Insert file object disk_path into the ISO image as iso_rr_path. If disk_path is a directory then its whole sub tree is inserted into the ISO image. -map_single disk_path iso_rr_path Like -map, but if disk_path is a directory then its sub tree is not inserted. I.e. these two commands do not ponder whether the iso_rr_path already leads to an up-to-date version of the file in the ISO filesystem, but rather copy disk_path to iso_rr_path unconditionally. You would write all intended xorriso commands into a disk file, e.g. /home/me/xorriso_commands and then let xorriso process it by command -options_from_file like in: xorriso \ -for_backup \ -outdev /dev/sr0 \ -blank as_needed \ -options_from_file /home/me/xorriso_commands \ -commit -toc -check_md5 FAILURE -- -eject all ----------------------------------------------------------------------- Another approach is to create a file with a list of pathspecs which are a concept from program mkisofs: -path_list disk_path Like -add but read the parameter words from file disk_path or standard input if disk_path is "-". The list must contain exactly one pathspec or disk_path pattern per line. The command -add inserts files into the emerging ISO image in a way that is usual with mkisofs: -add pathspec [...] | disk_path [***] Insert the given files or directory trees from filesystem into the ISO image. If -pathspecs is set to "on" or "as_mkisofs" then pattern expansion is always disabled and character '=' has a special meaning. It separates the ISO image path from the disk path: iso_rr_path=disk_path Character '=' in the iso_rr_path must be escaped by '\' (i.e. as "\="). With -pathspecs "on", the character '\' must not be escaped. The character '=' in the disk_path must not be escaped. With -pathspecs "as_mkisofs", all characters '\' must be escaped in both, iso_rr_path and disk_path. The character '=' may or may not be escaped in the disk_path. If iso_rr_path does not begin with '/' then -cd is prepended. If disk_path does not begin with '/' then -cdx is prepended. If no '=' is given then the word is used as both, iso_rr_path and disk path. If in this case the word does not begin with '/' then -cdx is prepended to the disk_path and -cd is prepended to the iso_rr_path. ... -pathspecs "on"|"off"|"as_mkisofs" Control parameter interpretation with xorriso actions -add and -path_list. Mode "as_mkisofs" enables pathspecs of the form iso_rr_path=disk_path like with program mkisofs -graft-points. ... With this approach you would write lines like /topdir/file=/home/me/topdir/file /topdir/filename with blanks=/home/me/topdir/filename with blanks /topdir/filename with \= in it=/home/me/topdir/filename with = in it into a disk file, e.g. /home/me/xorriso_pathspecs and perform in -path_list xorriso: xorriso \ -for_backup \ -outdev /dev/sr0 \ -blank as_needed \ -pathspecs as_mkisofs \ -path_list /home/me/xorriso_pathspecs \ -commit -toc -check_md5 FAILURE -- -eject all ----------------------------------------------------------------------- How i handle my larger backups: I assume that you want to split a larger collection of files into groups which fit on the BD media. Nearly half a life ago, my own endeavor with ISO 9660 and optical media began with creating a tool which does this splitting automatically: http://scdbackup.webframe.org/main_eng.html http://scdbackup.webframe.org/examples.html BD is configured and handled by the DVD configuration and commands of scdbackup. Once: ./CONFIGURE_DVD With each backup, you'd do something like: sdvdbackup /topdir=/home/me/topdir -not /home/me/topdir/temp_files Back then there was only mkisofs for producing ISO 9660. So sdvdbackup uses its pathspecs notation for defining the mapping from disk to BD. Of course i meanwhile use xorriso for the roles of cdrecord, growisofs and mkisofs. I'm still backing up multi-media file collections by help of sdvdbackup. Backups which fill dozens of media might become lengthy. So there is also the opportunity to perform incremental backups: http://scdbackup.webframe.org/examples.html#incremental ----------------------------------------------------------------------- Have a nice day :) Thomas