See my notes below. On Thursday 14 September 2006 01:34, Richard Mortimer wrote: > Some data from my tests below. I'm working with current CVS (13/Sep) > plus a few patches to make relabel work (I don't think that they will > change behaviour of the second volume stuff). > > Note I've sent this data to bacula-devel and will post any follow-ups > there. > > Regards > > Richard > > > -----Original Message----- > > From: [EMAIL PROTECTED] > > [mailto:[EMAIL PROTECTED] On Behalf > > Of Scott Simpson > > Sent: 13 September 2006 16:11 > > To: bacula-users@lists.sourceforge.net > > Subject: [Bacula-users] DVD labeling not working on second volume > > > > Bacula CVS 2006-09-11 built from source > > > > I'm writing to a DVD. This works fine on the first DVD I > > write but when it > > fills up and I put the second DVD in and type "label" to > > bconsole, the > > storage daemon just sits there. When I do a "status" on the > > storage daemon I > > get > > I've just tried something similar. I ran a backup that needed a > second DVD. Instead of "label" I used "mount" and it just > auto-labelled the device and carried on. That tells me that > support for a second DVD is at least working at some level. > > If I try to "label" the second volume I get a slightly different > error. The label appears to work but when SD kicks in to try to > use the newly labelled volume it fails to open the new DVD > > shirehall-sd: dvd.c:248 == DVD mount=1 > shirehall-sd: dev.c:545 DVD device mounted. > shirehall-sd: dvd.c:881 check_can_write_on_non_blank_dvd: found . (versus > OldelvetDVD0102) > shirehall-sd: dvd.c:881 check_can_write_on_non_blank_dvd: found .. (versus > OldelvetDVD0102) > shirehall-sd: dvd.c:881 check_can_write_on_non_blank_dvd: found > OldelvetDVD0102 (versus OldelvetDVD0102) > shirehall-sd: dvd.c:898 check_can_write_on_non_blank_dvd: size of > /export/bacula-dvd/OldelvetDVD0102 is 210 > shirehall-sd: dvd.c:877 check_can_write_on_non_blank_dvd: no more files in > dir /export/bacula-dvd (dev="DVDStorage" (/dev/cdrw)) > shirehall-sd: dvd.c:913 OK can_write_on_non_blank_dvd: got 3 files in the > mount point (matched=0) > shirehall-sd: dvd.c:94 Enter unmount_dvd > shirehall-sd: dvd.c:126 do_mount_dvd: cmd=/bin/umount /export/bacula-dvd > mounted=1 > shirehall-sd: dvd.c:137 Run mount prog=/bin/umount /export/bacula-dvd > shirehall-sd: dvd.c:237 Out of mount/umount loop > shirehall-sd: dvd.c:248 == DVD mount=0 > shirehall-sd: dev.c:297 preserve=0x0 fd=-1 > shirehall-sd: mount.c:168 open_device failed > > It then tries to create acquire another volume and marks the freshly > labelled volume as being in error. Looking at the label on the volume > it looks reasonable. I'll take a more detailed look tomorrow. >
There is a good chance that it is the check_can_write_on_non_blank_dvd() that is getting in the way. I never have liked this subroutine, though I can reluctantly admit to the necessity, but it has never had "proper" code to ensure that it is only called at the right time. I have had this on my todo list for some time, and I suspect that after the code reorganization I did last time, this will not be too hard. If you are interested in trying to tweak this, I suspect that you can just add an additional test to the if that is around the check_can_write. It should not enter the code if we are going to append (mode != OPEN_READ_ONLY). ------------------------------------------------------------------------- Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 _______________________________________________ Bacula-users mailing list Bacula-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/bacula-users