Showing posts with label Sharepoint. Show all posts
Showing posts with label Sharepoint. Show all posts

Sunday, August 11, 2013

Sharepoint prompting credentials for Explorer mapped drives

I have lived with the sharepoint explorer link prompting for many years, but found the solution below.  Oh joy.....

Windows 7 | The SharePoint Project: "1.   Click Start, type REGEDIT in the Start Search box, and then press ENTER.

2.   Locate and then click the following registry subkey:

HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\WebClient\Parameters"

make sire the sites you add start with http://  ie http://your sharepoint site.
Other blogs say you have to put the entries in twice.

Then goto services and restart the web client service.

Hey presto - it works.... (or at least should... and did for me)

Monday, July 02, 2012

Embedding a SWF into Sharepoint

I though this would have been easy, however Sharepoint strips out the HTML as a potential security threat.  I ended up useing a web content page link to an external hosted site, however here is a different way to achieve the same thing

Monday, June 11, 2012

addcontentdb Could not find stored procedure 'dbo.proc_SetDatabaseInformation'

Issue: I was attaching a restored content database using STSADM -o addcontent to a SharePoint 2007 web using the command below when I got the following error: Could not find stored procedure 'dbo.proc_SetDatabaseInformation'

stsadm.exe -o addcontentdb -url http://intranet.mycompany.local -assignnewdatabaseid -databasename WSS_Content_MyDB -databaseserver MySQL.mycompany.local
Solution: I found that the error message relates to the configuration database and there are lots of articles talking about different version patching issues.  

However the real issue seems to be the -assignnewdatabaseid parameter.  It causes SharePoint to look for the procedure which it cant find if the versions are missmatched.  If you can get away with not adding the -assignnewdatabaseid parameter you should find it will run ok

Thursday, May 10, 2012

stsadm -o import -updateversions 2 - error / doesnt do what its supposed to

I had a scynario where a site with multiple subsites needed to be restored in SharePoint 2007.

The majority of sites didnt need document history, so I thought that we could restore all of the sites without the history and then selectivly restore the ones that did need it.

There is a switch on the STSADM.EXE -o import  called -updateversions. This switch is supposed to indicate how to resolve situations where a file to be imported to a site already exists in that site.  using a value of 2 should Overwrite the file and all of its versions (delete then insert).  

BUT of course it doesnt.....  it seems to ignore my 2 switch and revert to the defaul of 1, which is to add the documents again so I get a complete set of duplicates.  Lovely......

http://technet.microsoft.com/en-us/library/cc287920(v=office.12).aspx

A usefull link to the Sharepoint Site Template Numbers

http://www.bfcnetworks.com/sharepoint-2010-site-template-id-numbers/

Wednesday, May 09, 2012

Office 365 Error- Access Services reports are not enabled.

I have long been sceptical about running custom SharePoint sites on Office 365, but I thought as its maturing I'd give it another bash.

I needed to store a list of contacts and other meta data, so I thought I'd add a "Contact Web" subsite.  This is actually an access database that is hosted in Sharepoint.  Very clever I thought, but so near and yet so far.....

The default Address book view allows you to add and edit contacts, however in the Note portion you get a correlation error saying "Access Services reports are not enabled. To view the report, open the report in the Access client." - not very helpful.  If you try to go to the Report Center tab you get the same issue.

Apparently the reason is that Office 365 hasnt turned on access services !    So the Contact Web subsite that that Office 365 allows you to create isnt fully supported by Office 365 !!

Come on Microsoft, either offer full access services or handle your errors properly and dont offer a site template you cant support.

http://support.microsoft.com/kb/2632471

Error- Access Services reports are not enabled. To view the report, open the report in the Access client. - Office Professional Plus developer - Office 365 - Microsoft Office 365 Community

Friday, October 07, 2011

Viewing Sharepoint sites on the Sharepoint server (disabling server loopback checks)

Its been a problem since Win2003 SP1 that you couldn’t browse to a web site hosted on Sharepoint on that server.
Ive now found this is security restriction called loopback check, where the server stops any access back to itself unless you use the server’s name in the URL.

There are two alternatives to stop this behaviour.

Option 1 - is to disable the loopback check for all sites – which should only be used on a development machine.

· In Registry Editor, locate the following registry key: HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Lsa
· Right-click Lsa, point to New, and then click DWORD Value. (In Win 2008, its DWORD 32bit)
· Type DisableLoopbackCheck, and then press ENTER.
· Right-click DisableLoopbackCheck, and then click Modify.
· In the Value data box, type 1 and then click OK.
· Quit Registry Editor.
· You may need to restart your server.

