Stop asking “What Computer are You On”! Instead use Active Directory and Group Policy to search for you! In this post, we are going to set Active Directory to automatically record where users login. And when a user calls, Active Directory Users and Computers will let us instantly remote into their computer and will find out what computer a user logged into. In short, you will be able to click on any computer in your domain and see the current logged in user. All within Active Directory Users and Computers!
Tag Archives: PowerShell
Block the Control Panel with Group Policy and PowerShell
Being able to block the Control Panel with Group Policy is quite easy, simply enable “Prohibit access to Control Panel”. Blocking certain control panel applets, like Sound, is harder! You would think that enabling “Hide specified Control Panel items” would do the trick – that is until you read the description for that setting.
So it isn’t as simple as entering in Volume to block the Volume and Sound applet. To make sure that we block the correct applet, let’s learn the incorrect and correct way for PowerShell to list our Control Panel canonical names.
Restrict Users to Certain Computers
Limiting a user to certain logon workstations is a common administrative task. Doing this is a very repetitive if you have to restrict users to certain computers. Even at that, Microsoft limits you to only 64 workstations when you are entering them in using the GUI. Although you can add additional computers in the AD attribute editor, it is still a huge (comma separated) pain!
To understand the problem, we will do it manually once. Open the user’s properties, go to the Account tab then click “Log on To”. Then add each computer one at a time. It will not take wildcards.
What if you could add a lab of computers just by typing the users name and computer name or prefix? What if you could add an entire site to a guest user automatically? Well you can using PowerShell! – you had to know that line was coming 🙂
AppLocker Errors: Troubleshoot Graphically
Applocker is a part of Windows 7/8 Enterprise. It allows an entire organization to eliminate malware. It is seriously that powerful! It works by whitelisting, or allowing, a specific set of trusted executables to run. Once setup, AppLocker is easy to manage. However, if an untrusted executable is ran, you still have to search the event log to gather the AppLocker Errors.
To get a picture of how ugly that event log is, here is a screenshot:
Now imagine opening up the event log for multiple machines! Not fun at all! To help aggregate these logs, we are going to use PowerShell!
Spring Cleaning for a Desktop Adminstrator
Have you got that spring cleaning itch yet? I’m not talking about cleaning the kitchen or pressure washing the house; I am talking about cleaning up your Desktop Administrator life!
To help you with those spring cleaning chores, I’ve written or collected a series of scripts for you:
Active Directory:
- Deleting Stale Computers
- Deleting Stale Users
- Deleting Empty Security Groups
- Enabling Accidental Deletion
Printers:
If you would like to see more scripts or another area to cleanup, let me know! I will see what I can do!





