Have you tried launching the PowerShell console by opening the configmgr 
console and clicking on the "File" menu/dropdown and selecting "Connect via 
Windows PowerShell"? that way it should force the PowerShell console to connect 
to the site server drive and if you have permission to launch and view the 
console the you should be able to set the location to the site server drive.

Thanks,

Uriah Patton
IUSM Department of Pediatrics
Systems Administrator

From: listsadmin@lists.myitforum.com [mailto:listsadmin@lists.myitforum.com] On 
Behalf Of Roland Janus
Sent: Monday, April 18, 2016 1:44 PM
To: ms...@lists.myitforum.com
Subject: AW: [mssms] Powershell CM cmdlets as system

Hm, that's when starting the console, not?
When starting the console, the error shows, although it populates the correct 
entry in the list, with site code and everything.
It looks right, but the console still fails.

-R



Von: listsadmin@lists.myitforum.com<mailto:listsadmin@lists.myitforum.com> 
[mailto:listsadmin@lists.myitforum.com] Im Auftrag von Wilbers, Scott
Gesendet: Montag, 18. April 2016 18:08
An: ms...@lists.myitforum.com<mailto:ms...@lists.myitforum.com>
Betreff: RE: [mssms] Powershell CM cmdlets as system

$SiteCode = "<Your sitecode>"
$SiteServer = "<Your siteserver>"

New-Item -Path HKCU:\Software\Microsoft\ConfigMgr10\AdminUI\MRU\1 -Force
New-ItemProperty -Path HKCU:\Software\Microsoft\ConfigMgr10\AdminUI\MRU\1 -Name 
DomainName -Value "" -PropertyType String -Force
New-ItemProperty -Path HKCU:\Software\Microsoft\ConfigMgr10\AdminUI\MRU\1 -Name 
ServerName -Value $SiteServer -PropertyType String -Force
New-ItemProperty -Path HKCU:\Software\Microsoft\ConfigMgr10\AdminUI\MRU\1 -Name 
SiteCode -Value $SiteCode -PropertyType String -Force
New-ItemProperty -Path HKCU:\Software\Microsoft\ConfigMgr10\AdminUI\MRU\1 -Name 
SiteName -Value "Primary Site $SiteCode" -PropertyType String -Force

You might need to add something like this to the beginning of your script.




From: listsadmin@lists.myitforum.com<mailto:listsadmin@lists.myitforum.com> 
[mailto:listsadmin@lists.myitforum.com] On Behalf Of Roland Janus
Sent: Monday, April 18, 2016 1:10 AM
To: ms...@lists.myitforum.com<mailto:ms...@lists.myitforum.com>
Subject: [mssms] Powershell CM cmdlets as system

What is required on the server to have Powershell ConfigManager cmdlets run as 
system within a status filter rule?

The computer account is in the same group as my account, granting full admin 
access to CM and SMS provider.
I've also enabled "SYSTEM" to have remote access on DCOM.

The script doesn't seem to have CM access.
So I've tried running the console as system (psexec), but the console complains 
about not having enough access.
What am I missing?

-R


********************************************************************************************
Note:
The information contained in this message may be privileged and confidential 
and protected from disclosure. If the reader of this message is not the 
intended recipient, or an employee or agent responsible for delivering this 
message to the intended recipient, you are hereby notified that any 
dissemination, distribution or copying of this communication is strictly 
prohibited. If you have received this communication in error, please notify us 
immediately by replying to the message and deleting it from your computer.
********************************************************************************************





Reply via email to