-
Linux cron 任务定时删除 5 天前的日志
使用场景 比如log4j中使用了DailyRollingFileAppender按日归档日志的方式,没有类似RollingFileAppender的maxBac
-
Linux中/bin、/sbin、/usr/bin、/usr/sbin、/usr/local/bin、/usr/local/sbin 目录的含义及区别
/bin 与 /sbin /bin 存放所有用户皆可使用的系统程序。即普通的基本命令,如:touch、ls等。 /sbin 存放超级用户才能使用的系统程序。即基
2021-05-19, Views: 1614 , Topics: Linux
-
MySQL 聚集索引和非聚集索引
聚集索引 聚集索引确定表中数据的物理顺序,每一行数据按照聚集索引物理上排序。 InnoDB存储引擎必须有且仅有一个聚集索引。 聚集索引存储的是这一行的数据本身(
-
PostgreSQL 重置序列序号
从 1 开始 false表示,数字1还没有被用掉。 select setval('post_id_seq', 1, false); 从 2 开始 true表示,
2021-05-17, Views: 1753 , Topics: PostgreSQL
-
PostgreSQL 修改字段属性
重命名 alter table record_page_view rename ua to user_agent; 添加字段 alter table reco
2021-05-16, Views: 2951 , Topics: PostgreSQL
-
PostgreSQL 时间戳转毫秒值并去除小数位
时间戳转毫秒值 使用extract函数及epoch from关键词。 select extract(epoch from (current_timestamp)
2021-05-16, Views: 6263 , Topics: PostgreSQL
-
Linux 编译安装 PostgreSQL 12.2
下载地址 清华大学镜像,下载并解压。 wget https://mirrors.tuna.tsinghua.edu.cn/postgresql/source/v
2021-05-15, Views: 2028 , Topics: PostgreSQL Linux
-
Ubuntu 卸载 Nginx
apt-get 方式安装 apt-get remove nginx nginx-common apt-get purge nginx nginx-common
-
Nginx 负债均衡的几种方式
轮询 http { upstream loadbalanceone{ server 127.0.0.1:9000; se
-
Nginx(OpenResty) 去掉默认错误页面中的版本号
说明 修改Nginx的源码才能去除,所以必须通过编译安装,yum或apt-get方式无法修改。 适用于OpenResty。 Nginx和OpenResty的开源
-
Ubuntu 使用 Certbot 给 Nginx 添加 SSL 证书
关于 Certbot Certbot不用注册Let's Encrypt账号(它会自动帮你注册),不用手动修改配置服务器配置,一行命令搞定。 安装示例 以我的服务
2021-05-10, Views: 2420 , Topics: Nginx Let's Encrypt HTTPS
-
OpenResty lua-resty-http unable to get local issuer certificate
错误信息 在请求https接口时,抛出了如下异常信息: lua ssl certificate verify error: (20: unable to get
-
OpenResty lua-resty-auto-ssl 无法颁发证书问题
开启 debug 日志 error_log logs/error.log debug; 错误日志 2021/02/17 11:13:47 [notice] 1
2021-05-09, Views: 2410 , Topics: OpenResty HTTPS Let's Encrypt
-
OpenResty lua-resty-auto-ssl: failed to set ocsp stapling for
错误日志 lua-resty-auto-ssl报错。 2021/02/17 08:59:12 [error] 28822#0: 17557 [lua] ssl
2021-05-08, Views: 2577 , Topics: OpenResty HTTPS Let's Encrypt
-
OpenResty 使用 lua-resty-auto-ssl 配置 https 证书
lua-resty-auto-ssl 开源地址 https://github.com/auto-ssl/lua-resty-auto-ssl lua-resty
2021-05-06, Views: 6479 , Topics: OpenResty Let's Encrypt HTTPS
-
使用 LuaRocks 管理 Lua 依赖
列出已安装依赖 luarocks list 查看帮助 luarocks help 查看命令帮助 luarocks help install 查找依赖 luaro
-
OpenResty 整合 LuaRocks - Linux
安装 LuaRocks 下载地址:https://luarocks.github.io/luarocks/releases 下载并解压 wget https:/
-
Linux 编译安装 OpenResty
下载 OpenResty 本文以openresty-1.19.3.1为例。 wget https://openresty.org/download/openre
-
Linux yum 安装 OpenResty
下载镜像 wget https://mirrors.tuna.tsinghua.edu.cn/openresty/centos/7/x86_64/openres
-
Arthas 获取 Spring Context 动态修改 Spring Boot 配置文件中的值
案例代码 Spring Boot配置文件:application.yml config: url: http://www.baidu.com isTes
2021-05-02, Views: 7338 , Topics: Arthas Spring Boot 诊断工具