5,443 questions with Windows Server PowerShell tags

Sort by: Updated
1 answer

The cluster is connected to Azure Arc and I can see the cluster resources on azure arc. But when I perform any commands to the cluster from Cloudshell, it says cluster not found under the resource group.

This is the error I'm getting while accessing the cluster on Azure Arc. This is my cluster connected to AzureArc.

Azure Arc
Azure Arc
A Microsoft cloud service that enables deployment of Azure services across hybrid and multicloud environments.
364 questions
Azure Kubernetes Service (AKS)
Azure Kubernetes Service (AKS)
An Azure service that provides serverless Kubernetes, an integrated continuous integration and continuous delivery experience, and enterprise-grade security and governance.
1,951 questions
Windows Server PowerShell
Windows Server PowerShell
Windows Server: A family of Microsoft server operating systems that support enterprise-level management, data storage, applications, and communications.PowerShell: A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
5,443 questions
asked 2024-06-28T15:39:59.9433333+00:00
Nikhitha Chandana Chinthapalli 0 Reputation points
answered 2024-06-29T17:34:15.69+00:00
Sina Salam 6,341 Reputation points
2 answers

How to add a Sql code to a powershell script

backup_report.txtI have the below sql script to check if any failover happened on the last 24 hrs and we want to use that in the existing powershell backup report script to check that condition before it reports, the below sql code only returns a…

Windows Server PowerShell
Windows Server PowerShell
Windows Server: A family of Microsoft server operating systems that support enterprise-level management, data storage, applications, and communications.PowerShell: A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
5,443 questions
asked 2024-06-28T14:46:35.28+00:00
Sara 421 Reputation points
edited a comment 2024-06-28T16:03:58.6966667+00:00
Sara 421 Reputation points
1 answer One of the answers was accepted by the question author.

how to set proxy on invoke-webrequest

can someone help me with how I can pass proxy here in this script and if I am missing any syntax here? Full script in comment section! running into defender.ps1 is not recognized and a invalid err token error Invoke-WebRequest @parameters .\defender.ps1…

Windows Server PowerShell
Windows Server PowerShell
Windows Server: A family of Microsoft server operating systems that support enterprise-level management, data storage, applications, and communications.PowerShell: A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
5,443 questions
asked 2024-06-14T14:10:40.7033333+00:00
Sara 421 Reputation points
accepted 2024-06-28T13:47:04.06+00:00
Sara 421 Reputation points
2 answers

How can I combine 2 get-ADComputer queries in 1

Can someone please help me? I am trying to find computers that match this criteria (see from screenshot Screenshot 2024-06-26 085801.png) Right now I have 2 queries, Find all enabled computers : $allEnabledComputers=Get-ADComputer -Filter…

Windows Server PowerShell
Windows Server PowerShell
Windows Server: A family of Microsoft server operating systems that support enterprise-level management, data storage, applications, and communications.PowerShell: A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
5,443 questions
PowerShell
PowerShell
A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
2,256 questions
asked 2024-06-27T02:44:50.9366667+00:00
Bhutani, Monika 0 Reputation points
answered 2024-06-27T18:59:51.69+00:00
Rich Matheisen 45,591 Reputation points
1 answer

Remove-FileLabel cmdlet is getting stuck sometimes

Hi, I have been exploring the new Microsoft Purview Infromation Protection PowerShell Module. I have been testing Remove-FileLabel cmdlet. Remove-FileLabel -Path "C:\Users\user\Documents\sample" -JustificationMessage "Migration…

Azure Information Protection
Azure Information Protection
An Azure service that is used to control and help secure email, documents, and sensitive data that are shared outside the company.
529 questions
Microsoft Purview
Microsoft Purview
A Microsoft data governance service that helps manage and govern on-premises, multicloud, and software-as-a-service data. Previously known as Azure Purview.
1,018 questions
Windows Server PowerShell
Windows Server PowerShell
Windows Server: A family of Microsoft server operating systems that support enterprise-level management, data storage, applications, and communications.PowerShell: A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
5,443 questions
asked 2024-06-27T06:47:00.7266667+00:00
Sundram Sontirkey 97 Reputation points
answered 2024-06-27T15:31:51.4433333+00:00
Rich Matheisen 45,591 Reputation points
20 answers One of the answers was accepted by the question author.

powershell script to disable and move computers to other ou

