-
- Service Provider
- Posts: 105
- Liked: 7 times
- Joined: Aug 24, 2010 8:55 am
- Full Name: Alex
- Contact:
set repository credentials
Maybe I've overlooked something but how would I set credentials for existing repositories?
Regards,
Alex
Regards,
Alex
-
- Veteran
- Posts: 293
- Liked: 19 times
- Joined: Apr 13, 2011 12:45 pm
- Full Name: Thomas McConnell
- Contact:
Re: set repository credentials
off the top of my head you would use Get-VBRServer to pull the one hosting the repo and there is a method in there to set it(.setcred() or something to that effect (Use "Get-VBRServer - Name "RepoServer" | gm" to get a list), I'm just powering up the lab and will provide a more detailed post soon
-
- Veteran
- Posts: 293
- Liked: 19 times
- Joined: Apr 13, 2011 12:45 pm
- Full Name: Thomas McConnell
- Contact:
Re: set repository credentials
Forget to ask, what type of repo is it? (Win/Linux/CIFS)
-
- Service Provider
- Posts: 105
- Liked: 7 times
- Joined: Aug 24, 2010 8:55 am
- Full Name: Alex
- Contact:
-
- Veteran
- Posts: 293
- Liked: 19 times
- Joined: Apr 13, 2011 12:45 pm
- Full Name: Thomas McConnell
- Contact:
Re: set repository credentials
If it was any other one I would have had the answer a while ago lol
Code: Select all
$repo = Get-VBRBackupRepository -Name CIFS
$creds = New-Object -TypeName Veeam.Backup.Common.CCredentials -ArgumentList "testdomain\User","Password",0,1
$credentials = New-Object -Type Veeam.Backup.Model.CDbCredentialsInfo -ArgumentList $repo.ShareCredsId, $creds
$manager = [Veeam.Backup.DBManager.CDBManager]::Instance
$manager.Credentials.UpdateCredentials($credentials)
-
- Service Provider
- Posts: 105
- Liked: 7 times
- Joined: Aug 24, 2010 8:55 am
- Full Name: Alex
- Contact:
Re: set repository credentials
Hi Thomas,
Your code works BUT only for changing existing credentials, in my case I do not have credentials in place yet. So the checkbox also needs to be set.
Thank you very much for your quick replies and efforts so far.
Regards,
Alex
Your code works BUT only for changing existing credentials, in my case I do not have credentials in place yet. So the checkbox also needs to be set.
Thank you very much for your quick replies and efforts so far.
Regards,
Alex
-
- Veteran
- Posts: 293
- Liked: 19 times
- Joined: Apr 13, 2011 12:45 pm
- Full Name: Thomas McConnell
- Contact:
Re: set repository credentials
Hi Alex, I can't seem to find how to do it, what's funny is I can't get credentials enabled at all when using Powershell with CIFS, the other types get there creds from the stored hosts(why I suggested Get-VBRServer in my first post) but CIFS seems to have me scratching my head as to how your suppose to enable it, as the Add-VBRBackupRepository seems more geared towards the Win/Linux ones and doesn't take a input for what we're trying to do. I'd advise you to open a support case as I might have missed something.
-
- VP, Product Management
- Posts: 7081
- Liked: 1511 times
- Joined: May 04, 2011 8:36 am
- Full Name: Andreas Neufert
- Location: Germany
- Contact:
Re: set repository credentials
just a small idea. edit one of your repositories mannual with all neccesarry settings. then copy it with powershell and do the neccesarry changes. copy instead of creating a new one. maybe this is a workaround.
Who is online
Users browsing this forum: Bing [Bot] and 9 guests