No Free Time

March 28, 2008

Membership Provider error: A connection was successfully established with the server, but then an error occurred during the login process. (provider: Shared Memory Provider, error: 0 - No process is on the other end of the pipe

Filed under: moss 2007 — Tags: , , — andrewmyhre @ 3:57 am

Got this obscure error today when setting up a membership provider. I was setting up an ASP.Net Sql Membership Provider for Sharepoint 2007.

First I ran aspnet_regsql.exe for the SQL Express database behind the Sharepoint install, creating a new database in the process just for the ASPNet membership provider data. I then set up a connection string in the web.config for the sharepoint application, and added the <membership> and <roleManager> data to the web.config also. Trying to open the sharepoint site in a browser then yielded the error:

“An unexpected error has occurred. “

To properly diagnose the issue I created a new, blank ASP.Net website, and copied the connectionStrings, membership and roleManager config settings into the web.config for the new site. Then I opened the ASP.Net Administration Tool, and clicked the Security section link, which gave me a much more informative description of the error:

Default Membership Provider could not be found. (C:\TestWebsite\web.config line 17)

Nice! So I added the defaultProvider attribute to the membership element. Next, though, I got a weird error:

“A connection was successfully established with the server, but then an error occurred during the login process. (provider: Shared Memory Provider, error: 0 - No process is on the other end of the pipe.)”

Weird. Luckily though, my sixth, or perhaps seventh sense told me it was probably an authentication issue with the database. Sure enough, when I replaced the User ID and Password parts of the connection string with “Integrated Security=true”, the administration tool started working without problems. Copying the changes back into the Sharepoint web.config proved that I’d fixed the issue.

Blog at WordPress.com.