SQL Server 2005 Workgroup - Performance counter shared memory setup failed
I'm running SQL Server 2005 Workgroup Edition on Windows 2000 Pro for testing purposes at my work. Every time I’m starting the server I'm keep getting these 2 errors in Event Viewer
Performance counter shared memory setup failed with error -1. Reinstall sqlctr.ini for this instance, and ensure that the instance login account has correct registry permissions.
Error in mapping SQL Server performance object/counter indexes to object/counter names. SQL Server performance counters are disabled.
Using unlodctr mssqlserver and lodctr sqlctr.ini doesn't help and registry permissions seems to be OK.
Suggestions are welcome.
Thank you.
Answers
This is usually an indication that your PerfLib titles database is corrupted (the second registry key bellow). In this particular case it seems that the SQL Server "First Counter" can not be found in the titles database.
HKLM\SYSTEM\CurrentControlSet\Services\MSSQLSERVER\Performance\First Counter
HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Perflib\009\Counter
Reinstalling SQL Server counters using unlodctr/lodctr may fix the problem but there is no guarantee for success. The following article describes how to manually rebuild your performance counter library values:
All Replies
This is usually an indication that your PerfLib titles database is corrupted (the second registry key bellow). In this particular case it seems that the SQL Server "First Counter" can not be found in the titles database.
HKLM\SYSTEM\CurrentControlSet\Services\MSSQLSERVER\Performance\First Counter
HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Perflib\009\Counter
Reinstalling SQL Server counters using unlodctr/lodctr may fix the problem but there is no guarantee for success. The following article describes how to manually rebuild your performance counter library values:I have the same issue as errpop although i am running SQL 2005 std 1 CPU SP1 on Win 2000 server SP4 (both fully patched clean installs). The errors i am getting in the sql server logs are below and occur immediately after the sql server service starts and the number of cpu's are detected and written to the sql logs.
Error: 8313, Severity: 16, State: 1.
Error in mapping SQL Server performance object/counter indexes to object/counter names. SQL Server performance counters are disabled.
Error: 3409, Severity: 16, State: 1.
Performance counter shared memory setup failed with error -1. Reinstall sqlctr.ini for this instance, and ensure that the instance login account has correct registry permissions.
I have followed the instructions in KB300956 and nothing changed. I noticed executing lodctr sqlctr.ini runs but i dont get any messages on screen. It is like it is not working. The reason i am so interested in the performance counters is i am trying to troubleshoot a local HP SureStore DLT1 tape drive (14 hours to backup 70GB) and i need the SQL backup device counter. I dont know if this is related or not?
Any help is greatly appreciated as this is entirely new territory to me.
- I don't have an answer on this, but just to say that I am experiencing the same very frustrating issue and solution help from Microsoft on this. SQL Server 2005 SP1 on Windows 2000 server sp4. Like everyone I have tried all articles and suggestions pointed in this thread but to no avail. Can anyone at Microsoft please address this? I can't go to production because of this an other failures that may be related. I am experiencing this is issue on a Developers Edition.
hi, i have hit the same issue after os hardening and manage to resolve the issue by granting the sql server service account with read permission to registry key hklm\software\microsoft\windows nt\currentversion\perflib.
You may also grant the permission to the local sql security group that contains the domain sql server service account.
Cheers!
Vincent Peh
Had a similar situation and found the Remote Registry Service must be running while SQL Server is loading.
turning on the remote registry service seems to have fixed it for me.
This is a typical error when you change the service account of sqlserver to a new account.
The following rights need to be added (manualy) to the new account via Local security Policy:
Log on as Service
Log on as a batch job
Locks pages in memory
Act as part of the operating system
Bypass traverse checking
Replace a process level token
note1: being local administrator on the machiene is not enough
note2: for a non local administrator you also need access to read the registry and read-write access on all sql server files
note3: if you fill in the correct sql service account in the installation procedure, all this is done automatically.
- Try to stop the VIA in NETWORK SETTING using SQL Server Configuration Manager
- Edited byyUanTao Friday, August 21, 2009 3:35 AM


