Operation Manager (SCOM) install SQL error - sql-server

The story:
Virtual environment SQL, SCOM, SCCM each on his VM, everything is working.
SCOM server gets deleted (the entire VM is gone).
In order to reinstall I delete old SQL databases and files (scom & scomDW).
Recreate a VM, install OS (2012R2), prerequisites, recreate accounts (action account, data access account, write account, read account).
Action account and data access account are local admins on the installation server.
Firewall rules ware verified.
Collation is correct.
The problematic update isn't installed.
The client is not installed on SQL server.
the setup is runed under a domain admin & SQL sysadmin.
The problem
When installing "management server" Management server returns a warning then passes to Data warehouse configuration just to fail.
First error from the log says : Error: :DB operations failed with SQL error 2812: Could not find stored procedure 'p_MOMManagementGroupInfoSelect'.
Last error says that it's unable to connect to management server.
Any idea is useful so THX!

The problem was fixed by checking the "security admin" tag in SQL for the account that was making the install.
I must mention that the account was already sa and dbcreator.

Related

SQL Server Agent doesn't turn on after upgrading from SQL EXPRESS to SQL Standard

I upgrade the SQL 2014 Express to a Standard edition without changing the instance name. There was a success and it seems to be working fine, except the SQL AGENT.
Error message from configuration manager:
The request failed or the service did not respond in a timely fashion.
Consult the event log or other applicable error logs details.
Trying with the server administrator user. Built in account/Local service also don't work.
Event log doesn't show anything except that it's turned on and then off.
This is what I see in DETAILS. doesn't tell me anything:
Provider
[ Name] SQLAgent$SQLEXPRESS
EventID 102
[ Qualifiers] 16384
Level 4
Task 2
Keywords 0x80000000000000
Trying to run it from CMD with admin rights:
StartServiceCtrlDispatcher failed (error 0).
Read somewhere to try to turn off VIA protocol. I don't have any protocol called VIA.
Any ideas?
Thanks
Just after I posted I checked the security and found out that the BUILTIN\USERS didn't have sysadmin permission..
After adding it, it was resolved!
I had a similar issue when I upgraded the SQL Server 2017 from Express to Standard. The SQL Server Agent would not start even after the upgrade.
I an error message in the SQLAgent Log
(C:\Program Files\Microsoft SQL Server\MSSQL14.SQL2017EXPRESS\MSSQL\Log)
2017-12-18 16:21:06 - ! [298] SQLServer Error: 229, The EXECUTE permission was denied on the object 'sp_sqlagent_update_agent_xps', database 'msdb', schema 'dbo'. [SQLSTATE 42000] (DisableAgentXPs)
Changing the SQL agent service Log On account to "Local System" does not work (as you described).
Ultimately what worked for me is changed the Log On account to "NT Service\MSSQL$SQL2017EXPRESS" works.
This user was created when I named the SQL Server "SQL2017EXPRESS" during installation. If you open up SSMS, connect to your database instance, and open up Security->Logins, you should able find a list of database NT Service users that have access the system database (msdb). Try using one of those users as your Log On user for the SQL Agent Service.
I think you install Standard edition, it would create a user call NT Service\MSSQLAgent$2014.
During research, I tried in the instruction in this article. It appears using Sql Server Configuration Manager to change the Log On user didn't work for me. Instead, changing the Log On user from Administrator->View Local Services works.
I know this is late, but I hope it helps someone in the future; a fix that has worked for me after an upgrade from Express to Standard was to run the Repair option (see image) from the Maintenance node of the SQL Server Installation Center. Once the repair completes & restart finishes, Agent works as expected.
Use Repair option from the Maintenance page of the SQL Server Installation Center
I had this same issue with SQL 2019 after upgrading from express to standard. Doing the Repair from the installation maintenance section fixed the agent for me.

How to recreate SQL Server MSSQLServer windows user for a SQL Server 2014 SP1 installation

