-
- Influencer
- Posts: 12
- Liked: 4 times
- Joined: May 29, 2024 2:47 pm
- Full Name: Vitalii Feshchenko
- Contact:
Get Proxy date-time
We are developing a script to retrieve information about the proxy and ensure that their date and time are synced with the VBR. I'm looking into the possibility of accomplishing this using the Veeam PowerShell module. Optionally, it might be retrieving the time server settings of the proxy for verification.
Any assistance in this matter would be greatly appreciated.
Any assistance in this matter would be greatly appreciated.
-
- Product Manager
- Posts: 10110
- Liked: 2696 times
- Joined: May 13, 2017 4:51 pm
- Full Name: Fabian K.
- Location: Switzerland
- Contact:
Re: Get Proxy date-time
Hi Vitalli
I don't think we have such a method in the PowerShell module. I can't see it in the official cmdlets.
Have you considered to use Get-Date?
Probably the challenge is to have the command run at the same exact moment on all proxies to have an accurate output.
One proxy may run the command a few seconds later which already makes the verification difficult.
Best,
Fabian
I don't think we have such a method in the PowerShell module. I can't see it in the official cmdlets.
Have you considered to use Get-Date?
Probably the challenge is to have the command run at the same exact moment on all proxies to have an accurate output.
One proxy may run the command a few seconds later which already makes the verification difficult.
Best,
Fabian
Product Management Analyst @ Veeam Software
-
- Veeam Software
- Posts: 2015
- Liked: 671 times
- Joined: Sep 25, 2019 10:32 am
- Full Name: Oleg Feoktistov
- Contact:
Re: Get Proxy date-time
Hi Vitalii,
We don't keep info on managed servers' datetimes in VBR database. You'd have to use either powershell remoting or wmi cmdlets to get it on a remote server.
Best regards,
Oleg
We don't keep info on managed servers' datetimes in VBR database. You'd have to use either powershell remoting or wmi cmdlets to get it on a remote server.
Best regards,
Oleg
-
- Influencer
- Posts: 12
- Liked: 4 times
- Joined: May 29, 2024 2:47 pm
- Full Name: Vitalii Feshchenko
- Contact:
Re: Get Proxy date-time
Thank you, everyone. I will proceed with the regular method.
Regarding the Veeam version on Proxies, is it possible to retrieve this information using the PowerShell module?
I discovered a method to get all components, but I couldn't find a way to obtain a general version. Here’s what I have so far:
$proxyHost = $proxy.Server.GetPhysicalHost()
$proxyHost.GetComponents()
Regarding the Veeam version on Proxies, is it possible to retrieve this information using the PowerShell module?
I discovered a method to get all components, but I couldn't find a way to obtain a general version. Here’s what I have so far:
$proxyHost = $proxy.Server.GetPhysicalHost()
$proxyHost.GetComponents()
-
- Veeam Software
- Posts: 2367
- Liked: 560 times
- Joined: Jun 28, 2016 12:12 pm
- Contact:
Re: Get Proxy date-time
Hi Vitalii,
A proxy in this case is best understood as the collection of the Veeam Components installed (transport, deployment, etc) installed on it rather than some specific single binary version. So you will check the version on those Components returned by GetComponents().
A proxy in this case is best understood as the collection of the Veeam Components installed (transport, deployment, etc) installed on it rather than some specific single binary version. So you will check the version on those Components returned by GetComponents().
David Domask | Product Management: Principal Analyst
-
- Influencer
- Posts: 12
- Liked: 4 times
- Joined: May 29, 2024 2:47 pm
- Full Name: Vitalii Feshchenko
- Contact:
Re: Get Proxy date-time
Thank you for answering, David.
-
- Influencer
- Posts: 12
- Liked: 4 times
- Joined: May 29, 2024 2:47 pm
- Full Name: Vitalii Feshchenko
- Contact:
Re: Get Proxy date-time
I ended up with this code below, which seeks the latest component version and parses it:
$proxyHost = $proxy.Server.GetPhysicalHost()
$ProxyComponents = $proxyHost.GetComponents()
$ProxyVersionRaw = $ProxyComponents | Select-Object -ExpandProperty Version | Sort-Object { [version]$_ } -Descending | Select-Object -First 1
$ProxyVersion = "{0}.{1}.{2}.{3}" -f $ProxyVersionRaw.Major, $ProxyVersionRaw.Minor, $ProxyVersionRaw.Build, $ProxyVersionRaw.Revision
$proxyHost = $proxy.Server.GetPhysicalHost()
$ProxyComponents = $proxyHost.GetComponents()
$ProxyVersionRaw = $ProxyComponents | Select-Object -ExpandProperty Version | Sort-Object { [version]$_ } -Descending | Select-Object -First 1
$ProxyVersion = "{0}.{1}.{2}.{3}" -f $ProxyVersionRaw.Major, $ProxyVersionRaw.Minor, $ProxyVersionRaw.Build, $ProxyVersionRaw.Revision
Who is online
Users browsing this forum: No registered users and 16 guests