Showing posts with label PowerShell. Show all posts
Showing posts with label PowerShell. Show all posts

Tuesday, November 10, 2015

Deploy a customized Windows 10 start menu during deployment

Did you know that when deploying Windows 10, it's possible to copy a default start menu too? When using a Windows 10 image from media, the start menu is filled with apps you never use :) Therefore remove (almost) all apps, and fill it with apps you want to use!

The command used to export the start menu is: Powershell export-startlayout –path "<path>\LayoutModification.xml"

An example looks like this:
<LayoutModificationTemplate Version="1" xmlns="http://schemas.microsoft.com/Start/2014/LayoutModification">
  <DefaultLayoutOverride>
    <StartLayoutCollection>
      <defaultlayout:StartLayout GroupCellWidth="6" xmlns:defaultlayout="http://schemas.microsoft.com/Start/2014/FullDefaultLayout">
        <start:Group Name="Office 2013" xmlns:start="http://schemas.microsoft.com/Start/2014/StartLayout">
          <start:DesktopApplicationTile Size="2x2" Column="0" Row="2" DesktopApplicationID="{7C5A40EF-A0FB-4BFC-874A-C0F2E0B9FA8E}\Microsoft Office\Office15\WINWORD.EXE" />
          <start:DesktopApplicationTile Size="2x2" Column="0" Row="0" DesktopApplicationID="{7C5A40EF-A0FB-4BFC-874A-C0F2E0B9FA8E}\Microsoft Office\Office15\EXCEL.EXE" />
          <start:DesktopApplicationTile Size="2x2" Column="2" Row="0" DesktopApplicationID="Microsoft.Office.OUTLOOK.EXE.15" />
          <start:DesktopApplicationTile Size="2x2" Column="4" Row="0" DesktopApplicationID="{7C5A40EF-A0FB-4BFC-874A-C0F2E0B9FA8E}\Microsoft Office\Office15\POWERPNT.EXE" />
        </start:Group>
        <start:Group Name="Applications" xmlns:start="http://schemas.microsoft.com/Start/2014/StartLayout">
          <start:DesktopApplicationTile Size="2x2" Column="4" Row="0" DesktopApplicationID="{7C5A40EF-A0FB-4BFC-874A-C0F2E0B9FA8E}\FastStone Capture\FSCapture.exe" />
          <start:Tile Size="2x2" Column="0" Row="0" AppUserModelID="Microsoft.WindowsCalculator_8wekyb3d8bbwe!App" />
          <start:DesktopApplicationTile Size="2x2" Column="0" Row="2" DesktopApplicationID="Microsoft.InternetExplorer.Default" />
          <start:DesktopApplicationTile Size="2x2" Column="2" Row="0"
DesktopApplicationID="{6D809377-6AF0-444B-8957-A3773F02200E}\CCleaner\CCleaner64.exe" />
        </start:Group>
      </defaultlayout:StartLayout>
    </StartLayoutCollection>
  </DefaultLayoutOverride>
</LayoutModificationTemplate>


During deployment copy the LayoutModification.xml with the following command to make it available for all users:
copy /y LayoutModification.xml "C:\Users\Default\AppData\Local\Microsoft\Windows\Shell"


With that the start menu is active when logon after deployment. Very nice if you ask me! :) Only thing so far is Internet Explorer is missing from the start menu. Is there a way to place that in the xml file too? Hope to find a solution for that as well, because all other apps are added as expected!

Update: On Microsoft Community and ccmexec.com the answer is found. Just create a "Internet Explorer.lnk" and copy the file:
copy /y "Internet Explorer.lnk" "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Accessories"
A PowerShell script is available there too, which do the same thing! Just remember the script looks for StartMenu.xml

Within LayoutModification.xml change DesktopApplicationID="Microsoft.InternetExplorer.Default" to DesktopApplicationLinkPath="%ALLUSERSPROFILE%\Microsoft\Windows\Start Menu\Programs\Accessories\Internet Explorer.lnk"
After that Internet Explorer will shown up in the start menu!


Keep up the good work :)

Thursday, October 23, 2014

Enable Adobe Flash Player on Windows Server 2012 R2

When starting the VMware vSphere Web Client on Windows Server 2012 R2, the following message is displayed: To view this page ensure that Adobe Flash Player version 11.5.0 or greater is installed. After that it's not possible to enable Flash because of the following message: Flash Player is integrated with Internet Explorer in Windows 8. You do not need to install Flash Player. 
 
The solution for this is not that hard, you must install the Desktop Experience feature on the server. Let's start PowerShell for that, and type the following command: Install-WindowsFeature Desktop-Experience

After that it's needed to restart the server, and install the latest Flash update with Windows Update. (KB3001237)


Flash Player will be available now. Just try to start the VMware vSphere Web Client again, and you will be fine.

When ActiveX Filtering is enabled you may discover issues. Just turn it off in Options > Safety > ActiveX Filtering.

