How do I install the ActiveDirectory Powershell module in windows 8.1? - powershell

I'm trying to use the ActiveDirectory module on a Surface Pro running Windows 8.1, however under Programs and Features | Turn Windows features on or off, it seems that RSAT is no longer listed there. I searched around and not only is a search on this topic flooded with hits for Windows 7, but even the technet article regarding the ActiveDirectory module in 8.1 links to Server 2012 when investigating installation.
Who moved my cheese?

Only servers have RSAT pre-installed. You need to install RSAT before you can activate it on a client OS.
RSAT for 8.1 is available here

Related

Powershell Solution: Run modules not supported on a older version of Powershell

I'm currently trying to remote to multiple servers that are on PowerShell 4.0 whereas the local computer currently runs on 5.0+. I am attempting to query servers that are Server 2016 for the Local Administrator group, but will fail for servers that are on 2012. Which upon researching the error messages for cmdlets from Microsoft.Powershell.LocalAccounts indicates that the modules don't exist for 2012.
Rather than updating the PowerShell version, or installing the modules to each server, I wondering if it's possible to execute cmdlets from the local 2016 into remote sessions of the 2012 servers.
Technically, yes, you could copy modules from the local server to one of the module directories on the remote server's $env:PSModulePath and import them in the remote session, but as #mklement0 stated there is no guarantee current modules will work with PowerShell 4.0, let alone Server 2012.
That said, Microsoft.PowerShell.LocalAccounts is a module provided by PowerShell 5.1, not the OS, and the features should still work on 2012. However, I don't have a 2012 instance I can test with. But you may be able to get your task done by upgrading your servers' PowerShell version to PowerShell 5.1 (Windows Management Framework 5.1) to leverage the additional features and built-in modules this version brings. But any modules that are shipped with later Windows versions and not PowerShell itself will remain unavailable.
$localAdminUsers = net localgroup administrators
After some talking with a colleague, I realized I had overcomplicated my script, when I could have used the command prompt. From there, I parse the string for the users I was looking for.
Thank you for your responses.

FailoverClusters module is not getting listed while running the cmdlet Get-Module -ListAvailable

I tried below command
Get-Module -ListAvailable
But it did not showed me "FailoverClusters" in the list
From where I can download this module? Do I have to install any SDK?
Note: I do not want to install Azure SDK. Is there any other way?
Update
I am using my local windows 10 to remote connect to the Azure Virtual Machine (Windows Server 2012 R2). I do want to manage all configurations using powershell from my local windows 10 machine.
As jisaak already explained, the FailoverClusters module is installed when you install the Failover Clustering feature on a Windows Server.
If, however, you want to manage a cluster from a computer without the Failover Clustering feature installed, this is what you do:
Download the appropriate version of Remote Server Administration Tools
Run the installer
Navigate to the Programs and Features control panel pane (run appwiz.cpl)
Choose "Turn Windows Features on or off"
Find the "Failover Cluster Management" feature under Remote Server Administration Tools
Enable it
Voila
The FailoverClusters Windows PowerShell module is installed on the
computer with the Failover Clustering feature
Source
Install the Failover Clustering Feature

Powershell MQ Snap-in MO74 doesn't work correctly

I have downloaded and installed MO74: WebSphere MQ - Windows PowerShell Library on a Windows Server 2012 with IBM WebSphere MQ Explorer Version: 7.5.0.2
The original website is website http://www-01.ibm.com/support/docview.wss?rs=171&uid=swg24017698&loc=en_US&cs=utf-8&lang=en
I have both tried to install for powershell 64bit and for powershell 32bit.
For 64bit I can add the plugin (Add-PSSnapin IBM.Powershell.WebsPhereMQ) without errors.
Afterwards the commands (for instance a simple Get-WMQQueue) gives no errors but no results as well.
For 32bit I can't even load the plugin.
The error is:
Add-PSSnapin : The Windows PowerShell snap-in 'IBM.Powershell.WebsPhereMQ' is not installed on this computer.
Anyone has this working with Windows Server 2012 and have a clue what can be wrong?
Installed MO74 on Windows Server 2012. System already had MQ8.0 installed on it. The Get-WMQQueue cmdlet works for me.
Got to know from the MO74 developers that MO74 can be used with 32 bit PowerShell only. Support for 64 bit PowerShell is not available yet.

