No connection could be made because the target machine actively refused it. [tcp://127.0.0.1:6379] in laravel 4.My code is:
$redis = Redis::connection();
$redis->set('name', 'Taylor');
$name = $redis->get('name');
$values = $redis->lrange('names', 5, 10);
安装redis服务器(可以从redis下载)后,只需运行通常位于C:\\Program Files\\Redis\\
文件redis-server.exe
并刷新页面即可!
问题可能是您的Redis实例根本没有运行,或者正在不同的主机和/或端口地址上运行(或端口6379被防火墙关闭了)。
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.