Tuesday, July 8, 2014

Delete multiple Packages in Configuration Manager 2012 SP1

Sometimes it's needed to delete multiple software packages in the ConfigMgr console. By default this isn't possible, when selecting multiple packages this option will be greyed out. In my case it was needed to delete around 50 packages.

By deleting a package you must select multiple clicks also, this because you have:
1) Click Delete
2) Click Next
3) Click No, I know that I want to delete this package
4) Click Next
5) Click Next
6) Click Close

You don't want to do that for over 50 packages, which are 300+ clicks then. Just have a look at a easier way. From within the ConfigMgr console start "Connect via Windows PowerShell".


Then type in the following command:
Remove-CMPackage -Name "Package name" -Force


You can also type Remove-CMPackage and click Enter. Then you can enter as many Package ID's as you want and press enter twice. Then you must press enter for every package that you want to delete.

Way better then 6 clicks for every package if you ask me! ;)

Thursday, March 27, 2014

Most popular scripts, tools and queries for ConfigMgr usage

During ConfigMgr installation I'm using a lot of scripts, tools and queries. These are most used during or after OS deployment to get the job done. In this blogpost I mention a few of most popular scripts, tools and queries used. Have fun using them!
 
Adding Computer to AD groups during deployment
Application E-Mail Approval Tool
Automate Computer Name during OSD
ConfigMgr Console Extensions
Enabling and Disabling Microsoft Update in Windows 7
Group Policy WMI filters
Move computer object to another OU
Powershell Right Click Tools
Powershell script collection for ConfigMgr 2012
Remove from collection and clear PXE flag
Re-run Task Sequence Tool 1.0
RIGHT CLICK TOOLS FOR SCCM 2012 CONSOLE
SCCM 2012 Management Scripts
SCCM Client Actions Tool PowerShell Edition
Showing the Collection Membership of a Resource
System Center 2012 R2 Configuration Manager Toolkit

Update1:
Deploy Wifi profiles with SCCM
Endpoint Protection Definition Script
Remove Client from Collection after OSD 1.1
Show Collection Details right-click action
Show Maintenance Windows information for a device
 
Update 2:
Dell Command | Integration Suite for System Center
HP Client Integration Kit for ConfigMgr 2012 R2
Now Micro Right Click Tools (free)
Remove Expired & Superseded Updates in SUGs
Set of Operational SCCM Collections

Update 3:
Add computer to security group during OSD
System Center Endpoint Protection Policy Templates
ConfigMgr Prerequisites Tool 1.4.1

Even more scripts, tools and queries can be found here: "System Center - resources for IT professionals".

Friday, July 6, 2012

Upgrade OpsMgr 2012 from evaluation to retail version

Last days I installed a clean System Center Operations Manager (OpsMgr) 2012 server. After installation the following configuration task was seen in the OpsMgr console: Upgrade to full version


This because during installation there is no possibility to fill in a product key. That must be done after installation. Strange thing, because with System Center Configuration Manager (ConfigMgr) 2012 it can be filled in during installation. When you don't fill in the product key, an evaluation version (180 days) is used by default.

To upgrade OpsMgr 2012 from evaluation  to Retail version use the following commands:

1) Start Operations Manager Shell (PowerShell)
2) Enter "Set-SCOMLicense –ProductID <product-key>"
3) Choose Yes or press enter for default
4) Reboot the OpsMgr server or restart the "System Center Data Access Service" (!)

After that start the OpsMgr 2012 console, choose Help > About, and you will see Version 7.0.8560.0 (Retail) now.

Friday, November 11, 2011

Disable the GUI in Windows Server 8 with PowerShell

Last month I installed Windows Server Developer Preview (Windows Server 8). This can be found here: Windows Server 8 installed

There is the choice between installing the Full Installation, Server Core or Features on Demand edition. By default when doing a Full Installation the GUI is installed. In this blogpost I wil explain how to remove the GUI with usage of PowerShell.

This is the default screen after doing a Full Installation

Start Windows PowerShell with the default button available

In PowerShell the following commands are needed to remove the GUI:
  • Import-Module ServerManager
  • Get-WindowsFeature
  • Remove-WindowsFeature Server-Gui-Shell
  • Shutdown /r /t 5

After reboot the default screen is changed, no background anymore..

When logon, Server Manager and a command window is started

In PowerShell it's possible to enable or disable Windows features again

Open the command window for that and use the following commands:
  • PowerShell
  • Import-Module ServerManager
  • Get-WindowsFeature
  • Add-WindowsFeature <Name> (or)
    Remove-WindowsFeature <Name>

The following command are needed to install the GUI again:
  • Add-WindowsFeature Server-Gui-Shell
  • Shutdown /r /t 5

If needed, Windows PowerShell Getting Started Guide:
http://msdn.microsoft.com/en-us/library/windows/desktop/aa973757(v=vs.85).aspx


Thanks to @RandolphWinjaja for PowerShell support.