Is it possible to install Remote Server Administrative Tools on a Windows Server 2012?

I understand that RSAT is used to manage domain controllers remotely from a computer that is not a domain controller,I found links to download RSAT for Windows 8, 7 or Vista, but nothing to download it on a windows server. I need to use it on a windows server 2012, is this possible ?
On Windows Server 2012 (and 2008 as well) the Remote Server Administration Tools are available for installation using the Add Roles and Features wizard, so you don't need to download it like you would on a client OS, eg you can install the tools from there without installing the associated roles.
You'll find it under Features and you can then install all of them or just those tools you need. You'll also find Group Policy Management listed separately under the features list, though I'm not sure why it's not listed under the RSAT items.

How to upgrade PowerShell version from 2.0 to 3.0

The OS that I am using is Windows 7, and the PowerShell version that is installed here is 2.0. Is it possible for me to upgrade it to version 3.0 or 4.0?
Because there are cmdlets that version 2.0 can't recognize.
Download and install from http://www.microsoft.com/en-us/download/details.aspx?id=34595. You need Windows 7 SP1 though.
It's worth keeping in mind that PowerShell 3 on Windows 7 does not have all the cmdlets as PowerShell 3 on Windows 8. So you may still encounter cmdlets that are not present on your system.
The latest PowerShell version as of Sept 2015 is PowerShell 4.0. It's bundled with Windows Management Framework 4.0.
Here's the download page for PowerShelll 4.0 for all versions of Windows.
For Windows 7, there are 2 links on that page, 1 for x64 and 1 for x86.
Just run this in a console.
#powershell -NoProfile -ExecutionPolicy unrestricted -Command "iex ((new-object net.webclient).DownloadString('https://chocolatey.org/install.ps1'))" && SET PATH=%PATH%;%systemdrive%\chocolatey\bin
cinst powershell
It installs the latest version using a Chocolatey repository.
Originally I was using command cinst powershell 3.0.20121027, but it looks like it later stopped working. Since this question is related to PowerShell 3.0 this was the right way. At this moment (June 26, 2014) cinst powershell refers to version 3.0 of PowerShell, and that may change in future.
See the Chocolatey PowerShell package page for details on what version will be installed.
Install Chocolatey
Run the following commands in CMD
choco install powershell
choco upgrade powershell
As of today, Windows PowerShell 5.1 is the latest version. It can be installed as part of Windows Management Framework 5.1. It was released in January 2017.
Quoting from the official Microsoft download page here.
Some of the new and updated features in this release include:
Constrained file copying to/from JEA endpoints
JEA support for Group Managed Service Accounts and Conditional Access Policies
PowerShell console support for VT100 and redirecting stdin with interactive input
Support for catalog signed modules in PowerShell Get
Specifying which module version to load in a script
Package Management cmdlet support for proxy servers
PowerShellGet cmdlet support for proxy servers
Improvements in PowerShell Script Debugging
Improvements in Desired State Configuration (DSC)
Improved PowerShell usage auditing using Transcription and Logging
New and updated cmdlets based on community feedback
The latest PowerShell version as of Aug 2016 is PowerShell 5.1. It's bundled with Windows Management Framework 5.1.
Here's the download page for PowerShell 5.1 for all versions of Windows, including Windows 7 x64 and x86.
It is worth noting that PowerShell 5.1 is the first version available in two editions of "Desktop" and "Core". Powershell Core 6.x is cross-platform, its latest version for Jan 2019 is 6.1.2. It also works on Windows 7 SP1.
do use the links above. If you run into error "This update is not applicable to your computer. " then make sure you are in fact using the right file for your os. for example i tried running windows 2012 server from that link on windows 7 service pack 1 and I got the above error so be sure to use the right zip. If you don't know which os you have then go to start and system and it should pop right up This should be self explanatory but