Tuesday, December 20, 2011

PowerShell script to configure your SharePoint Services

Check this link if you want to configure your SharePoint 2010 services from PowerShell script http://todd-carter.com/post/2010/04/26/The-Wizard-Likes-His-GUIDs.aspx

The good thing here is that documenting these scripts is much more easier than documenting step by step with images to do it from the central admin.

Thursday, December 15, 2011

PerformancePoint error after adding new servers to the farm

I was adding two front end servers to a SharePoint farm this week, and I got an error in all the dashboards when the load balancer redirect to these two servers:

PerformancePoint Services could not connect to the specified data source. Verify that either the current user or Unattended Service Account has read permissions to the data source, depending on your security configuration. Also verify that all required connection information is provided and correct.

System.Data.SqlClient.SqlException: A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server)

at System.Data.ProviderBase.DbConnectionPool.GetConnection(DbConnection owningObject)

at System.Data.ProviderBase.DbConnectionFactory.GetConnection(DbConnection owningConnection)

at System.Data.ProviderBase.DbConnectionPool.GetConnection(DbConnection owningObject)

at System.Data.ProviderBase.DbConnectionFactory.GetConnection(DbConnection owningConnection)

at System.Data.ProviderBase.DbConnectionClosed.OpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory)

at System.Data.SqlClient.SqlConnection.Open()

at System.Data.SqlClient.SqlConnection.Open()

at Microsoft.PerformancePoint.Scorecards.DataSourceProviders.SqlTabularDataSourceProvider.GetConnection()

at Microsoft.PerformancePoint.Scorecards.DataSourceProviders.SqlTabularDataSourceProvider.GetConnection()

at Microsoft.PerformancePoint.Scorecards.DataSourceProviders.SqlTabularDataSourceProvider.GetConnection()

at Microsoft.PerformancePoint.Scorecards.DataSourceProviders.SqlTabularDataSourceProvider.GetDataSetInternal(Int32 maximumRows)

PerformancePoint Services error code 201.

And finally I found the solution here http://social.msdn.microsoft.com/forums/en-US/sqldataaccess/thread/c488cf76-2515-440f-b3f8-9cfad689c5b6/

I’m just posting the URL in my blog to make sure that I will find it again as it helped me a lot, it has all the possible places to check.

Also you have to see if the servers are configured for Kerberos delegation if you have it, and the claims to windows token service account has the right permission on the servers as per this document http://www.microsoft.com/download/en/details.aspx?displaylang=en&id=23176, and check the user groups on the servers to make sure that the service accounts are in the right place. you can also check the binding in the ISS and make sure that the required applications are running. Also check the web.config and the e-mail settings in iis (6)

Tuesday, November 22, 2011

Get Public Key External Tool

Another good external tool command is to get the public key token of your assembly.

Title: Get Public Key
Command: C:\Program Files (x86)\Microsoft SDKs\Windows\v7.0A\Bin\sn.exe
Arguments: -Tp "$(TargetPath)"
Use Output Window: Yes

Wednesday, October 19, 2011

Know which process to debug


With each new machine or new setup I'm searching for this information to know which w3wp process is mine to debug, so I'm adding it here in my blog to find it easily next time and to be available to everyone who search for the same information.

go to Tools from the upper menu, then External tool and add a new command:


The ID displayed in the output menu beside your application pool name is yours, and this is the process ID that you can select when you want to debug your application.



Tuesday, May 10, 2011

Moving SPWeb inside the SPSSite in SharePoint 2010 using PowerShell

This script will move the site “ToBeMoved” to be under “ToBeMovedTo” and change its Url and Title to “Moved”



$w = Get-SPWeb 'http://servername/ToBeMoved'
$w.Url
$w.ServerRelativeUrl = '/ToBeMovedTo/Moved'
$W.Title = 'Moved'
$w.Update()
$w.Url


Please note that it will take some time to be updated.

Sunday, March 13, 2011

SPDiscussionBoard after 6 years!

Just published was developed on 2005 with into consideration before working on SP.

SPDiscussionBoard started on 2005 while developing an ASP.NET forum and taking into consideration that I may use it on SharePoint in a day. Yesterday I remembered that, and started to alter it to run as a webpart inside SharePoint 2010, and it took about 4 hours to work.

Blessings of working on large real-world projects

Working on large real-world projects can offer numerous blessings and benefits, both professionally and personally. Here are some of the key...