Registry access not allowed on the Project Server Box

Jul 4, 2007 at 8:52 PM
I have the following error in the event log, after a publication of assigments in PS07, marked with
- autosync true
- work item type : task

I have the error even if I don't have any association declared within the connector.
After I create an association I can browse the hierarchy of assigment on the connector web site,
but no assigment is associated with a workitem.

On the other direction, I have an error when I validate a work item created in VS:
- the association remains locked on the connector web site
- I have an error message in the event log.

All suggestion will be welcomed.



Event Type: Error
Event Source: Office SharePoint Server
Event Category: Project Server Server-Side Events
Event ID: 6663
Date: 04/07/2007
Time: 13:38:42
User: N/A
Computer: SNCF_PS07
Description:
Event Handler \Microsoft.Vsts.Ranger.Connector.PS2007EventHandlers.ProjectEventsReceiver\ threw an exception: Requested registry access is not allowed.
at System.ThrowHelper.ThrowSecurityException(ExceptionResource resource)
at Microsoft.Win32.RegistryKey.OpenSubKey(String name, Boolean writable)
at System.Diagnostics.EventLog.CreateEventSource(EventSourceCreationData sourceData)
at System.Diagnostics.EventLog.VerifyAndCreateSource(String sourceName, String currentMachineName)
at System.Diagnostics.EventLog.WriteEntry(String message, EventLogEntryType type, Int32 eventID, Int16 category, Byte[] rawData)
at System.Diagnostics.EventLog.WriteEntry(String source, String message, EventLogEntryType type, Int32 eventID, Int16 category, Byte[] rawData)
at System.Diagnostics.EventLog.WriteEntry(String source, String message, EventLogEntryType type, Int32 eventID)
at Microsoft.Vsts.Ranger.Connector.PS2007EventHandlers.ProjectEventsReceiver.OnCheckIn(PSContextInfo contextInfo, ProjectPostEventArgs e)

For more information, see Help and Support Center at http://go.microsoft.com/fwlink/events.asp.
Coordinator
Jul 5, 2007 at 12:17 PM
Garolion,
The account under which the Connector web service is running should have permission to write to the registry. Can you ensure that it is set up that way?

Thanks,
Lenny
Jul 6, 2007 at 1:11 PM
The problem is, it already have access : I installed the connector on the 3 boxes with the TfsService account, who is a domain administrators group member.
This TfsService account is also the account under which the connector is running on each box.

To go further I granted full control permission to tfsservice and network service on each root node of the registry on the Project Server box without any success.

So I have a question : why the connector does it try to write in the registry. Is it beacause it try to create an eventlog through the registry because of a previous hidden error, that I should correct before.

Thanks for your help!
Coordinator
Jul 6, 2007 at 5:23 PM
Yes, it creates an event log source on the Project Server machine. However, it does this upon installation not while it is running and it does not do this for the Connector or the TFS box. Other te Connector box, it just leverages the Enterprise Library 3.1 Exception Handling and Logging application blocks to log information tot he event log. We didnt want to make it a requirement to have the EL assemblies present ont he PS2007 box which is why it just writes to the Event Log without using EL.

Does this help at all?

Lenny
Jul 8, 2007 at 7:35 PM
OK, I don't see any new eventlog entry on the eventlog console, it seems to be a first problem if you say it would be created during the installation. More generally is there a checklist for the project server box, to check if the installation has really successfulled despite the end conclusion of the wizard. I don't have any other issue in my eventlogs than the current one.

When I investigated, I smw through the Hierarchy of assigment in Connector Web Site, that there were a problem of synchronisation. Is it the problem at the origin of the attemp of writing in the event log that fall into error?

With a short example of 2 task, the second beeing the uccessor of the first one, I see 2 bugs in my environment (full english installation on servers TFS-AD/Connector-PS and mix english-french on the client OS-english / Project pro in french):
- Date are note take into account by the connector, however there are well interpreted in the project server web site.
- Predecessor and suceessor assigment Id mismatched (eg, successor id of my first assigment is not the id of the second assigment).

SNCF1
Associated Project: SNCF1
Task: Initialisation
Task: Réunion de lancement
Assignment: f2e89694-73c1-45cf-9b8f-d5c853a0b003
Actual Work: 0
Remaining Work: 0
Work: 0
Start Date: 01/01/0001 00:00:00
Finish Date: 01/01/0001 00:00:00
Successor: 6a619da3-6a5d-44da-88ed-f4fca2d2e364

Task: Mise en place des serveurs
Assignment: 4e6c68ce-23c4-4d8e-ae2a-69c86cb2dd14
Actual Work: 0
Remaining Work: 0
Work: 0
Start Date: 01/01/0001 00:00:00
Finish Date: 01/01/0001 00:00:00
Predecessor: b1700e41-75cd-4517-8507-5ac9d7f18dbf

