Discussions related to using object storage as a backup target.
Post Reply
edingc
Influencer
Posts: 15
Liked: 2 times
Joined: Jun 26, 2018 12:51 pm
Full Name: Cody Eding
Contact:

Pre- and Post- Scripts for SOBR Tiering Operation

Post by edingc »

Will there be support for pre- and post- scripts for the SOBR tiering operation in an upcoming release?
wishr
Veteran
Posts: 3077
Liked: 455 times
Joined: Aug 07, 2018 3:11 pm
Full Name: Fedor Maslov
Contact:

Re: Pre- and Post- Scripts for SOBR Tiering Operation

Post by wishr »

Hi Cody,

Could you please clarify in detail your use-case?

Thanks
edingc
Influencer
Posts: 15
Liked: 2 times
Joined: Jun 26, 2018 12:51 pm
Full Name: Cody Eding
Contact:

Re: Pre- and Post- Scripts for SOBR Tiering Operation

Post by edingc »

Specifically, thinking about file immutability on a Linux repository as a protection mechanism from accidental deletion. Presumably, the SOBR tiering operation requires the VBK/VIB/VBM files to be modifiable as the operation happens and data is transferred. I would need some way to notify the repository to remove the immutable flags once the operation starts and reset them when it ends.

Additionally, I could see us having a simple Send-MailMessage or something when an operation kicks off and ends just for debugging/logging purposes.

Thanks!
veremin
Product Manager
Posts: 20353
Liked: 2285 times
Joined: Oct 26, 2012 3:28 pm
Full Name: Vladimir Eremin
Contact:

Re: Pre- and Post- Scripts for SOBR Tiering Operation

Post by veremin »

I don't think we have a way to return offload sessions in PowerShell, but even if we had one, it would work only for move policy (copy policy works more or less contioniously, no start or stop time).

And I would be aware, while commiting to custom immutability option, so, consider thoroughly testing this configuration before going all in.

Thanks!
dalbertson
Veeam Software
Posts: 492
Liked: 175 times
Joined: Jul 21, 2015 12:38 pm
Full Name: Dustin Albertson
Contact:

Re: Pre- and Post- Scripts for SOBR Tiering Operation

Post by dalbertson »

@edingc Once minio supports object lock you could leverage that tool to present the linux repo as a immutable s3 bucket and reach your objective in some fashion
Dustin Albertson | Director of Product Management - Cloud & Applications | Veeam Product Management, Alliances
edingc
Influencer
Posts: 15
Liked: 2 times
Joined: Jun 26, 2018 12:51 pm
Full Name: Cody Eding
Contact:

Re: Pre- and Post- Scripts for SOBR Tiering Operation

Post by edingc »

@dalbertson

Something like that does look like an option for us right now, too.

I have had no issues in limited testing with pre/post scripts that set and remove immutable flags in the Linux OS on the repository before any data transfer or storage operations are done. But I do need to do more testing before that would roll out in production.

I suppose since SOBR tiering doesn't have the pre/post scripts, I would need some logic to account for whatever the tiering logic is (i.e. backups over X days old are not set with the immutable flag so that Veeam can do what it needs to with them).
dalbertson
Veeam Software
Posts: 492
Liked: 175 times
Joined: Jul 21, 2015 12:38 pm
Full Name: Dustin Albertson
Contact:

Re: Pre- and Post- Scripts for SOBR Tiering Operation

Post by dalbertson » 1 person likes this post

My concern with the pre/post scripts would be that removing the flag even for short periods of time opens that file up to corruption. using a repo that supports the API calls is a more secure approach.
Dustin Albertson | Director of Product Management - Cloud & Applications | Veeam Product Management, Alliances
oleg.feoktistov
Veeam Software
Posts: 2006
Liked: 666 times
Joined: Sep 25, 2019 10:32 am
Full Name: Oleg Feoktistov
Contact:

Re: Pre- and Post- Scripts for SOBR Tiering Operation

Post by oleg.feoktistov » 1 person likes this post

Actually, it is possible to return offload sessions in Powershell with .NET methods.
Both move and copy policies do have CreationTime/EndTime as they don't linger in UI awaiting for operational restore window check to be done or job to finish:

Code: Select all

$allOffloadSessions = @()
$moveJob = [Veeam.Backup.Model.EDbJobType]::ArchiveBackup
$moveSessions = [Veeam.Backup.Core.CBackupSession]::FindLastByJobType($moveJob)
$copyJob = [Veeam.Backup.Model.EDbJobType]::ArchiveCopy
$copySessions = [Veeam.Backup.Core.CBackupSession]::FindLastByJobType($copyJob)
$allOffloadSessions += $moveSessions
$allOffloadSessions += $copySessions
$allOffloadSessions | select Name, JobType, CreationTimeUTC, EndTimeUTC 

Name                  JobType CreationTimeUTC      EndTimeUTC          
----                  ------- ---------------      ----------          
SOBR-02 Offload ArchiveBackup 5/18/2020 7:21:28 PM 5/18/2020 7:21:36 PM
SOBR-02 Offload   ArchiveCopy 5/16/2020 7:28:35 PM 5/16/2020 7:28:46 PM 

However, it wouldn't help us in any way as we control offload policies on SOBR level and not with a regular job entity.
So seeking for any offload job info in backup job classes would return nothing:

Code: Select all

$jobs = [Veeam.Backup.Core.CBackupJob]::GetAll() | where {$_.Id -eq $moveSessions[0].JobId -or $_.Id -eq $copySessions[0].JobId} 

PS C:\WINDOWS\system32> $jobs
PS C:\WINDOWS\system32>  
Adding to the point @dalbertson highlighted, here is another thing that bothers me:
Due to the reasons I appealed to above, pre- and post- scripts would be also controlled on SOBR level.
Then, for instance, if the same SOBR is configured as a target for several jobs, I don't know, I think we basically open a Pandora's box.
edingc
Influencer
Posts: 15
Liked: 2 times
Joined: Jun 26, 2018 12:51 pm
Full Name: Cody Eding
Contact:

Re: Pre- and Post- Scripts for SOBR Tiering Operation

Post by edingc » 1 person likes this post

Thanks for all of the comments. It's much appreciated. This really helped me think through the process and I can go back to and come up with something that works for us.
Post Reply

Who is online

Users browsing this forum: No registered users and 3 guests