Thursday, December 6, 2012

Error Failed to Connect to the Configuration Database: An Exception of Type System.ArgumentNullException Was Thrown. Additional Exception Information: Value Cannot Be Null Parameter Name: Service.

So, here we are trying to expand the SharePoint 2010 farm a bit. The farm is comprised of one or more VM sitting in an elaborate VMware infrastructure and a few physical servers hosting the databases. So the VM hosting the application services for SharePoint 2010 is kinda slow, so, decided to add a new one and yank the slow one out, or perhaps even leave both of them in there, y'know how cool it is for us to have more servers doing stuff, good for my ego.

And after going through the harrowing experience of missing locally and missing in xxxx servers and yyyy servers, and other annoying language pack issues, the box was finally ready. So, I fired up the SharePoint 2010 Products Configuration Wizard of Oz, and got this along the way, just the very first steps really:


error failed to connect to the configuration database: an exception of type system.argumentnullexception was thrown. additional exception information: value cannot be null parameter name: service.


Familiar it seems. Of course the error is not familiar, but getting errors from SharePoint is like our thing. I mean if you don't get any you begin to wonder am I doing things right? Kidding.

So, how do we resolve this?
Create an alias on the server for the SQL client. For some reason this was just the solution.
And to do that:

SQL Alias is something which you may have to create when you’re moving your database server. I had a requirement to move from an old database server to new one  and as a part of the migration had to create SQL Alias. This is how you create it.

You will have to create SQL Alias on each web front and application server of SharePoint.

Click on Start > Run and Type cliconfg
Click on Ok
Now enable TCP/IP Protocol.
Select TCP/IP and Click on Enable



Click on Alias Tab
Click on Add
Select TCP/IP from Network Libraries
And enter the old database server name in Server Alias
And set the Server Name to New Database Server Name
Click Ok

An Exception of Type System.Reflection.TargetInvocationException was Thrown

From the stables of SharePoint 2007 error-laden blockbuster features, comes another mysterious and annoying error, *drum roll*special effects*camera upclose*camera drawback*more Star War effects*


An exception of type System.Reflection.TargetInvocationException was thrown. Additional exception information: Exception has been thrown by the target of an invocation.

Sounds like something from FRINGE.
This happens when you try to join a new server to a farm. And that is after you have battled the infamous installcheck which returned like 80 language packs problem, 120+ missing locally problem and the rest of the evil minions from SharePain hell.

So, what do we do? How do we resolve?

You won't believe this. It's your NTFS drive letter causing this. Crazy!
Just to be sure, open your ULS log file in the APPLICATION server and do a search for directory name you entered is invalid.

If this returns a series of results (best if you use Notepad++) then that is the problem. What to do is take a look at the drive letter convention in your machines, and ensure your new server is consistent with the drive letters. So, if your APPLICATION server has C, D, E, F drives, ensure your new machine is named the same way. When done, re-run the Configuration Wizard again, and you should be fine.