You are not logged in.
Version 10.3.4, seems that cron launched backup, even if not executed due to time schedule not matched, deletes the .ERR file of an interactive user launched backup
I agree, since I also requested such feature..
[quote=admin]Make sure the --exec=yes directive is at the end of the backup job string[/quote]
yes, figured out debugging the script... now it works!
[quote=sistemi]
Get used to employ leading zeros in dates.
In other order of things, for goodness sake, don't use USB devices to backup your VMs. USB is a nice method to plug your key and copy your office documents, but it's not a serious mean to backup critical data. If you don't know what I mean, I bet you'll end up knowing why we are vehement about it ;-)[/quote]
the test works, but the job is not launched, as i told i see the command line if i execute ps -c|grep xsibackup, but it last in just a second and there is no log to check...
Damn, i thought i was so near to heaven, no way to make it working, what's wrong here?
All working from command line, test date formati is weekday-hh-mm, doing ps -c|grep xsibackp i see the /bin/sh ... etc..., but joust for a moment, nothing on the log or .ERR
if [ "$(date '+%u-%H-%M')" == "3-14-03" ]
then
# usb mount
esxcli storage nfs add -H 192.168.1.1 -v usb -s /USBDisk2/
/vmfs/volumes/datastore1/xsi-dir/xsibackup backupid=E1BAKtoUSB --exec=yes --backup-prog=xsitools:z --backup-how=hot --override=xsibakfilter --backup-type=custom --test-mode=false --use-smtp=1 --mail-to=xxxxxxxx --subject="test backup" --backup-point=/vmfs/volumes/usb/aaaaaaa --debug-info=yes --backup-vms=zzz
#usb umount
esxcli storage nfs remove -v usb
fi
This weekend I launched a backup that lasted longer than expected, meanwhile the cron start another remote backup of the same host, resulting in killing the previous backup that was more critical.
As a suggestion, can you include a switch to stop a backup if another is running in the same machine, only notifying on the log and leaving us the choice?
Thanks.
AH AH, the third option was the first I considered, but as it seemed the uglyest, I discarded it, but i will try, thanks.
I searched the forum but i wasn't able to find an answer.
I want to schedule a backup job that needs to mount a temporary NFS filesystem, so i wrote a script that mounts, call xsibackup, and the unmount.
I would prefer to schedule that script into xsibackup-cron, instead o esxi cron, but i cannot figure how, can someone give me a working solution?
Thanks.
That's clear, thank you!
Hi admin, may we use this thread to follow the development of that promising script? I just want to open a bug for it regarding the names of the .vmdk files containing spaces that causes the script to crash.... Thanks.
first remote onediff hot quiesced backup, from hostA to hostB, for a windows 2008 server VM
Info: transfering file | /vmfs/volumes/datastore1/mailServer/mailServer-flat.vmdk
-------------------------------------------------------------------------------------------------------------------
Info: first Rsync transfer is assumed by XSIDiff, as it is faster and will preserve VMFS data sparseness
-------------------------------------------------------------------------------------------------------------------
(c) XSIDiff 1.0.6.1 licensed: xxxxxxxxxxxxxxxxxxxxxxxxxx
File#1 size 42949672960 bytes
Writing to file /vmfs/volumes/datastore1/bkp/mailServer/mailServer-flat.vmdk
1351485600.00% done
ls on hostB
580458584204266838 Jan 30 11:39 mailServer-flat.vmdk
stopped the backup!
deleted all backups, snapshots, restarted vm, it seems no more happens, I love computers and software certainties...
Hi, regarding to the remote backup, the scheduled backups worked fine but today, trying to launch another backup using --run-backup i received an error:
It's a minor bug for me but i dont'have spare time to investigate...
###############################################################################
#
# (c) XSIBACKUP-PRO 10.2.5 | Backup for (c) VMWARE ESXi Hypervisor by 33hops.co m
#
################################################################################ ###
Found (c) XSIBackup installation. Remote path is set dynamically
Remote xsi path set to: /vmfs/volumes/524d1b54-ddf4d08c-5600-90b11c388503/xsi-di r
-------------------------------------------------------------------------------- -------------------------------------------------------------------------------- ---------------------------------
...
...
Preparing to execute backup in remote server: xxx
-------------------------------------------------------------------------------- -------------------------------------------------------------------------------- ---------------------------------
-------------------------------------------------------------------------------- -------------------------------------------------------------------------------- ---------------------------------
wc: standard input: Interrupted system call
Copying file EULA to remote server xxx
EULA 100% 4589 4.5KB/s 00:00
...
...
------------------------------------------------------------------------------------------------------------- ------------------------------------------------------------------------------------
Executing remote backup on xxx
Saving log locally to => xsibackup-cron-xxx.log
ssh: illegal option --
usage: ssh [-1246AaCfgKkMNnqsTtVvXxYy] [-b bind_address] [-c cipher_spec]
[-D [bind_address:]port] [-e escape_char] [-F configfile]
[-I pkcs11] [-i identity_file]
[-L [bind_address:]port:host:hostport]
[-l login_name] [-m mac_spec] [-O ctl_cmd] [-o option] [-p port]
[-R [bind_address:]port:host:hostport] [-S ctl_path]
[-W host:port] [-w local_tun[:remote_tun]]
[user@]hostname [command]
Killed
thanks, i did yesterday, and now my weekly backup chain is working fine! Wait for the next amazing version...
P.S. check also my other post about du -m wrong values it appears randomly and I think is related to some math rounding, counting bytes should solve that bug.
Have a nice weekend.
Regards.
PP
while you are thinking about it, I found that you changed the way to call the remote job, from
ssh $( echo "$SSHOPTS" ) -o ConnectTimeout=20 -p$srv2 ${defremusr}@$srv1 "${xsidefaultpath}/xsibackup \"${keyvalstr} --from=$HOSTIP --exec=yes\" &" >>"$PWD"/xsibackup-cron-${srv1}.log &
to
eval ssh "$SSHOPTS" -o ConnectTimeout=20 -p$srv2 ${defremusr}@$srv1 "\"${xsidefaultpath}/xsibackup ${keyvalstr} --from=$HOSTIP --exec=yes\" &" >>"$PWD"/xsibackup-cron-${srv1}.log &
using eval the backupid-> is lost (perhaps the ">" is interpreted as output redirection), unfortunately I'm not able to solve, please give a workaround!
Nightly is launched a backup from host A to host B using cron, upon success I expect that xsibackup launch another job, defined in the host B xsibackup-cron, but id doesn't happen. Other chained backups on the same host are correctly launched.
this is the xsibackup-cron command:
/vmfs/volumes/datastore1/xsi-dir/xsibackup backupId=AR1ZF --time="Tue 00:05|Wed 00:05|Thu 00:05|Fri 00:05" --backup-how=hot --backup-prog=onediff --backup-type=custom --test-mode=false --use-smtp=2 --mail-to=xxxxxx --subject="AR1ZF" --backup-point=<hostC>:/vmfs/volumes/datastore1/bkp --zippa=no --host=<hostB> --backup-vms=zfs1 --debug-info=yes --on-error="backupId->AR2ZF" --on-success="backupId->AR2ZF"
this is the command that should be launched upon success (xsibackup-cron on hostB)
/vmfs/volumes/datastore1/xsi-dir/xsibackup backupId=AR2ZF --backup-how=hot --backup-prog=onediff --backup-type=custom --test-mode=false --use-smtp=1 --mail-to=xxxxxx --subject="AR2ZF" --backup-point=<hostC>:22:/vmfs/volumes/datastore1/bkp --host=<host D> --backup-vms=zfs2 --debug-info=yes
this is the mail after the first backup, notice that on-success and on-error are blanks:
Wed Jan 24 00:07:18 UTC 2018
XSIBACKUP-PRO 10.2.5 AT HOST:
IP v4: <hostB>/ 255.255.255.0
VMware ESXi 5.5.0 build-1331820
Done hot backup (id: ar1zf) using onediff (no compression)
Mirroring following VMs to <hostC>:22:/vmfs/volumes/datastore1/bkp...
VM Name State Size (Gb) Stop Copy Start Time (min) Speed (mb/s)
zfs1 ON 104/ 121 NO (hot backup) OK - 21 81/ 94
Complete backup elapsed time: 21 min
The ESXi configuration was saved to <hostC>:22:/vmfs/volumes/datastore1/bkp
DEBUG INFORMATION:
• backupid: ar1zf
• backuphow: hot
• backupprog: onediff
• backuptype: custom
• testmode: false
• mailto: xxxxxxxx
• usesmtp: 2
• debuginfo: yes
• onerror: backupid-
• onsuccess: backupid-
• from: <hostA>
• exec: yes
• DATE DIR:
• XSIDIR: /vmfs/volumes/524d1b54-ddf4d08c-5600-90b11c388503/xsi-dir
• LAUNCHED BY: cron
• KEY: -4 -o StrictHostKeyChecking=no -i /vmfs/volumes/524d1b54-ddf4d08c-5600-90b11c388503/xsi-dir/xsibackup_id_rsa
• PID: 11274704
• ESXi VERSION: 5.5.0
VMXFILEPATH: /vmfs/volumes/datastore1/zfs1/zfs2.vmx
• VM zfs1 remote VMX path exists at: <hostC>:22:/vmfs/volumes/datastore1/bkp/zfs1/zfs2.vmx
• VM zfs1 SYS DISK1 EXISTS: /vmfs/volumes/datastore1/zfs1/zfs2.vmdk
• VM zfs1 SYS DISK2 EXISTS: /vmfs/volumes/datastore1/bkp/zfs1/zfs2.vmdk
• VM zfs1 CID1: 267a5fac
• VM zfs1 CID2: 267a5fac
• VM zfs1 CID: 0
• VM zfs1 SNAPSHOT: xsibackupdiff
• VM zfs1 SNAPSHOT NUM: 1
I noticed an error in Onediff backup to a remote host:
ERROR (DIFQMSH3) details [zfs1] error: data size mismatch: 99339 NE 99338
launching du -m on the affected files gives taht numbers, so the error is true, but an ls -l shows the same size (107374182400) and also computed hashes are the same.
This error reinitialize Onediff and force subsequent backup to full, vanishing the onediff strategy.
Why not use ls -l or something else (i'm not so skilled on shell commands) ?
that's obvious, I'll try with the original copy of the file and I'll give you the feedback
Sorry, the lines could not be the same, since i have customizations, 1208 - 1220 are the correct numbers
I solved my issue commenting lines 1225 to 1237 in xsibackup, which also seems to have coding errors with variable RMXSIDIFFPATH. The script crashes if it executes the comphashes function at line 1226. It's not a real solution but now i0m able to do the scheduled backups.
I rebooted the remote (target) host, nothing, same error, but I can't reboot the source host as is H24 production system, could you explain better which memory is involved and why a reboot will solve?
all the involved hosts are XSIBACKUP-PRO 10.2.1
Same error after removing :z option, worked well before last update
here the full cmd
xsibackup backupId=AR1ZF --backup-how=hot --backup-prog=onediff --backup-type=custom --test-mode=false --use-smtp=2 --mail-to=xxxxxxxxxxxx --subject="AR1ZF" --backup-point=xxxxxxxxxxx:22:/vmfs/volumes/datastore1/bkp --backup-vms=zfs1 --debug-info=yes
Launching a backup to remote datastore crashes immediately...
###############################################################################
#
# (c) XSIBACKUP-PRO 10.2.1 | Backup for (c) VMWARE ESXi Hypervisor by 33hops.com
#
###################################################################################
NOTICE: (c) XSIBackup will kill any previous processes, make sure you don't overlap backup jobs
------------------------------------------------------------------------------------------------------------------------------------
XSIBackup PID: 5497803 xxxxxxxxx
Fri, 05 Jan 2018 08:15:16 +0000 IPv4: xxxxxxxx/255.255.255.0
VMware ESXi 5.5.0 build-1331820 (c) Rsync 3.1.0 as opt. dependency
------------------------------------------------------------------------------------------------------------------------------------
Backup Id: ar1zf Intel(R) Xeon(R) CPU E5-2650 0 @ 2.00GHz
------------------------------------------------------------------------------------------------------------------------------------
ADVICE: no SSD disks, please consider adding an SSD cache disk to improve performance
------------------------------------------------------------------------------------------------------------------------------------
Backup user is: root
------------------------------------------------------------------------------------------------------------------------------------
Backup program is: onediff
------------------------------------------------------------------------------------------------------------------------------------
Service OpenSSH ready at server yyyyyyyyy:22
Found more than one remote (c) XSIBackup installation dir at [yyyyyyyyy]
Using hardcoded var at conf/xsiopts [xsidefaultpath] as remote path.
------------------------------------------------------------------------------------------------------------------------------------
Remote xsi path set to: /vmfs/volumes/datastore1/xsi-dir (filesystem: VMFS-5)
------------------------------------------------------------------------------------------------------------------------------------
Compression option is deprecated since XSIBackup 10.0.4, SSH 2.0 is forced since this version and it handles compression dynamically
Remote ESXi version is 6.0.0
------------------------------------------------------------------------------------------------------------------------------------
Mirroring to server yyyyyyyyy port 22
Checking Rsync exists on the other side...
------------------------------------------------------------------------------------------------------------------------------------
(c) Rsync (samba.org) found at [ yyyyyyyyyy:22:/vmfs/volumes/...mes/datastore1/xsi-dir/bin/xsibackup-rsync ]
------------------------------------------------------------------------------------------------------------------------------------
Segmentation fault
Scenario VM centralino in on ESXI 5.5.0, it weekly backupped on a NAS using Onediff.
The backup Onediff VM (centralino_XSIBAK) on NAS is copied using xsitools on a USB external drive, mounted as a datastore.
ESXI1->xsibackup(centralino, onediff) -> NAS
EXSI2->xsibackup(centralino_XSIBAK, xsitools) -> USBDISK
While executing that xsitools backup I got this error:
[centralino_XSIBAK] XSIT1MbM alert: disk [/vmfs/volumes/6e254ea5-7a6c9ffd/EXSI2/centralino/centralino2-flat.vmdk] size (108134400) is not multiple of 1M (1048576 bytes)
[-flat.vmdk] disks should be exact multiples of 1048576 byte blocks, which is the VMFS block size
Some operations like physical to virtual conversions can render disks which are not aligned to 1M
(c)XSITools requires -flat.vmdk disks to be aligned to 1M (1048576 bytes) chunks to work correctly
Turn off your VM and run: [ vmkfstools -X 104M /vmfs/volumes/6e254ea5-7a6c9ffd/EXSI2/centralino/centralino2.vmdk ]
to align your disk to the closest 1M (1048576 bytes) multiple, or choose another multiple integer
The suggested command could corrupt the VM disk?
Also, the path is related to the NAS (centralino_XSIBAK), should I execute command also on the original VM disk on ESXI1?
If there is a clean solution please suggests it.
Looking at VM settings I see 103,125 MB for disk size, both in centralino and centralino_XSIBAK.
Thanks for you support.
I confirm that moving the line solves the issue, waiting feedback for the --run-backup issue