Option 2 - is to disable the loopback check for each site individually – which should be used on production machines.
· Click Start, click Run, type regedit, and then click OK.
· In Registry Editor, locate and then click the following registry key:
· HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Lsa4.Right-click Lsa, point to New, and then click DWORD Value.
· Type DisableLoopbackCheck, and then press ENTER.
· Right-click DisableLoopbackCheck, and then click Modify.
· In the Value data box, type 1, and then click OK.
· Quit Registry Editor, and then restart your computer.


Ps I also found a related issue with respect to CNAME sharing restrictions (see this link)
HKLM\System\CurrentControlSet\Services\LanmanServer\Parameters [DisableStrictNameChecking (DWORD) = 0x01]



Blog references
http://support.microsoft.com/kb/896861
http://www.harbar.net/archive/2009/07/02/disableloopbackcheck-amp-sharepoint-what-every-admin-and-developer-should-know.aspx
http://platinumdogs.wordpress.com/2009/08/26/sharepoint-host-headers-and-loopback-checking/


Thursday, June 10, 2010

Viewing SharePoint 2010 sites on Windows Server 2008 R2

Running SharePoint 2010 server on a Windows 2008 R2 server seems to be a sensible thing to do.  Well at least I thought that until I tried to locally access SharePoint sites on that server via IE.

You will find that on Windows Server 2008 R2, you will be prompted for authentication three times and the page will fail to load. This is because R2 uses the new SPNEGO2 implementation:

 (You may ask why would you need to access sites locally on the server? - well for things like Visual Studio development for SharePoint you must actually develop and run them on your development SharePoint server)

 The solution to this is to make sure that Web Applications you need to access on a Windows 2008 R2 server are setup with the following:

a) a SPN for each Web Application URL
This consists of using the http url of the Web Application and adding it to the Service Principle Name (SPN) of the AD account that the Web application pool runs as. eg.  with a Web Application called http://home.company.com which runs in an IIS AppPool called MySPSites that runs under the security account of mydomain\SPServices.
SETSPN.exe -S HTTP/home.company.com mydomain\SPServices
  • (make sure you use an administrative CMD window)
  • (this may take a little while on a large AD as it first checks for any duplicate SPNs and if it doesnt find one then adds it to the account).
and (b) For the URL or (URL plus port number) of the Web Application you wish to access on the Windows 2008 R2 Server, you must set either the Default security Zone, or an extended one to have IIS Authentication set to use Kerberos security.
You can do this either on intially setting up the Web Application with Kerberos, or if you need to use different IIS Authentication types for your Default Zone Web App then, after you have created it, extend it using either a different URL or port number.  You can choose a different security Zone when you extend the Web App, or, unlike SharePoint 2007, you can change the IIS Authentication Settings at any time from the Sharepoint Admin console via -> Central Administration->Security->Specify Authentication Provider.
I had hoped that I would only need to carry out step (a) as eluded to in the Harbar.net article but thus far I havnt managed to avoid step (b)
References:

Wednesday, June 09, 2010

Access Web Services : form filtering and sorting

If you setup a form based on a table source and then add in the forms properties to sort and filter, when you add this form to a Navigation page it completely disregards what you have entered in the forms properties and  just uses the default sort for the table with all values - Brilliant Microsoft!



Filter and Order By Properties  get ignored.


So to get around this for sorting you need to write a query on your table that has the data sorted in the format you require.  Then change the form to use the query instead of the table and that’s sorting sorted out.

But what about filtering?

Well on the tab for a navigation page there is a property called "Navigation Where Clause"  if you put your where statement in there Microsoft actually uses this filter in the way you would expect and doesn’t ignore it as before.  Wonderful!

Navigation Where Clause's do  work

Tuesday, June 01, 2010

SharePoint 2010 : State Service issues & problems


I built two SharePoint Enterprise servers in separate farms from scratch using different farms and SQL servers. The first is a development machine to try things out on and the second is the production box.

As with all the best MVP advice you should not use the configuration wizard but manually create each service and for the most part Ive done this successfully, however when we started trying to use Infopath or Reports in Access Web Services we started getting some odd errors such as:

The form cannot be rendered. This may be due to a misconfiguration of the Microsoft SharePoint Server State Service.

And

This report failed to load because session state is not turned on.

This was happening on both the production and development servers which was most odd.

Looking in SharePoint service applications there was no reference to the "State Service" on one of the servers and one line item for "State Service" on the other. Also most odd as both servers had been setup in the same way.

 There is no way to create the State service from the new service application menu as it should have been setup from the SharePoint install, so you either have to use the Configuration wizard or PowerShell.

 In the case of there not being any reference to a State Service I ran a powershell command to create a state service database and then ran the Configuration Wizard with everything possible unchecked apart from the State Service. The powershell command to create the database is "

New-SPStateServiceDatabase" See TechNet for more details

After an IISReset the errors seemed to clear and all was well with one of the servers.

