系统

查看系统版本号

SRE实战 互联网时代守护先锋,助力企业售后服务体系运筹帷幄!一键直达领取阿里云限量特价优惠。

cat /etc/redhat-release 

Ngixn

启动和重新启动nginx(/usr/local/ngixn/sbin/nginx)

./nginx -s reload 重启
./nginx

nginx  systemctl自启配置(nginx安装位置/usr/local/nginx)

 

vim    /usr/lib/systemd/system/nginx.service

[Unit]
Description=The nginx HTTP and reverse proxy server
After=syslog.target network.target remote-fs.target nss-lookup.target

[Service]
Type=forking
PIDFile=/usr/local/nginx/logs/nginx.pid
ExecStartPre=/usr/local/nginx/sbin/nginx -t
ExecStart=/usr/local/nginx/sbin/nginx
ExecReload=/bin/kill -s HUP /usr/local/nginx/logs/nginx.pid
ExecStop=/bin/kill -s QUIT /usr/local/nginx/logs/nginx.pid
PrivateTmp=true

[Install]
WantedBy=multi-user.target

 

 

mysql

更改mysql 数据库密码

update mysql.user set authentication_string=password('your password') where user='root';centos 7

Mysql 无法安装 依赖 在后面添加

--force --nodeps

(查看临时密码)

grep 'temporary password' mysqld.log 

扫码关注我们
微信号:SRE实战
拒绝背锅 运筹帷幄