Veeam Maintanence for Patching

Availability for the Always-On Enterprise

Veeam Maintanence for Patching

Veeam Logoby Jonneh » Tue Jun 27, 2017 8:57 am

Hi,

If I have a veeam server (windows) and several proxies (also windows) and these machines need to be OS patched and rebooted to comply with .. well, good sense.... how do I do that without generating loads of failure messages which will get logged and needlessly investigated.

The veeam box does hourly replicas with an allowed schedule of 6am-8pm, and copy jobs offsite the data to a target at another datacenter down a VPN.

I can easily schedule this, and make sure no backups are actually running, but you still generate failure messages because the replicas and copy jobs are all in a state where they are "waiting" for the next copy window, so rebooting the box causes a false failure notification even though there is no backup running.

A global maintenance window feature would be nice, but I don't believe that exists. How else can I do this without pissing off first line with false alerts?
Jonneh
Novice
 
Posts: 6
Liked: 1 time
Joined: Tue Jun 27, 2017 8:51 am
Full Name: Jonathan Spencer

Re: Veeam Maintanence for Patching

Veeam Logoby PTide » Tue Jun 27, 2017 9:28 am

Hi,

Do you use Veeam One for alarms or just built-in email notifications?

but you still generate failure messages because the replicas and copy jobs are all in a state where they are "waiting" for the next copy window, so rebooting the box causes a false failure notification even though there is no backup running.

Replicas and copy jobs occur between repositories directly without proxy servers. Have you tried completely disabling the jobs first?

A global maintenance window feature would be nice, but I don't believe that exists.It does not

Right, it doesn't. Good candidate for FR though.

How else can I do this without pissing off first line with false alerts?

If you have sevral proxies serving the same set of jobs then you should try temporarily disabling proxies for maintenance, one by one, instead of stopping all the jobs.

Thanks
PTide
Veeam Software
 
Posts: 2958
Liked: 241 times
Joined: Tue May 19, 2015 1:46 pm

Re: Veeam Maintanence for Patching

Veeam Logoby Jonneh » Tue Jun 27, 2017 10:03 am

PTide wrote:Hi,

Do you use Veeam One for alarms or just built-in email notifications?


Replicas and copy jobs occur between repositories directly without proxy servers. Have you tried completely disabling the jobs first?

Sadly running a script to disable the replicas probably would be OK, but disabling the copy jobs still generates a failure message (yes, default email alerts). This customer does not use Veeam One.

How do I log a FR? It does seem logical to me also. Thanks!
Jonneh
Novice
 
Posts: 6
Liked: 1 time
Joined: Tue Jun 27, 2017 8:51 am
Full Name: Jonathan Spencer

Re: Veeam Maintanence for Patching

Veeam Logoby PTide » Tue Jun 27, 2017 10:48 am

How do I log a FR?

You just did :)

but disabling the copy jobs still generates a failure message (yes, default email alerts)

If a copy job is a in an 'idle" state then it should not yell when you disable it. If you still get failure messages then I'd suggest you to contact support team.

Thank you
PTide
Veeam Software
 
Posts: 2958
Liked: 241 times
Joined: Tue May 19, 2015 1:46 pm

Re: Veeam Maintanence for Patching

Veeam Logoby Jonneh » Tue Jun 27, 2017 10:54 am

PTide wrote:If a copy job is a in an 'idle" state then it should not yell when you disable it. If you still get failure messages then I'd suggest you to contact support team.

You are right actually, I just tested it on an Idle one. I think before I must have tested it on one that wasn't fully complete. I think we can work this with a simple get-vbrjob | disable-vbrjob at a time when we can be sure there are no jobs actually running, and then just re-enable them after our maintenance window.

Going forward though that script gets more complicated when you want to allow for jobs that might be disabled by design, and a simple script will just re-enable them when it does all the rest. I'd need to write logic into it to test if a job is disabled before the window and then exclude it from being re-enabled.

Thanks for taking the feedback and FR, it would make life much simpler, I'll look forward to it appearing in a future release!
Jonneh
Novice
 
Posts: 6
Liked: 1 time
Joined: Tue Jun 27, 2017 8:51 am
Full Name: Jonathan Spencer

Re: Veeam Maintanence for Patching

Veeam Logoby v.Eremin » Tue Jun 27, 2017 3:01 pm

Before disabling jobs, you can run this query to get list of already disabled jobs:

Code: Select all
Get-VBRJob | where {$_.IsScheduleEnabled -eq $False} | select name

Then, while re-enabling jobs, be aware to exclude those from this list (name filter).

Thanks.
v.Eremin
Veeam Software
 
Posts: 13103
Liked: 951 times
Joined: Fri Oct 26, 2012 3:28 pm
Full Name: Vladimir Eremin

Re: Veeam Maintanence for Patching

Veeam Logoby Jonneh » Tue Jun 27, 2017 3:12 pm 1 person likes this post

Thanks,

What we did was...

Code: Select all
#  Load Veeam snap-in and connect to Veam server
Add-PSSnapin VeeamPSSnapin
Connect-VBRServer -Server <SERVERNAME>

$mailFrom = "Veeam@customerdomain.com"
$mailTo = "backupalerts@recipient.com"
$SMTPServer = "smtp.host"
$mailSubject = "Veeam Server Maintenance"
$mailBody = "Server is entering scheduled maintenance.  All backup/replication failures shortly before & after this message can be ignored.  A list of

affected backup jobs is attached"
$mailAttachment = "c:\scripts\joblist.txt"

# Get list of enabled jobs and write the job names to a file
$jobsToDisable = get-vbrjob | ?{$_.isscheduleenabled -eq $true}
$jobsToDisable | select -expand name | set-content c:\scripts\joblist.txt

foreach ($job in $jobsToDisable) {
write-output "Disabling job $($job.name)"
get-vbrjob -name $job | disable-vbrjob
}

Send-MailMessage -From $mailFrom -To $mailTo -SMTPServer $SMTPServer -Subject $mailSubject -Body $mailBody -Attachments $mailAttachment


Then to restart...

Code: Select all
#  Load Veeam snap-in and connect to Veeam server
Add-PSSnapin VeeamPSSnapin
Connect-VBRServer -Server <SERVERNAME>

# Read list of previously running jobs from file
$jobsToEnable = Get-Content c:\scripts\joblist.txt

# Enable each job from the list
foreach ($job in $jobsToEnable) {
write-output "Enabling job $job"
get-vbrjob -name $job | enable-vbrjob
}
Jonneh
Novice
 
Posts: 6
Liked: 1 time
Joined: Tue Jun 27, 2017 8:51 am
Full Name: Jonathan Spencer

Re: Veeam Maintanence for Patching

Veeam Logoby v.Eremin » Tue Jun 27, 2017 7:01 pm

Yep, that's exactly what I was suggesting. Thank you for sharing the scripts with the community; most appreciated.
v.Eremin
Veeam Software
 
Posts: 13103
Liked: 951 times
Joined: Fri Oct 26, 2012 3:28 pm
Full Name: Vladimir Eremin


Return to Veeam Backup & Replication



Who is online

Users browsing this forum: Bing [Bot], Google [Bot], Google Feedfetcher, jay.cheon, Matt@ManSol and 22 guests