Link to home
Start Free TrialLog in
Avatar of clivingIOS
clivingIOS

asked on

Microsoft CRM 4.0

We have a CRM database we use for sale staff, I inhertied it as part of a network when we took over.

yesterday the domain controlled crashed so to get everyone up and running we setup a new DC, new domain and joined everyone too it.

Now when we go to the CRm website http://SERVERNAME:5555 we get user not recognised, but ofcourse the users are now NEWDOMAIN\username instead of OLDDOMAIN\username

I have regained access to the SQL database but cannot get into the CRM deployment manager as it says "only the deployment administrators are able to use the deployment manager"

Is there anyway I can make the CRM available to anyone on the network or alternatively how I can add the new users through SQL?
Avatar of clivingIOS
clivingIOS

ASKER

I canow get into the deployment administrator as I followed the guide to add another using this: https://thecrmgrid.wordpress.com/2010/06/04/you-are-not-a-deployment-administrator/ 

Now i just need to rather create some new users or somehow get in through the database and change their usernames from OLDDOMAIN\username to NEWDOMAIN\username
ASKER CERTIFIED SOLUTION
Avatar of Feridun Kadir
Feridun Kadir
Flag of United Kingdom of Great Britain and Northern Ireland image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
I have also managed to find the user through the database using the following:

select FullName, * from SystemUserBase where SystemUserId = '05BF47FE-9D8C-DE11-9406-001CC4395D5F'

That is his SystemUserID, I can see his username says OLDDOMAIN\username - just need to know the command to change that now I guess?
I am thinking If I can alter his username to the correct one I can login into CRM and change everyones, or evern change them all through the database if needed?

As long as they can see the records once logged in i'm not to bothered as we are moving away from crm shortly anyway.
I advise you against making changes to the database. Yes although you will see references in various places, IMHO your deployment is broken and should be reinstalled as per earlier post.
I see.

Well you can try updating one record and see what happens.

In SQL Deployment Manager, connect to your CRM database and run the following SQL:

update systemuserbase
set DomainName='newdomain\loginname',
set ActiveDirectoryGuid='new AD GUID'
where SystemUserId = '05BF47FE-9D8C-DE11-9406-001CC4395D5F'

You'll need to get the Active Directory guid for the user from Active Directory Users and Computers or some other tool.
That didn't work, I updated the user and it still didn't let me in, I am reinstalling CRM now - Is everything stored in the database or is there some other folders I need to restore? Will it reconfigure IIS itself?

Regards

J
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Ok so i reinstalled crm and removed the database, I had it create a new IIS website since the other disappeared during the reinstallation - now when i go to http://server/crm it shows my the favicon for crm but nothing shows.

I imported the database as you said, I think now the problem may lie with IIS?

Is everything actually stored in the database, the layout of our crm etc? how do it know what to show us on the front end, I have full server backups so can restore the iis program files or even restore websites if they need restoring and link them back in iis
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
so I have got a CRM in place at the moment so everything is up and working with an empty CRM, i can access it by going to http://crmserver:5555 which redirects me to http://crmserver:5555/TestCRM/loader.aspx

I went in deployment manager and selected import organisation - selected the database i restored ourcrm_MSCRM - manually selected the users (since some of the ones in their don't exist anymore)

It pops up in the list of organisation saying pending then after a few minutes disapeers
In the event log I got error code 19726 saying "import Organisation" failed to complete
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
The last CRM was version number 4.0.7333.3822 which seems to be version 21, I have updated it to that version now and still failing to import with the same error although i dont get a "warning" about the version number anymore.

Thanks for your help this far.
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
here is the part of the latest log fiel where it failed, since i t was after a restart anyway I shouldn't need to do another one I assume - although I can if you think it would help?

11:53:01|  Error| Import Organization (Name=ERMLTD, Id=9b22e988-6d14-e711-99db-90b11c101ded) failed with Exception:
System.InvalidOperationException: ExecuteNonQuery requires an open and available Connection. The connection's current state is closed.
   at System.Data.SqlClient.SqlConnection.GetOpenConnection(String method)
   at System.Data.SqlClient.SqlConnection.ValidateConnectionForExecute(String method, SqlCommand command)
   at System.Data.SqlClient.SqlCommand.ValidateCommand(String method, Boolean async)
   at System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(DbAsyncResult result, String methodName, Boolean sendToPipe)
   at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
   at Microsoft.Crm.CrmDbConnection.InternalExecuteNonQuery(IDbCommand command)
   at Microsoft.Crm.CrmDbConnection.ExecuteNonQuery(IDbCommand command, Boolean impersonate)
   at Microsoft.Crm.CrmDbConnection.SetTransactionIsolationLevel(IsolationLevel il)
   at Microsoft.Crm.CrmDbConnection.Dispose(Boolean disposing)
   at Microsoft.Crm.SqlExecutionContext.Dispose(Boolean disposing)
   at Microsoft.Crm.SqlExecutionContext.Dispose()
   at Microsoft.Crm.Tools.Admin.ImportOrganizationInstaller.Import(Guid organizationId, String organizationUniqueName, String organizationFriendlyName, String sqlServerName, String databaseName, Uri reportServerUrl, String privilegedUserGroupName, String sqlAccessGroupName, String userGroupName, String reportingGroupName, String privilegedReportingGroupName, ICollection`1 users, MultipleTenancy multipleTenancy)
11:53:01|Warning| Attempting to cancel a long running process: ProgressWizard. This might leave the data in an invalid state and the application might not function correctly.
11:53:05|Warning| Attempting to cancel a long running process: FinishWizard. This might leave the data in an invalid state and the application might not function correctly.
11:54:15|   Info| Deployment Manager Exit
Interesting. Is your database especially large?
15GB - the log file is 65GB
OK I have added those changes and the server is restarting now, hopefully in about 5 minutes I'll be giving some good news!
Hmm, not particularly huge but not small either. It also depends on the hardware spec of the SQL server.  The log file size shouldn't matter but it does sound as if it needs backing up to reduce its size.
It took a lot longer than 5 minutes but I can now access our CRM on the server - but not the local machines, is their usually something else needed?
Excellent,  You probably need to allowing incoming connections on port 5555 in Windows firewall (if enabled). If this isn't the issue let me know what users see when they to connect to CRM.
OK the port allowed people to see it, I ended up doing a full backup restore from last week as some of the data was messed up, all working fantastic now - thankyou very much for your help!
Excellent solution and walkthrough
Great, glad you got there.
I have a further issue with this and was wondering if you can help, the CRM after 30 days has just shut down and is telling us it needs registering, however the registration wizard says it cannot connect to the internet.

We have no proxies and the server has full internet access so my guess in the online registration has been shut down by MS and I cant find any phone numbers for them either since the help links it tells you to use dont work either.

I found a command to run on the database which marks it as registered below - but it comes up with the error below - any ideas?

Thanks in advance?

Command:
USE MSCRM_CONFIG
UPDATE ConfigSettings SET IsRegistered = TRUE

Error:
Msg 207, Level 16, State 1, Line 2
Invalid column name 'TRUE'.

from:
https://community.dynamics.com/crm/f/117/t/159517
I think you need single quote marks around the word true

set isregistered = 'true'
Scratch that - I went into the "edit top 200 rows" of dbo.ConfigSettings and changed it to TRUE and it is now working.
I tried it with and without quotation marks also, got the same error - thanks for taking the time to respond, I posted my fix in the last message.
Great that you got there.