I want to disable a bunch of computers and move them to another OU in AD thru Powershell. Cannot get to work though, have tried several scripts but it does not work: cannot find object beneath dc=xxx,dc=xxx However when i do a move adcomputer in…

Windows Server PowerShell
Windows Server PowerShell
Windows Server: A family of Microsoft server operating systems that support enterprise-level management, data storage, applications, and communications.PowerShell: A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
5,443 questions
asked 2021-01-06T09:01:46.277+00:00
corne nietnodig 196 Reputation points
commented 2024-06-27T08:22:18.63+00:00
Huw Jones 0 Reputation points
2 answers One of the answers was accepted by the question author.

Listing file information filtered on values in a file

Hi, I would like to list sizes on all files in a directory, but the listed file names must match filenames picked up from a file. Basic information file size from this; Get-ChildItem -Path "\servername\DATA\files" -File | Select-Object…

Windows Server PowerShell
Windows Server PowerShell
Windows Server: A family of Microsoft server operating systems that support enterprise-level management, data storage, applications, and communications.PowerShell: A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
5,443 questions
PowerShell
PowerShell
A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
2,256 questions
asked 2024-06-26T09:18:57.3433333+00:00
Fredrik M 206 Reputation points
accepted 2024-06-27T07:02:42.51+00:00
Fredrik M 206 Reputation points
1 answer

Powershell - DLP - Add Rules to the DLP Policy

Hi Im trying to making Add Rules to DLP Policy with PowerShell # Add Rules to the DLP Policy $RuleName = "DlpRule" $ContentContainsSensitiveInformation = @( New-DlpSensitiveInformationTypeRuleCondition ` -SensitiveInformationType…

Microsoft Purview
Microsoft Purview
A Microsoft data governance service that helps manage and govern on-premises, multicloud, and software-as-a-service data. Previously known as Azure Purview.
1,018 questions
Windows Server PowerShell
Windows Server PowerShell
Windows Server: A family of Microsoft server operating systems that support enterprise-level management, data storage, applications, and communications.PowerShell: A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
5,443 questions
asked 2024-06-26T06:26:27.2933333+00:00
Sokoban 996 Reputation points
answered 2024-06-27T01:00:10.67+00:00
Ian Xue (Shanghai Wicresoft Co., Ltd.) 32,741 Reputation points Microsoft Vendor
0 answers

Get-AdminPowerApp fails when authenticating using service principal

I registered an application and added it as a Service Principal according to this guide: https://learn.microsoft.com/en-us/power-platform/admin/powershell-create-service-principal. I then logged in as this service principal. I am trying to get a list of…

Windows Server PowerShell
Windows Server PowerShell
Windows Server: A family of Microsoft server operating systems that support enterprise-level management, data storage, applications, and communications.PowerShell: A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
5,443 questions
PowerShell
PowerShell
A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
2,256 questions
asked 2024-06-26T19:53:35.7433333+00:00
FabulousFab 21 Reputation points
1 answer

Powershell to copy the folder and files

Dear All, Currently using the below script to copy the single file but I need to copy folder, subfolder and files also. Can you someone help me with this and I need to see the progress of the copy $sourceFiles = Read-Host "Enter The Restored…

Windows Server PowerShell
Windows Server PowerShell
Windows Server: A family of Microsoft server operating systems that support enterprise-level management, data storage, applications, and communications.PowerShell: A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
5,443 questions
asked 2021-04-15T13:27:10.827+00:00
Kalaimani Thirupathi 411 Reputation points
commented 2024-06-26T16:46:43.04+00:00
Andreas Baumgarten 101.2K Reputation points MVP
1 answer

How to change SQL Server Failover Cluster IP addresses with PowerShell

Hello, I am trying to create a script that will change Windows Failover Cluster and SQL Server Cluster IP addresses. I can do this by using Failover Cluster Manager GUI, but I need to script it in PowerShell. I cannot find any information on how to…

SQL Server
SQL Server
A family of Microsoft relational database management and analysis systems for e-commerce, line-of-business, and data warehousing solutions.
13,166 questions
Windows Server PowerShell
Windows Server PowerShell
Windows Server: A family of Microsoft server operating systems that support enterprise-level management, data storage, applications, and communications.PowerShell: A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
5,443 questions
asked 2024-04-18T20:07:43.18+00:00
Yana Glozman 0 Reputation points
answered 2024-06-26T11:13:58.61+00:00
Kenneth Phillips 0 Reputation points
3 answers

