当前位置:论坛首页 > Linux面板 > 求助

【已回应】Redis怎么启动

发表在 Linux面板2019-9-9 20:17 [复制链接] 8 3907

本帖最后由 谢花郎 于 2019-9-10 09:17 编辑

QQ图片20190909201640.png Redis已安装
使用道具 举报 只看该作者 回复
发表于 2019-9-10 09:16:03 | 显示全部楼层
本帖最后由 谢花郎 于 2019-9-10 09:17 编辑
  1. /etc/init.d/redis status       查看运行状态
  2. /etc/init.d/redis start          启动
复制代码
  1. /etc/init.d/redis stop     停止服务
  2. /etc/init.d/redis restart  重启服务
复制代码

已经在运行了,安装上去就会自启动的了。
使用道具 举报 回复 支持 反对
发表于 2019-9-10 11:09:32 | 显示全部楼层
还是没有启动
使用道具 举报 回复 支持 反对
发表于 2019-9-10 11:32:51 | 显示全部楼层

ssh 内执行一下重启服务命令看看返回值

/etc/init.d/redis restart
使用道具 举报 回复 支持 反对
发表于 2019-9-10 12:50:11 | 显示全部楼层
Stopping ...
Redis stopped
Starting redis server...
806:C 10 Sep 2019 12:48:05.466 # oO0OoO0OoO0Oo Redis is starting oO0OoO0OoO0Oo
806:C 10 Sep 2019 12:48:05.466 # Redis version=5.0.5, bits=64, commit=00000000, modified=0, pid=806, just started
806:C 10 Sep 2019 12:48:05.466 # Configuration loaded
Starting redis success!
使用道具 举报 回复 支持 反对
发表于 2019-9-10 14:12:18 | 显示全部楼层
妥妥团队 发表于 2019-9-10 12:50
Stopping ...
Redis stopped
Starting redis server...

您好,这已经是成功运行了,你是怎么判断redis没成功运行的了。
使用道具 举报 回复 支持 反对
发表于 2019-9-10 18:55:47 | 显示全部楼层
[0] BadFunctionCallException in Redis.php line 81
不支持: redis

            if ('' == $this->options['password']) {
                unset($this->options['password']);
            }

            $this->handler = new \Predis\Client($this->options, $params);

            $this->options['prefix'] = '';
        } else {
            throw new \BadFunctionCallException('not support: redis');
        }
    }

    /**
     * 判断缓存
     * @access public
     * @param  string $name 缓存变量名
     * @return bool
     */
Call Stack
in Redis.php line 81
at Redis->__construct(['type' => 'redis', 'prefix' => 'hm:', 'expire' => 600, ...])
at ReflectionClass->newInstanceArgs([['type' => 'redis', 'prefix' => 'hm:', 'expire' => 600, ...]]) in Container.php line 439
at Container->invokeClass('\think\cache\driver\...', [['type' => 'redis', 'prefix' => 'hm:', 'expire' => 600, ...]]) in Loader.php line 396
at Loader::factory('redis', '\think\cache\driver\', ['type' => 'redis', 'prefix' => 'hm:', 'expire' => 600, ...]) in Cache.php line 70
at Cache->connect(['type' => 'redis', 'prefix' => 'hm:', 'expire' => 600, ...]) in Cache.php line 92
at Cache->init(['type' => 'redis', 'prefix' => 'hm:', 'expire' => 600, ...]) in Cache.php line 47
at Cache->__construct(['type' => 'redis', 'prefix' => 'hm:', 'expire' => 600, ...]) in Cache.php line 100
at Cache::__make(object(Config))
at ReflectionMethod->invokeArgs(null, [object(Config)]) in Container.php line 431
at Container->invokeClass('think\Cache', []) in Container.php line 284
at Container->make('think\Cache', [], false) in Container.php line 281
at Container->make('cache') in Container.php line 516
at Container->__get('cache') in App.php line 356
at App->containerConfigUpdate('index/') in App.php line 334
at App->init('index/') in Module.php line 61
at Module->init() in Url.php line 25
at Url->init() in App.php line 402
at App->run() in index.php line 18
使用道具 举报 回复 支持 反对
发表于 2019-9-10 19:20:05 | 显示全部楼层
[0] BadFunctionCallException in Redis.php line 81
不支持: redis

            if ('' == $this->options['password']) {
                unset($this->options['password']);
            }

            $this->handler = new \Predis\Client($this->options, $params);

            $this->options['prefix'] = '';
        } else {
            throw new \BadFunctionCallException('not support: redis');
        }
    }

    /**
     * 判断缓存
     * @access public
     * @param  string $name 缓存变量名
     * @return bool
     */
Call Stack
in Redis.php line 81
at Redis->__construct(['type' => 'redis', 'prefix' => 'hm:', 'expire' => 600, ...])
at ReflectionClass->newInstanceArgs([['type' => 'redis', 'prefix' => 'hm:', 'expire' => 600, ...]]) in Container.php line 439
at Container->invokeClass('\think\cache\driver\...', [['type' => 'redis', 'prefix' => 'hm:', 'expire' => 600, ...]]) in Loader.php line 396
at Loader::factory('redis', '\think\cache\driver\', ['type' => 'redis', 'prefix' => 'hm:', 'expire' => 600, ...]) in Cache.php line 70
at Cache->connect(['type' => 'redis', 'prefix' => 'hm:', 'expire' => 600, ...]) in Cache.php line 92
at Cache->init(['type' => 'redis', 'prefix' => 'hm:', 'expire' => 600, ...]) in Cache.php line 47
at Cache->__construct(['type' => 'redis', 'prefix' => 'hm:', 'expire' => 600, ...]) in Cache.php line 100
at Cache::__make(object(Config))
at ReflectionMethod->invokeArgs(null, [object(Config)]) in Container.php line 431
at Container->invokeClass('think\Cache', []) in Container.php line 284
at Container->make('think\Cache', [], false) in Container.php line 281
at Container->make('cache') in Container.php line 516
at Container->__get('cache') in App.php line 356
at App->containerConfigUpdate('index/') in App.php line 334
at App->init('index/') in Module.php line 61
at Module->init() in Url.php line 25
at Url->init() in App.php line 402
at App->run() in index.php line 18
使用道具 举报 回复 支持 反对
发表于 2019-9-11 00:35:15 | 显示全部楼层
php56能安装为什么 php70不能安装redis?
使用道具 举报 回复 支持 反对
您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

普通问题处理

论坛响应时间:72小时

问题处理方式:排队(仅解答)

工作时间:白班:9:00 - 18:00

紧急运维服务

响应时间:3分钟

问题处理方式:宝塔专家1对1服务

工作时间:工作日:9:00 - 18:30

宝塔专业团队为您解决服务器疑难问题

点击联系技术免费分析

工作时间:09:00至18:30

快速回复 返回顶部 返回列表