Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

vnstat-dashboard 好像没有办法运行了,大佬可以更新下吗? #7

Closed
airysoar opened this issue May 26, 2022 · 9 comments
Closed

Comments

@airysoar
Copy link

vnstat-dashboard 好像没有办法运行了,大佬可以更新下吗?提示的错误也是和上次一个人一样的:
Fatal error: Uncaught Exception: JSON is invalid in /var/www/html/includes/vnstat.php:60 Stack trace: #0 /var/www/html/includes/vnstat.php(44): vnStat->processVnstatData('') #1 /var/www/html/index.php(37): vnStat->__construct('/usr/bin/vnstat') #2 {main} thrown in /var/www/html/includes/vnstat.php on line 60

@stilleshan
Copy link
Owner

检查本地 vnstat 安装的目录和挂载目录是否一致

@airysoar
Copy link
Author

检查本地 vnstat 安装的目录和挂载目录是否一致
检查确认过,没有问题的。我安装官方的vnstat-docker也能正常的显示流量信息的,就是官方的vnstat-docker的图片太丑了

@stilleshan
Copy link
Owner

你 vnstat 的安装过程发一下

@airysoar
Copy link
Author

airysoar commented May 30, 2022

你 vnstat 的安装过程发一下

正常的本地先apt安装vnstat以后,然后再安装docker版本的,试了下,好像原版的两个tomangert/vnstat-dashboard,和alexandermarston/vnstat-dashboard也是一样的错误。我用其他的vps安装了2次官方的vnstat-docker都是能正常打开,正常显示官方vnstati生成的图片的

@stilleshan
Copy link
Owner

vnstat-dashboard 是非官方的面板,是要基于服务器安装了 vnstat 才能用,不能用 docker 安装 vnstat, 你发的 vnstat-docker 都没挂载数据到宿主机,肯定更没法用 dashboard

@airysoar
Copy link
Author

vnstat-dashboard 是非官方的面板,是要基于服务器安装了 vnstat 才能用,不能用 docker 安装 vnstat, 你发的 vnstat-docker 都没挂载数据到宿主机,肯定更没法用 dashboard

嗯,是服务器安装了vnstat的,不是docker安装vnstat的,就是服务器本地安装vnstat后,你们三个的面板部署后都提示错误。用官方的vnstat-docker是可以正常调用服务器上的vnstat的。

@stilleshan
Copy link
Owner

我是在 centos 上 yum install 安装的,或者官方github编译安装的都可以,不知道你是怎么装的

@airysoar
Copy link
Author

airysoar commented Jun 3, 2022

我是在 centos 上 yum install 安装的,或者官方github编译安装的都可以,不知道你是怎么装的

我是在debian上apt install和官方github编译安装都试过,都是面板提示出错,官方的docker显示正常,不知道为啥不行

@stilleshan
Copy link
Owner

https://github.com/vergoh/vnstat/blob/master/INSTALL.md

你参考这个编译安装试试吧.

我的ARM CentOS 就是按照这个编译安装没问题.

如果还是不行我也没办法了

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants