系统安装指南
如何安装和重装操作系统
本指南将帮助您了解如何在VPS上安装和重装操作系统。
支持的操作系统
Linux发行版
- Ubuntu:18.04 LTS, 20.04 LTS, 22.04 LTS
- Debian:10 (Buster), 11 (Bullseye), 12 (Bookworm)
- CentOS:7, 8 Stream
- AlmaLinux:8, 9
- Rocky Linux:8, 9
选择建议
- Ubuntu 22.04 LTS:推荐新手使用,社区支持好
- Debian 12:稳定性极佳,适合生产环境
- AlmaLinux 9:CentOS的替代品,企业级稳定
通过控制面板重装
重装步骤
- 登录控制面板
- 进入”系统重装”页面
- 选择目标操作系统
- 设置root密码(8-20位,包含字母和数字)
- 确认重装操作
重装时间
- 通常需要5-15分钟
- 重装期间服务器将无法访问
- 完成后会自动重启
重装前准备
数据备份
# 备份重要文件
tar -czf backup.tar.gz /home /etc /var/www
# 备份数据库
mysqldump -u root -p --all-databases > all_databases.sql
记录配置
- 网站配置文件位置
- 数据库连接信息
- SSL证书文件
- 自定义服务配置
重装后配置
1. 更新系统
# Ubuntu/Debian
apt update && apt upgrade -y
# CentOS/AlmaLinux
yum update -y
2. 安装基础软件
# 安装常用工具
apt install -y curl wget vim git htop
# 安装开发工具
apt install -y build-essential
3. 配置防火墙
# Ubuntu (UFW)
ufw enable
ufw allow ssh
ufw allow http
ufw allow https
# CentOS (firewalld)
systemctl enable firewalld
firewall-cmd --permanent --add-service=ssh
firewall-cmd --permanent --add-service=http
firewall-cmd --permanent --add-service=https
firewall-cmd --reload
自定义ISO安装
上传ISO文件
- 联系技术支持
- 提供ISO文件下载链接
- 等待技术人员协助安装
支持的自定义系统
- Windows Server(需额外授权费用)
- 其他Linux发行版
- 特殊定制系统
注意事项
重要提醒
- 重装会清空所有数据,请务必备份
- 重装后IP地址保持不变
- SSH密钥需要重新配置
- 所有软件需要重新安装
常见问题
- 重装失败:联系技术支持
- 无法启动:可能是硬件问题
- 网络异常:检查防火墙配置