使用certbot自动给通配符证书续期

今晚发现 hellodk.com 的几个网站的证书过期(比如 https://router.hellodk.com )无法访问,然后续期证书遇到问题,本文记录解决过程。 由于之前是配置了 crontab 脚本定期续期证书的,没有成功续上那就肯定是程序执行出错了。检查 cron 日志发现下面这个报错 PluginError('An authentication script must be provided with --manual-auth-hook when using the manual... 阅读全文

openwrt 编译安装 nginx 1.14.0 并编写 init.d 启动脚本

2021年04月22日 update 于是想到应该是由于 nginx 版本升级(1.14.0 到 1.16.1)导致了这个配置不能生效了(应该是和文件传输相关,需要更多的配置项,这个可以留到后面再研究缺少什么配置) 当时通过 pt.to 无法添加种子开启下载任务,当时没有找出来原因,重新编译安装了nginx解决。 现在发现问题不在于nginx版本或者缺少什么文件传输相关的配置,而在于nginx运行时使用的 user 和 group /etc/nginx/nginx.conf 默认指定的user是... 阅读全文

openwrt history 命令在退出后不保存历史记录的解决办法

1. 背景原因 由于 openwrt 默认 root 用户使用的 shell 解释器是 ash 它的 history 命令默认只能在当前这次 ssh 会话中有效,当你 exit 重新 ssh 登录上了之后,执行 history 命令发现输出是空的 最简单的解决办法就是把用户的 shell 解释器换成 Linux 默认的 bash 就可以了 2. 安装 bash opkg update && opkg install bash 如果安装成功,请继续;如果安装不成功,看下是什么问题导... 阅读全文

openwrt opkg install 安装 xxx 提示Package xxx wants to install file xxx But that file is already provided by package *xxx 依赖包问题导致无法安装的解决办法

首先 opkg update 然后安装 opkg install lighttpd lighttpd-mod-webdav lighttpd-mod-auth l ighttpd-mod-authn_file root@softRouter:~# opkg install lighttpd lighttpd-mod-webdav lighttpd-mod-auth l ighttpd-mod-authn_file Installing lighttpd (1.4.58-1) to root...... 阅读全文

openwrt 定时检查进程是否还在运行并自动重启(以 qbittorrent-nox 为例)

众所周知 openwrt 的软件包不够完善,除了自己编译,目前官方或第三方源里都没有 systemd 这些程序 本文以 qbittorrent-nox 为栗子? 首先找到 qbittorrent-nox 的执行命令,是 /usr/bin/qbittorrent-nox --profile=/mnt/ThreeTB2/qbit_backup 编写 /mnt/ThreeTB2/check_qbittorrent.sh #!/bin/bash # author: hellodk # time: 202... 阅读全文