[SOLVED] System Backups

Moderator: crythias

Locked
mcrognale
Znuny newbie
Posts: 7
Joined: 22 Apr 2014, 16:04
Znuny Version: 3.3.6
Real Name: Matt Crognale
Company: Industry Weapon, Inc.

[SOLVED] System Backups

Post by mcrognale »

I'm having a bit of trouble backing up the OTRS appliance. I can run /sbin/backup.pl from the command line and it dumps the ISO into /BACKUP as expected. The problem occurs when I attempt to run the backup through cron:

0 4 * * * /usr/bin/perl /sbin/backup.pl

I get this error in syslog:

(CRON) error (grandchild #23797 failed with exit status 255)

And this is what shows up in /var/log/backup.log

2014/05/01 09:46:01 exmsg DEBUG> Locale is en_US.UTF-8.
2014/05/01 09:46:01 main DEBUG> Reading settings from file /etc/essex/settings.properties
2014/05/01 09:46:01 main DEBUG> LINE: bootmode=harddisk
2014/05/01 09:46:01 main DEBUG> Key: <bootmode> Value: <harddisk>
2014/05/01 09:46:01 main INFO> Bootmode is harddisk
2014/05/01 09:46:02 main INFO> INIT COMPLETE: EXTERNAL BACKUP MEDIA 0 MB, BACKUP FILES 712 MB, BACKUP PARTITION 22174 MB
2014/05/01 09:46:02 main INFO> Executing: lvcreate -l +50%FREE -s -n NODE_SNAP /dev/vg/NODE
2014/05/01 09:46:02 main ERROR> Returned error: -1
2014/05/01 09:46:02 main FATAL> UNKNOWN ERROR
2014/05/01 09:46:02 main INFO> Executing: umount /mnt/NODE_SNAP
2014/05/01 09:46:02 main DEBUG> [>] output: --------------------
umount: /mnt/NODE_SNAP: not mounted
2014/05/01 09:46:02 main DEBUG> [<] output: --------------------
2014/05/01 09:46:02 main ERROR> Returned error: 256
2014/05/01 09:46:02 main INFO> Executing: umount /mnt/SHARE_SNAP
2014/05/01 09:46:02 main DEBUG> [>] output: --------------------
umount: /mnt/SHARE_SNAP: not mounted
2014/05/01 09:46:02 main DEBUG> [<] output: --------------------
2014/05/01 09:46:02 main ERROR> Returned error: 256
2014/05/01 09:46:02 main INFO> Executing: lvremove -f /dev/vg/NODE_SNAP
2014/05/01 09:46:02 main ERROR> Returned error: -1
2014/05/01 09:46:02 main INFO> Executing: lvremove -f /dev/vg/SHARE_SNAP
2014/05/01 09:46:02 main ERROR> Returned error: -1
2014/05/01 09:46:02 main FATAL> CANCLE EXIT: unknown_error 255
Last edited by mcrognale on 05 May 2014, 18:15, edited 1 time in total.
crythias
Moderator
Posts: 10170
Joined: 04 May 2010, 18:38
Znuny Version: 5.0.x
Location: SouthWest Florida, USA
Contact:

Re: System Backups

Post by crythias »

what user is running cron? Make sure it's the otrs user.
OTRS 6.0.x (private/testing/public) on Linux with MySQL database.
Please edit your signature to include your OTRS version, Operating System, and database type.
Click Subscribe Topic below to get notifications. Consider amending your topic title to include [SOLVED] if it is so.
Need help? Before you ask
mcrognale
Znuny newbie
Posts: 7
Joined: 22 Apr 2014, 16:04
Znuny Version: 3.3.6
Real Name: Matt Crognale
Company: Industry Weapon, Inc.

Re: System Backups

Post by mcrognale »

It's running as the root user. I get all kind of permission denied errors when I attempt to run the script as the otrs user. It will only successfully backup running as root from the command line.
crythias
Moderator
Posts: 10170
Joined: 04 May 2010, 18:38
Znuny Version: 5.0.x
Location: SouthWest Florida, USA
Contact:

Re: System Backups

Post by crythias »

I'm not sure how the appliance works. I thought the otrs backup utility was within /opt/otrs. Please excuse the interruption. Perhaps someone else might be of assistance.
OTRS 6.0.x (private/testing/public) on Linux with MySQL database.
Please edit your signature to include your OTRS version, Operating System, and database type.
Click Subscribe Topic below to get notifications. Consider amending your topic title to include [SOLVED] if it is so.
Need help? Before you ask
mcrognale
Znuny newbie
Posts: 7
Joined: 22 Apr 2014, 16:04
Znuny Version: 3.3.6
Real Name: Matt Crognale
Company: Industry Weapon, Inc.

Re: System Backups [SOLVED]

Post by mcrognale »

I gave up on getting the /sbin/backup.pl script that's included with the appliance to work. I switched over to /opt/otrs/scripts/backup.pl and things are working as expected.
Locked