- 建立软链接
ln -s shell执行路径 软链接路径
ln -s /root/node/bin/node /usr/bin/node
# 此时node命令时全局的
- 宝塔安装mariadb失败:使用快速安装,不要使用编译安装
- 查看端口情况:
# 查看端口
netstat -aptn | grep 3000
# 端口使用的进程
netstat -tnlp | grep :22
# 运行的程序
ps -aux
# 杀死程序
kill %jobnum
4.配置用户权限
vim /etc/sudoers
- 端口
# 查看开放端口
iptables -L -n
# 修改开放端口
vim /etc/sysconfig/iptables
- 启动程序
# 查看apache2文件,里面有启动方式
sudo /etc/init.d/apache2 start
- python2与python3切换
# 设置python3选项
sudo update-alternatives --install /usr/bin/python python /usr/bin/python3 150
# 查看Python选项
sudo update-alternatives --config python
# 结果如下