Synchronization of disabled and enabled Onepremise Active Directory users with Microsoft entra

Hi, Currently when I deactivate a user in the Onpremise active directory it remains activated in Microsoft Entra. I want the user's status to be updated as soon as a change is made to the active directory. I looked at the Synchronization Rules Editor…

Active Directory
Active Directory
A set of directory-based technologies included in Windows Server.
6,121 questions
Windows Server PowerShell
Windows Server PowerShell
Windows Server: A family of Microsoft server operating systems that support enterprise-level management, data storage, applications, and communications.PowerShell: A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
5,443 questions
Microsoft Entra ID
Microsoft Entra ID
A Microsoft Entra identity service that provides identity management and access control capabilities. Replaces Azure Active Directory.
20,275 questions
asked 2024-06-20T13:08:14.9433333+00:00
FCH-M365 0 Reputation points
commented 2024-06-26T06:02:26.9733333+00:00
Givary-MSFT 30,071 Reputation points Microsoft Employee
1 answer One of the answers was accepted by the question author.

What is the purpose of enabling Windows Server internal firewall for internal AD Domain servers?

People, I wonder if enabling the internal Windows Server firewall feature is going to be very helpful or not ? Because I must also create the firewall rule to allow RDP on port 3389 and ICMP ping and also the WMI for the PowerShell remoting feature for…

Windows Server 2019
Windows Server 2019
A Microsoft server operating system that supports enterprise-level management updated to data storage.
3,558 questions
Windows Server
Windows Server
A family of Microsoft server operating systems that support enterprise-level management, data storage, applications, and communications.
12,494 questions
Active Directory
Active Directory
A set of directory-based technologies included in Windows Server.
6,121 questions
Windows Server Security
Windows Server Security
Windows Server: A family of Microsoft server operating systems that support enterprise-level management, data storage, applications, and communications.Security: The precautions taken to guard against crime, attack, sabotage, espionage, or another threat.
1,772 questions
Windows Server PowerShell
Windows Server PowerShell
Windows Server: A family of Microsoft server operating systems that support enterprise-level management, data storage, applications, and communications.PowerShell: A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
5,443 questions
asked 2024-05-02T02:33:44.8766667+00:00
EnterpriseArchitect 4,976 Reputation points
edited a comment 2024-06-25T14:08:34.98+00:00
Vadim P 0 Reputation points
1 answer

1. I am Trying to download the Language and Optional Features ISO & Inbox, Apps ISO for Windows Server 2022 Standard Evaluation But I can't find the download link . Please Provide me the Link

Hi Microsoft Team, I'm trying to download the "Language and Optional Features ISO" & "Inbox, Apps ISO" for Edition - "Windows Server 2022 Standard Evaluation", Version - "21H2" from Microsoft officials' website…

Windows 10
Windows 10
A Microsoft operating system that runs on personal computers and tablets.
11,030 questions
Windows
Windows
A family of Microsoft operating systems that run across personal computers, tablets, laptops, phones, internet of things devices, self-contained mixed reality headsets, large collaboration screens, and other devices.
4,984 questions
Windows Server
Windows Server
A family of Microsoft server operating systems that support enterprise-level management, data storage, applications, and communications.
12,494 questions
Windows Server PowerShell
Windows Server PowerShell
Windows Server: A family of Microsoft server operating systems that support enterprise-level management, data storage, applications, and communications.PowerShell: A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
5,443 questions
asked 2024-01-31T12:33:00.8066667+00:00
MANMEET SINGH SAINI 0 Reputation points
commented 2024-06-25T14:01:47.27+00:00
DUO, Patrick 0 Reputation points
1 answer

Windows 2019 servers patch failed

windows 2019 servers getting security patch failed and when I tried manual then stuck on 80% then I tried to clear table but again stuck, what is solution and how to fix this issue. we have tried below steps DISM /Online /Cleanup-Image /RestoreHealth …