Coordinator
Jul 9, 2007 at 11:57 AM
Garolion,
It is a little diificult for me to comment on either of these without more information. Do you know how to get the ProjectDataSet for the project you showwed above? Can you send the XML output for that dataset?

Re: installation of Project Server, here's what you should see when it has completed successfully:
  • A new Event Log Source for the Project Server Connector
  • new LookupTables in PS2007 for Enteprise WorkItemType and RequirementType
  • some more Custom Fields in PS2007 for "AutoSync to External System", "Enterprise WorkItem Type", "Requirement Type", "Bug Description", "Steps to Reproduce"
  • five new EventHandlers; three for Project and two for Statusing. Project are OnPublished, OnDeleted, OnCheckedIn. Statusing are OnApplied and OnStatusApprovalUpdated.

HTH,
Lenny
Jul 10, 2007 at 5:19 PM
Hi Lenny,

I Have some news.

I solved my problem with a re-installation of project server in a normal mode (eg. not in the basic mode with SQL Express). I think my problem occurred because of the Network Service account under which the Shared Services Web App (handling PS Web Services) is started. This account is automatically set during the automatic configuration. So when do the configuration manually and set the tfsservice account all semms to be better, for the PS EventHandlers. I now have my two entries "Project Saved" "Project Checked-in" in the event log.

I checked all the points mentionned in your previous post, and the connector seems to be well installed. But I still have a problem!

- First. With a french installation of Project Pro, after a project check-in I saw the two "Project Saved" "Project Checked-in" entries in my event log, but nothing fall down in TFS, despite a project association, autosync:true and a valid workitem type on my tasks.

-Second with an english version of Project Pro, if I follow your process in the user guide :
1. Creation of a Project in PS
2. Creation of Task
3. Creation of a Project in TFS
4. Management of Project Properties and resources in PS
5. Modification of tasks (Resource, AutoSync, WorkItem type)
6. Binding PS Project - TFS Project
All the assigments are synchronized for the first time. I saw that :
- when I do an update on the synchronized assigments or create new one, no synchronisation is done, everythink remains in state in the connector DB (the old association remain in bd, and the new ones are not created), but the association form in the Connector Web Site becomes empty. I didn't see anything in event logs neither on the PS box, nor on the Connector one.
- when I delete the project association, delete every record (project and assigment-wi association) in the connector database, and recreate the same one, my old assigments are synchronised (eg. updates are ignored and new assigment since the first successfull synchronisation are ignored too). Is there a cache or a parameter in the connector to set?
-when I try to create another project association, no assigment are synchronized, whitout any error message in event logs.

- I still have my problem on the Hierarchy panel, but it is a secondary problem compared to the previous points, because the synchronized assigments have there right remaining work data, description... (on the first synchronisation). I didn't success in retrieving the ProjectDataSet. I tried to call the project webservice through the GetProject method in a small project but IIS throw an unauthorized HTTP exception. So if you have a piece of code I could send you the dataset to go further on that point.

Regards,
Arnaud
Coordinator
Jul 10, 2007 at 6:05 PM
Arnaud,

Sounds like there are a few things. Did you publish the project after you made the changes in project? The changes get pushed from project when the project is published; i.e,. this is the event that triggers the synchronization. The saem goes with deleting a project in PS2007.

What kind of authroization issue are you getting when trying to access the web service? You should definitely resolve this in order to get the Connector functioning properly.

HTH,
Lenny
Jul 10, 2007 at 6:51 PM
Lenny,

Yes I published my project within project pro, is it what you mean?

I got a http 401.1 Unauthorized: Access is denied ... so I first tought about a basic IIS configuration problem and executed the cscript adsutil.vbs set w3svc/NTAuthenticationProviders "NTLM" but the exception remain.

Arnaud
Jul 10, 2007 at 11:42 PM
Lenny,

I re-install allmy environnement on clean boxes, and I have the same issue, with a little variation : I have a http 401 unautorized exception each time published and check-in event are fired and your eventhandlers are called. Nevertheless Work Item are created on the first synchronisation like my previous post.

I checked my Project Server environment as you suggested in a previous discussion : http://www.codeplex.com/pstfsconnector/Thread/View.aspx?ThreadId=11565
and all is OK.

my tfsservice is used to run the connector (has been used to install the connector), to run every sharepoint service, sharepoint web app...
So I don't know what to do more.

I have following entries in my event log:

Event Type: Warning
Event Source: PS2007 Connector
Event Category: None
Event ID: 3651
Date: 11/07/2007
Time: 01:29:20
User: N/A
Computer: XYZ_PS07
Description:
User: XYZ\tfsservice
Project name: Test1
was published.

----------

