Posts

  • VirtualBox 设置静态 IP

    虚拟机网络配置方式 Windows: NatNetwork 或者 共享网络 + Host-only MacOS: NatNetwork MacOS 使用 Host-only 模式共享网络比较复杂,推荐使用 NatNetwork,可以使用端口映射或者开一台Client虚拟机操作 文件传输示例: ssh user@127.0.0.1 -p 2022 scp -P 2022 ~/Downloads/a.zip user@127.0.0.1:~ MacOS: VirtualBox ...
  • Nginx

    Install Nginx nginx -V #查看编译选项 2>&1 nginx -V | tr ' ' '\n' nginx -t # 检查配置文件是否正确 nginx -s stop nginx -s reload #平滑重启 Red Hat NGINX Init Script https://www.nginx.com/resources/wiki/start/topics/examples/redhatnginxinit/ sed -i 's/nginx=...
  • MySQL

    MySQL Documentation: https://dev.mysql.com/doc/ 常用命令 连接数据库 mysql -uroot -p -- 创建用户 CREATE USER 'test'@'%' identified BY 'test@123!'; -- CREATE USER 'test'@'%' identified WITH 'mysql_native_password' BY 'test@123!'; GRANT ALL PRIVILEGES ON tes...
  • CentOS7

    Centos7 系统约定 软件源代码包存放位置:/usr/local/src 源码包编译安装位置:/usr/local/软件名字 网络设置 CentOS 7.0默认安装好之后是没有自动开启网络连接的! cd /etc/sysconfig/network-scripts/ #进入网络配置文件目录 编辑网络开启自动启用网络连接,ifcfg-en开头的文件将ONBOOT设置为yes。 service network restart # ...