How do I find orphaned computer objects in Active Directory using PowerShell?

How can I find all computer accounts in my Active Directory domain that have been inactive for x days using PowerShell?

This would give you all computer accounts that have no activity for the last 365 Days.

Search-ADAccount -AccountInactive -ComputersOnly -TimeSpan 365.00:00:00

This would sort it for you by lastlogondate.

Search-ADAccount -AccountInactive -ComputersOnly -TimeSpan 365.00:00:00 | Sort-Object lastlogondate | Ft name,lastlogondate -auto

This would give you disabled computer accounts.

Search-ADAccount -AccountDisabled -ComputersOnly 

Disabling Java Automatic Updates on a Terminal Server 32-bit and 64-bit Registry Redirection (Wow6432Node)

On a recently setup Windows Server 2008 R2 terminal server, Java was installed, and by default the JRE will enable automatic updates for all users. No daily users have administrative privileges, but all users are prompted to install updates. No users can actually install the available updates, nor can they disable the update check via the Control Panel.

Continue reading

Media added to DLNA shared library does not show up in Samsung Allshare Play

I’m streaming a lot of my media directly to my Samsung TV (Allshare). lately I added music to my Music Library in Microsoft Windows 8. The Library is shared using DLNA Protocol. For some reason, the newly added media did not show up am my Samsung TV. I started playing around with the configuration of DLNA/Homegroup/Sharing and finally I realized (and that’s an assumption), that the whole sharing stuff, especially when it comes to indexing the media, is managed by Windows Media Player (WMP).

I started Windows Media Player and under Streaming I clicked on More Streaming Options

Combobox Show Devices On => choose All networks

Select the relevant Device and click on Customize.

Then uncheck “Use Default settings”
and then check “Make all my media available to this device.”

2013-03-17 11_23_31-Media streaming options

2013-03-17 11_23_31-Media streaming options

Finally my newly added media has shown up in Allshare/Samsung TV.

Update a VMware ESX 4.1 Host

To scan for updates

esxupdate -m scan

Stage updates

esxupdate -m stage

Enter Maintenance Mode

vim-cmd /hostsvc/maintenance_mode_enter

Apply updates

esxupdate -m update

Exit Maintenance Mode

vim-cmd /hostsvc/maintenance_mode_exit

Finally Reboot


Powershell – Eventlog – List Events of last N days with specific source

Querying EventLog using PowerShell.

Count the number of occurences of Kerberos Entries in System Eventlog for the last 24 hours

(Get-EventLog -LogName System -Source Kerberos -After (Get-Date).AddDays(-1)).Count

output the all Kerberos entries in System Eventlog for the last 24 hours:

Get-EventLog -LogName System -Source Kerberos -After (Get-Date).AddDays(-1)

VMware – Working with Snapshots (orphaned, broken VMDK descriptor file etc.)

Snapshots created via API (NetApp SMVI, Equallogic’s Auto-Snapshot Manager/VMware Edition, VMware VCB or VDR) occasionally get stuck. If you find an orphaned snapshot (ie – it is not listed in the snapshot manager but you can’t change the size of a vmdk / the provisioned size grayed out, or you happen to notice a -delta file where there shouldn’t be one or your scheduled monitoring tasks report an issue here are some potential fixes. Logo_VMware

Continue reading

Send text messages directly from any e-mail program (Outlook, Thunderbird..)

eSMS by Dolphin Systems allows you to send and receive text messages from any e-mail program.
You must have a Swisscom mobile phone number for using eSMS.

Ready for immediate use

Before you can use eSMS, you have to register via text message; follow the relevant user manual for this. You can then use eSMS immediately.

Billing directly on your mobile phone

The billing of SMS messages is done via the mobile phone bill or prepaid credit from the mobile number given at registration. The costs per SMS (160 characters) is CHF 0.20.

The advantages

  • Very easy setup

  • Send and receive SMS

  • Direct answers back

  • Contacts from Outlook adress book

  • Preview of the transmission order

  • Delayed transmission

Very easy to use

pdfeSMS Manual for MS Outlook 2010

pdfeSMS Manual for MS Outlook 2007

For users of MS Outlook 2003 and other e-mail programs:

pdfeSMS Manual for all e-mail programs

Remote Server Administration Tools for Windows 8 Release Preview

Remote Server Administration Tools for Windows 8 Release Preview enables IT administrators to manage roles and features that are installed on computers that are running Windows Server 2012 from a remote computer that is running Windows 8 Release Preview.


Remote Server Administration Tools for Windows 8 Release Preview includes Server Manager, Microsoft Management Console (MMC) snap-ins, consoles, Windows PowerShell cmdlets and providers, and command-line tools for managing roles and features that run on Windows Server 2012. In limited cases, the tools can be used to manage roles and features that are running on Windows Server 2008 R2 or Windows Server 2008. Some of the tools work for managing roles and features on Windows Server 2003.

Continue reading