Event Type: Error
Event Source: Office SharePoint Server
Event Category: Project Server Server-Side Events
Event ID: 6663
Date: 11/07/2007
Time: 01:29:20
User: N/A
Computer: XYZ_PS07
Description:
Event Handler \Microsoft.Vsts.Ranger.Connector.PS2007EventHandlers.ProjectEventsReceiver\ threw an exception: The request failed with HTTP status 401: Unauthorized.
at System.Web.Services.Protocols.SoapHttpClientProtocol.ReadResponse(SoapClientMessage message, WebResponse response, Stream responseStream, Boolean asyncCall)
at System.Web.Services.Protocols.SoapHttpClientProtocol.Invoke(String methodName, Object[] parameters)
at PS2007EventReceivers.AutoSynchronizeEnterpriseProject(Guid projectGuid)
at Microsoft.Vsts.Ranger.Connector.PS2007EventHandlers.ProjectEventsReceiver.OnPublished(PSContextInfo contextInfo, ProjectPostPublishEventArgs e)

----------

Event Type: Warning
Event Source: PS2007 Connector
Event Category: None
Event ID: 3651
Date: 11/07/2007
Time: 01:29:23
User: N/A
Computer: XYZ_PS07
Description:
User: XYZ\tfsservice
Project name: Test1
was checked in.

----------

Event Type: Error
Event Source: Office SharePoint Server
Event Category: Project Server Server-Side Events
Event ID: 6663
Date: 11/07/2007
Time: 01:29:23
User: N/A
Computer: XYZ_PS07
Description:
Event Handler \Microsoft.Vsts.Ranger.Connector.PS2007EventHandlers.ProjectEventsReceiver\ threw an exception: The request failed with HTTP status 401: Unauthorized.
at System.Web.Services.Protocols.SoapHttpClientProtocol.ReadResponse(SoapClientMessage message, WebResponse response, Stream responseStream, Boolean asyncCall)
at System.Web.Services.Protocols.SoapHttpClientProtocol.Invoke(String methodName, Object[] parameters)
at PS2007EventReceivers.ReleasePendingProjectUpdate(Guid projectGuid)
at Microsoft.Vsts.Ranger.Connector.PS2007EventHandlers.ProjectEventsReceiver.OnCheckIn(PSContextInfo contextInfo, ProjectPostEventArgs e)

Any suggestion will be welcome
Arnaud
Jul 17, 2007 at 4:41 PM
Hi Lenny,

I successfully read the ProjectDataSet. My error was to read it through the http://servername:56737/sharedservices1/psi/project.asmx whereas the http://servername/PWA/vtibin/psi/project.asmx

So now, if the EventHandler still throw an unathorized access exception, when I publish my project and if my project hierarchy still have unvaluabled assigments, I am able to send you the project dataset to understand the mistake (assigment are valuabled in it).

Do you have a email, to send you the dataset, because of its size.

Arnaud
Coordinator
Jul 19, 2007 at 12:28 PM
Garolion,
Sure. I'll take offlien with you.

Lenny
Jul 26, 2007 at 5:10 PM
Edited Jul 26, 2007 at 5:10 PM
I had a similar problem as the original poster. The application log of my Project server was showing 6663 errors every time a Project was saved and published. Here is an example of the error:

_Event Type: Error
Event Source: Office SharePoint Server
Event Category: Project Server Server-Side Events
Event ID: 6663
Date: 7/26/2007
Time: 12:44:39 PM
User: N/A
Computer: PS2007
Description:
Event Handler \Microsoft.Vsts.Ranger.Connector.PS2007EventHandlers.ProjectEventsReceiver\ threw an exception: Requested registry access is not allowed.
at System.ThrowHelper.ThrowSecurityException(ExceptionResource resource)
at Microsoft.Win32.RegistryKey.OpenSubKey(String name, Boolean writable)
at System.Diagnostics.EventLog.CreateEventSource(EventSourceCreationData sourceData)
at System.Diagnostics.EventLog.VerifyAndCreateSource(String sourceName, String currentMachineName)
at System.Diagnostics.EventLog.WriteEntry(String message, EventLogEntryType type, Int32 eventID, Int16 category, Byte[] rawData)
at System.Diagnostics.EventLog.WriteEntry(String source, String message, EventLogEntryType type, Int32 eventID, Int16 category, Byte[] rawData)
at System.Diagnostics.EventLog.WriteEntry(String source, String message, EventLogEntryType type, Int32 eventID)
at Microsoft.Vsts.Ranger.Connector.PS2007EventHandlers.ProjectEventsReceiver.OnPublished(PSContextInfo contextInfo, ProjectPostPublishEventArgs e)

For more information, see Help and Support Center at http://go.microsoft.com/fwlink/events.asp._


I fixed the error by changing the user that runs the SSP Service to be TFSService (same account that the connector is running). Now I don't get the error, but I get warnings that the project was Checked in and that it was published.

Is it normal for those messages to be showing as Warnings and not information messages?
Coordinator
Jul 26, 2007 at 6:30 PM
Yeah, its normal for it to show as warnings. Guess I should probably fix that :-)

Thanks,
Lenny