An interactive shell, scripting and programming language, and surrounding environment from Microsoft. Commonly used by system administrators managing Microsoft software (including Windows, Exchange, SharePoint, and cloud services Azure and Office 365), PowerShell is included by default with Windows, ...

learn more… | top users | synonyms (1)

1
vote
0answers
45 views

Powershell IIS plugin - cmdlets not working

I'm pretty much a novice at Powershell so bear with my noobness. I'm specifically trying to run the "Get-WebBinding" cmdlet (which I have successfully run on some of my other servers) Windows Server ...
1
vote
1answer
89 views

Remote location management copy and install large software updates to 50 LAN

Initially posted to Stack Overflow and was directed here. I'm new to programming and am trying to write a powershell script to manage software updates. I'm in a windows domain environment with over ...
4
votes
1answer
936 views

Cannot connect to Office 365 with PowerShell

I want to connect to Office 365 through powershell, referring to the tutorials a very simple task. But apparently not for me. I think I missed a simple but important trivia. Some info: license is ...
0
votes
1answer
95 views

Trouble with embedding html email with PowerCLI/Powershell for gmail

I am new to Powershell, I am a junior admin for a VMware environment. I am trying to automate a weekly report for snapshots in PowerCli. I am making the script in Powershell. I have made a simple ...
1
vote
0answers
105 views

Create shared folder on share automatically

I know there is a group policy where I can map a specific share. What if I want the group policy to create a folder on that share and map it during log on? I know there must be a way to do this in ...
3
votes
1answer
52 views

Exchange 2013: Weekly Message Count

I have a manager needing to check on an employees sent and received message count as the employee is stating they are getting too much mail compared to others in the company. I've been checking ...
0
votes
0answers
24 views

Access denied on service password change [duplicate]

This works if I change the password manually but I get an access denied message. I think it might be how I am trying to do it. #Service Credential Change -Multi #This script allows us to input a ...
1
vote
2answers
2k views

Access already mapped network drive in PowerShell

