Tuesday, April 28, 2009

Configuring Usage Analysis Processing using stsadm

I ran into a problem recently when attempting to enable and configure Usage Analysis Processing (UAP)using stsadm, I needed to do this as part of a fully scripted installation of MOSS 2007 that I was assisting a customer with. Looking at the stsadm documentation, the following commands are available:

stsadm -o setproperty
-propertyname usageprocessingenabled
-propertyvalue {Yes | No}
stsadm -o setproperty
-propertyname job-usage-analysis
-propertyvalue {Yes | No}


I then ran the following two commands to configure UAP:
stsadm -o setproperty -pn job-usage-analysis -pv "daily between 08:00 and 09:00" To configure the time that the process runs.
stsadm -o setproperty -pn usageprocessingenabled -pv "Yes” To enable Usage Analysis Processing.
However when I browsed to Central Administration – Operations – Usage analysis processing the following was displayed



If you look closely you can see that the time has been set correctly but it hasn’t enabled usage analysis processing. As you can see this is grayed out meaning that Enable logging must be selected before it can be enabled – but how do I enable logging? After much investigation I eventually found out (from a colleague- thanks Kirk) that the following stsadm can be used to enable this.
stsadm -o setproperty -pn loggingenabled -pv "Yes”To put this all together I need to run the commands in this order to achieve my objective:

• stsadm -o setproperty -pn loggingenabled -pv "Yes”
• stsadm -o setproperty -pn job-usage-analysis -pv "daily between 08:00 and 09:00"
• stsadm –o setproperty -pn usageprocessingenabled -pv "Yes”


No comments: