Microsoft Q&A

Windows Server PowerShell

4,756 questions

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.

Browse all Windows tags

4,756 questions with Windows Server PowerShell tags

Sort by: Updated
4 answers

How to copy folder/subfolders from source to destination using csv in powershell

Hello, I am a new to Powershell and I have been given a task to copy all folders/subfolders files from source to destination using csv file in powershell. I have managed to pull files from source to one destination but what if I need to copy the same…

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.
4,756 questions
asked 2021-09-16T18:50:38.817+00:00
Akshay Solanki 1 Reputation point
commented 2023-03-30T04:51:20.2333333+00:00
Nikhilesh Mehta 0 Reputation points
2 answers

How to extract used or free ips for all vnet with ip address space in powershell script

Extract used or free ips for all vnet with subnet and also giving the ip address space for bith vnet by using powershell. and also get the result for extracting output in CSV file.

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.
4,756 questions
Azure Virtual Machines
Azure Virtual Machines
An Azure service that is used to provision Windows and Linux virtual machines.
4,924 questions
Azure Active Directory
Azure Active Directory
An Azure enterprise identity service that provides single sign-on and multi-factor authentication.
13,643 questions
asked 2023-03-27T11:19:14.5166667+00:00
Saranya Manivannan 0 Reputation points
commented 2023-03-29T12:55:36.2533333+00:00
KapilAnanth-MSFT 11,611 Reputation points Microsoft Employee
1 answer

windows winrm server keeps replying 400 when I try to send encrypted kerberos message over HTTP

To start with, our product is written in Java, we use a custom transport that wraps org.apache.http.client and javax.security.auth to communicate to windows Remote management service. What we have now: firstly we authenticate through kerberos, then send…

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.
4,756 questions
Hyper-V
Hyper-V
A Windows technology providing a hypervisor-based virtualization solution enabling customers to consolidate workloads onto a single server.
1,947 questions
Windows Server
Windows Server
A family of Microsoft server operating systems that support enterprise-level management, data storage, applications, and communications.
8,873 questions
asked 2023-03-28T19:43:05.5366667+00:00
zbeyebee 20 Reputation points
answered 2023-03-29T11:25:40.86+00:00
Limitless Technology 17,121 Reputation points
1 answer One of the answers was accepted by the question author.

How to give random bandwidth value using Windows Powershell?

I want to assign a random bandwidth value to my Windows machine using Powershell only. Does anyone know any commands to do this?

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.
4,756 questions
asked 2023-03-29T06:20:06.4766667+00:00
Ayushi Chaudhuri 120 Reputation points
accepted 2023-03-29T11:03:19.56+00:00
Ayushi Chaudhuri 120 Reputation points
1 answer

i tried to upgrade win 10 to win 11,but after upgrade my system bit locker was pause

Untitled.png I have a Dell Latitude 3420 laptop that I upgraded from Windows 10 to Windows 11. My laptop's BitLocker paused after I upgraded the operating system. When I right-clicked on the C drive, there was an option like resume BitLocker…

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.
4,756 questions
Windows 11
Windows 11
A Microsoft operating system designed for productivity, creativity, and ease of use.
4,135 questions
asked 2023-03-29T05:24:05.8766667+00:00
Jishnu K H 0 Reputation points
answered 2023-03-29T10:40:01.43+00:00
Limitless Technology 17,121 Reputation points
0 answers

add normal user or users to local administrator group for certain time through GPO and PowerShell

Hi besides adding a normal user to the local administrator manually on his computer. how to add a normal user or users to the local administrator group on their computer for a certain time, where the user or users are automatically removed from the local…

PowerShell
PowerShell
A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
406 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.
4,756 questions
Windows Group Policy
Windows Group Policy
A feature of Windows that enables policy-based administration using Active Directory.
2,018 questions
Windows 10
Windows 10
A Microsoft operating system that runs on personal computers and tablets.
6,720 questions
asked 2023-03-29T10:02:20.36+00:00
SysAdmin 81 Reputation points
2 answers One of the answers was accepted by the question author.

How to get a list of shared links in a SharePoint Online document library? Any PowerShell or other way?

