分类: 编程技术

85 篇文章

thumbnail
配置Nginx端口转发
如何将Nginx的某个端口配置到某个域名上 例如我要将9000端口配置到 leanote.hupc.site这个域名上upstream leanote.hupc.site{     server localhost:9000; } server{   listen&nb…
thumbnail
修改Nginx请求日志格式
修改nginx.conflog_format main '$http_x_forwarded_for $remote_addr - $remote_user [$time_local] "$request" ' '$statu…
thumbnail
用curl分析URL请求时间
如何用curl分析URL请求时间: curl -o /dev/null -s -w %{time_namelookup}::%{time_connect}::%{time_starttransfer}::%{time_total}::%{speed_download}"\n" "https://hupc.site/?p…
thumbnail
rsync返回值
rsync常用的错误代码: 0      Success 1      Syntax or usage error 2      Protocol incompatibility 3      Errors selecting input/output files, dirs 4      Requested action not supporte…
【转】php配置没有生效怎么办?
本文操作环境:linux5.9.8系统、PHP7.2版、DELL G3电脑 php配置没有生效怎么办? php重启后,配置不生效,一定要重新加载php.ini文件 停止PHP: [root@jiang host]# pkill php-fpm 查看9000端口: [root@jiang host]# netstat -lnt | grep 9000…
【转】Linux常用命令
基本操作 Linux关机,重启 # 关机 shutdown -h now # 重启 shutdown -r now 查看系统,CPU信息 # 查看系统内核信息 uname -a # 查看系统内核版本 cat /proc/version # 查看当前用户环境变量 env cat /proc/cpuinfo # 查看有几个逻辑cpu, 包括cpu型号 …
thumbnail
php删除数组中的某个值
通常删除数组的值,我们会想到unset()这个函数,但是有时候的场景是索引数组,而且不知道数组的key,只知道要删除某个值。 那这种情况下,PHP没有官方的函数来实现,但是有另一个函数可以变相实现删除数组的效果。 那就是array_diff()函数。 array_diff (PHP 4 >= 4.0.1, PHP 5, PHP 7, PHP …