frainzy1477 / clash

Clash for openwrt [Luci-app-clash] https://github.com/frainzy1477/luci-app-clash
MIT License
351 stars 77 forks source link

luci 配置文件上传问题及无法启动 #20

Closed GhostFlying closed 5 years ago

GhostFlying commented 5 years ago

启动后没有配置文件,有如下日志错误

time="2019-06-09T17:01:12Z" level=fatal msg="Parse config error: Configuration file /etc/clash/config.yml is empty"

此时通过 luci 提交配置文件失败,改用 vim 直接编辑配置文件,重新选择 enabled,并不会启动且则仅有以下日志:

===============================2019-06-10 01:13:13 CLASH IS DISABLED =====================================

以及 openwrt system log 存在以下日志:

Mon Jun 10 01:13:09 2019 daemon.err uhttpd[2159]: Model clash/config returns SimpleForm but is dispatched via cbi(), Mon Jun 10 01:13:09 2019 daemon.err uhttpd[2159]: please change admin/services/clash/config to use the form() action instead.

frainzy1477 commented 5 years ago

config.yml

config.yml 没了怎么启动?

frainzy1477 commented 5 years ago

config.yml

config.yml 没了怎么启动?

luci更新了

GhostFlying commented 5 years ago

更新后依旧复现该问题,复现步骤如下: (卸载并重新安装两个包)

  1. luci 进入设置,此时没有配置;
  2. 选择本地上传 config 文件,出现 The submitted security token is invalid or already expired! 错误,无法提交(多次复现,隐身模式也出现);
  3. 更换使用配置订阅功能,成功更新配置;
  4. 选中 enable clash,等待一段时间依旧没有启动。

此时 clash 的日志输出如下:

===============================2019-06-12 00:14:12 CLASH IS DISABLED ===================================== --2019-06-12 00:14:20-- https://xxx/clash?auth=yyy Resolving xxx Connecting to xxx... connected. HTTP request sent, awaiting response... 200 OK Length: unspecified [text/plain] Saving to: '/etc/clash/config.yml' 0K .......... .......... .......... .......... .... 51.8K=0.9s 2019-06-12 00:14:25 (51.8 KB/s) - '/etc/clash/config.yml' saved [45910]

===============================2019-06-12 00:14:25 CLASH IS DISABLED ===================================== ===============================2019-06-12 00:14:36 CLASH IS DISABLED =====================================

system log 输出为:

Wed Jun 12 00:14:25 2019 daemon.err uhttpd[2158]: Model clash/config returns SimpleForm but is dispatched via cbi(), Wed Jun 12 00:14:25 2019 daemon.err uhttpd[2158]: please change admin/services/clash/config to use the form() action instead.

openwrt 版本为: LuCI openwrt-18.06 branch (git-19.020.41695-6f6641d) / OpenWrt 18.06.2 r7676-cddd7b4c77