webman-thinkorm-cache-master 数据库问题

siwei

问题描述

 我学习了webman,想用thinkorm-cache,https://gitee.com/uspear/webman-thinkorm-cache/tree/master  下载后,运行起来,总是报如下错误,据群里大咖说缺数据库等,不知道是怎么样的数据库

报错信息

D:\phpstudy_pro\WWW\webman-thinkorm-cache-master>php windows.php

----------------------- WORKERMAN -----------------------------
Workerman version:4.0.37          PHP version:7.4.3
------------------------ WORKERS -------------------------------
worker                        listen                              processes status
webman                        http://0.0.0.0:8888                 2         [ok]
monitor                       none                                1         [ok]

Fatal error: Uncaught think\db\exception\PDOException: SQLSTATE[HY000] [2002] 由于目标计算机积极拒绝,无法连接。
 in D:\phpstudy_pro\WWW\webman-thinkorm-cache-master\vendor\topthink\think-orm\src\db\PDOConnection.php:797
Stack trace:
#0 D:\phpstudy_pro\WWW\webman-thinkorm-cache-master\vendor\topthink\think-orm\src\db\PDOConnection.php(710): think\db\PDOConnection->getPDOStatement('select 1', Array, false, false)
#1 D:\phpstudy_pro\WWW\webman-thinkorm-cache-master\vendor\topthink\think-orm\src\db\PDOConnection.php(656): think\db\PDOConnection->pdoQuery(Object(think\db\Query), 'select 1', Array, false)
#2 D:\phpstudy_pro\WWW\webman-thinkorm-cache-master\vendor\webman\think-orm\src\ThinkOrm.php(21): think\db\PDOConnection->query('select 1')
#3 D:\phpstudy_pro\WWW\webman-thinkorm-cache-master\vendor\workerman\workerman\Events\Select.php(233): Webman\ThinkOrm\ThinkOrm::Webman\ThinkOrm\{closure}()
#4 D:\phpstudy_pro\WWW\webman-thinkorm-cache-master\vendor\workerman\workerman\Events\Select.php(283): Workerman\E in D:\phpstudy_pro\WWW\webman-thinkorm-cache-master\vendor\topthink\think-orm\src\db\PDOConnection.php on line 797
Worker process terminated with ERROR: E_ERROR "Uncaught think\db\exception\PDOException: SQLSTATE[HY000] [2002] 由于目标计算机积极拒绝,无法连接。
 in D:\phpstudy_pro\WWW\webman-thinkorm-cache-master\vendor\topthink\think-orm\src\db\PDOConnection.php:797
Stack trace:
#0 D:\phpstudy_pro\WWW\webman-thinkorm-cache-master\vendor\topthink\think-orm\src\db\PDOConnection.php(710): think\db\PDOConnection->getPDOStatement('select 1', Array, false, false)
#1 D:\phpstudy_pro\WWW\webman-thinkorm-cache-master\vendor\topthink\think-orm\src\db\PDOConnection.php(656): think\db\PDOConnection->pdoQuery(Object(think\db\Query), 'select 1', Array, false)
#2 D:\phpstudy_pro\WWW\webman-thinkorm-cache-master\vendor\webman\think-orm\src\ThinkOrm.php(21): think\db\PDOConnection->query('select 1')
#3 D:\phpstudy_pro\WWW\webman-thinkorm-cache-master\vendor\workerman\workerman\Events\Select.php(233): Webman\ThinkOrm\ThinkOrm::Webman\ThinkOrm\{closure}()
#4 D:\phpstudy_pro\WWW\webman-thinkorm-cache-master\vendor\workerman\workerman\Events\Select.php(283): Workerman\E in D:\phpstudy_pro\WWW\webman-thinkorm-cache-master\vendor\topthink\think-orm\src\db\PDOConnection.php on line 797"

Fatal error: Uncaught think\db\exception\PDOException: SQLSTATE[HY000] [2002] 由于目标计算机积极拒绝,无法连接。
 in D:\phpstudy_pro\WWW\webman-thinkorm-cache-master\vendor\topthink\think-orm\src\db\PDOConnection.php:797
Stack trace:
#0 D:\phpstudy_pro\WWW\webman-thinkorm-cache-master\vendor\topthink\think-orm\src\db\PDOConnection.php(710): think\db\PDOConnection->getPDOStatement('select 1', Array, false, false)
#1 D:\phpstudy_pro\WWW\webman-thinkorm-cache-master\vendor\topthink\think-orm\src\db\PDOConnection.php(656): think\db\PDOConnection->pdoQuery(Object(think\db\Query), 'select 1', Array, false)
#2 D:\phpstudy_pro\WWW\webman-thinkorm-cache-master\vendor\webman\think-orm\src\ThinkOrm.php(21): think\db\PDOConnection->query('select 1')
#3 D:\phpstudy_pro\WWW\webman-thinkorm-cache-master\vendor\workerman\workerman\Events\Select.php(233): Webman\ThinkOrm\ThinkOrm::Webman\ThinkOrm\{closure}()
#4 D:\phpstudy_pro\WWW\webman-thinkorm-cache-master\vendor\workerman\workerman\Events\Select.php(283): Workerman\E in D:\phpstudy_pro\WWW\webman-thinkorm-cache-master\vendor\topthink\think-orm\src\db\PDOConnection.php on line 797
Worker process terminated with ERROR: E_ERROR "Uncaught think\db\exception\PDOException: SQLSTATE[HY000] [2002] 由于目标计算机积极拒绝,无法连接。
 in D:\phpstudy_pro\WWW\webman-thinkorm-cache-master\vendor\topthink\think-orm\src\db\PDOConnection.php:797
Stack trace:
#0 D:\phpstudy_pro\WWW\webman-thinkorm-cache-master\vendor\topthink\think-orm\src\db\PDOConnection.php(710): think\db\PDOConnection->getPDOStatement('select 1', Array, false, false)
#1 D:\phpstudy_pro\WWW\webman-thinkorm-cache-master\vendor\topthink\think-orm\src\db\PDOConnection.php(656): think\db\PDOConnection->pdoQuery(Object(think\db\Query), 'select 1', Array, false)
#2 D:\phpstudy_pro\WWW\webman-thinkorm-cache-master\vendor\webman\think-orm\src\ThinkOrm.php(21): think\db\PDOConnection->query('select 1')
#3 D:\phpstudy_pro\WWW\webman-thinkorm-cache-master\vendor\workerman\workerman\Events\Select.php(233): Webman\ThinkOrm\ThinkOrm::Webman\ThinkOrm\{closure}()
#4 D:\phpstudy_pro\WWW\webman-thinkorm-cache-master\vendor\workerman\workerman\Events\Select.php(283): Workerman\E in D:\phpstudy_pro\WWW\webman-thinkorm-cache-master\vendor\topthink\think-orm\src\db\PDOConnection.php on line 797"
process D:\phpstudy_pro\WWW\webman-thinkorm-cache-master\start.php terminated and try to restart
process D:\phpstudy_pro\WWW\webman-thinkorm-cache-master\runtime\windows\start_monitor.php terminated and try to restart
monitor                       none                                1         [ok]
webman                        http://0.0.0.0:8888                 2         [ok]
1026 1 0
1个回答

yongdao35

你应该按照webman官方文档来学习webman,而不是下载一个没文档的第三方的项目来学习。

  • 暂无评论
年代过于久远,无法发表回答
×
🔝