PHP redis uncaught exception ' redisexception ' with message ' Redis server went a
PHP Code:
Ini_set (' Default_socket_timeout ',-1);
$redis = new Redis ();
$redis->connect ("192.168.2.156", "6379"); IP and port set by PHP client
$redis->auth (' 123456 ');
$redis->select (1);
$redis->set ("Say", "Hello World");
$data = $redis->get ("say"); Should output Hello World
Var_dump ($data);
Hint Error: Fatal error:uncaught exception ' redisexception ' with message ' Redis server went away ' In/usr/local/nginx/html/index . php:56 Stack Trace: #0/usr/local/nginx/html/index.php: Redis->auth (' 123456 ') #1 {main} thrown in/usr/local/ nginx/html/index.php on line 56
Redis Service opened, the firewall is also closed, Phpinfo also see the php redis extension, SELinux regardless of set to disabled or permissive are not good use, really do not know where the problem, please master pointing
------to solve the idea----------------------
The future of business is in your sight.
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.