Scheduled backups fails due to network delay after workstation wakeup


Author
Message
HolyK
HolyK
New Member
New Member (38 reputation)New Member (38 reputation)New Member (38 reputation)New Member (38 reputation)New Member (38 reputation)New Member (38 reputation)New Member (38 reputation)New Member (38 reputation)New Member (38 reputation)New Member (38 reputation)
Group: Forum Members
Posts: 18, Visits: 167
Hi,

I am facing issues with backups which are triggered during the night together with automatic wakeup of the Worstation. It is basically failing every time (and i know why, see bellow).
Note that i have other backup definitions (incrementals) which are executed only if the workstation is running and these are working properly.

Log of the backup says:

Destination:
Backup Type: Full
File Name: \\xxx.xxx.xxx.xxx\Some\Path\Data\A037FFFF90661739-00-00.mrbak
Attempting to connect to: '\\xxx.xxx.xxx.xxx\Some\Path\Data'
Failure: User - RB4501 - The specified network name is no longer available.
Failure: User - No user - The specified network name is no longer available.
Failure: User - anonymous - The specified network name is no longer available.

The user RB4501 and its password is 100% proper and the "Use the Windows SYSTEM user for scheduled tasks" is enabled as well.
The rest two attempts are just some in-build/hardcoded attempts from Macrium client itself so ignore these (BTW any way to remove them? They're pointless)

The reason is that it takes some time to establish secured connection to the target server. Sadly Macrium wont wait for remote server to become available and just fails right after startup. There is not even an attempt to try it again. Something like "retry every 30s for 300sec before giving up" or "wait for the target resource to become available for XXsec" would be very nice to have!. Currently it just wakes up the machine, tries to connect (the network device/tunnel is not even up at that point huh), fails, then it tries two more times with the anonymous users, fails as well (obviously) and then hibernates the machine with Failed backup result...

I've removed the automatic hibernate for a test and i can confirm that the server becomes available just few seconds after the backup fails. Sadly there is nothing i can do with that connection delay.

Is there some way to actually enforce Macrium to WAIT till the network is up and the connection is established?

I know about the registry Key: HKEY_LOCAL_MACHINE\Software\Macrium\Reflect\Settings and Value: SpinUpTime but that does not do anything (i've set it to 300000ms which is way more that actually required but the workstation hibernates within 2mins so seems like it does not honor this at all)

I am using MacriumReflect7 Home edition version 7.3 Build 5321

Thanks !

Alex
Edited 12 November 2020 9:35 PM by HolyK
HolyK
HolyK
New Member
New Member (38 reputation)New Member (38 reputation)New Member (38 reputation)New Member (38 reputation)New Member (38 reputation)New Member (38 reputation)New Member (38 reputation)New Member (38 reputation)New Member (38 reputation)New Member (38 reputation)
Group: Forum Members
Posts: 18, Visits: 167
I've solved it so bellow is "how" just in case someone has the same "issue".

First ... the "migrated" tasks from Windows Scheduler to Macrium one are not reliable. Something is wrong and you can see multiple threads about this on the forum with various symptoms. I gave up trying to fix the multiple wake-up events caused by single backup definition (System wakes up, backup fails due to the issue above, goes back to hibernation, after 5 min it wakes up again and stays powered on w/o any further actions. WakeUp clearly triggered by Macrium in both cases.) ==> Just disable the migrated schedules and create a new one. The one created in Macrium scheduler will work as expected.

Now for the issue I had ...
- As stated above I've disabled the existing backup schedules (the migrated ones) AND I've created new backup definitions with new names/XMLs but with the same settings like the ones I already had. This might be unnecessary (and time consuming for someone with complex setup) but I did not wanted to take the chances as the issue might be on the backup definition level (they were created back in version 6).
- In the last step of the backup definition I've defined only the retention policy but NO backup schedule execution. Then I saved the backup definition as XML and did not executed the backup at the time of creation.
- I used the "Generate a PowerShell script" for each of the new backup definition and saved the script with matching name.
- Then i went to "PowerShell Files" and edited each of the script by adding following line to the "Func: Main" on line 74 (right before the " $iExitCode = Backup; " line)
Start-Sleep -s 120 #Wait for network interfaces to actually go fully up!

- Then I scheduled the PowerShell script (not the Backup definition!) via the Macrium scheduler as per my needs including automatic wake-up. (Note that the Hibernation is configured on the backup definition level, not on the schedule).
- Done !

It is working like a charm since then! Two weeks now and no backups missed. Weekly full backups properly wakes up the workstation, waits for these 2 mins so the NIC goes up and connection is established properly. Then backup is performed and PC goes back to hibernation. Daily incremental triggers only if the PC is running and will not wake nor hibernate. If the INC is missed it triggers upon next system start. It honors the delay as well so no issues at all.

It is a bit overkill and simple configuration option for number of attempts/waiting time before giving up would solve this easily but till then it is the only solution which works as desired (at least for me).

Hope this helps someone :]

Bottom line ... I Like Macrium a lot, backups are reliable, I never faced issues with restores (can't say the same for some of the other SW i tried before, including the paid ones) and it does what it suppose to do (backup/restore!) and nothing else (no unnecessary/extra functions, no proprietary drivers messing up other things ...(looking at you, Acronis!), no build-in cloud providers, no ads, toolbars, bloatware, .. etc). So I will easily forgive the issues with migrated schedules. Keep up the good work guys !!

Regards,

Alex

Edited 30 December 2020 11:26 PM by HolyK
Patrick O'Keefe
Patrick O'Keefe
Talented Member
Talented Member (167 reputation)Talented Member (167 reputation)Talented Member (167 reputation)Talented Member (167 reputation)Talented Member (167 reputation)Talented Member (167 reputation)Talented Member (167 reputation)Talented Member (167 reputation)Talented Member (167 reputation)Talented Member (167 reputation)
Group: Forum Members
Posts: 116, Visits: 624
I, too, have run into this problem (and mentioned it here).  This is a bit frustrating since Macrium Reflect is head and shoulders above  Acronis True Image in almost all respects, but ATI does have that retry function.

I'm sure I could handle the problem with a script but I haven't taken the time to write one.  It would be a bit more extensive than the one mentioned in this thread because I would need to wake up a hibernating NAS.  I would have to attempt to access the NAS, wait a couple minutes, and then let MR proceed with the backup.  And usually the script isn't needed at all; MR usually accesses the NAS with no trouble.                         
I


Beardy
Beardy
Talented Member
Talented Member (144 reputation)Talented Member (144 reputation)Talented Member (144 reputation)Talented Member (144 reputation)Talented Member (144 reputation)Talented Member (144 reputation)Talented Member (144 reputation)Talented Member (144 reputation)Talented Member (144 reputation)Talented Member (144 reputation)
Group: Forum Members
Posts: 115, Visits: 458
@pokeefe You can attempt to access the NAS & wait 2 minutes if it fails very easily, it's so simple it can be done with a single line in a basic batch file just so long as you know the locaction of a pre-existing file on there.

IF NOT EXIST \\server\share\path\testfile PING -n 120 127.0.0.1 > NUL

If your NAS is awake it wouldn't even waste time pinging localhost & throwing the result into a black hole.

Edited 9 January 2021 5:59 PM by Beardy
Patrick O'Keefe
Patrick O'Keefe
Talented Member
Talented Member (167 reputation)Talented Member (167 reputation)Talented Member (167 reputation)Talented Member (167 reputation)Talented Member (167 reputation)Talented Member (167 reputation)Talented Member (167 reputation)Talented Member (167 reputation)Talented Member (167 reputation)Talented Member (167 reputation)
Group: Forum Members
Posts: 116, Visits: 624
I may try doing something like that if the problem happens again.   have rarely run into the problem.  Since Reflect's support of batch file scripting is pretty limited I'd probably do it using PowerShell (even though I don't know much PowerShell).  Is there a reason to do a repeating ping rather than a sleep?

alQamar
alQamar
Junior Member
Junior Member (99 reputation)Junior Member (99 reputation)Junior Member (99 reputation)Junior Member (99 reputation)Junior Member (99 reputation)Junior Member (99 reputation)Junior Member (99 reputation)Junior Member (99 reputation)Junior Member (99 reputation)Junior Member (99 reputation)
Group: Forum Members
Posts: 50, Visits: 117
Hi @HolyK if you use Windows 10 pro you might taken a different attempt and enable the local computer based GPO "always wait for network" this way the startup is a bit slower but makes sure that during the startup and logon the GPO is not processed before a network is available. 
You do not have enterprise GPO, yet the result should be the same for Macrium

this won't work with the hibernation thing though, just to prevent early launch of the job after logon.
as they migrated off Scheduled Tasks, I think there was also a checkmark like only run with connected network. I would contact the support to raise this as a feature request.
Edited 9 January 2021 8:07 PM by alQamar
Beardy
Beardy
Talented Member
Talented Member (144 reputation)Talented Member (144 reputation)Talented Member (144 reputation)Talented Member (144 reputation)Talented Member (144 reputation)Talented Member (144 reputation)Talented Member (144 reputation)Talented Member (144 reputation)Talented Member (144 reputation)Talented Member (144 reputation)
Group: Forum Members
Posts: 115, Visits: 458
Patrick O'Keefe - 9 January 2021 7:46 PM
I may try doing something like that if the problem happens again.   have rarely run into the problem.  Since Reflect's support of batch file scripting is pretty limited I'd probably do it using PowerShell (even though I don't know much PowerShell).  Is there a reason to do a repeating ping rather than a sleep?

If it fails you know you've network problems on the host, pinging the NAS might be even better, that would prove basic connectivity.

I've found no issues with the batch support, you can basically do anything batch scripting allows, both before & after the backup runs, including checking
%ERRORLEVEL%
for anything you've run
Edited 10 January 2021 1:54 AM by Beardy
Patrick O'Keefe
Patrick O'Keefe
Talented Member
Talented Member (167 reputation)Talented Member (167 reputation)Talented Member (167 reputation)Talented Member (167 reputation)Talented Member (167 reputation)Talented Member (167 reputation)Talented Member (167 reputation)Talented Member (167 reputation)Talented Member (167 reputation)Talented Member (167 reputation)
Group: Forum Members
Posts: 116, Visits: 624
Beardy - 10 January 2021 1:51 AM
I've found no issues with the batch support, you can basically do anything batch scripting allows, both before & after the backup runs, including checking
%ERRORLEVEL%
for anything you've run
I'm pretty new to Macrium Reflect and have hardly done any scripting so I may have this completely wrong, but as I understand it, Reflect passes parameters to VBS and PS scripts (such as backup type, etc.) that are not passes to .bat scripts.  If true, that means a separate.bat script is needed for each full, incr, and diff backup defined.

I would like finding out I'm wrong.  I'm more familiar with .bat scripts than either VBS  and PS.

Beardy
Beardy
Talented Member
Talented Member (144 reputation)Talented Member (144 reputation)Talented Member (144 reputation)Talented Member (144 reputation)Talented Member (144 reputation)Talented Member (144 reputation)Talented Member (144 reputation)Talented Member (144 reputation)Talented Member (144 reputation)Talented Member (144 reputation)
Group: Forum Members
Posts: 115, Visits: 458
Um, well that's not how I do it, my .bat is scheduled daily & determines internally the date, day of week etc, & passes the backup type to Macrium based off that, you can certainly pass parameters to a batch file when starting it & have them used internally, but as to if Macrium does pass any I've not investigated.

Personally I detest PowerShell, but if you're more familiar with it then:
Test-Path 'filesystem::\\Server\share\testfile'

Rreturns True if it's accessible & false otherwise.  I'm sure you could do a conditional pause & re-test based off that.

Edited 10 January 2021 10:58 PM by Beardy
alQamar
alQamar
Junior Member
Junior Member (99 reputation)Junior Member (99 reputation)Junior Member (99 reputation)Junior Member (99 reputation)Junior Member (99 reputation)Junior Member (99 reputation)Junior Member (99 reputation)Junior Member (99 reputation)Junior Member (99 reputation)Junior Member (99 reputation)
Group: Forum Members
Posts: 50, Visits: 117
you can use Test-Connection or (older) Test-NetConnection and use PowerShell to get a true or false condition and skip legacy batch files. 
GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...




Reading This Topic

Login

Explore
Messages
Mentions
Search