Hi there How to get a list of shared links in a SharePoint Online document library? Any PowerShell or other way? (Shared links when we click on the ellipsis next to a folder/file, and click Share, and type the emails of users) Thanks.

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.
4,756 questions
SharePoint
SharePoint
A group of Microsoft Products and technologies used for sharing and managing content, knowledge, and applications.
6,486 questions
asked 2022-09-02T20:41:59.363+00:00
frob 3,951 Reputation points
commented 2023-03-29T09:48:42.9866667+00:00
Bokhorst, Sjaco 1 Reputation point
0 answers

How to access sharepoint pages by authenticate using ADFS token - powershell or c# - On Premises

Hello, I have a requirement to warmup my SharePoint sites using PowerShell. My PowerShell script was running good the way of authentication using FEDAuth cookie using Invoke-webrequest & response. Now ADFS implemented their new changes (Self…

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.
4,756 questions
Active Directory Federation Services
Active Directory Federation Services
An Active Directory technology that provides single-sign-on functionality by securely sharing digital identity and entitlement rights across security and enterprise boundaries.
993 questions
SharePoint Server Development
SharePoint Server Development
SharePoint Server: A family of Microsoft on-premises document management and storage systems.Development: The process of researching, productizing, and refining new or existing technologies.
1,382 questions
asked 2020-09-21T21:35:55.883+00:00
S, Vijaivel (Cognizant) 0 Reputation points
commented 2023-03-29T08:49:12.7966667+00:00
Akbar Husain 0 Reputation points
1 answer One of the answers was accepted by the question author.

How to install SmbBandwidthLimit in Powershell?

I am trying to install SMB Bandwidth Limit feature but I am getting error, showing "The SMB Bandwidth Limit Feature is not installed". When I am trying to install it using Install-WindowsFeature FS-SMBB , it is showing "The term…

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.
4,756 questions
asked 2023-03-27T09:04:32.0466667+00:00
Ayushi Chaudhuri 120 Reputation points
accepted 2023-03-29T06:18:16.1666667+00:00
Ayushi Chaudhuri 120 Reputation points
2 answers One of the answers was accepted by the question author.

Log Parser + how to use dynamic filelogdate

I am trying to write a query in Log Parser 2.2 to dynamically fill in the LogFileDate field with todays date. I have to do this since W3C format doesn't allow for -iCheckPoint From my research, I can use powershell and the get-date function: E:"Log…

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.
4,756 questions
asked 2023-03-28T16:04:29.4566667+00:00
Jeff Harding 41 Reputation points
commented 2023-03-28T21:44:07.9266667+00:00
Jeff Harding 41 Reputation points
4 answers One of the answers was accepted by the question author.

deploy powershell script

Hi All i want to deploy below PowerShell script using sccm on a collection. The script is working fine but how do i know how many servers this script got deployed successfully and on how many servers the script got failed. $registryPath =…

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.
4,756 questions
Microsoft Configuration Manager
Microsoft Configuration Manager Application
Microsoft Configuration Manager Application
Microsoft Configuration Manager: An integrated solution for for managing large groups of personal computers and servers.Application: A computer program designed to carry out a specific task other than one relating to the operation of the computer itself, typically to be used by end users.
359 questions
Windows Server 2019
Windows Server 2019
A Microsoft server operating system that supports enterprise-level management, data storage, applications, and communications.
2,426 questions
asked 2023-03-27T22:41:12.19+00:00
Glenn Maxwell 6,911 Reputation points
accepted 2023-03-28T20:42:19.8366667+00:00
Glenn Maxwell 6,911 Reputation points
4 answers

Why can't I use Invoke-WebRequest twice?

Hi All, I need to rely on the first Invoke-WebRequest to piece together a URL for the second Invoke-WebRequest, but the second time is forcibly terminated. My Script: Import-Module -ErrorAction Stop…

PowerShell
PowerShell
A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
406 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.
4,756 questions
asked 2023-03-25T04:01:16.9866667+00:00
Hsieh, Iverson 45 Reputation points
commented 2023-03-28T17:04:04.76+00:00
MotoX80 24,716 Reputation points
3 answers

Active Directory managed service account clarification

Hello Everyone, I need some clarification and assistance in creating the gMSA that will be used in every IIS server across the Single Forest AD domain. How can I check if My AD Domain is capable of creating this gMSA ? Any assistance would be very much…

PowerShell
PowerShell
A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
406 questions
Windows Server
Windows Server
A family of Microsoft server operating systems that support enterprise-level management, data storage, applications, and communications.
8,873 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.
4,756 questions
Active Directory
Active Directory
A set of directory-based technologies included in Windows Server.
3,993 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,362 questions
asked 2023-03-28T04:08:23.7633333+00:00
EnterpriseArchitect 2,456 Reputation points
answered 2023-03-28T15:33:17.0166667+00:00
Limitless Technology 17,121 Reputation points
2 answers

How to troubleshoot body of email is blank in Powershell emailing?

This is my code. The email comes through but the body is blank. If I do sendMail("This is a test") it does come through with that text in the body though. $servers =…

PowerShell
PowerShell
A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
406 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.
4,756 questions
asked 2023-03-27T19:11:11.0733333+00:00
CharlieLor 451 Reputation points
commented 2023-03-28T15:00:14.7333333+00:00
Rich Matheisen 36,331 Reputation points
4 answers

Win11 22H2 Broke PINTOHOME GPO Logon Script

I use a script set to run at logon to pin network folders to quick access on user desktops. After this update users that logon no longer see their shared folders. I am guessing it is due to the quick access being changed to "Home" in Windows 11…

Windows Group Policy
Windows Group Policy
A feature of Windows that enables policy-based administration using Active Directory.
2,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.
4,756 questions
asked 2022-12-05T20:25:16.807+00:00
John R 1 Reputation point
answered 2023-03-28T10:25:55.1633333+00:00
CrankyZZ 0 Reputation points
2 answers

How to Get Xpath the href for this url?

Hi All, About https://www.adobe.com/devnet-docs/acrobatetk/tools/ReleaseNotesDC/index.html this url, I need to get the href in the topmost position. Since his href is in a different position every time, how can I fix the href in the top link and get the…

PowerShell
PowerShell
A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
406 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.
4,756 questions
asked 2023-03-24T08:28:32.1733333+00:00
Hsieh, Iverson 45 Reputation points
commented 2023-03-28T03:49:45.3266667+00:00
Hsieh, Iverson 45 Reputation points
1 answer

WinRM cannot process the request.

I have local admin right on all remote servers that I'm trying to query the expiring certificate. I'm also able to query this same remote server for their Sql Server version by using Invoke-Sqlcmd -query "select @@version" -ServerInstance…

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.
4,756 questions
PowerShell
PowerShell
A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
406 questions
asked 2023-03-27T17:47:18.53+00:00
CharlieLor 451 Reputation points
commented 2023-03-27T21:06:06.3433333+00:00
Rich Matheisen 36,331 Reputation points
1 answer

Powershell 5.1 not accepting keyboard input when using Remote Desktop HTML5 Web Client

Install the latest RDS HTML5 client on a RDS deployment as specified here: https://learn.microsoft.com/en-us/windows-server/remote/remote-desktop-services/clients/remote-desktop-web-client-admin Open a web browser session and start an RDS session. …

PowerShell
PowerShell
A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
406 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.
4,756 questions
Remote Desktop
Remote Desktop
A Microsoft app that connects remotely to computers and to virtual apps and desktops.
3,236 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.
297 questions
asked 2023-03-24T15:25:41.6533333+00:00
Ag-8821 31 Reputation points
answered 2023-03-27T12:06:23.72+00:00
Limitless Technology 17,121 Reputation points
3 answers

some properties are null inside parallel foreach block

For below sample code, $_.lastLogonTimestamp is always Null. Any idea? Most other properties can be retrieved OK. $users=get-aduser -filter * -properties lastLogonTimestamp $users|foreach -parallel{ $_.lastLogonTimestamp # this…

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.
4,756 questions
asked 2023-03-25T02:36:18.07+00:00
jl 81 Reputation points
answered 2023-03-27T11:50:55.38+00:00
jl 81 Reputation points
3 answers One of the answers was accepted by the question author.

Exporting user last login to M365 or Azure to .CSV file ?

How can I extract and export the last user login time to the M365 portal or Azure AD as .CSV file? is there any PowerShell script or GUI procedure?

Azure Active Directory
Azure Active Directory
An Azure enterprise identity service that provides single sign-on and multi-factor authentication.
13,643 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.
4,756 questions
asked 2022-10-10T13:43:24.61+00:00
EnterpriseArchitect 2,456 Reputation points
commented 2023-03-27T10:08:10.2666667+00:00
Vidar Andersen 0 Reputation points