Quantcast
Browsing all 21975 articles
Browse latest View live

SetAuditRuleProtection($False, $True) and Set-ACL

$acl = Get-ACL ...#do some stuff to the DACL#mark SACL to inherit audit$acl.SetAuditRuleProtection($False, $True)While this sequence of events will not break SACL inheritance, it will not restore SACL...

View Article


creat custom table

Hi, Thanks for you help My best regards Arnold

View Article


How to show Win32_classes properties

HelloWhen I do this in PowerShell:Get-WmiObject Win32_TCPIPPrinterPortor even: Get-WmiObject Win32_TCPIPPrinterPort | Format-List *it doesn't show anything. But if I put Get-WmiObject with another...

View Article

Powershell foreach -parallel WMI query operation did not complete within the...

Hello!I'm running the following script in PS 3.0:Workflow Test-My-WF {    $servers=Get-Content -Path "ser.txt"  foreach -parallel ($server in $servers) {    $proci = (Get-WmiObject win32_Processor...

View Article

email trouble

have tried to answer many ads on crasigslist & ebay. when replying by email msn says email sent. also sometimes says problem sending email from my address. have never gotten reply from any ad-...

View Article


set-alias

Hello,What is wrong with the following code:Set-alias gs set-executionpolicy restrictedI want to set this line in my $profile but the line isnt working. I got the same problem when I want to use "cd"...

View Article

Connect to Hotmail using Powershell

Folks,I have been trying to connect to Hotmail through Powershell. Can you offer any advice on how to accomplish thatThanks

View Article

Similar to connecting to remote computer using WSManagement, how to do it...

I have the following code to connect to the remote powershell and execute script on remote machine :WSManConnectionInfo connectionInfo =newWSManConnectionInfo(false,"MachineName",5985,"/wsman",...

View Article


Azure AD Managment

Hi, I recently ran into the situation where we wanted to create multiple Azure AD's from a particular subscription. However, I quickly discovered there are no management options from within powershell....

View Article


Bypassing Execution Policy for a specific host

Is is possible to have the execution policy set to remotesigned but have specific hosts set to bypass? I am administering an SCCM 2012 environment and I want to be able to run Powershell to check for...

View Article

Restart IIS remotely

Hi,I want to restart IIS service on a remote machine. What's the Powershell command for this, where I will be able to mention the remote server name, username, password?

View Article

AD Module for Windows PowerShell - Insufficient Access Rights to perform the...

I have a recently upgraded domain that's now running all 2008R2 DCs.  The domain functional level is 2008R2 and the forest functional level is 2003.  I've also created a brand new lab domain with...

View Article

How do I search a spreadsheet for a list of URL's | then search those URL's...

Fist, I should mention I am not a programmer but am eagerly learning powershell!I am looking for an automated solution to accomplish what I am currently doing manually.  I need a script that would...

View Article


Wmi class Win32_printer not found in root/cimv2

Hello all,I'm trying to use powershell to remove a local IP printer.  I tried with this.  The command ran successfully but did not remove my printer.remove-wmiobject -computername localhost -class...

View Article

Adding Global Groups to Domain Local through script.

Hi, I have a script from creating Local Domain groups from Global Security groups, now I want to expand that script so it automatically adds that Global group to Domain Local group.Here is the script...

View Article


Remove-ADGroupMember where member is in parent domain and group is in child...

I have a parent domain (sandbox.local) and a child domain (child.sandbox.local) and want the capability to add and remove sandbox\User to a (domain local) group in the child domain. I can add the user...

View Article

The term 'new-object' is not recognized as the name of a cmdlet, function,...

I have a script that runs well the vast majority of the time.  On occasion I get an exception.  I would appreciate any insight as to why it fails on occasion.  I can't understand why the new-object...

View Article


PowerShell Script Running Through Scheduler

Hi Folks,I am running below script to copy a file from one server to another server. This script uses it's own authentication.Issue is my security policy doesn't allow me to store password on task...

View Article

Use Same Excel Object in Start-Job as Main PS1

I have hundreds of Excel files and one main file that has links to each of these files, but in order for the data to be pulled into the main excel file I need to have every file opened within the same...

View Article

Server2012: Set-ClusterScheduledTask + "Run with highest Priviledges" - ???

Hey there,I'm trying to fix a script we have to trim VSS copies on our Fileserver which is a Serve 2012 Failover Cluster. This has worked in the past, however I think it got messed up when I changed...

View Article
Browsing all 21975 articles
Browse latest View live