Tag Archives: Windows

Renaming a Domain Controller

Posted on .

You can use netdom to rename any computer, including a domain controller:

However this will leave the attribute msDS-AdditionalDnsHostName with the old name. Check this in ADUC attribute editor (or ADSIEDIT.msc):

Remove the old name and restart.

PS. This fixes not being able to re-use the old name on another computer. You get the error The operation failed because SPN value provided for addition/modification is not unique forest-wide, and you will see the old domain name when you run setspn -l <oldname>. Performing the above attribute changes fixes this.

Using VBScript to Create Dated Backups with 7-Zip

Posted on .

I needed a simple method to backup a small folder using 7-Zip on a regular basis without installing extra software. I wanted to be able to leave it running daily and have it remove old backups.

I chose VBScript to complete this task, re-learning a few things from the last time I used the language.

The script shall backup C:\Customer to S:\Backup\backup_DATE.7z. It will also delete old backups, only keeping the first 5. The directories and number of kept backups are variables, check the code comments.

  backup-folder.vbs (3.4 KiB, 3,115 hits)

Elevated/Admin Notepad++ Context Menu

Posted on .

I use NotePad++ on Windows and sometimes it is a little frustrating when UAC gets in the way of my editing some files. I have to manually load NotePad++ as Administrator, and try again.

This INF file will install an extra context menu called “Edit with NotePad++ (elevated)”.

Once downloaded, right click the file and choose Install.

Note: The install script assumes NotePad++ is at “C:\Program Files (x86)\Notepad++\notepad++.exe”. You can adjust the location in the install script by editing the very last line.

  NotepadppElevated.inf (1.3 KiB, 4,132 hits)

(tested on Windows 7 x64)

Session (ID X) remote control failed

Posted on .


You may find it impossible to remote control a user from Task Manager on Windows Server and get the above error.

If it only works when using the built-in administrator account, then this may be because UAC is enabled. Task Manager needs to be UAC-elevated in order to perform the remote control task.

The long-term fix is to disable UAC like discussed in this Technet forum post.


A quicker method, and if you want to keep UAC enabled, is to elevate Task Manager by going to the “Processes” tab and clicking “Show processes from all users” button. This elevates Task Manager to show all processes and then allows you to remote control.