Find all MSSQL Instances running, Connect and show Version

The diagram below, shows how you can use SQL Management Studio to connect to all instances of SQLServer running on your computer (as indicated in the Services list) and run a simple query to find out the exact version and service pack of SQLServer running.

In the SQL Management Studio, you can connect to a default instance by just typing the computername. To connect to a named (second) instance, you can connect to computername\instancename

Clicking “New Query” opens up the query window, and after typing “select @@version” (intellisense prompting will appear) and pressing F5, runs the query and shows the SQLServer version and service pack.

Posted in IT | Tagged | Comments Off on Find all MSSQL Instances running, Connect and show Version

Limit Memory Usage of store.exe – Microsoft Exchange

On the SBS 2011 Server, Microsoft Exchange isn’t used at all, yet store.exe uses over 700MB of memory (via Processes in Task Manager). It doesn’t look simple/possible to remove Exchange as part of a SBS Server. Instead, below shows how to limit its memory usage.

  • START -> (run/search) ADSIEDIT.msc
  • Right-Click on ADSI Edit and choose “Connect to…” and choose “Select a well known Naming Context: Configuration”.
  • Browse to: Configuraion -> CN=Configuration, -> CN=Services -> CN=Administrative Groups -> CN=Exchange Administrative Group -> CN=Servers -> CN=Servername -> CN=InformationStore -> (right-click) Properties
  • Scroll down for “msExchESEParamCacheSizeMax”
  • For Exchange 2010 (uses 32KB Pages). Example for 1GB Memory ->
    1GB = 1048576KB
    1048576 / 32 = 32768
  • *new* Set “msExchESEparamCacheSizeMin” to 256 (8MB of Memory).

 References:
Microsoft Article for Exchange 2000 & Microsoft Article for Exchange 2010 with reference to 32KB Page Size
http://eightwone.com/2010/03/25/limiting-exchange-2010-database-cache/
http://eightwone.com/2011/04/06/limiting-exchange-2010-sp1-database-cache/

Posted in IT | Tagged , | Comments Off on Limit Memory Usage of store.exe – Microsoft Exchange

SQL Activity Monitor – Debug high CPU Usage for SQL Server

START -> All Programs -> Microsoft SQL Server 2008 R2 -> SQL Server Management Studio

Connect as normal and right-click on the SQL Server (top left) and go “Activity Monitor”.

The Activity Monitor will show the queries been run, the user, the computer been run from etc. This can help narrow down clients chewing up the SQL Database and/or show the databases and queries causing the most issues.

You can also right-click on a Process listed (by a user/computer) and go “Kill Process” to end the SQL client connection (useful if you want to force a user to logout of sql to free up a client license etc.).

————————————————–
Problem:
When I tried to launch the Activity Monitor on a Windows 7 x64 client, I got the error below:

The Activity Monitor is unable to execute queries against Server. Activity Monitor for this instance will be placed into a paused state.
Unable to  find SQL Server process ID on server (Microsoft.SqlServer.Management.ResourceMonitoring)
Solution:
cd \windows\system32
lodctr /R

Ref (#).

Alternative to Activity Monitor

Run the following queries:

#Stored Procedure for showing who is connected.
sp_who2;

#In the SPID column you can see the Session ID of the User. You can go kill spidno to kill that query.
kill SPIDNo.

#Stored Procedure for showing locks.
sp_lock;

Ref (#).

Posted in IT | Tagged | Comments Off on SQL Activity Monitor – Debug high CPU Usage for SQL Server

SEO tweaks using mod_rewrite to prevent duplicate content being crawled

Over the past few years, with the rise in popularity of using no-www there have been some issues where content is getting crawled by a search engines twice, and in some cases getting a negative scoring due to duplicated content. I.E. Accessing a website using http://www.site.com and also http://site.com

More recently I’ve come across the fact that http://www.site.com/index.html and http://www.site.com/ (just ending in a trailing slash) are been indexed twice as separate pages, and also getting a negative score due to duplicated content.

I’m sure search engines are getting more intelligent and not negatively scoring websites for these oversights, however I said I’d use mod_rewrite for the Apache webserver to overcome these issues.

vi .htaccess
RewriteEngine On
RewriteCond %{HTTP_HOST} ^domain\.com$
RewriteRule (.*) http://www.domain.com/$1 [R=301,L]
RewriteRule ^$ http://www.domain.com/index.html [R=301,L]

In your apache vhost config, you may have to change “AllowOverride None” to “AllowOverride FileInfo” (more fine grained and safer than going AllowOverride All).

So the above mod_rewrite code rewrites http://domain.com to http://www.domain.com/index.html It also rewrites http://www.domain.com/ to http://www.domain.com/index.html
This was for a recent web design project for a simple static website. Your mileage may vary, so if you use the above, make sure to test thoroughly.

 

Posted in IT, Web Design, Web Development | Tagged , , | Comments Off on SEO tweaks using mod_rewrite to prevent duplicate content being crawled

Remove a Preferred Network from the Dell Wireless Utility

An information sheet on how to remove a Preferred Network from a computer with a Dell Wireless Utility on Windows XP. Link to Document

Posted in Broadband, IT | Tagged , | Comments Off on Remove a Preferred Network from the Dell Wireless Utility