Monday, March 15, 2010

Showing active SharePoint connections

It can be very useful to see how many active connections you have on your SharePoint server. This can be easily done using PowerShell to look at the IIS performance counters.

As is mostly the case with scripting, somebody has already done a much better job than I ever could. Here is a script which creates a PowerShell function Get-WebServiceConnections.

I created a PowerShell script called CurrentConnections.ps1 with the following content and can now run it whenever needed:

function Get-WebServiceConnections()
{
  $results = @{}
  $perfmon = new-object System.Diagnostics.PerformanceCounter
  $perfmon.CategoryName = "Web Service"
  $perfmon.CounterName = "Current Connections"

  $cat = new-object System.Diagnostics.PerformanceCounterCategory("Web Service")
  $instances = $cat.GetInstanceNames()

  foreach ($instance in $instances)
  {
    $perfmon.InstanceName = $instance
    $results.Add($instance, $perfmon.NextValue())
  }
  write-output $results
}

Get-WebServiceConnections

Thursday, March 4, 2010

Customizing Forefront Server Security Notification messages

As an administrator, you would like to know more information when a virus is detected on your Exchange organization than the default message.



Here you will find the list of keywords that can be added to your message template.
In my case, I wanted to add the recipient details, and sender address :

Sender: "%ISName%%ESName%%ESAddress%"
Recipient: "%IRName%%ERNames%"

Wednesday, March 3, 2010

Large XML file editor useful for displaying BackupExec logs

When using BackupExec to save all your data, the xml logfile can be huge, hundreds of MB or more.
Then BackupExec cannot display the result and it is really hard to find the reason of any issue encountered.
I found this freeware : XML Marker which works pretty good with a 700MB file (you can start searching the file even if not finished loading).

Exchange 2010 Public Folder Replication

After installing the first Exchange 2010 Server in an Exchange 2007 environment, I noticed the public folders weren’t replicating. Even after adding a number of replicas the hierarchy wasn’t even showing up.

After much searching I found this comment in a blog entry with the solution. Basically, it was due to an object still remaining in Active Directory from Exchange 2003 days.

Using ADSIEdit open “Configuration-Services-Microsoft Exchange-<Organization Name>-Administrative Groups-<Name of your Admin Group>

In this container delete the object “Servers”.

(Before doing this you should probably back up your AD ;) )

 

After a little waiting, all was back to normal.

Wednesday, February 10, 2010

Changing the polling interval for the Exchange FDS

The Exchange 2007 File Distribution Service is responsible for keeping the OAB on the CAS in sync with the mailbox server. The default setting only polls the OAB every 8 hours. This could mean that a change you make doesn’t make it to the Outlook clients until well over a day (if you leave the OAB creation to the default once a day)!

To change this setting to e.g. every hour (60 minutes) use this command:

Get-OabVirtualDirectory| Set-OabVirtualDirectory -pollinterval 60

Wednesday, February 3, 2010

Exchange organization reboot issue : blocked emails

When your exchange 2007 organization have multiple servers, since roles should be splitted on different machines, and you need to reboot them, it appears that sometimes emails are blocked.
This can come from the Hub transport server and even if the MS Exchange transport service is set on automatic, is appears not started after reboot.
Just start the Microsoft Exchange Transport service, and all emails will be released.

Unmanaged SAN storage processor (SP)

It could happen that one of the storage processor of your SAN displays as unmanaged in GUI.
This can happen after a SAN reboot and is usually related to the UPS powering this SP.
Since the communication between the UPS and the SAN is broken (not available), the SP goes on unmanaged and disable the cache.
In order to solve this, you'll need to stop the SAN (and everything running on before), stop the UPs, restart the UPS and let it do the check opreations (< 1 minute), and finally start the SAN.
Everything should be ok.

Tuesday, February 2, 2010

Viewing the Dell Service Tag from Windows

If you ever need to check the Dell Service Tag on a machine from within Windows, run the following command:

wmic bios get serialnumber

To do this remotely you need to add the /node: switch. For example:

wmic /node:<servername> bios get serialnumber

Thursday, January 21, 2010

Displaying the Quick Launch in Web Part Pages

If you create a web part page in MOSS 2007 it won’t show the Quick Launch on the left side of the page.

To work around this open the page in SPD and remove the following code:

<asp:Content ContentPlaceHolderId="PlaceHolderLeftNavBar" runat="server"></asp:Content>

 

Unfortunately, the Quick Launch won’t be the correct width so in order for that to be displayed correctly you need to remove these additional lines of code:

<asp:Content ContentPlaceHolderId="PlaceHolderPageImage" runat="server"></asp:Content>
<asp:Content ContentPlaceHolderId="PlaceHolderNavSpacer" runat="server"></asp:Content>

Friday, December 11, 2009

Forefront /NOMOM cannot update

If you have a single server running Forefront and not having access to your WSUS for updates (ie: an ISA server in a DMZ) you need to install the AV software with the /nomom option :
clientsetup /nomom
But it won't update automatically by itself.
You need to run Microsoft update and enable updates for Microsoft products in addition to Windows updates.