I had a new machine which windows crashed and I had to do a Windows reset which reinstalled Windows. Afterwards I deleted the old app user accounts in the C:\Users folder since the reinstall didn't delete it, these included SQL Server MSSQLServer and .net accounts because I was going to install all the apps from scratch I decided to clear it up and delete it.
I then ran SQL Server 2014 SP1 setup selecting database engine, client connectivity and Management Studio on default instance MSSQLServer
using mixed mode authentication and added my own sa password and my current windows user.
At the end of my installation I notice the installer takes a very long time at the following step
SqlEngineDBStartConfigAction_install_configrc_Cpu64
I then get an error
The following error occurred:
Could not find the Database Engine startup handle.
Logs
Feature: Database Engine Services
Status: Failed: see logs for details
Reason for failure: An error occurred during the setup process of the feature.
Next Step: Use the following information to resolve the error, uninstall this feature, and then run the setup process again.
Component name: SQL Server Database Engine Services Instance Features
Component error code: 0x851A0019
Error description: Could not find the Database Engine startup handle.
Error help link: http://go.microsoft.com/fwlink?LinkId=20476&ProdName=Microsoft+SQL+Server&EvtSrc=setup.rll&EvtID=50000&ProdVer=12.0.4100.1&EvtType=0xD15B4EB2%400x4BDAF9BA%401306%4025&EvtType=0xD15B4EB2%400x4BDAF9BA%401306%4025
I open SQL Server configuration manager Services and noticed my MSSQLServer doesn't start up because it runs as NT Service\MSSQLSERVER user. I change that to local system account and start the service and the service runs.
However when I open SQL Server Management Studio and try to connect to the database engine I can't connect with neither my windows user I added during the SQL Server setup nor the sa user with password I specified.
Cannot connect to PCName. Login failed for user PCName\User. Microsoft SQL Server Error 18456
When I uninstall SQL Server and reinstall it I get the same issue. Even when I delete the program files directory C:\Program Files\Microsoft SQL Server\MSSQL12.MSSQLSERVER
How do I get it to work?
Why does a new SQL Server 2014 SP1 installation not create the MSSQLServer user?
How to I create the MSSQLServer user manually and what permissions and groups do I assign to it?
I tried everything to resolve it. Delete all the SQL Server folders. Remove registry entries as mentioned in other stackoverlow answers. Installed SQL Server 2014 SP1 again and the problem still occurs.
Even when I installed SQL Server 2012 SP1 on the default instance I would still get the error.
The only workaround I could get it to work was to install SQL Server as a separate instance and not the default instance.
This made me thinking if the issue is only related to the default instance.
I looked at my C:\Users folder and the default instance MSSQL user folder was not there meaning the installer never created it. The problem must have occurred that I previously deleted the User folder to clean up the machine where I should have deleted the windows users from Control Panel Admin Tools instead.
Solution: Use regedit.exe
The problem entry should be the corresponding S Folder in.
HKEY_LOCAL_MACHINE - SOFTWARE - Microsoft -Windows NT -CurrentVersion -ProfileList
Delete this user
Reinstall and verify in the C:\Users if the MSSQL user gets created.
I tried to be safe and deleted all references to the MSSQL user in the registry user after uninstalling all SQL Server references in Add/Remove Programs and clearing up the Program Files folders the one registry item is probably the cause.
This solution helped me to fix the issue.
I had deleted MSSQLServer and SQLAgent account while cleanup of SQLServer2016, but then MSSQLServer 2016 installer wasn't getting re-installed, reason being it could not create the service account, and my application is limited to support "only default SQL instance"
I have followed this and deleted the REG entries and this helped me to reinstall SQL Server smoothly.
Thank you so much .
Solution: Use regedit.exe
The problem entry should be the corresponding S Folder in.
HKEY_LOCAL_MACHINE - SOFTWARE - Microsoft -Windows NT -CurrentVersion -ProfileList

Error authenticating proxy while running agent job

I am trying to schedule a SSIS2014 package via SQL Server Agent job. Both SSIS and SSMS are running on my local machine in the same domain. I am running SSMS with the same user Domain\Admin which is the creator of the SSIS package. SSMS 32-Bit and SSIS 32-Bit are running on Windows 7 64-Bit machine. I can run the package within SSIS without problems.
Using Microsofts KB article http://support.microsoft.com/kb/918760 and tutorial video http://technet.microsoft.com/en-us/library/dd440760%28v=sql.100%29.aspx I tried a couple of methods (proxy, configuration file, EncryptSensitiveWithPassword) but none of them worked for me.
When I use a proxy account to run the job step, the following message occurs:
Unable to start execution of step 1 (reason: Error authenticating proxy
`Domain\Admin`, system error: Logon failure: unknown user name or bad password.).
The step failed.
The proxy account uses the credentials identity Domain\Admin. Since the password fields for credential properties in SSMS cannot be left blank, I typed any password although my corresponding windows account has no password. So as mentioned above it's the same user account that created the SSIS package since Domain\Admin is stated in the CreatorName property of the SSIS package.
With this proxy, I tried to run SSIS jobs using the package ProtectionLevel's EncryptSensitiveWithUserKey and EncryptSensitiveWithPassword. Running the package manually within SSDT without problems, but from SSMS agent job the same error message appears. I tried the package sources "File System" and, after importing the package to MSDB, "SQL Server" and "SSIS Package Store". But exactly the same error message appears with each method.
Task manager shows that SSMS is running in administrator mode. Using Windows Component Services I added DCOM permissions for Domain\Admin to start and activate "Microsoft SQL Server Integration Services 12.0" from local. But the same error message appears. So in my opinion it's a problem with SSMS user account permissions (???) but unfortunately I don't know what exactly to do here. I tried the following:
In the system database MSDB (full path: Databases / System Databases / MSDB / Security / Logins) I assigned all available role memberships (Including db_ssisoperator, db_ssisltduser, db_ssisadmin) to Domain\Admin.
In server security (full path: Security / Logins) I assigned all available server roles. In the tab User Mapping, I assigned the MSDB database.
Still the same error message appears when I try to run the job. Does anybody have some ideas what I can try?

