Showing posts with label SharePoint 2007. Show all posts
Showing posts with label SharePoint 2007. Show all posts

Wednesday, January 30, 2013

SharePoint 2007 - stsadm error


After trying to restore a site collection from another environment I received the following error :


No content databases are available for this operation. Create a content database, and then try the operation again. To create a content database, click "Content databases" on the Application Management page, select the Web application to use, and then click "Add a content database".

Check CA and all was as expected, content DB's online.

I realised that the site collection had actually been restored before, even though it has a new name it had the same GUID within SharePoint and therefore needed to be on a new contentDB.



Wednesday, October 31, 2012

SharePoint 2007 "Code blocks are not allowed in this file" after saving a file from Word

Received the error after trying to save to a SharePoint document library via Word.
The method I used to resolve was to 

Go to Site Actions -> Site Settings.Click the "Reset to site definition" link.
The type in the link that is not working "Latest Documents/Forms/AllItems.aspx" and just reset this library 
This was fine for me as I didn't have any customizations as they will be reset.

Wednesday, March 28, 2012

SharePoint 2007 - Update multiple Site Collections quota values

Out of the box SharePoint 2007 does not offer an automated way to modify existing site collections with a quota value. For example if you have a quota "Extranet" with a size limit of 3GB that's been applied to 1000 sites currently there is no method to update this value on batch


However using the "SharePoint Administration Toolkit" you can run the following command


The following would update all the sites using the quota extranet with the new value


  • stsadm –o updatequota –quotaname Extranet

The following would update all the sites using the quota extranet with the new value but only that are contained in WSS_Content_001 


  • stsadm –o updatequota –quotaname Extranet -contentdb WSS_Content_001

For more examples follow this link 
http://technet.microsoft.com/en-us/library/ee449569(office.12).aspx


Saturday, March 10, 2012

SharePoint - Script to copy a files to SharePoint Library


Recently I was asked to automate a file copy from windows (UNC) into a SharePoint directory.  There are limitations with this especially with windows 7 and Server 2008 but luckily my requirement was from a Windows 2003 server to SharePoint 2010. You need to make sure you can view the "Explorer View" for this to work.


I used this simple DOS script, utilising  PUSHD (connects a the last free network drive) and POPD (release network drive).


rem $echo off
rem ************
set REPORT="d:\Sharepointcopy\InsiteSharepoint2010.log"
echo %date% %time% >> %REPORT%
pushd "\\contoso.com\Documents" >> %REPORT%
copy d:\*.xml /Y z:\ >> %REPORT%
popd 
echo %date% %time% >> %REPORT%
echo *Finished*>> %REPORT%



Monday, February 13, 2012

SharePoint 2007 - Configuration must be performed in order for this product to operate properly

Received this error when trying to upgrade a 2007 farm from 12.0.06545 to 12.0.06565 on a test environment.


I had run all patches on the farm both WSS and MOSS and could not see why the configuration wizard would not complete - my first reaction was to try re-installing patches but all stated "Already Installed".


I then checked the servers in farm via CA and saw the following - see version numbers






From the screen shot you can see the versions are not displaying correctly and this was causing the wizard to fail, even though all had been installed !!


After a few reboots, IIS resets I realised that the issue was the timer job on the offending server was not running (not on purpose). As soon as this was started the version upgraded and wizard run correctly.

Thursday, February 9, 2012

SharePoint 2007 - Errors after patch deployment

Recently we started seeing the following errors appearing in our SharePoint 2007 environment and sites not able to be created.:



  • The element 'FormTemplatesList' of type 'ListInstance' for feature 'IPFSWebFeatures' (id: a0e5a010-1329-49d4-9e09-f280cdbed37d) threw an exception during activation: Operation aborted (Exception from HRESULT: 0x80004004 (E_ABORT))
  • Failed to activate template-associated site-collection-scoped features for template 'STS#0' in site
  • Failed to apply template "STS#0" to web at URL 
  • Feature Activation: Failed to ensure feature dependencies for feature 'PublishingSite
  • Feature Activation: Failed to ensure feature dependencies for feature 'PremiumSite'



In our environment  by mistake one of the servers in the farm had a latest patch downloaded to it - in this case 12.0.0.6565 - and the rest of the servers were on 12.0.0.6545. However we were not aware the patch had been deployed to the above errors were the only indication something had changed in the farm as via CA it still displayed the old version number.


Out first thought was to run the wizard on the affected servers which proceeded in upgrading the server to the patch and then also all the content databases in the farm .... not ideal and against all Microsoft best practices. Once we realised there was no way to roll back we upgraded the rest of the farm and the errors above disappeared.


Its seems the errors were around mismatches in dlls 









Wednesday, February 1, 2012

SharePoint 2007 Locked Documents

SharePoint Locked Documents


This document contains three potential problems that can occur on SharePoint with locked/checked out documents.  The below will help a reader to recognize and resolve these issues.

Index


Identifying the problems
Fixing the issues
Recovering lost Information/document
Understanding the issue

Identifying the problems


1) A user reports that they cannot edit a SharePoint document as it is locked.  They receive the “File In Use” popup when trying to edit the document.
At some point in time, you will run into the DocumentName is locked for editing by ‘Username’ message when working with SharePoint. Most of the time, this is a very valid message and is notifying the user that someone else is already editing the document.

    Figure 1
 
2) A user reports that they cannot edit a SharePoint document as it is locked, and it is their username that has it locked.
This situation most commonly occurs under the following scenarios:
·         The Microsoft Office product crashes while you were working on the document
·         Computer freezes or crashes while document is open
·         Lost of network connectivity while document is open
3) A user is on holiday or has left Bromley employment and they have some documents checked out (locked). As such users are unable to edit these documents which are checked out.
When trying to edit a document you receive the message reported in “Figure 1”.  The user who has locked/checked-out the document is on holiday or left the company.

Fixing the issues


1) Issue one is a valid message from SharePoint which informs the user that someone else had the document open for editing. 

2) Issue two happens when SharePoint has not received an updated from the client computer that the document has been closed.  To resolve this issue please follow the steps below to reset the lock on the document.

  • If the user has lost information or can not find the document please first follow the “Recovering lost Information/document” section of this document”.
  • Navigate to the document which you are unable to edit, and then check the document back in using the menu in SharePoint as below.  If you are unable to check in the document select the “Discard Check Out” option, and click OK.


  • Move all files from the location below to a temporary folder, wait 10 minutes, then restart the P.C.

“C:\Documents and Settings\<UserName>\Local Settings\Temporary Internet Files\Content.MSO”



  • Once the P.C. has been restarted the file will be accessible for editing on SharePoint.
  • Request confirmation from the user that the document is accessible and up to date.  If the document is accessible and up to date remove the temporary folder you created.   If the document is not up to date please follow the steps outlined in “Recovering lost Information/document”

3) With Issue three, report this to the SharePoint administrator as they will have to take ownership of the documents and then check them into SharePoint.

Recovering lost Information/document


If word has terminated unexpectedly when editing a SharePoint document, or the network became unavailable and the user has lost work you can attempt to recover this information from three places on the users P.C.

  • Navigate to the hidden folder below.

    “C:\Documents and Settings\<UserName>\Local Settings\Temporary Internet Files\Content.MSO”

    This folder should contain the last saved changes.  The document will not have the same name but will be a .doc file extension as below.  Also there should not be a lot of files in this folder as it is cleared out once the file is correctly checked-in to SharePoint.


  • Draft documents are also saved in M:\SharePoint Drafts.  When a document is checked out, it is saved in the user's My Documents folder in a subfolder named "SharePoint Drafts." As long as the document is checked out, the user can only save edits to this local folder. When the user is ready to check the document in, the document is saved back to the original server location. 
  • Microsoft Word also has an auto recovery folder for which can be checked for office documents that have not been saved correctly.  The default location of this folder is

    C:\Documents and Settings\<user_name>\Application Data\Microsoft\<office application i.e. word>. 
The document may never have been saved and so may not have title. This will make it hard to identify, but again there should not be lots of files in this location.  Use the detailed view for the most recently created documents to help identify the correct file.


Understanding the issue

When you edit a document, SharePoint registers that you have this document open for editing.  Word launches and informs SharePoint that you have the document open for editing.  A copy of the document that you have opened is placed into a hidden folder in your temporary internet files
C:\Documents and Settings\UserName\Local Settings\Temporary Internet Files\Content.MSO
Once every 3 minutes or so, the Office product will check back in with SharePoint letting it know that it is still open by you, after 10 minutes without office checking back the soft lock will be removed (soft lock is a document that is being edited but not checked out, checked out is a hard lock). Once the document is saved, closed and checked-in the content.MSO folder be removed and office will let SharePoint know that the document is now available to other users. 
If the document has not been saved closed and checked back into SharePoint and another user tries to access this document they will receive the message reported in “figure 1”.  This is a normal function of SharePoint informing users that someone has the document open and is editing it.
On some occasions you will receive the locked for editing message with your name there and no matter what you attempt to do you cannot get rid of the message (closing / reopening the document or restarting your computer does nothing to help rectify this).
This situation most commonly occurs under the following scenarios:
·         The Microsoft Office product crashes while you were working on the document
·         Computer freezes or crashes while document is open
·         Lost of network connectivity while document is open
Further information:

Friday, January 27, 2012

SharePoint Disable Loopback on server


This needs to be actioned to resolve 401 errors (access denied from Web Server and putting a logon failure in eventlog)




Setting the DisableLoopbackCheck registry entry in the HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Lsa registry subkey to 1. 


To set the DisableLoopbackCheck registry entry to 1, follow these steps on the client computer: 


1. Click Start, click Run, type regedit, and then click OK.  
2. Locate and then click the following registry subkey: HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Lsa 
3. Right-click Lsa, point to New, and then click DWORD Value.  
4. Type DisableLoopbackCheck, and then press ENTER.  
5. Right-click DisableLoopbackCheck, and then click Modify. 
6. In the Value data box, type 1, and then click OK.  
7. Exit Registry Editor. 
8. Restart the computer. 


Note You must restart the server for this change to take effect. 

Thursday, January 26, 2012

500 Service Unavailable - ISA 2006 and SharePoint 2007

Using SharePoint 2007 and ISA 2006 I came across an issue where external users of a site were recieivng the error "500 Service Unavailable" - even though the site was available and working. After some digging around I found the following resolved my issue 


I was required to switch off "verify normalisation" on ISA - it seems its an incompatibly between ISA 2006 and SharePoint 2007 










Wednesday, January 25, 2012

SharePoint 2007 - Central Admin stops working when installing search


On a couple of occasions when going through initial configuration of search- Central Admin stops working - cannot access.
Don't panic - What actually happened in my instances whilst  using Windows 2008 is that if you setup the Search service it writes an entry in its local host file. For example on myServerA we set up appserver to be index server, sharepoint adds following entry to host files


fy80::49e2:5150:a356:32ac%10 myServerA 


What sharepoint is actually doing is reading the Link-local IPv6 Address which is not quite right.


This just needs to be manually replaced in host file 
127.0.0.1 localhost myServerA