Koozali.org: home of the SME Server

Backup to DVD is locked out

markfarey

Backup to DVD is locked out
« on: August 04, 2007, 03:05:27 AM »
I am running the CD Backup Extension for SME (cd-utils) to backup to DVD. However, I rebooted shortly after starting the backup process. Now, when I visit the server manager it reports, "A CD/DVD backup is in progress", even though I'm pretty sure it's not running.

Can anyone please tell me how to recover from this so that backups are again enabled? I've rebooted repeatedly and tried resetting various parts of the e-smith database using (e.g.) "/sbin/e-smith/db configuration setprop cdbackup status idle", but to no avail.

Can anyone help please, I'm really stuck?

Regards to all,
Mark.

Offline Jáder

  • *
  • 1,099
  • +0/-0
    • LinuxFacil
Backup to DVD is locked out
« Reply #1 on: August 04, 2007, 02:03:11 PM »
Hi

Plase remove the file /etc/e-smith/cdutils
It contains the CD/DVD status and will looks like:

-------------------------------------------------
# DO NOT MODIFY THIS FILE.
# This file is automatically maintained by the Mitel Networks SME Server
# configuration software. Manually editing this file may put your
# system in an unknown state.
#
# updated: Mon Dec 22 17:04:23 2003
cdutils=status|error||finish|1072119830|start|1072119818|state|idle|type|backup
-------------------------------------------------

BTW: Do you have it working on SME7 ?
Do you mind to share your package/rpm (I can try to build a RPM if you send me a tar file!)
...

markfarey

Backup to DVD is locked out
« Reply #2 on: August 05, 2007, 01:45:40 AM »
Hi,

Many thanks for the fix. It cleared the hangup and I was able to restart the backup. However it failed after about 12 minutes (19:14:52 onwards). Here's the logs. I see that it fails with:
ERROR: error occurred while burning CD at /opt/cd_utils/cd_backup.pl line 188

That part of the script reads:
#############################################
# Burn the CD
#############################################
#print "$MKISOFS -quiet -J -R -A CDBU_$DATE_STR -V CDBU_$DATE_STR $CD_STAGING_DIR/Data-$DATE_STR.tar.gz $CD_STAGING_DIR/index-$DATE_STR.txt.gz | $CDRECORD_BURN -waiti speed=$WRITE_SPEED dev=$DEVICE tsize=${backup_size}k - > /tmp/cdbackup.out 2>/tmp/cdbackup.err ";
if (system("$MKISOFS -quiet -J -R -A CDBU_$DATE_STR -V CDBU_$DATE_STR $CD_STAGING_DIR/Data-$DATE_STR.tar.gz $CD_STAGING_DIR/toc-$DATE_STR.txt.gz | $CDRECORD_BURN -waiti speed=$WRITE_SPEED dev=$DEVICE tsize=${backup_size}k - > /tmp/cdbackup.out 2>/tmp/cdbackup.err ") != 0)
{
  system("$CDRECORD dev=$DEVICE -eject 2>&1 > /dev/null") if $EJECT_ON_BACKUP eq "true";
  die ("ERROR: error occurred while burning CD");
}

I believe I left a blank DVD in the drive, but am now working off site and cannot check that until Tuesday. Does it look like the DVD is missing to you? What about other errors in the log?

BTW, I had to add: ln -sf /dev/hda /dev/pg0 to get the application to run at all, since I understand /dev/pg0 is missing in this release. Have you tried that? Any other insight?

Regards,
Mark.


Aug  4 19:03:13 server /etc/e-smith/web/panels/manager/cgi-bin/cd_backup[9651]: /etc/e-smith/cdutils: OLD cdutils=status|error||finish|1186268389|start|1186268389|state|idle|type|backup
Aug  4 19:03:13 server /etc/e-smith/web/panels/manager/cgi-bin/cd_backup[9651]: /etc/e-smith/cdutils: NEW cdutils=status|error||finish|1186268389|start|1186268389|state|running|type|backup
Aug  4 19:03:13 server /etc/e-smith/web/panels/manager/cgi-bin/cd_backup[9651]: /etc/e-smith/cdutils: OLD cdutils=status|error||finish|1186268389|start|1186268389|state|running|type|backup
Aug  4 19:03:13 server /etc/e-smith/web/panels/manager/cgi-bin/cd_backup[9651]: /etc/e-smith/cdutils: NEW cdutils=status|error||finish|1186268389|start|1186268593|state|running|type|backup
Aug  4 19:03:13 server esmith::event[9653]: Processing event: cdutils-backup  
Aug  4 19:03:13 server esmith::event[9653]: Running event handler: /etc/e-smith/events/cdutils-backup/S10cdutils-backup
Aug  4 19:03:17 server esmith::event[9666]: Processing event: pre-cd-backup  
Aug  4 19:03:17 server esmith::event[9666]: Running event handler: /etc/e-smith/events/pre-cd-backup/S10mysql-delete-dumped-tables
Aug  4 19:03:17 server esmith::event[9666]: S10mysql-delete-dumped-tables=action|Event|pre-cd-backup|Action|S10mysql-delete-dumped-tables|Start|1186268597 597006|End|1186268597 600189|Elapsed|0.003183
Aug  4 19:03:17 server esmith::event[9666]: Running event handler: /etc/e-smith/events/pre-cd-backup/S20mysql-dump-tables
Aug  4 19:03:17 server esmith::event[9666]: /etc/e-smith/events/pre-cd-backup/S20mysql-dump-tables: line 12: mysql: No such file or directory  
Aug  4 19:03:17 server esmith::event[9666]: S20mysql-dump-tables=action|Event|pre-cd-backup|Action|S20mysql-dump-tables|Start|1186268597 600500|End|1186268597 650890|Elapsed|0.05039
Aug  4 19:03:17 server esmith::event[9666]: Running event handler: /etc/e-smith/events/pre-cd-backup/S25gentle-ldap-dump
Aug  4 19:03:17 server slapcat: bdb_initialize: Sleepycat Software: Berkeley DB 4.2.52: (December  3, 2003)
Aug  4 19:03:17 server slapcat: bdb_initialize: Sleepycat Software: Berkeley DB 4.2.52: (December  3, 2003)
Aug  4 19:03:17 server slapcat: /etc/openldap/slapd.conf: line 18: schema checking disabled! your mileage may vary!
Aug  4 19:03:18 server esmith::event[9666]: S25gentle-ldap-dump=action|Event|pre-cd-backup|Action|S25gentle-ldap-dump|Start|1186268597 651102|End|1186268598 82565|Elapsed|0.431463
Aug  4 19:14:52 server esmith::event[9653]: WARNING: Cannot determine media capacity - assuming it is DVD(4.38G)..../usr/bin/mkisofs: Value too large for defined data type. File /tmp/Data-07_08_04.tar.gz is too large - ignoring  
Aug  4 19:14:52 server esmith::event[9653]: /usr/bin/mkisofs: Value too large for defined data type. File /tmp/Data-07_08_04.tar.gz is too large - ignoring  
Aug  4 19:14:52 server esmith::event[9653]: /usr/bin/mkisofs: Broken pipe. cannot fwrite 2048*1  
Aug  4 19:14:52 server esmith::event[9653]: scsidev: '0,0,0'  
Aug  4 19:14:52 server esmith::event[9653]: scsibus: 0 target: 0 lun: 0  
Aug  4 19:14:52 server esmith::event[9653]: /usr/bin/cdrecord: Found DVD media: using cdr_mdvd.  
Aug  4 19:14:57 server esmith::event[9653]: ERROR: error occurred while burning CD at /opt/cd_utils/cd_backup.pl line 188.  
Aug  4 19:14:57 server /etc/e-smith/events/cdutils-backup/S10cdutils-backup[9654]: /etc/e-smith/cdutils: OLD cdutils=status|error||finish|1186268389|start|1186268593|state|running|type|backup
Aug  4 19:14:57 server /etc/e-smith/events/cdutils-backup/S10cdutils-backup[9654]: /etc/e-smith/cdutils: NEW cdutils=status|error||finish|1186268389|start|1186268593|state|error|type|backup
Aug  4 19:14:57 server /etc/e-smith/events/cdutils-backup/S10cdutils-backup[9654]: /etc/e-smith/cdutils: OLD cdutils=status|error||finish|1186268389|start|1186268593|state|error|type|backup
Aug  4 19:14:57 server /etc/e-smith/events/cdutils-backup/S10cdutils-backup[9654]: /etc/e-smith/cdutils: NEW cdutils=status|error||finish|1186269297|start|1186268593|state|error|type|backup
Aug  4 19:14:57 server /etc/e-smith/events/cdutils-backup/S10cdutils-backup[9654]: /etc/e-smith/cdutils: OLD cdutils=status|error||finish|1186269297|start|1186268593|state|error|type|backup
Aug  4 19:14:57 server /etc/e-smith/events/cdutils-backup/S10cdutils-backup[9654]: /etc/e-smith/cdutils: NEW cdutils=status|error|Error occurred during backup - see /var/log/messages and /tmp/*.err files|finish|1186269297|start|1186268593|state|error|type|backup
Aug  4 19:14:57 server esmith::event[9653]: Error occurred during backup - see /var/log/messages and /tmp/*.err files  
Aug  4 19:14:57 server esmith::event[9653]: ErrorMessage: Error occurred during backup - see /var/log/messages and /tmp/*.err files  
Aug  4 19:14:57 server esmith::event[9653]: S10cdutils-backup=action|Event|cdutils-backup|Action|S10cdutils-backup|Start|1186268593 846149|End|1186269297 337488|Elapsed|703.491339|Status|2304
Aug  4 19:25:24 server /etc/e-smith/web/panels/manager/cgi-bin/cd_backup[9719]: /etc/e-smith/cdutils: OLD cdutils=status|error|Error occurred during backup - see /var/log/messages and /tmp/*.err files|finish|1186269297|start|1186268593|state|error|type|backup
Aug  4 19:25:24 server /etc/e-smith/web/panels/manager/cgi-bin/cd_backup[9719]: /etc/e-smith/cdutils: NEW cdutils=status|error|Error occurred during backup - see /var/log/messages and /tmp/*.err files|finish|1186269297|start|1186268593|state|idle|type|backup
Aug  4 19:25:24 server /etc/e-smith/web/panels/manager/cgi-bin/cd_backup[9719]: /etc/e-smith/cdutils: OLD cdutils=status|error|Error occurred during backup - see /var/log/messages and /tmp/*.err files|finish|1186269297|start|1186268593|state|idle|type|backup
Aug  4 19:25:24 server /etc/e-smith/web/panels/manager/cgi-bin/cd_backup[9719]: /etc/e-smith/cdutils: NEW cdutils=status|error||finish|1186269297|start|1186268593|state|idle|type|backup

Offline Jáder

  • *
  • 1,099
  • +0/-0
    • LinuxFacil
Backup to DVD is locked out
« Reply #3 on: August 05, 2007, 02:35:56 PM »
Worth to try :
1) verify cdbackup.err and cdbackup.log searching for error reports
2) be sure backup file generated (compressed on /tmp!) is smaller than your media
3) if you're off site, try to mount DVD on linux shell
4) try this commands:
Code: [Select]
cdrecord -dev=0,0,0 -toc
cdrecord -dev=0,0,0 -atip

report results from "cdrecord -scanbus" and verify this device (1,0,0 or 0,0,0) is configurated on web interface.
...