Getting Error 324 (net::ERR_EMPTY_RESPONSE). when using memcache in kohana
i'm getting this error when i try to use memcache using kohana. all i did was changed the hostname in the configuration file and used $cache = Cache::instance('memcache');
.
i can telnet my memcached servers so probably the problem is not there.
开发者_JAVA技巧any help?
When using a PHP framework like FuelPHP https://fuelphp.com/forums/topics/view/4256#11344
Problem
- In Google Chrome "Error 324 (net::ERR_EMPTY_RESPONSE): The server closed the connection without sending any data."
- No PHP errors, due to Apache dying before anything is sent back to the browser
- In Apache logs, this not helpful message "Error [notice] child pid 19647 exit signal Segmentation fault (11)"
Solution Double check there is an opening php tag (duh!), or check for other silly, rookie syntax mistakes.
The error described is a Google Chrome error. This suggests that Kohana is not responding with anything, most likely because the error/exception handling is being suppressed. Check that PHP error_reporting
is on (E_ALL
is a good value).
If there still is no output, it could be that PHP is segfaulting during execution. If so you should be able to find out what is wrong in your web server logs if not the system log.
My best guess is that php-memcache and/or the memcache library is not compiled correctly or has been corrupted.
Can't reproduced this problem in local as my local and server have different environment. This happened after setting the PDO
$db = new PDO('mysql:host='.$host.';dbname='.$db_name, $user, $pass,
array( PDO::ATTR_PERSISTENT => true));
$db->setAttribute(PDO::ATTR_EMULATE_PREPARES, false);
$db->setAttribute(PDO::ATTR_STRINGIFY_FETCHES, false);
However after run an update for sudo apt-get install php5-mysqlnd
. Problem fixed. So this could be one of the things you can check if you have run out of idea where's the problem coming from.
精彩评论