Categoriearchief: IT-Related

Reset Domain Controller password

This post is based on ‘this one‘, but now with some ‘print screens’ attached.

I know it should not be necessary :), but unfortunately it is…
And because i could not find the solutions very easily/quickly, i thought i should share it…

  1. Restart your server with an install disk in place.
  2. Boot from this setup disc
  3. Choose language and keyboard layout
  4. Click Next
  5. Click Repair you computer
  6. Choose the right (mostly one?) installation
  7. Start the ‘Command Prompt’
  8. Type: C:
  9. Type: cd Windows\System32
  10. Type: copy Utilman.exe Utilman.exe.backup
  11. Type: copy cmd.exe Utilman.exe
  12. Type: exit
  13. Click ‘Restart’
  14. Do a normal boot now
  15. When ready to login…
  16. Click the ‘Ease of access’ icon OR press [Windows] + [U]
  17. A command prompt starts now  (note that the titlebar says utilman.exe 🙂 )
  18. Type: net user “Administrator” “newpassword”
  19. Type: exit
  20. Login with the “Administrator” user and your new password “newpassword”
  21. You are done now.
  22. Do not forget to change back Utilman.exe.backup to Utilman.exe
  23. If you do not have write acces on this file now…
  24. Repeat steps 1 to 9 and then
  25. Type: copy Utilman.exe.backup Utilman.exe

Lees verder

Nagios Core (Server)

Leuk hé, elke morgen door tientallen mailtjes van diverse systemen werken. Gemak is anders. Van de week zelf toch maar eens gekeken naar een niet al te dure monitoring oplossing. En die is er: Nagios Core, een opensource gratis beschikbaar programma waar je tegen betaling ook support op kunt krijgen.

Eerst maar even de monitor server inrichten (Nagios Core server):

  • Zorg voor een Debian 6 machine (al dan niet een schone machine)
  • Ik heb voor de test (en later productie) een VPS op het net gehuurd.
  • Download nagios-core en nagios-plugins voor een basis monitoring server. (Pak gewoon de laatst beschikbare versie)

Download server components

$ mkdir nagiossetup
$ cd nagiossetup
$ wget http://../nagios-3.4.1.tar.gz
$ wget http://../nagios-plugins-1.4.15.tar.gz

Installeer nagios afhankelijkheden

$ apt-get install apache2 libapache2-mod-php5 build-essential libgd2-xpm-dev

Serviceaccounts (windows term?) aanmaken

## Gebruiker aanmaken (in debian wordt ook een group aangemaakt)
$ useradd nagios
## Account activeren met wachtwoord, wachtwoord daarna documenteren/archiveren
$ passwd nagios 

## Nagios Command group aanmaken waar ook apache (www-data) lid van is
$ groupadd nagcmd
$ usermod -a -G nagcmd nagios
$ usermod -a -G nagcmd www-data

Nagios Core, uitpakken, configureren, compileren en installeren

$ cd ~/nagiossetup
## Extract download
$ tar xzf nagios-3.4.1.tar.gz
$ cd nagios-3.4.1
## Run configure script with servicegroup nagcmd
$ ./configure --with-command-group=nagcmd
## Compile source
$ make all
## Install nagios
$ make install
$ make install-init
$ make install-config
$ make install-commandmode
$ make install-webconf

Webtoegang regelen (aanmaken account in htpasswd)

## De eerste keer dit commando uitvoeren (-c = create NEW file)
htpasswd -c /usr/local/nagios/etc/htpasswd.users nagiosadmin
## Voor iedere andere contactpersoon (zie etc/objects/contact.cfg)
htpasswd /usr/local/nagios/etc/htpasswd.users [[contact_name]]

## Opstarten/herstarten webserver:
$ service apache2 reload (or restart)

Nagios Core opstarten of herstarten

## Na iedere bewerken van Nagios Config files nagios herstarten
$ service nagios restart

Na de Core ook nog een basis set van Plugins installeren

## Download uitpakken
$ cd ~/nagiossetup
$ tar xzf nagios-plugins-1.4.15.tar.gz
$ cd nagios-plugins-1.4.15

## Configureren (met service account informatie)
$ ./configure --with-nagios-user=nagios --with-nagios-group=nagios

## Compileren en installeren
$ make
$ make install

 De nagios monitor server is nu klaar voor gebruik

Binnenkort zal ik eens wat schrijven over het monitoren van remote diensten en remote systemen.

Wat nog wel even goed is om te weten:

## Nagios Program Files map (klink als windows?)
## Bevat configuratiebestanden en programmabestanden
$ cd /usr/local/nagios

## Controleren op fouten in configuratie:
$ /usr/local/nagios/bin/nagios -v /usr/local/nagios/etc/nagios.cfg

 

Nagios Downloads: http://nagios.org/download
Nagios Documentatie: http://nagios.sourceforge.net/docs/nagioscore/3/en/toc.html

Windows 7 Disappearing Icons

Desktop Icons disappear randomly, and NO, it is not the checkbox ‘Show desktop icons’…

The problem and (possible) solution is explained at the Microsoft TechNet forums.
http://social.technet.microsoft.com/Forums/en-US/w7itprogeneral/thread/ada5d392-2af7-43c3-9191-08baf63f0098

It seems that a service cleaning up broken desktop shortcuts. Maybe the service can not determine very well if the link is broken or not. All involved shortcuts are linked to folder on a network drive.

We will wait for a couple of day to see if this really was the problem.

Server: Small Business 2003 Dutch
Client: Windows 7 64b Dutch
Roaming profiles enabled, with only My Documents redirected.

Update 1: My Customized Solution:

Take a look at this site for manual command:
http://rays-it.blogspot.com/2011/02/one-way-to-get-around-desktop-shortcuts.html

Then you will see that making an Windows 7 startup script is not very hard to do. This may be helpfull if you have to update multiple computers in a Windows Domain environment.

Go to your NETLOGON share and make a new script file:

TS_Brokenshortcuts_Script.bat

# NETLOGON Script: TS_BrokenShortcuts_Customized
# Take Ownership of the file
takeown /f "C:\Windows\diagnostics\scheduled\Maintenance\TS_BrokenShortcust.ps1" /A
# Assign Administrator full access rights
icacls "C:\Windows\diagnostics\scheduled\Maintenance\TS_BrokenShortcuts.ps1" /grant "Administrators:F"
# Now you can replace the file
xcopy "\\server\netlogon\TS_BrokenShortcuts_NEW.ps1" "C:\Windows\diagnostics\scheduled\Maintenance\TS_BrokenShortcuts.ps1" /y

Place also the new ps1 file in you netlogon share. And do not forget to call the new scripts. One possibility to do is by using Group Policy’s: Computer Startup Scripts.