Update 9/25/2007: This command has been deprecated in favor of the gl-mysitesettings command.
Update 9/18/2007: I've modified this command so that it no longer manipulates the database directly. The content below has been updated to reflect the changes. T
his is another one of those for which there is no public API to manipulate programmatically. The command uses an internal method called CommitPersonalSiteSettings which is part of the UserProfileManager class (I had to use reflection to call this method but at least I'm not accessing the database directly). The previous version of this command required passing in the database server and database name for the SSP - now that I'm not hitting the database directly all that's necessary is the SSP name (and the naming format of course). I'm hoping that Microsoft will either make this method public or will create the ability to set these values via the existing properties:
The syntax of the command I created to do this can be seen below.
C:\>stsadm -help gl-setsitenamingformat stsadm -o gl-setsitenamingformat Sets the site naming format for the My Sites web application. Parameters: -sspname <SSP name> -format <Username_CollisionError|Username_CollisionDomain|Domain_Username>
Here’s an example of how to set the site naming format:
Please note that because this command uses an internal only method directly it could, according to Microsoft, put your environment into an un-supported state (though this is Microsoft's recommended approach over directly manipulating the database). Please make sure you understand what the command is doing and what your support options with Microsoft are.
stsadm –o gl-setsitenamingformat –sspname SSP1 -format Username_CollisionDomain