Elevated Rights Error when trying to deploy SSIS packages to a remote server

this is a new staging server with SQL 2008. I'm not famliary with SSIS that much so trying to deploy a couple packages. So I do the following in BIDS..which is probably typical:
Right-click my solution, go to properties, then go to the deployment utility tab
Change CreateDeploymentUtility to true
Go and find the .SSISDeploymentManifest file locally on my machine
Run it and try to perform a SQL Server deployment to the customer's remote server (we're running vpn to get to it)
I put in the fully qualified remote server's name, my windows auth or SQL account (I tried both ways)
Try to click now the Package Path and get this:
TITLE: Package Installation Wizard
An OLE DB error 0x80040E09 (The EXECUTE permission was denied on the object 'sp_ssis_listpackages', database 'msdb', schema 'dbo'.) occurred while enumerating packages. A SQL statement was issued and failed.
ADDITIONAL INFORMATION:
An OLE DB error 0x80040E09 (The EXECUTE permission was denied on the object 'sp_ssis_listpackages', database 'msdb', schema 'dbo'.) occurred while enumerating packages. A SQL statement was issued and failed.
BUTTONS:
OK
So what do I do? How do I essentially run this as an administrator to get past this stupid elevated rights security error?
You should add your windows / sql account to sysadmin role.
In SQL Server Management Studio, go to Security -> Server Roles and double click sysadmin. Add your login and it should work when you try again.

SSRS - Unable to determine if the owner of job has server access [SQLSTATE 42000] (Error 15404))

SQL Server Reporting Services, in SSRS it seems like Schedules never fire, however a look at the SQL Agent reveals a permission issue related to not being able to resolve a user account.
Seems SQL Agent does not rely on caching or whatever voodoo Windows magically works.
link text
Fix is listed here...
edit --
Above is the fix I used to workaround this issue, has any one found any other work arounds or resolutions to this issue?
It seems that by default the SSRS Generated Schedules are run as this phantom user account. How do I change this default? Is SSRS creating the jobs as the user the service runs as?
Thanks Remus
I was running into the same issue. Here is how I fixed it.
Problem description
When setting an SSRS report subscription to run at a given time, I would wait for the time to pass and then find that the "Last Run" timestamp did not change. My subscription appears not to have run.
Relevant troubleshooting info
SSRS report subscriptions are executed as SQL Jobs that the Report Server web UI creates for you behind the scenes.
When looking at the job that was created for my report subscription, I saw that it always failed with the error:
The job failed. Unable to determine if the owner (domain\userName) of job 0814588B-D590-4C45-A304-6086D5C1F559 has server access (reason: Could not obtain information about Windows NT group/user 'domain\userName', error code 0x5. [SQLSTATE 42000] (Error 15404)).
In the Sql Server Configuration Manager I could see that the "SQL Server Reporting Services" service was configured to run using an AD user account.
In the Sql Server Configuration Manager I could see that the "SQL Server" service was configured to run using a local Windows account.
As #Remus Resanu pointed out, the SQL error 15404 refers to an exception when EXECUTE AS context cannot be impersonated.
Solution
Bingo! #4 and #5 are the key to the problem. The SQL Server service (a local Windows user account) was trying to authenticate the user "domain\userName" in AD, which it could not do because it does not have the right/permission to access AD resources.
I changed the SQL Server service to us an AD user account, restarted the SQL Server and SQL Server Agent services, re-ran the SQL job and, blamo, success!
15404 is the exception when EXECUTE AS context cannot be impersonated. Reasons for these error are plenty. The most common reasons are:
when the SQL Server instance does not have access to the AD server because is running as a local user or as 'local service' (this would have an error code 0x5, ACCESS_DENIED)
when the SQL Server is asked to impersonate an unknown user, like an user from a domain the SQL Server has not idea about (this would have the error code 0x54b, ERROR_NO_SUCH_DOMAIN)
The proper solution is always dependent on the error code, which is the OS error when trying to obtain the impersonated user identity token: one searches first for the error code in the System Error Codes table (or fires up windbg, does a loopback non-invasive kernel debug connection and goes !error, which is what I prefer cause is faster...).
So, John... do you actually have a question, or just posted a random piece of partial information?
I did 2 things and it's now working.
1) Go to "SQL Server Configuration", change the "SQL Server Agent" - "Log On As" to match the "SQL Server" above.
2) Secondly, open "Microsoft SQL Management Studio", at the "SQL Server Agent", expand the "Jobs" and you should be able to see your created job. Right click on it and go to "Properties".
3) Change the owner to also match the "SQL Server Agent" above.
After, I'm able to execute the Maintenance Plan without any issue.
Just follow this steps in images

Resources