Replies: 10 comments 5 replies
-
That looks like it would be on the attempt to connect to the server. If you execute the command in a fresh PowerShell session, after the error run |
Beta Was this translation helpful? Give feedback.
-
Did run Get-DbaAvailabilityGroup Server, then $error[0] 1 select *. Did get this: writeErrorStream : True Strugling to understand this, so if someone has anything here would be very grateful :). BrF |
Beta Was this translation helpful? Give feedback.
-
Did see this: "Failed to connect to server Data Source=Server;Integrated Security=True |
Beta Was this translation helpful? Give feedback.
-
Ok been digging into this. And it's my fult :(. I did only load the following Assembly's: When i did load the rest of them: "Microsoft.SqlServer.Dmf ", There was no problem, the Get-DbaAvailabilityGroup worked like a charme :) Hope this can help othere that get's this problem :). |
Beta Was this translation helpful? Give feedback.
-
You are correct, did take away all the loading of assembly's. And it worked. Sorry for make my post abow, that is not correct. Tnx |
Beta Was this translation helpful? Give feedback.
-
dbatools commands started throwing this error today: I was running the commands from this version of PowerShell: PSVersion 5.1.17763.3770 I've tried uninstalling and reinstalling the module. A restart of the PowerShell window resolved the issue. Let me know if you need additional information. |
Beta Was this translation helpful? Give feedback.
-
Name Version dbatools 2.0.4 |
Beta Was this translation helpful? Give feedback.
-
I just hit the error again. Here is a list a loaded modules: dbatools 2.0.4 |
Beta Was this translation helpful? Give feedback.
-
Shawn,
Thanks.
Frank
[Logo Description automatically generated]
Frank Gill
Senior Consultant
Fortified Data
***@***.******@***.***>
O – 980.353.3572
Emergency Production Support
1.844.282.DATA(3282)
DATABASE MANAGED SERVICES | DATABASE CONSULTING SERVICES | DATA TIER ASSESSMENTS
From: Shawn Melton ***@***.***>
Sent: Monday, June 19, 2023 10:18 PM
To: dataplat/dbatools ***@***.***>
Cc: Frank Gill ***@***.***>; Comment ***@***.***>
Subject: Re: [dataplat/dbatools] Powershell and dbatools - Get-DbaAvailabilityGroup (Discussion #8783)
CAUTION: This email originated from outside of the organization. Do not click links or open attachments unless you recognize the sender and know the content is safe.
SQLPS is your issue. Can't load that module.
—
Reply to this email directly, view it on GitHub<#8783 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AXUZASXM45BMBINLWNMVGZLXMEI7FANCNFSM6AAAAAAVNCQZPA>.
You are receiving this because you commented.Message ID: ***@***.******@***.***>>
|
Beta Was this translation helpful? Give feedback.
-
Chrissy,
Thanks. This issue just bit me in another scenario, so I was able to knock out a longstanding problem last night.
Frank
[Logo Description automatically generated]
Frank Gill
Senior Consultant
Fortified Data
***@***.******@***.***>
O – 980.353.3572
Emergency Production Support
1.844.282.DATA(3282)
DATABASE MANAGED SERVICES | DATABASE CONSULTING SERVICES | DATA TIER ASSESSMENTS
From: Chrissy LeMaire ***@***.***>
Sent: Tuesday, June 20, 2023 7:12 AM
To: dataplat/dbatools ***@***.***>
Cc: Frank Gill ***@***.***>; Comment ***@***.***>
Subject: Re: [dataplat/dbatools] Powershell and dbatools - Get-DbaAvailabilityGroup (Discussion #8783)
CAUTION: This email originated from outside of the organization. Do not click links or open attachments unless you recognize the sender and know the content is safe.
Looks like SQLPS could be the problem. That is an unsupported scenario (using both in one session) because super weird things happen when both are loaded.
—
Reply to this email directly, view it on GitHub<#8783 (reply in thread)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AXUZASSHJFWB5ONPEH754MLXMGHRJANCNFSM6AAAAAAVNCQZPA>.
You are receiving this because you commented.Message ID: ***@***.******@***.***>>
|
Beta Was this translation helpful? Give feedback.
-
Hi, I'm new to powershell and dbatools. Did get a recomondation on dbatools from my MS PFE. So started to play with it, and so happy I found this. Made my days :).
But I get a problem with the command: Get-DbaAvailabilityGroup
When i run it with -SqlInstance Server01, I get the following error:
[Get-DbaAvailabilityGroup] Failure | The value's length for key 'data source' exceeds it's limit of '128'.
I have tryed to move the dbatools to another disk and folder, have remembere to update the enviroment path for PS.
Nothing helps, anyone know how to fix this problem. It's not the dbatool module because it works fine in my test enviroment. So has to be somthing on my prod admin server.
That server is: Windows Server 2016 with all current windows update.
Powershell versjon:
Name Value
PSVersion 5.1.14393.5582
PSEdition Desktop
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0...}
BuildVersion 10.0.14393.5582
CLRVersion 4.0.30319.42000
WSManStackVersion 3.0
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1
Tnx
Trond
Beta Was this translation helpful? Give feedback.
All reactions