The site is slow; how do I tell whether the problem is in TR7 or in the backend?
Short answer
By breaking the slowness down into its time components. In Debug Mode Logs, the Performance Info tables in the Request and Response tabs of a request break the time down into stages: if Tr is high, the source is the Backend Service; if Tw is high, it is the queue or the limits in TR7; if Tc is high, it is establishing the connection to the Backend Service. The instantaneous state is monitored in Live Stats (Avg. Response Time, Wait/Connect, Queued requests) and the historical trend in Dashboard; in the last step, the same request is sent directly to the Backend Service, bypassing TR7, and the times are compared.
Problem: The Source of the Slowness Is Unclear
When users report that the site is slow, the problem may be in the client network, in TR7 (queue, limit, WAF, resource constraint) or in the Backend Service. For the right team to handle the problem, the stage at which the delay occurs must be separated.
Solution: Four Methods
| Your situation | Suitable method |
|---|---|
| Instantaneous picture | Method 1: Live Stats |
| Historical trend and comparison | Method 2: Dashboard |
| Time breakdown of a single request | Method 3: Debug Logs → Performance Info |
| Definitive separation | Method 4: Measuring with TR7 taken out of the path |
Method 1: Live Stats Recommended
- How it works The instantaneous time and queue values of the vService and the Backend Services are seen in cards.
- Where it is opened Left Monitor Panel → vService → Live Stats
- Requirement HTTP or L7 TCP vService
- vService type HTTP · L7 TCP
Step-by-Step Configuration
The vService is clicked in the Left Monitor Panel and the Live Stats tab is opened.
In the Frontend section, Avg. response time shows the average response time of the Backend Services, the Wait/Connect card in the Backend Services section shows the queue waiting (Queue wait) and connection establishment (Connect) time, Queued requests shows the waiting requests, and CPU and Memory usage show the vService's own load. In the Backend Services table, the response time and 5xx rate per Backend Service are seen.
Verification
If Avg. Response Time is high and Queued requests is 0, it is the Backend Service; if Queued requests is constantly greater than 0, it is capacity or a limit.
The side of the slownessMethod 2: Dashboard
- How it works The charts show when the slowness started and in which component it increased.
- Where it is opened Left Monitor Panel → vService → Dashboard
- Requirement HTTP or L7 TCP vService
- vService type HTTP · L7 TCP
Step-by-Step Configuration
The Dashboard tab of the vService is opened.
Backend Response Time Distribution, Backend Connect Time Distribution and Backend Queue Distribution in the Backend tab; the vService CPU and memory usage in the System tab; and a flat ceiling (bandwidth limit) in the Frontend Bandwidth chart are examined.
Verification
The chart in which the increase started is determined.
Response, connection, queue or systemMethod 3: Debug Logs → Performance Info
- How it works The total time of a single request is broken down into the parts measured by TR7.
- Where it is opened vService → Logs & Tracking → Debug Mode Logs
- Requirement HTTP vService
- vService type HTTP
Step-by-Step Configuration
On the Load Balancer → Load Balancer vService List screen, the HTTP vService is selected and Edit is clicked.
Debug Mode is selected in the Status field, or the Debug box is checked in the Details panel; to limit the load, only certain IPs or paths can be selected with conditional debug (How are debug logs enabled).
Save is clicked.
In the Logs & Tracking tab, Debug Mode Logs is selected as the log source and the record of the slow request is opened; in the Performance Info table in the Request tab, Tc (the time to establish the connection to the Backend Service) and Tr (the time for the Backend Service to send the response headers), and in the table in the Response tab, Tw (the time waiting in the queue) are read; the values are in milliseconds. The Termination State and Retries values are also checked.
When the examination is finished, Debug Mode is turned off.
Verification
Tr dominant: Backend Service · Tw: queue/limit · Tc: connection to the Backend Service.
The dominant componentMethod 4: Measuring with TR7 Taken Out of the Path
- How it works The same request is sent first through TR7 and then directly to the Backend Service; the difference between the two measurements shows the contribution of TR7 and the network.
- Where it is opened The client or a machine on the same network as TR7
- Requirement Direct access to the Backend Service
- vService type HTTP · L7 TCP
Step-by-Step Configuration
With curl -o /dev/null -s -w 'connect=%{time_connect} tls=%{time_appconnect} ttfb=%{time_starttransfer} total=%{time_total}\n', a request is sent first to the vService address and then to the own address of the Backend Service server.
If the direct measurement is also slow, the source is the Backend Service; if it is slow only through TR7, the vService Limits, QOS, Bandwidth, Cache and Compression settings are checked.
Verification
The first byte times of the two measurements are compared.
If the difference is small, Backend ServiceCommon Mistakes
- Looking for times in HTTP Logs. The per-request time breakdown is seen in Debug Mode Logs.
- Forgetting Debug Mode on. Debug produces a high log and processor load; it is limited with a condition and turned off when the work is finished.
- Looking at the average and missing a single server. If the time of one Backend Service differs from the others in the Backend Services table in Live Stats, the problem is on that server.
- Overlooking the queue. If Queued requests keeps increasing: How does the queue work; how long do requests wait at most?
How it is done in the documentation
