Archive for the ‘SBS 2011’ Category


Moving the database (SUSDB)

The following instructions are for moving the SUSDB and should be valid irrespective of if you are using SBS or WSUS as a standalone product.

As with a regular SQL Server datastore, you can detach and move the database.

Since the database is a normal SQL database, you can simply detach, move and reattach the database. In order to do this, you will however need some tools. Note that these tools are not part of the operating system, so if you haven’t already installed them previosly, then you will need to do so now.

The tools you need are eith SQL Server Managment Studio or SQL Server Management Studio Express. At the time of writing the express (free) version can be downloaded from here:
SQL 2005: http://www.microsoft.com/download/en/details.aspx?id=8961
SQL 2008: http://www.microsoft.com/download/en/details.aspx?id=7593
or search on Google if the above links aren’t valid.
Please download the correct version for your platform (x86 or x64) – Note that SBS 2008+ is ALWAYS x64.

NOTE: You can also download and use the command line tools instead of the full management studio. (If you are familliar with these tools and their usage, then these instructions will probably be a piece of cake for you.)

Command line tools:
sqlncli.msi and SQLServer2005_SQLCMD.msi (Search for them on Google or Microsoft Download)

Prior to moving the database, please stop the following services:

  • IIS Admin Service
  • Update Services (Not Windows Update Service!).

You can do this via the commandline or by using the Services MMC snap-in (start run, services.msc).

Command line:

net stop "update services"
net stop w3svc

(Once the database has been moved you will need to restart these services. Also note that if you have any other services which are dependant on the above services – such as Terminal Services Gateway – they will also be stopped and will need to be restarted.)

Once the services have been stopped, you can proceed to detach the database.

Via SQL Server Management Studio (or Express):

  • Login to server as an administrator.
  • Click Start/Programs/Microsoft SQL Server 2005/SQL Server Management Studio Express. (NOTE: If you are not logged in as Administrator, Right click on SQL Server Management Studio and select Run As Administrator.)
  • Fill in the following information and then click Connect
    • Server type: Database Engine
    • Servername: \\.\pipe\MSSQL$MICROSOFT##SSEE\sql\query
    • Authentication: Windows Authentication
  • Expand Databases, right-click on SUSDB and select Tasks > Detach…  (Please continue reading before proceeding with this step, unless you are 100% sure where your current SUSDB files are located.)
  • Select the “Drop Connection” checkbox and click OK.  (There shouldn’t be any open connections as we have stopped all the relevant services.)
  • Move C:\WSUS\SUSDB folder to the <new drive>:\WSUS directory.  (Assuming that your SUSDB is currently located here – otherwise you can check where it is located prior to detaching the database by viewing it’s properties.)
  • To reattach the database, right-click on Database and select Attach…
  • On the Attach Databases page select the Add button.
  • Browse to the new location of the SUSDB and click OK twice to complete task

Via command line:

  • Login to server as administrator
  • To detach the database:
    c:\Program Files\Microsoft SQL Server\90\Tools\binn\SQLCMD.EXE" -E -S np:\\.\pipe\MSSQL$MICROSOFT##SSEE\sql\query -Q "sp_detach_db 'SUSDB'
  • Now move the SUSDB.mdf and SUSDB.ldf to their new location. In the example below, we use D:\WSUSDB\. Use explorer to move the files to the path you’d like.
  • Then we reattach the database:
    c:\Program Files\Microsoft SQL Server\90\Tools\binn\SQLCMD.EXE" -E -S np:\\.\pipe\MSSQL$MICROSOFT##SSEE\sql\query -Q "sp_attach_db @dbname=N'SUSDB',@filename1=N'E:\WSUSDB\SUSDB.mdf', @filename2=N'D:\WSUSDB\SUSDB_log.ldf'

Moving the content folders (SBS 2008+):

  • Start the Windows SBS Console
  • Click on the Backup and Server Storage icon
  • Click on the Server Storage Tab
  • Select Move Windows Update Repository Data (Right hand side)

Moving the conent folders (non SBS):

The “movecontent” command:

C:\Program Files\Update Services\Tools\wsusutil.exe" movecontent [newpath] [logfile]

For example:

C:\Program Files\Update Services\Tools\wsusutil.exe" movecontent \\server\WSUS$\ c:\wsusmove.log
C:\Program Files\Update Services\Tools\wsusutil.exe" movecontent D:\WSUS c:\wsusmove.log

 



Source: http://defaultreasoning.wordpress.com/2009/11/16/synchronize-time-with-external-ntp-server-on-windows-server-2008-r2/

I can never seem to remember how to do this on 2008, so herewith instructions (copied from above link):

Time synchronization is an important aspect for all computers on the network. By default, the clients computers get their time from a Domain Controller and the Domain Controller gets his time from the domain’s PDC Operation Master. Therefore the PDC must synchronize his time from an external source. I usually use the servers listed at the NTP Pool Project website. Before you begin, don’t forget to open the default UDP 123 port (in- and outbound) on your firewall.

  1. First, locate your PDC Server. Open the command prompt and type: C:\>netdom /query fsmo
  2. Log in to your PDC Server and open the command prompt.
  3. Stop the W32Time service: C:\>net stop w32time
  4. Configure the external time sources, type: C:\> w32tm /config /syncfromflags:manual /manualpeerlist:”0.pool.ntp.org, 1.pool.ntp.org, 2.pool.ntp.org”
  5. Make your PDC a reliable time source for the clients. Type: C:\>w32tm /config /reliable:yes
  6. Start the w32time service: C:\>net start w32time
  7. The windows time service should begin synchronizing the time. You can check the external NTP servers in the time configuration by typing: C:\>w32tm /query /configuration
  8. Check the Event Viewer for any errors.

If you’re in South Africa, then pick one of the stratum 2 server on the following website:

http://www.time.org.za/

At the time of writing, they are:

Stratum-2 Servers

Server DNS name Location Hosted by OS Platform Upstream ISP
ntp1.meraka.csir.co.za Pretoria CSIR FreeBSD Internet Solutions
ntp.is.co.za Johannesburg Internet Solutions UNIX / FreeBSD Internet Solutions
ntp2.is.co.za Cape Town Internet Solutions UNIX / FreeBSD Internet Solutions
igubu.saix.net Cape Town SAIX Solaris SAIX
ntp-ndf.mweb.co.za Johannesburg M-Web Cisco Internet Solutions
ntp0.za.uu.net Cape Town MTN Business FreeBSD MTN Business
ntp1.za.uu.net New Doornfontein, Jhb MTN Business FreeBSD MTN Business
ntp2.za.uu.net Cape Town MTN Business FreeBSD MTN Business