For the other server the same process wasn't an option as the Configuration Wizard already had the State Service Checked. So using Powershell I manually created a State Service Application and State Service Proxy and enabled it all using the commands


New-SPStateServiceApplication
New-SPStateServiceDatabase
New-SPStateServiceApplicationProxy
and
Enable-SPSessionStateService

(See http://technet.microsoft.com/en-us/library/ee890113.aspx)

 However after doing all of this successfully and being able to see the State Application and Proxy in the SharePoint Central administration list of service applications the error s still persisted. So using the SharePoint service application screen I deleted the first State Service and the new State Service Proxy and State Service which I had created. This allowed me to run the configuration wizard with only the State Service tick box checked and after another iisreset voila !

Others have also seen this issue - see

Misconfiguration of the MOSS State Service
Pasted from <http://social.msdn.microsoft.com/Forums/en/sharepointworkflow/thread/521db715-0d76-49ce-be36-7c37cfb8026f>








 

Monday, May 31, 2010

Access 2010 Web database conversion

Native SharePoint 2010 is dissapointing in terms of not being able to have relational data lists or lookups with filtering and for reporting I used Access reporting based on SharePoint lists.
With Access Services in SP2010 I thought I'd just convert these reports and data sources over, but as ever its not that simple. You need to create a new Access Web database and then import tables into Web Compliant tables. It would appear that linked tables to sharepoint are not compatible. As ever with Microsoft so near and year so far from a complete solution....

Here is a very good article about converting your access databse "Converting Access Databases to Access Web Databases (25th May 2010)"

Sunday, May 23, 2010

How to remove the “title” column from a SharePoint list | EndUserSharePoint.com

With custom Sharepoint lists or those imported from Excel the default Title field (which is inherited from the content type Item) is always included. This link gives a neat trick to hide this field from the edit screen if you dont want it.
How to remove the “title” column from a SharePoint list EndUserSharePoint.com:

Friday, May 21, 2010

Configuring Business Data Connectivity Services


Setup BDC with its own user, database and App pool
Start the service
You should have a pages host to contain the external content type definitions so you need to Configure /add an External Content Type Profile Page Host.
Create a new site collection (I use the same web application as the metadata hub created earlier)
Use the Publishing Pages Portal Template
Once published goto Central Admin ->Manage service applications –> Choose the BDC /BCS Service -> Click manage from the toolbar->Configure->Type in the URL of the site collection you created above. ie http://metadata.company.com/sites/ExternalContentTypesFinally assign administrators of the BDC Metadata Store by clicking on the Set MetaData Store Permissions.

To create external connections see this article

Multiple Authentication Methods in SharePoint 2010

There are new and exiting authentication methods such as Claims-based authentication in SharePoint 2010 which leads Microsofts product line in being the first Server to offer it.  This article introduces them
while (alive) { writeCode(); } : Multiple Authentication Methods in SharePoint 2010:

Thursday, May 20, 2010

Setup Managed Meta Data Hub for the Sharepoint 2010 farm

My personal notes to: Setup a Managed Meta Data Hub for the SP2010 farm
Create a new web applicationCreate a new user for this (and make sure its in the Managed accounts list with the correct permissions)

Create a new web application & make sure the "Document Sets metadata synchronization" web app. feature is activated (you can find this by managing the web application and choosing "manage features" from the tool bar.
always use NTLM to start with to test work and can switch after
Create a new site collection with a template of "Publishing ->publishing Portal"

Create the service application

Create a new "Service Application" from Central Admin->Application Managment->Service Applications->Manage Service applications

Click on the new button on the toolbar and choose "Managed Metadata Service"

Enter the name, SQL server and DB name.

You can either use the IIS Web application pool you created when you setup the web application and site above or create a new one with yet another new user account which has been added to the managed users

For the Content Type Hub use the URL of the site collection you setup above and then click ok.
Note: this will not start the Managed Metadata service, and you may see errors in the event log saying that this service is not running on any of the servers in your farm. You need to start the serice seperatly.
You start the service by Central Admin->System Settings->Servers->Manage services on server

Click start next to Managed Metadata Web Service

-------------

To check it is working and to manage the content goto Central Admin->Application Management-> Service Applications->manage Service Applications

You will see two entries for the Service, the first is the actual service and the second indented line is a proxy stub.

Click on the first line and choose Manage from the toolbar. This will bring you up the Term Store Mangement Tool where you can manually input Terms or import them using a CSV


Note: you may find errors if you do this straight away as certain timer services need to run to fully impliment this service. Gernerally I would always do an IISReset as well (well it cant hurt!)

Article for next steps setting up content types

SharePoint 2010 Connection Filter Logic

For SharePoint 2007 our MOSS profile sync uses the an LDAP query that filters which OU Users we dont't require -

ie User filter: (&(objectClass=user)(!Status:=System)(!UserAccountControl:1.2.840.113556.1.4.803:=2))

This assumes we want everyone except those with and AD attribute of Status=System (the UserAccountConrol setting excludes accounts disabled)

For SharePoint 2010 once you have setup your Sychronization Connection to include one or more OUs from AD, you can then add exclusion rules by clicking to the right of the Syncronization Connection and choosing Edit Connection Filters from the menu.

I didn't read the screen properly and just applied the same filter logic as SharePoint 2007 but after 4 hours of pain not getting the results I wanted, so I read what it said on the screen.
It says "Exclusion Filter for Users" - as such YOU MUST REVERSE YOUR LOGIC from SP2007!!

Thus to achieve the same result above you need:
ie User filter: (Status:=System)(UserAccountControl:Bit On:=2))

I'll read the screen next time - duh!

The importance of SharePoint 2010 Managed Service Application install order


SharePoint 2010 is very unforgiving when it comes to the configuration of its Managed Service Applications. Not only do all the security settings need to be just so, but the order of install needs to be just right.
Because of this sensitivity, after installing the binaries and getting the administration site running I concentrated on getting the most tricky Service Apps running first, ie the User Profile and User Sync Service Application. However after a good install with few errors, on editing a user's profile some of the fields had really odd errors saying that "There was a problem retrieving data for this field"

There was nothing obvious; however it turns out that if you don't install the Managed Meta Data Service then you will have this problem. It doesn't matter if you install the MMD before are after the UPA but it just needs to be there.

The order I attempted to install Services after the binary and install of the administration site is as follows:

  • Register some pre-configured AD accounts into SharePoints' Managed Accounts (having setup the right AD permissions first). These will be used for the IIS Application Pools so you know what is running what. SharePoint very unhelpfully gives these GUIDS as names.
  • Create a New Web Application for the MySite Profiles with its own application pool and use one of the Managed Users we setup above

  • Create New Site collection in that Web Application – using a template of Enterprise –> My Site Host
    (Don't try to load site at this time)

  • Create a new User Profile Service Application with its own app pool
    • Start the UPA service – (very easy to miss this)
  • After service has started do an IIS Reset – or even reboot to make sure
  • Start the User Profile Sync service – prompts for details – wait 10 minutes until started
  • Reboot again – very important.
  • Add a Synchronization Connection to AD (You can add LDAP Filters to the connection after it is setup)
  • Start profile Synchronisation (full)
  • Once complete (and it will take a while…..) Manage User Profiles and you will see on some of the fields the errors I mentioned above.
  • Now install the Managed MetaData Service
  • IISReset or reboot again – and these field errors disappear!!

Glad it's so intuitive……..!
References :
Spencer Harbar's Rational Guide to implementing SharePoint Server 2010 User Profile Synchronization
SharePoint 2010 – Provisioning User Profile Synchronization

MSDN: Edit Profile Synchronization connection filters

http://blogs.msdn.com/brporter/archive/2010/02/20/excluding-disabled-user-accounts-in-sharepoint-2010.aspx
http://www.wictorwilen.se/Post/SharePoint-2010-user-profile-properties-temporarily-disabled.aspx

Tuesday, May 11, 2010

Sharepoint 2010 BCS connection getting started and authentication issues

There is a very good "get you started" article here, walking you through creating a SharePoint List to an external SQL table. Whilst all the steps were clear it did not deal with security and authentication to the SQL server.

Several methods are available to connect through to back end data providers, however "Connect with User's Identity" (or Pass Through) will only work with Kerberos enabled, and if it is not you will get a Login failed for user 'NT AUTHORITY\ANONYMOUS LOGON' error.

With SP2010 it is much better to use either the Impersonate Windows (or Custom) Identity - which makes use of the SharePoint 2010 Secure Store Service.

If however you dont want to use these or havnt set them up then you can use RevertToSelf which uses the BCS's application pool credentials.

Microsoft warn against this method as a potential security risk and if you try to select it as a connection property it will give you an error saying that revert has to be enabled for the application pool. (See this link)

This is done by setting RevertToSelfAllowed for the BCS model's authentication mode wont work without using powershell to set the Sharepoint Server setting for this to True.

$apps = Get-SPServiceApplication
$bcs = Get-SPServiceApplication where {$_ -match ""}

## If you’re doing this by hand, just type $apps and look #for the Business Data one, then index into it like $apps[i].#If you’re doing it for automation, filter by #$_.GetType.FullName (not $_.TypeName, which is localized).

$bcs.RevertToSelfAllowed = $true

Remember that if you do use this method then the BCS's application pool credentials must have the appropriate rights to the SQL Server Table.

References:
Authenticating to Your External System - BCS Team blog
BCS and External List Learning – Part1
BCS and External List Learning – Part2
Getting started with Business Connectivity Services (BCS) in SharePoint 2010