On Mon, 1 Oct 2001, Timothy Shimmin wrote:
> Hi Charles,
> On Fri, Sep 28, 2001 at 03:42:47PM +0200, Charles Radeke wrote:
> > I would like to backup a partition of some GB by burning cd's with
> > splitted xfsdump , each is 650MB. Is it possible to use a cdrom-drive as
> > a tape (like/dev/rmt)? and if, how to simulate the tape change?
> So what are possible solutions ?
> (b) write your own drive strategy for xfsdump/xfsrestore :)
This option might not be as hard as it looks. All you really want is
to be able to specify the media file size and to allow for a prompt for
new media when you get ENOSP in the drive_simple strategy. So
- copy the drive_simple.c to drive_cdrom.c
- modify it so that references to drive_simple become drive_cdrom
- insert the new strategy into strategypp in drive.c (before
- modify drive_cdrom.c:ds_match() to do something clever like check we're
writing to a device
- work out how you can incorporate the change media stuff that's in
drive_scsitape.c (or perhaps drive_minrmt.c might be simpler?). Do a
search on "changemedia" in dump/content.c, do_get_device_class()
in drive_simple.c and DEVICE_DISK_REMOVABLE in drive.h.
Note: I haven't looked into this at all, so I'm very probably missing
some fundamental problems. In other words, don't blame me if you waste
weeks of your life on this... :)