I am running a Windows Server 2012 installation inside VMWare Workstation. I have shared folders enabled, so drive Z: is mapped to \\vmware-host. I can correctly access this drive in Explorer (I can ...
1
vote
0answers
70 views

PowerCLI automation set-cddrive error

When attempting to change ISOs on a powered on guest instance, set-cddrive is returning an error but completing the command. A couple different commands produce the same result: $theVM | Get-CDDrive ...
0
votes
0answers
117 views

Can't log into Exchange Management Shell and EAC in Exchange 2013 via Server 2012 R2

I'm not sure why but I my Exchange PowerShell can't log into my Exchange server and I can't access the EAC via localhost or the URL. I did notice that I enabled HTTP Proxy in IIS and that I used ...
0
votes
1answer
183 views

Reflect HKLM registry changes to HKCU

Ok so I have a Local Group Policy (under Computer Config, not User Config) to force install extensions in Chrome. This policy needs to run for every user of the computer. The value is going to change ...
0
votes
1answer
112 views

AAD Sync not able to connect to online service using powershell

When trying to connect to my Office 365 tenant using connect-msolservice from powershell I get the following error: Connect-MsolService : The HTTP request was forbidden with client authentication ...
2
votes
0answers
98 views

Viewing Storage Space allocation for physical disk

I have a server that had four disks (2x 4TB and 2x 3TB drives) in a Server 2012 R2 Storage Pool. There are two virtual disks in the pool - a parity disk and a mirrored disk. The idea was to add two ...
4
votes
1answer
995 views

Search-ADAccount :: Finding Inactive, Disabled or Expired Accounts

The Search-ADAccount cmdlet has switches -AccountDisabled, -AccountExpired and -AccountInactive; the results of which may not be mutually exclusive nor inclusive. i.e. an account which was disabled ...
0
votes
2answers
47 views

How do you edit a Powershell script to continue on an error?

I modified this script(https://gallery.technet.microsoft.com/scriptcenter/Create-HTML-Uptime-and-68e6acc0) to hit multiple servers, but it doesn't generate a report even if only one of the systems are ...
1
vote
1answer
88 views

PSTerminalServices returning no details about session

I am connected to a machine using RDP but when I call the following (using PSTerminalServices via powershell): get-tssession -computername thecomputer I get: Exception calling "GetSessions" with ...
1
vote
2answers
562 views

Set NTP server on all AD members (old and newly connected) using w32tm or PowerShell?

I am looking for a PowerShell script that I run one time only on the DC. I found w32tm but I don't know how to use it. Thanks in advance!
3
votes
1answer
808 views

Can vSphere PowerCLI cmdlets execute from a PS1 file?

I'm looking to write an admin script that will: Delete a VM from vSphere Delete the VM's DNS entry Release the VM's IP address with our Windows DHCP server I can accomplish the first item via ...
4
votes
0answers
76 views

Besides looking dumping $PSVersionTable and dumping the variable and env “PS-Drives”, what else can I do to compare PowerShell environments?

Besides looking dumping $PSVersionTable and dumping the variable and env "PS-Drives", what can I do to compare PowerShell environments? Here's the problem: I have very similar machines running ...
1
vote
0answers
204 views

“Please Wait” When running startup script, only on Windows 8.1

I have a startup script and I have been testing it on 3 different virtual machines. These machines are running different versions of Windows(7, 8, and 8.1). They all have the same Group Policy applied ...
0
votes
2answers
39 views

Setting to Show/Hide Hidden items on a Folder

Where is the setting to display or not display hidden items on a particular folder? For example, if the global setting is to show all hidden files, how would I change the seeing on the Desktop ...
0
votes
2answers
220 views

Generate List of IP's With User Names On Windows Network

We recently setup GFI WebMonitor on our network which is giving me back IP's instead of User's. I'm in the process of determining whether we will be able to implement authentication on the proxy to ...
1
vote
1answer
239 views

How can i create an install a domain signed certificate in IIS using PowerShell?

In my environment we host a whole lot of websites and WCF webservices in IIS (on Windows 2008 R2 and Windows 2012). We are in the process of enabling HTTPS on these sites. This goes as follows: ...
1
vote
1answer
62 views

Setting HomePath to EmployeeNumber as a variable

We are planning to use the EmployeeNumber user attribute in AD to create the path to each user's Home drive. Reason for this is that AD user names are currently based on last name, which changes often ...
4
votes
1answer
195 views

Win32_OperatingSystem.FreePhysicalMemory and $_.TotalVisibleMemory giving output in wrong units

I've been putting together a pretty simple script to monitor some aspects of our Terminal Server farm usage and am implementing a section where I check the memory usage on the servers at a given point ...
1
vote
0answers
281 views

Powershell execute Queries using SQLPLUS

I have a RHEL server with Oracle 10G installed. I need to write a powershell script to query my database and get the output. I have imported Posh-SSH module and am able to connect to my RHEL server ...
1
vote
1answer
119 views

How does SCSM Relate Affected Users to Service Requests?

I'm using the built in SCSM cmdlets and the SMlets powershell module. I'm able to query Service Requests, but I can't seem to figure out how to get the Affected User of a given Service Request. I'm ...
0
votes
0answers
100 views

Windows PE: Powershell is not installed & error 0x80070002

Trying to run a task sequence. In the last step, I'm trying to run a powershell-script to install various IIS-features. At this step the task sequence terminates with an error (can't remember error ...
1
vote
1answer
116 views

Powershell DSC uses the incorrect certificate file for encryption where node names partially match?

I think there's a bug in the way that DSC chooses the certificate file that is used for credential encryption, such as with the Service resource and a PSCredential. The DSC configuration uses the ...
1
vote
1answer
50 views

Powershell: Pass parameter by name toa com object function

How can I pass parameters to a com-object function by name rather than by position? Specifically, I've a com-object function (Word document com-object SaveAs2) and for example I want to pass values ...
0
votes
0answers
78 views

Access denied while settings FSRM quotas with powershell

I'm trying to set size quotas on the users personal directories in the organization. When using the Gui (fsrm snap-ins), everything works as expected. When trying to use powershell cmdlets to ...
2
votes
1answer
925 views

Get-ADUser -Properties MemberOf returns nothing

Something that is kind of weird that I haven't ran into before. We just did a domain migration and so now when I run a Get-ADUser {username} -Properties MemberOf against a standard user the MemberOf ...
1
vote
1answer
27 views

Large number of unmanagable groups in Exchange 2010 following migration from Exchange 2003

Recently we migrated from Exchange 2003 to 2010, and now we have many groups greyed out in the 2010 Exchange Management Console, because they are not Universal Groups. While these groups are ...
0
votes
0answers
44 views

Is it possible to create my own custom SQL 'trigger' with Powershell?

I'm familiar with MSSQL triggers already, however they aren't fine grained enough for what I want to do. In my scenario I want the trigger to fire after a row containing certain information lands in ...
1
vote
1answer
70 views

Using reflection in Powershell with different .NET framework versions

I am trying to reflect some assembly attributes from a .NET assembly. I am using Powershell 2.0, but the assembly was written using .NET Framework 4.5.1, so when I try the following command: ...
6
votes
1answer
325 views

How can I modify an existing scheduled task using Powershell?

I am working on some release automation scripts that use Powershell to update existing scheduled tasks which execute various applications. In my script, I can set the Path and Working Directory of the ...
0
votes
1answer
86 views

Powershell - Using a WHERE clause after an @{name alias not returning anything

Can I not use a WHERE in the pipe after an @{name alias? I have to use custom column headers in my output so I am using the @{name syntax. Later in the pipe, the sort works using the alias I've given ...
0
votes
1answer
204 views

Powershell: invoke-expression with “find”-command

I need to call DISM.exe via its absolute path which changes dependent on system architecture. Therefore, I store the filepath of dism.exe in a variable and then proceed to execute the wntire command ...
0
votes
2answers
127 views

Static IP injection to guest VM in Win2k8

Is there a way to inject IP address and do network configuration of a CentOS VM running on Windows server 2008? In Win2k12 there is SetGuestNetworkAdapterConfiguration using which IP address can be ...
0
votes
0answers
25 views

EventLog Source “Connect”. No events in EventLog

I'm baffled by this, as I can find no documentation on wether or not "Connect" or "Connection" is some kind of registered keyword for EventLog Sources. I'm trying to create an EventLog Source called ...
2
votes
0answers
43 views

Deploying Server 2012 with DNS role using WDS and answer file

I want to deploy an image using WDS on Server 2012. I will be using an answer file for unattended installation with little touch as possible. My answer file works great but I can't get the auto-logon ...
0
votes
0answers
154 views

Exchange 2013 Powershell: Setting up Public Folder Mailbox in multi-tenant topography

My exchange system has multiple habitats/tenants (i.e. domains). How do I set my public folder mailbox system? Do I set one up for each habitat (tenant)? If so, what is the syntax? Or do I set one ...
0
votes
1answer
85 views

CloudFormation powershell to run as domain admin + elevated priviledge

So... I'm writing some cloud formation templates. Using cfn-init, I get the machine to join the domain, and now I need to run in a Domain Admin context as local admin with elevated privilege to: ...
0
votes
1answer
66 views

Allowing multiple executables into a “Run only specified applications” group policy at one time

At my workplace we whitelist executables using a "Run only specified Windows applications" group policy applied to the domain. At certain times we need to whitelist large number of executables at a ...
1
vote
1answer
241 views

Some groups show no members in Get-ADGroup

So I have a question about strange PowerShell behavior with Get-ADGroup. If I use it on a group I created, I can get members just fine. But on some (not all) built in groups, including Domain Users, ...
2
votes
4answers
292 views

Different group policies in one domain

I'm using powershell to display the password expiration of an account before I reset it at work. But the global GP from what I can see, is 180 days, and there are some employees who have 90 days set ...
1
vote
1answer
238 views

Allow Enter-PSSession to work from local systems account

I have a PowerShell script that creates a Windows PowerShell session (PSSession) on a remote server via Enter-PSSession, both servers are not connected to a DOMAIN. This script is called from a ...
0
votes
1answer
53 views

Need looping Powershell script to email me when site has error message [closed]

Running 08 windows server on a VM We need to be notified by email or by other means whenever the site is either 404 or goes to maintenance page. Therefore, we need the script to be constantly ...
1
vote
1answer
1k views

Windows 2012 R2 RDS - can't change Connection Broker DNS round robin name via Powershell

I'm running into an issue when setting up a Windows 2012 R2 RDS Farm. I mistakenly set up my High Availability Connection Broker's DNS round robin name to something that didn't match my cert. I ...
4
votes
2answers
811 views

Install - Import PFX Certificate to separate local account's Personal store - Automated

I've been wrapping my head around automating a way to perform this task: We deploy Windows Server 2008 R2 images for our customers. We use PowerShell (version 2) to deploy our proprietary software ...