Closed k-laughman closed 5 months ago
The errors above should be related to running in Windows Powershell vs Powershell 7. Can you confirm the following?
Hi,
I have confirmed through some additional testing that the .29 version is now working when using PowerShell 7. However, the .29 version is still failing with the same errors on PowerShell 5.1:
PS C:\WINDOWS\system32> get-module
ModuleType Version Name ExportedCommands
---------- ------- ---- ----------------
Manifest 3.1.0.0 Microsoft.PowerShell.Management {Add-Computer, Add-Content, Checkpoint-Computer, Clear-Content...}
Manifest 3.1.0.0 Microsoft.PowerShell.Utility {Add-Member, Add-Type, Clear-Variable, Compare-Object...}
Script 2.0.0 PSReadLine {Get-PSReadLineKeyHandler, Get-PSReadLineOption, Remove-PSReadLineKeyHandler, Set-PSReadLineKeyHandler...}
Script 0.29 RubrikSecurityCloud {Connect-Rsc, Disconnect-Rsc, Get-RscCmdlet, Get-RscFileset...}
PS C:\WINDOWS\system32> echo $MssqlLiveMount
CdmId : ed773c28-09fe-4adc-8fd0-aad227404a1e
CreationDate : 4/3/2024 12:43:28 PM
Fid : 57aafa6b-58f1-502c-9abf-9e5067c66090
IsReady : True
MountRequestId :
MountedDatabaseId : 333ebb3b-f00f-4764-bfb3-069496ed281d
MountedDatabaseName : graphql
OwnerId : 0bf8daca-5ab1-4a79-a3a8-7e40a0b544e0
RecoveryPoint : 4/1/2024 8:22:44 AM
UnmountRequestId :
Cluster :
SourceDatabase :
TargetInstance :
PS C:\WINDOWS\system32> Remove-RscMssqlLiveMount -MssqlLiveMount $MssqlLiveMount
The following exception occurred while retrieving member "id": "Could not load file or assembly 'System.ComponentModel.Annotations, Version=4.2.0.0, Culture=neutral,
PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. The system cannot find the file specified."
At C:\Program Files\WindowsPowerShell\Modules\RubrikSecurityCloud\0.29\Toolkit\Public\Remove-RscMssqlLiveMount.ps1:55 char:34
+ $query.Var.input.id = "$($MssqlLiveMount.Fid)"
+ ~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (:) [], ExtendedTypeSystemException
+ FullyQualifiedErrorId : CatchFromBaseGetMember
Exception calling "Invoke" with "0" argument(s): "Could not load file or assembly 'System.ComponentModel.Annotations, Version=4.2.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or
one of its dependencies. The system cannot find the file specified."
At C:\Program Files\WindowsPowerShell\Modules\RubrikSecurityCloud\0.29\Toolkit\Public\Remove-RscMssqlLiveMount.ps1:59 char:9
+ $result = $query.Invoke()
+ ~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (:) [], MethodInvocationException
+ FullyQualifiedErrorId : FileNotFoundException
I will wait for .30 to be released next week and retry/update with that. Thanks.
It works after upgrade to version 1.0
Agreed - just tested it out and it all seems to work with the updated version now. Thank you
RSC Powershell Module Version - .27 Powershell version - 5.1
I have been able to successfully mount and umount SQL Live Mounts through the RSC playground, but an attempt to perform the same operations with the Powershell cmdlets throws errors on the mount and unmount. In this case, I have a Live Mount that is mounted manually, that throws errors trying to delete it: