WSS 3.0: Deleted Config LDF file – no backups, now what?

Posted by on Jun 26, 2009 in Deployment, Sharepoint |

Well guys, i just had the pleasure of deleting the LDF database file for my WSS 3.0 dev site.

Why? The server had literally 0.99MB of hard disk space and out of desperation, i deleted the 7GB log file by stopping the sql service and deleting the LDF file – i know, i wasn’t thinking straight…

Anyway, SQL went into a heap.. I couldn’t detach the database so i could re-attach it and re-create the logs..

The error was: It couldn’t find the log file so it couldn’t detach <- i mean how stupid is that…

Anyway, after fanning around, i uninstalled WSS3.0 and restarted the server.

Logged into SQL management studio, started a new Query and ran the following;

USE [master]
(FILENAME = N'D:\Path\To\Sharepoint\ConfigDB.mdf')

 Now, the other database has detached itself and the new database SharePointTest is up and working with a LDF file.

My main concern now was will WSS 3.0 install and connect to an existing database? is it smart enough?

I managed to install WSS as usuall (stand alone server), then i went to Central Administration and it said none had been configured so hit next and to my amazement it configured it and launched sharepoint and boom i was back to my old sharepoint site.

Fantastic huh!

Read More

IIS Log File location

Posted by on Jun 26, 2009 in IIS |

One thing i have noticed with windows server is that IIS will keep on creating log files and won’t stop.

You should always delete IIS log files espicially on servers that OWA is being used on ALOT..

Log File locations:

Windows Server 2000/2003

  • Logfiles are here by default – %SystemDrive%\windows\system32\logfiles

Windows Server 2008

  • The default location for IIS Logfiles has been moved here – %SystemDrive%\inetpub\logs\LogFiles
Read More

SharePoint application logs massive!!

Posted by on Jun 25, 2009 in Sharepoint |

After doing some development/webpart work on our sharepoint server, the log file to grew to 3.5GB – we have 0.99MB of free space of a 20GB disk (this is a dev/test Virtual server).

Anyway after searching, i came across this blog: – thanks Steven!

Apparently you can manage how SharePoint logs it’s events:

The Problem:

SharePoint 2007 by default stores 48 hours worth of logs in a directory buried in your program files folder (C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\12\LOGS\ !). Very few events get logged to the application event log.

Expect each log file to be at least 200 megs (a log file being generated every 30 minutes by default), or 19 GB of space at the minimum being used by SharePoint logs.


Go to your central administration server web site, and open up the Diagnostic logging:

Central Administration -> Operations  -> Logging and Reporting -> Diagnostic logging


In the Diagnostic logging page, focus on the following categories:

  • Event throttling: how much you log
  • Trace Log: where you store the logs

Event Throttling:

  • For a Dev/staging server server, you should log all or “medium events”
  • For a Production server, only log errors
  • The search crawler will take up most of the log space

Trace Log:

  • By Default, logs are sent to: C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\12\LOGS\
  • Store the logs on a separate drive so that at worse your drive gets full and your application stops logging, but still functions. It’s a pretty standard practice for SQL server installations for instance.
  • Reduce the number of log files. The default is two days worth of logging (96 files x 30 min intervals). See if this is too much for you; it might depend on how much you chose to log in the Event Throttling.

Read More

Set an ESX Host into maintenance mode using the service console

Posted by on Jun 21, 2009 in VMWare |

If you are using the service console and want to put the ESX server into maintenance mode, simple run the following commands:

Enter maintenance mode:

vimsh -n -e /hostsvc/maintenance_mode_enter

Exit maintenance mode:

vimsh -n -e /hostsvc/maintenance_mode_exit

How do you check whether you are in maintenance mode or not?

vimsh -n -e /hostsvc/runtimeinfo | grep inMaintenanceMode | awk ‘{print $3}’

Read More
%d bloggers like this: