©XSIBackup-Free: Free Backup Software for ©VMWare ©ESXi

Forum ©XSIBackup: ©VMWare ©ESXi Backup Software


You are not logged in.

#1 2018-02-10 18:07:37

DaveK
Member
Registered: 2018-02-10
Posts: 15

Cron job works, but xsibackup-cron.log is empty

Hello,
After upgrade from XSIBACKUP-FREE 9.1.9 to XSIBACKUP-PRO 10.2.8 i've got problem with xsibackup-cron.log, everything is working, PID is visible in xsibackup-pid, vSphereClient shows information about snapshots etc. but xsibackup-cron.log is still empty, why?

Offline

#2 2018-02-10 18:59:01

admin
Administrator
Registered: 2017-04-21
Posts: 2,055

Re: Cron job works, but xsibackup-cron.log is empty

Have you upgraded all files in the package?, or just partially.

UPDATE:
Please, let us know your ESXi version and build.

Offline

#3 2018-02-10 19:21:19

DaveK
Member
Registered: 2018-02-10
Posts: 15

Re: Cron job works, but xsibackup-cron.log is empty

In few steps:
-I downloaded new installation via provided script, then I renamed xsibackup(my old xsi dir) to xsibackup_.
-I renamed xsi-dir folder name to xsibackup
-I was started ./xsibackup, there was an license agreement request, and script was looking for VM, so I stoped it by ctrl+c.
-I generate license key via web site, and put it in xsibackup dir
Then I added line with commands to xsibackup-cron, with additionally "--backup-prog=onediff" switch and changed start hour to actual, plus few minutes. Xsi was start to works, xsibackup-cron.log appears but is still empty

as I mentioned before actual version is XSIBACKUP-PRO 10.2.8

Offline

#4 2018-02-11 11:40:01

admin
Administrator
Registered: 2017-04-21
Posts: 2,055

Re: Cron job works, but xsibackup-cron.log is empty

I'm sorry DaveK, but I'm not quite getting you.
You mean you didn't accept the license agreement?; you have to, for the software to work.
Apart from that, you do need to test your backup jobs before placing them in the xsibackup-cron file. Once you know they are correctly formatted and working, enable them in the crontab.
You still haven't told us what ESXi version you are using.

Offline

#5 2018-02-11 11:46:13

DaveK
Member
Registered: 2018-02-10
Posts: 15

Re: Cron job works, but xsibackup-cron.log is empty

ESXi 5.5.0 2068190, before upgrade, with XSI version XSIBACKUP-FREE 9.1.9 everything worked well. I'll try to reboot Host, but its not so easy, there are VM's that needs to be still online. Maybe restart cron service? or this is not a reason?

Offline

#6 2018-02-11 11:55:19

admin
Administrator
Registered: 2017-04-21
Posts: 2,055

Re: Cron job works, but xsibackup-cron.log is empty

ESXi 5.5 is installed in one of our development servers, and it's probably our most tested ESXi version.

Don't leave the old folder hanging around, just copy it outside the host and delete it in the ESXi server. It's O.K. to keep it, but I'm helping you blindfolded, so we should remove any element that could cause an interfeerence.

If you renamed the xsi-dir folder, but did not reinstall the cron, then the XSIBackup process is looking for the xsibackup-cron.log file in a place where it does not exist any more. So..., rename the folder back again to xsi-dir, or uninstall the cron file by running

./xsibackup --install-cron

Rename the folder to whatever you want and then run the cron install command again, to make xsibackup to point to the correct path when looking for the cronfile.

Offline

#7 2018-02-11 12:06:38

DaveK
Member
Registered: 2018-02-10
Posts: 15

Re: Cron job works, but xsibackup-cron.log is empty

If I delete file "xsibackup-cron.log" it appears after minute or two, so for me cron service works, and looks for file in proper place. More over, backup job starts if I set job in xsibackup-cron, but it dosen't write outs to xsibackup-cron.log I was tryed reinstall cron by ./xsibackup --install-cron, restarted cron service. Everything looks ok, but cron log is still empty. Last chance for me is host reboot, but i'm still looking for better resolution, because as I mentioned it's not so easy in my case

Offline

#8 2018-02-11 14:34:59

admin
Administrator
Registered: 2017-04-21
Posts: 2,055

Re: Cron job works, but xsibackup-cron.log is empty

Just make sure that things are where they have to be.
This posts may be of help to you:

https://33hops.com/xsibackup-cron-how-to.html
https://33hops.com/xsibackup-advanced-c … -cron.html

From the README.txt file:

Update:

	You can try to just overwrite the existing files, but you must be 
	aware of the fact that memory corruption may appear. Should this 
	happen (you will notice it because some weird syntax and runtime 
	errors will be thrown), please reboot your server. This is due to 
	how bash scripts are cached in memory. One good way to ensure you 
	work this issues around is to copy the new version to a different 
	folder and then delete the old and rename the new to xsi-dir. This 
	changes every program's file inode and prevents mem caching.

	If you run a mission critical environment and you have a working 
	XSIBackup installation, you'll have to ponder whether to upgrade 
	or continue using the existing version.

Offline

#9 2018-02-13 11:00:23

DaveK
Member
Registered: 2018-02-10
Posts: 15

Re: Cron job works, but xsibackup-cron.log is empty

Ok, there's a trace. After xsi finished execution, xsibackup-cron.log appears and looks OK, there's all job execution log! So it loks like a problem with real-time output redirection to file, maybe it's buffered somewhere, and xsi writes it after execution? So how can i force xsi to dump log in real-time?

Offline

#10 2018-02-13 11:12:23

admin
Administrator
Registered: 2017-04-21
Posts: 2,055

Re: Cron job works, but xsibackup-cron.log is empty

Busybox's sed utility, suddenly happened to be buffered in ESXi 6.5.0. We removed it from the crontab call some versions ago to avoid this kind of problems, but if you had installed the crontab in a previous version, then you might still experience this issue.

Check your /var/spool/cron/crontabs/root file and see if you have something like:

*/1 * * * * '/vmfs/volumes/datastore1/xsi-dir/xsibackup-cron' | sed '/\r/d' >> '/vmfs/volumes/datastore1/xsi-dir/xsibackup-cron.log' 2>&1

If so, just remove the sed call in bold letters.

Offline

#11 2018-02-14 22:23:23

DaveK
Member
Registered: 2018-02-10
Posts: 15

Re: Cron job works, but xsibackup-cron.log is empty

Now after I removed sed call everything is OK, without host reboot. Thank you! smile

Offline

#12 2018-02-22 12:48:14

admin
Administrator
Registered: 2017-04-21
Posts: 2,055

Re: Cron job works, but xsibackup-cron.log is empty

To make this change permanent you should remove that sed from this file:

/etc/rc.local.d/local.sh

Otherwise it will reappear on /var/spool/cron/crontabs/root after reboot.

Offline

Board footer