Windows Server 2019
Windows Server 2019
A Microsoft server operating system that supports enterprise-level management updated to data storage.
3,558 questions
Windows Server 2012
Windows Server 2012
A Microsoft server operating system that supports enterprise-level management, data storage, applications, and communications.
1,561 questions
Windows Server Security
Windows Server Security
Windows Server: A family of Microsoft server operating systems that support enterprise-level management, data storage, applications, and communications.Security: The precautions taken to guard against crime, attack, sabotage, espionage, or another threat.
1,772 questions
Windows Server PowerShell
Windows Server PowerShell
Windows Server: A family of Microsoft server operating systems that support enterprise-level management, data storage, applications, and communications.PowerShell: A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
5,443 questions
asked 2024-06-25T09:12:44.4633333+00:00
Devesh Mishra (Microland) 0 Reputation points
answered 2024-06-25T13:55:39.1333333+00:00
Daisy Zhou 20,556 Reputation points Microsoft Vendor
2 answers One of the answers was accepted by the question author.

WinGet.exe upgrade --all -Exclude

How to exclude the list of apps [third-party application, MS applications, and MS KBnumbers] while running winget upgrade -all commands. Is there any parameter to exclude any application? It will be appriciated

Windows 10
Windows 10
A Microsoft operating system that runs on personal computers and tablets.
11,030 questions
Windows Server PowerShell
Windows Server PowerShell
Windows Server: A family of Microsoft server operating systems that support enterprise-level management, data storage, applications, and communications.PowerShell: A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
5,443 questions
Microsoft Intune
Microsoft Intune
A Microsoft cloud-based management solution that offers mobile device management, mobile application management, and PC management capabilities.
4,640 questions
asked 2023-04-07T17:32:54.1133333+00:00
Vij 306 Reputation points
commented 2024-06-24T17:21:57.23+00:00
Iandolo, Walter 0 Reputation points
1 answer One of the answers was accepted by the question author.

How to Set the Group of users Password never expire and password not reset via powershell

How to set Group of AD Users Password never expiry and not reset the password Via Powershell

Windows Server PowerShell
Windows Server PowerShell
Windows Server: A family of Microsoft server operating systems that support enterprise-level management, data storage, applications, and communications.PowerShell: A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
5,443 questions
asked 2022-10-06T17:27:08.463+00:00
SN, Yatheesha (Cognizant) 21 Reputation points
accepted 2024-06-24T16:52:46.6166667+00:00
SN, Yatheesha (Cognizant) 21 Reputation points
1 answer

how to enable internet connection share on windows server core 2016

please, how to enable internet connection share on windows server core 2016, just with command line console or powershell.

Windows Server
Windows Server
A family of Microsoft server operating systems that support enterprise-level management, data storage, applications, and communications.
12,494 questions
Windows Server PowerShell
Windows Server PowerShell
Windows Server: A family of Microsoft server operating systems that support enterprise-level management, data storage, applications, and communications.PowerShell: A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
5,443 questions
PowerShell
PowerShell
A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
2,256 questions
asked 2024-06-21T14:44:03.5666667+00:00
jiajia wan 0 Reputation points
commented 2024-06-24T10:44:22.6333333+00:00
jiajia wan 0 Reputation points
1 answer One of the answers was accepted by the question author.

Scripting installation of extension in Edge

What is the best way to force installation of extension in Edge (and Chrome)? I have 2 possibilities but which one is preferred? Use ExtensionSettings registry string and configure the extension Use the ExtensionInstallForceList registry key, obtain…

Microsoft Edge
Microsoft Edge
A Microsoft cross-platform web browser that provides privacy, learning, and accessibility tools.
2,217 questions
Windows Server PowerShell
Windows Server PowerShell
Windows Server: A family of Microsoft server operating systems that support enterprise-level management, data storage, applications, and communications.PowerShell: A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
5,443 questions
asked 2024-06-16T21:34:10.83+00:00
Johan Pol 46 Reputation points
accepted 2024-06-21T21:08:42.8566667+00:00
Johan Pol 46 Reputation points
3 answers

How to get a list of AD users that are set to change password at next logon

Hello, I am trying to export a list of all users in AD including a column for "ChangePasswordAtLogon" attribute. I have tried a lot of different variations but none of them have worked. This is one of the formats that didn't work. …

Active Directory
Active Directory
A set of directory-based technologies included in Windows Server.
6,121 questions
Windows Server PowerShell
Windows Server PowerShell
Windows Server: A family of Microsoft server operating systems that support enterprise-level management, data storage, applications, and communications.PowerShell: A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
5,443 questions
PowerShell
PowerShell
A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
2,256 questions
asked 2024-06-19T22:39:41.01+00:00
Vahid 0 Reputation points
answered 2024-06-20T15:03:03.7433333+00:00
Rich Matheisen 45,591 Reputation points