Drupal 7 dreadful TTFB
|
09-21-2017, 09:16 PM
(This post was last modified: 09-21-2017 09:17 PM by Jesse Gersenson.)
Post: #1
|
|||
|
|||
Drupal 7 dreadful TTFB
https://www.webpagetest.org/result/17092...view_step1
Description of problem: Long TTFB times, but not on every page load. Basics: Site is running Drupal 7. DB and site are on the same box. In front of this is a proxy running apache and storing some static files to disk. We typically have about 17 apache processes running. We are not running Memcached or any other db caching layer. What I've tried: 1. Using a sample of SELECT statements drupal is running, I added indexes to the 'table' in "WHERE 'table' ...". 2. tweaked a number of db variable values, mostly taken from "High Performance Drupal" (O'Reily, Oct 2013). This is my first time working with Drupal and I assume this is a drupal-specific issue. Any direction and insight would be much appreciated. Server specs ---------------- Virtual machine 4 cores on an Intel® Xeon® CPU E5-2630 v4 @ 2.20GHz 8 gb ram ~$ uname -a 3.16.0-4-amd64 #1 SMP Debian 3.16.x x86_64 GNU/Linux cat /proc/meminfo Code: MemTotal: 8197700 kB ENV php -v Code: PHP 5.6.30 (cli) Copyright (c) 1997-2016 The PHP Group Zend Engine v2.6.0, Copyright (c) 1998-2016 Zend Technologies mysql -V Code: mysql Ver 14.14 Distrib 5.5.57, for debian-linux-gnu (x86_64) using readline 6.3 Current settings, attached 'mysql-show-variables.txt' apache2 -v Code: Server version: Apache/2.4.10 (Debian) cat /etc/apache2/mods-enabled/mpm_prefork.conf Code: <IfModule mpm_prefork_module> iostat -cx Code: Linux 3.16.0-4-amd64 09/20/2017 _x86_64_ (4 CPU) phpmyadmin reports the following variables as having 'alert' values: Code: Aborted connects 2 |
|||
09-22-2017, 01:30 AM
Post: #2
|
|||
|
|||
RE: Drupal 7 dreadful TTFB
Hi Jesse,
Your issue seems to be your SSL certificate. Check if it's expired or something's wrong with it. Have you tried running the same test from other WPT machines? I doubt anything's wrong with your test machine itself, but you never know. So I would try another machine. If you get the same results, I think the issue is with your certificate. I'm not a Drupal expert, but I don't think it's the cause of this particular problem. Looking at the waterfall, there are no requests for a little over 1 second between the WPT machine and your server. There is little CPU usage and no BW usage during this time. After your initial request to https://www.upce.cz/vvr/ved-projekty.html on request #3, I noticed in the color breakdown that communication stops after SSL negotiation. Then, about 1 second later, two HTTP requests go out to ocsp.digicert.com to check the revocation status of your certificate. This wait time seems to be the reason why it takes so long for WPT to get the first byte from your server. So I would take a look at any issues with the server's SSL certificate. I would also look at what's happening on the backend, if you can. What communication is your server having with other servers that WPT does not see? Lastly, if all else fails, I would run another WPT test with tcpdump enabled, and take a look at what's happening during the SSL key exchange. Hope that helps. - Jean Jean Tunis Principal Consultant, RootPerformance Consulting http://www.websiteevals.com Author, Analyzing HTTP http://www.analyzinghttp.com |
|||
09-22-2017, 07:29 AM
Post: #3
|
|||
|
|||
RE: Drupal 7 dreadful TTFB
Notice that the first two requests are to SSL CA to verify your SSL cert. This is unnecessary. Enable OCSP stapling - that should do it.
|
|||
« Next Oldest | Next Newest »
|
User(s) browsing this thread: 2 Guest(s)