Sep 7, 2016

SSRS 2014 - IE 11 - Toolbar items may render in multiple rows instead of one row.

I have been facing issues with SSRS 2008 R2, The reports were freezing and not showing any data. Microsoft did not provide any support as SQL 2008 R2. MS anyways closed for any new enhancements SQL 2008 variants.

We upgraded to SSRS 2014, reports started working and data was rendered. Wait, now the toolbar started appearing in multiple rows. For smaller resolution screens, this was not acceptable. I could not find any solution or fix by Microsoft for SSRS 2014, though I could find a workaround that worked for me.

This workaround requires me to modify the ReportViewer.aspx file.

The ReportViewer.aspx file is located under Pages Folder at %ProgramFiles%\Microsoft SQL Server\MSRS12.MSSQLSERVER\Reporting Services\ReportServer\Pages. 

The folder name and path may differ based on the SQL Version and installation location, the path provided above is generalized.

  1. Take backup of original ReportViewer.aspx file, just in case the changes have to be restored.
  2. Open ReportViewer.aspx, 
    • find meta Tag
    • Replace the content property with content="IE=EmulateIE10; IE=Edge" in the tag
  3. Restart the SSRS service
  4. Try the report now, it should work
  5. It it does not work, then try different options in the content, example: IE=EmulateIE7 etc.

Changing this option will try to Emulate the Report with version specified in order.

May 18, 2016

How to reload Missing SQL Server Performance Counters

Recently I was working on one of the servers to analyze the performance using Performance Counters which were collected historically for a long period of time.

I noticed some of the needed counters were missing for the collection. 

So what was happening with that server where performance counters were missing? After running the following query on current snapshot of performance counters, I did not get the result. SQL Server was not reporting any counters. 



After doing some research I found that there is one configuration file that lists all the performance counters which SQL Server loads. The name of the performance counter configuration file is generally perfsqlctr.ini or perf-sqlctr.ini located in Binn directory.
To precisely get the file name and location, you may take help from Registry.

  1. In Registry Go to HKLM\SYSTEM\CurrentControlSet\services\
  2. Extract the value from Key ImagePath until Binn
  3. Go to HKLM\SYSTEM\CurrentControlSet\services\[InstanceName]\Performance
  4. Extract the value from key PerfIniFile
  5. Merge the values from #2 and #4, that is the file name which has all of the counters.
Now you got all of the file names needed, follow these steps to reload the counters.
  1. Open file in text editor, make sure that all of the needed counters are there in the file, if not there then add counter while matching the format of existing counters.
  2. Unload the Counters
    • If Default Instance then run following command from shell.
      • Unlodctr MSSQLSERVER
    • If Named Instance then run the following command from shell.
      • Unlodctr MSSQL$[ServiceName]
  3. Restart the MSSQL Service for that instance
  4. Reload the counters with following command from shell.
      • Lodctr [path\file you got in #5]
  5. Restart MSSQLService for the instance
It worked for me, I could see the counters.



If you still see the issues, then please make sure that the registry keys as discussed above are accessible by Service Account of SQL Service. Then repeat steps between 2 and 4.

Optimizing Indexes with Execution Plans

Contact Me

Name

Email *

Message *