Wednesday, January 28, 2009

Warning: SharePoint rant

It has been a while since I have had cause to rant about the quality of SharePoint (see post about variation hotfix), but today after spending most of the day looking for solutions to a problem I was having with updating SharePoint to SP1, I have good reason to rant.


Originally when creating a variation, I had run across an issue where I was getting an error about a Primary Key Violation. I did some searching and found that it could be a couple of things. One of the options was that there were pages in draft mode, so I checked for those and there weren't any. I then found another post that suggested there was a hotfix for the issue, so I downloaded the hotfix related to KB936867 and installed it. The issue went away and I was able to create my variation.


Then I decide to finally upgrade to SP1 since there is a post-SP1 hotfix for another issue I was having with variations. (Notice a pattern here already). Why I need a post-SP1 hotfix for another hotfix that should have been fixed in SP1 is ridiculous. So I install SP1 after some trouble and try running a variation. I once again get the Primary Key Violation. I did some more searching and everyone said that this was supposed to be fixed in SP1. It couldn't have been since many people are still having the issue. So I kept searching and finally found a post that described the same problem I was having and come to find out there is another hotfix to fix whatever SP1 broke in the previous hotfix. The KB is 950279. What ticks me off is the number of times you find an issue, Microsoft issues a hotfix for you, the hotfix is supposed to be rolled into the Service Pack, but after you install the Service Pack, you get the issue again. What is even more troubling is that you can't back SP1 back out, you have to reinstall MOSS or WSS. Then you have to wait for Microsoft to create another hotfix for you to apply to get back to where you were before you tried installing SP1.


My advice to anyone who has not installed SP1 yet, make sure you have post-SP1 hotfixes for any hotfixes you currently have installed on your server. If you don't you will run into a number of messes that you may not be able to recover from.


It would be nice if Microsoft would test these Service Packs and hotfixes before they release them instead of typing up a paper saying you need to back up your databases before updating, just to cover their butts.


I am going to do some serious thinking before I install any more SharePoint updates on my servers.

Labels: ,

Wednesday, January 21, 2009

Upgrading to MOSS SP1

This past weekend I was set to upgrade the Web server to MOSS SP1 and see if there were any perfomance and stability gains. I looked over the many documents that Microsoft published to make sure I had all my ducks in a row. I also checked with our hosting company to make sure that they could restore the server to a previous snapshot in case the upgrade went bad.





Good thing I did that!!





One of the biggest things to keep in mind with this Service Pack is that there is no way to uninstall it. You have to uninstall ALL of MOSS and then reinstall it and connect the new installation to your content databases.





The upgrade to SP1 can be quite long, depending on how many laguage packs you have installed.





The upgrade for my particular installation looked like this:







  • Install WSS 3.0 SP1


  • Install MOSS 2007 SP1


  • Run config wizard


  • Install WSS 3.0 Spanish Language Pack SP1


  • Install MOSS 2007 Spanish Language Pack SP1


  • Install WSS 3.0 French Language Pack SP1


  • Install MOSS 2007 French Language Pack SP1


  • Run config wizard


  • Install Post-SP1 hotfix for variation issue


  • Bring site back online and make sure everything still works


The first two items on the list went very smooth. The third one, not so much. I ran the config wizard and it got to step 8 of 9 (which is the one that actually updates the DBs) and it failed and told me to check the log file. I looked in the logs and traced back to the errors and the first one I found said 'The b2b timer job failed.' That was it! No description of what failed or anything. So my mind started to go into panic mode and I went to check to make sure that the site would run at all and it did. So then I began poking around on the net for people that had similar issues. There were tons of articles and posts from people that said they received the same error and stopped various services and ran psconfig and then ran the config wizard and everything worked fine then.



No such luck with my installation. No matter what I tried I still got the same error message with no better explanation. After three hours of searching, I decided to leave it and let our hosting company restore the server.



I will be diving further into this error in the near future as I saw some posts that said Microsoft will not support you if you do not upgrade to SP1 and I would really like the server to be running on it for stability reasons.


UPDATE: I finally figured out what was causing the upgrade to fail. Something was wrong with the Shared Services Database, so I created a new Shared Services Provider since the only thing running on it was Search and deleted the old one. I then moved the site collections to use the new SSP. I then ran the updates and the configuration wizard ran fine. After getting the updates installed I had some other issues with Primay Key Exceptions which led to installing another hotfix, but finally have my test installation upgraded to post-SP1.

Labels: ,

Monday, January 5, 2009

Using a batch file to Open SharePoint site in browser

Today I was tasked with making it easier for employees to get to our Intranet site. There are a couple of public computers in the break room that employees can use to browse the net on their breaks.


These computers are not really computers in any sense. They are more like dumb terminals. They can store a certain amount of data in non-volatile storage so this limits much of what I can do.


The task was to provide an icon on the desktop that the employees could click on and it would open up the Intranet site in the browser and make sure they are automatically logged in. The logging in would not be so hard in a normal corprate network situation as the user that is logged into Windows would have their credentials passed into SharePoint. This was not the case as these computers are not attached to the domain and not on the corporate network.


I figured the best way to accomplish this task was to create a batch file. I knew it was pretty easy to open a program in a batch file so I began with:


start iexplore.exe http://intranet


This would open up the Intranet site in Internet Explorer. Now I just need to pass in the user credentials so the user is not prompted for a login and password.


I began searching on the web and found some posts that suggested using /user:domain\username password so that it looks like this:


start iexplore.exe http://intranet /user:domain\username password


This did not change the user at all and it still caused the prompts. I then found a post by David Klein on using impersonation batch files for testing web applications. He had very similar conditions - Integrated Windows Authentication and an Intranet site that he wanted to open as a different user. His suggestion is short, simple, and works like a charm:


runas /user:domain\username /savecred "%ProgramFiles%/Internet Explorer/iexplore.exe http://intranet"


This will cause the machine to prompt for the password the first time it is ran but after that it stores it (until the computer is rebooted). This is also fairly secure even if it is a batch file that anyone can view in Notepad since the command does not contain any passwords.


The only downside to this is that if the computers are rebooted or the power goes out, you will need to re-enter the password the first time.

Labels: ,

Thursday, January 1, 2009

SharePoint Databases

If you ever wondered about the structure of the SharePoint databases and what all of the fields mean and where you should look in the databases for the information you need, you will want to check out the MSDN articles. (I don't recommend changing anything inside the SharePoint databases, you can really mess up an installation that way). There are articles that explain the tables for the configuration and content DBs as well as the stored procedures.

Labels: