Posts

Showing posts with the label SharePoint 2007

SharePoint 2007 documents opening as read-only

Consider the following Scenario: On Windows Vista, Windows 7 or Windows 2008 systems with Office 2007 or Office 2010 installed and Internet Explorer 7 or Internet Explorer 8, you attempt to open files from a SharePoint site using a Fully Qualified Domain Name (a URL including ‘.’ in the site name). The SharePoint 2007 is hosted on Windows 2008 or 2008 R2 Server with WebDav enabled. The SharePoint 2007 site is setup to use Windows Authentication. Users of the SharePoint site are expecting Client Integration (being able to edit and save directly back to the server) to be functional. In this scenario, a user may see one or more of the following symptoms: The user is prompted unexpectedly to enter their credentials.  The Office document will open in Read Only.   When opening SharePoint Explorer View an error will occur showing the path to the Document Library and a message of "Not Implemented".  When trying to save from Office back to a SharePoint ...

PeoplePicker - Picking user from multiple domains, stsadm commands

Image
When you want to pick users from multiple domains in your SharePoint Site's PeoplePicker (it will comfortably work in the Central Administration though!), here is what you need to do. 1. Ensure there is a trust relationship between the two domains (one domain could also be a child domain of another) 2. Run the stsadm -o setapppassword command 3. Run the stsadm -o setproperty command Find screenshots below:

SharePoint Server 2007 - Central Administration Service Unavailable

If you encounter the "Service Unavailable" error in your Central Administration, you might try running the Configuration Wizard and also check if the Application Pool is running fine, but if all this does not work, it is definitely ready to take you for a ride. One thing you should check is EventViewer and you might find an issue with any SharePoint Services like SPSearch for exampe not being to successfully login to the content database. You might go to the Control Panel -> Services -> SharePoint Server Search, change the Log On identity to the Farm Admin account and run it successfully, but still you might have a problem with the Central Admin. This is where you need to step back and think if someone has changed the password for the service accounts without actually letting you know! Now, start going through the various stsadm commands over here and update the service accounts one by one... http://support.microsoft.com/kb/934838 Now, this will definitely do...

Renaming your SharePoint Server Machine when SharePoint is installed

When you want to rename your SharePoint Server Machine (where SharePoint is already installed and running), follow the following steps: 1. Use the StsAdm or Windows PowerShell Command to rename your SharePoint Server 2. Change the Computer Name in Computer, Properties 3. Restart the machine 4. Go to the Farm Administrators Group in Central Administration to possibly change the Name of the Administrator from oldserver\admin to newserver\admin 5. Then change the Alternate Access Mappings to refer to the new server instead of the old server 6. Bingo, you are done! stsadm -o renameserver    -oldservername <oldServerName>    -newservername <newServerName>

Code blocks are not allowed in this file

Whenever you encounter this error, when having Server Side Script in your custom ASPX Page stored in your Pages Library, you just need to add this line in your site's web.config. Do not forget to replace the VirtualPath to point to the folder or library which has those pages. <PageParserPaths> <PageParserPath VirtualPath="/sites/TestSites/page/*" CompilationMode="Always" AllowServerSideScript="true" /> </PageParserPaths>

Creating automatic SharePoint backup script (.dat)

Image
Create Backups Directory Create a backup directory for storing the scheduled SharePoint backups (e.g.d:\backupsharepoint) Create Bat File Directory Create a directory for storing the backup script file (e.g. d:\scriptssharepoint) Create Bat File Create a bat file using the code below, modified for your environment. Use UNC paths when using in a server farm environment. @echo off echo ==================================================== echo Backup Script For Office SharePoint Server 2007 echo ==================================================== cd \program files\common files\microsoft shared\web server extensions\12\bin @echo off stsadm.exe -o backup -url http://servername -filename d:\backupssharepoint\backupsharepoint.dat -overwrite @echo off echo completed Schedule bat file Schedule the backup to run frequently, during off peak hours. Open Start > Programs > Accessories > System Tools > Scheduled Tasks Add a Scheduled Task Schedule...

Increasing Maximum File Upload Size in MOSS 2007

Image
By default, MOSS 2007 has a setting of allowing file sizes of upto 50 MB. If you need to change it, do the following: 1. Change the Max Upload Size in Central Admin -> Application Management -> Web Application General Settings 2. Also in IIS 7, change the Connection Timeout to how many ever seconds you want - reason is, the more the file size, the longer it is going to take to upload, so to be safe, default is 120 seconds

The security validation for this page is invalid - resolution

Image
Whenever you are having your code trying to manipulate files in document libraries and they have to work in different identities, you most properly will have your "Allowunsafeupdates=true" line added in your code. This works most times, but at certain scenarios, it might throw up the below error (at the time when the code is trying to move a document from one library in one site to another library in another site). The same code however would have worked for the Admin login. Resolution The resolution for this is not in the code unfortunately! All you need to do is go to your Central Administration -> Application Management -> Web Application general Settings and turn off the "Security Validation" Bingo, your code for all users starts working fine!

Restoring SharePoint 2007 on a new server

This is my scenario. I have one server running AD, SQL 2008, MOSS 2007 SP2 and wanted to separate the AD into one server and MOSS into a new server. This is what I did (and definitely not as simple as I thought it would be!) Leave the AD server as it is Install Windows, SQL, MOSS on the new machine Format and install AD on the first server Re-join the MOSS server to the Domain Create all required SharePoint accounts in the AD Now, you will have your SharePoint site giving an HTTP 404 error mostly If you check the EventVwr, you will have "Cannot open database...Login Failed" error for the SharePoint content access account You need to delete this user from the AdminContent database and re-add by giving that respective login After that, you need to re-create the Schema as well (Ensure the particular admin account for example domain\spadmin is scripted in a notepad and kept Once you do the above, you will have both the Central Admin and Sites opening properly but not...

Access Denied Error - stsadm restore

Image
When doing stsadm restore, sometimes you might end up getting access denied error. If you get this, first, check whether your command prompt is running as Administrator even if that does not solve the issue, go and add your Administrator account (assuming that is your main services account), as your primary site collection administrator (this is in Central Admin). Make sure Secondary Admin is not the same as the primary admin. Secondary admin ideally can be the machine's administrator (assuming your server is a member server of the doman and you alreay have added the domain administrator as the primary admin)

VSS Error in Event Viewer after installing SharePoint

After installing SharePoint Server 2007 on Windows Server 2008 R2, you may start to see the following error message in the event logs : Volume Shadow Copy Service error: Unexpected error calling routine RegOpenKeyExW(-2147483646,SYSTEM\CurrentControlSet\Services\VSS\Diag,…). hr = 0×80070005, Access is denied. Inspection of the detailed tab of the event log entry will show information about the process that generated the error. Take note of the user mentioned after the “- User: Name:” portion of the bytes. To resolve this error, simply give that user full permission to the HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\services\VSS registry key.

Enable Features shows as initializing and not moving

Image
If you have the above problem, check your Time Job Definitions and Delete the "Enable Features" job, that should stop this particular activity from running indefinitely.

Issues connecting to SQL Server 2008 from SharePoint (while installing) or issue connecting to Windows Server 2008

Whenever you have issues connecting to SQL Server 2008 from your SharePoint installation wizard or when you are having trouble accessing your Windows 2008 machine from outside (your VMWare or VirtualPC) - trust me, the issue is with the Windows Firewall! Turn it off (it has Domain, Public and Private Profiles) and turn all of them off for you to seamlessly connect through!

The type 'Microsoft.SharePoint.Portal.Analytics.UI.ReportViewerMessages, Microsoft.SharePoint.Portal, Version=12.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c' does not implement IReportViewerMessages

You get this error when you have a custom ASPX page having a ReportViewer WebPart. I initially had my SSRS 2008 running in SharePoint Integrated Mode, later I changed the mode to Native and also uninstalled the SharePoint Reporting Services Add-in. Even after this, I still had this error coming up. This is what I did to fix it : added inside the tag of my SharePoint application as well as the virtual directories of ReportServer and ReportManager (these are inside C:\Program Files\Microsoft SQL Server\MSRS10.MSSQLSERVER\Reporting Services) Last but not the least, I also restarted the server for this to start working! :)

The given key was not present in the dictionary - issue when opening a SharePoint List

Whenever you encounter this error "The given key was not present in the dictionary" when opening a SharePoint List or when creating a new item on a list, am sure you are led to search your own code to see if you have wrongly referenced any non present field... But, that is not the case unfortunately! This mostly comes in lists where you have Custom Fields (inherited from SPField) created. You will have to check if you have the corresponding fldtypes xml created and placed in the template/xml folder apart from placing the .ascx file in the ControlTemplates folder. So in your case, you will mostly not have placed the xml file and that is what will be causing this issue!

Removing missing feature dependency on a STP file

When you have a missing feature in your SharePoint that refuses to go away inspite of deactivating it as well as uninstalling it by force, a site template (.stp) that depends on - fails to work... so how do you make this work? Well, you have to manually delete the feature id reference from the manifest.xml that is present in the .stp file. As you know, .stp files are nothing but .cab (cabinet) files, so all you need to do is rename, change the extension, open in WinRar or any such cabinet handling program, extract the files out, modify the manifest.xml file  (just delete the xml tag that points to that missing feature) and then when you have to place it back - you have to be careful! You have to make sure there are no sub folders that get created! Check my another post on how you can use the makecab.exe utility to recreate the cabinet file. Once you create that, then you need to rename it back to .stp, upload it back to the Site Template Gallery - and start using it!!!

SharePoint Activating Publishing Infrastructure issue - Product has expired

In SharePoint when activating through GUI, "Publishing infrastructure" feature, you get this error inspite of the product not being in Trial. I fixed it by first running stsadm -o activatefeature -name PublishingResources -url http://site/  in command line and then activating using the GUI.

SharePoint 2007 Full Crawl Never Stops

I found this behaviour when you have just changed your index location to a different folder instead of the default location. The full crawl just does not stop! It keeps running forever! All I did was to "Reset all Crawled Content" and then reran the crawl. It started working like a breeze! :)

Change Default Index File Location

Change Default Index File Location In a farm environment it will be usually a requirement to have the index file location on a separate drive and folder as opposed to the default location which is: "C:\Program Files\Microsoft Office Servers\12.0\Data\Office Server\Applications" You can set this path for an SSP by using the UI through Central Administration. But to set the default path for Office SharePoint Server Search Service and for WSS Search Service you will have to set the location through STSADM command. Office SharePoint Server Search Service is configured using OSEARCH command: stsadm -o osearch -defaultindexlocation e:\Data\MOSS_Search_Index (By default, the search index will be located at this path on this server. For index servers, you can specify a different path when you create an SSP. Note: Changing the index location will reset the index. To move an index with a reset, use the noreset parameter of the Spsearchsensitive or Osearchsensitive op...

Site Template (.stp) invalid error

Sometimes, when you save your Site as a Template, you get a .stp file and then when you try and create a new site out of it, it could give you a Site Template Invalid or not found issue.... This usually is because your Site Template has got dependencies (features) which are not correctly present ie installed. The best way to see this is to use STP Inspector tool ( http://stpinspector.codeplex.com/releases/view/38429 ) which will show you the various dependencies and then you can independently go and troubleshoot them. Once you correctly install all dependencies, the site template will start working correctly.