Follow

Capturing a HAR file for troubleshooting

 Description

One diagnostic test to determine if there are slow loading or problem components on a page load is to use a browser's built-in Developer Tools. It's important to collect this page-load information from a user during a time when they are experiencing slowness.

Note: We recommend that users capture these logs in Google Chrome or Firefox, as IE does not allow the option to Save as a .har.

Resolution

Create and view HAR files in supported browsers

Chrome

1. Go to the page where you're experiencing slowness.
2. Press F12 on your keyboard.
3. Click the Network tab in the diagnostic window.
4. Click on the link/button/tab to have the problem page or action load in the main window.
5. After the page loads, you should see some information and graphs in the diagnostic window. If the slowness was seen during this page load, Right-click in the diagnostic window and Save as HAR with content.
6. If you need to preserve the logs for multiple page loads, there's a 'preserve log' checkbox below the tabs.
7. Press F12 to remove the diagnostic window.

Firefox

1. Go to the page where you're experiencing slowness.
2. Press F12 on your keyboard.
3. Click on the Network tab in the diagnostic window.
4. Click on the link/button/tab to have the problem page or action load in the main window.
5. After the page loads, you'll see some information and graphs in the diagnostic window. If the slowness was seen during this page load, right-click anywhere in the resulting waterfall and click Save All as HAR.
6. When saving, be sure you add the file extension .har to it.
7. Press F12 to remove the diagnostic window.

Edge

1. Go to the page where you're experiencing slowness.
2. Press F12 on your keyboard.
3. Click on the Network tab in the diagnostic window.
4. Click on the link/button/tab to have the problem page or action load in the main window.
5. After the page loads, you'll see some information and graphs in the diagnostic window. If the slowness was seen during this page load, click the disk icon(export as HAR) to save the HAR file.
6. Press F12 to remove the diagnostic window.

Internet Explorer

1. Press F12 on the keyboard.
2. You should see a component appear on the bottom of the screen.
3. Go to the Network tab in this component and press the green triangle (Play button)
4. Reproduce the issue.
5. To save, click the red square (stop button.) Directly to the right you will see a disk icon with an arrow on it.
6. Click the disk icon and save it.
7. Name your file in the Save dialog box, and make sure that the 'Save as Type' selector is set to har (*.har), then click Save.

Safari

1. Launch Safari.
2. Open Safari's Preferences by selecting Safari | Preferences (the Safari menu is the one with a little gear icon.)
3. Click the Advanced tab.
4. Place a check mark next to Show Develop menu in menu bar.
5. You can now hit ALT to bring up the menu, then go to the 'Develop' menu and select Web Inspector.
6. Now go to the 'Timeline' tab, at the bottom of the window:
      • Deselect Scripting and Rendering.
      • Click the Record button.
7. While recording, move around Enterprise Tester, clicking on parts of the UI: expand packages, load scripts, saving scripts etc., Focus on the areas where see poor performance, and do this for a couple of minutes.
8. Click Record again to stop.
9. Take a screen shot, this will give an overall picture of how long and the number of requests being made.
10. Next switch to the 'Network' tab. At the bottom click XHR.
11. Repeat the above tests, clicking on scripts, expanding tree nodes, updating and then saving. After a minute or so, you should have a number of requests recorded.
12. Right click on the list of requests and select 'Copy All as HAR.' This will put all the request info on the clipboard.
13. Now, create a new text file with the extension '.har' in a simple text editor, and paste in the text. Save the file and email it to Salesforce Support for analysis.

View the HAR file

1. Go to the HAR viewer.
2. Uncheck: Validate data before processing? (Otherwise, an error may occur.)
3. Drag the HAR file inside 'Preview' box.

 

Was this article helpful?
0 out of 0 found this helpful

Download PDF

Have more questions? Submit a request

0 Comments

Article is closed for comments.