February 26, 2020 at 7:19 pm
Greetings,
Given this Powershell SMO method call...
$_cert.Export("$CertificateLocation\$_cert_name.cer", `
"$PrivateKeyLocation\$_cert_name.pvk", `
$_secret)
where $_cert is a Microsoft.SqlServer.Management.Smo.Certificate object and the arguments are plain strings (not secure strings).
When I execute the code it returns a FailedOperationError. I can't figure out why it is failing. I have tested all the paths in the script to ensure it has access. I've written test files from within the script to ensure it is not a permissions issue. Information in the exception has been no help. I'm frustrated and would appreciate any help figuring this out.
I can hear someone thinking "why don't you just use t-sql to backup the certificates?" I prefer the flexibility of executing the script from a central location and not needing to give the SQL service account to some file share.
Thanks.
February 27, 2020 at 8:10 pm
Thanks for posting your issue and hopefully someone will answer soon.
This is an automated bump to increase visibility of your question.
June 23, 2020 at 7:46 am
What is the Meaning of SMO/RMO/DMO ???
Anyone explain in brief ???
Viewing 3 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic. Login to reply
This website stores cookies on your computer.
These cookies are used to improve your website experience and provide more personalized services to you, both on this website and through other media.
To find out more about the cookies we use, see our Privacy Policy