利用u盘安装 Debian

制作开机启动盘

1、制作开机启动u盘,请参考 制作启动u盘

2、下载 debian-13.5.0-amd64-DVD-1.iso 并将其拷贝到u盘根目录

#.官网地址
https://www.debian.org/CD/http-ftp

#.下载 Debian 13.5.0 [ x86_64架构, 3.7 GB ]
https://cdimage.debian.org/debian-cd/current/amd64/iso-dvd/debian-13.5.0-amd64-DVD-1.iso
https://mirrors.huaweicloud.com/debian-cd/13.5.0/amd64/iso-dvd/debian-13.5.0-amd64-DVD-1.iso

安装 Debian 13.5

  • 第1步,安装主菜单,选择 Install

  • 第2步,选择语言,建议 English

  • 第3步,选择地区,建议 United States

  • 第4步,选择键盘,建议 American English

  • 第5步,设置 Hostname,示例改为 localhost

  • 第6步,设置 Domain,默认为空即可

  • 第7步,设置 root 密码

  • 第8步,创建普通用户,示例 appadmin

  • 第9步,设置新用户的密码

  • 第10步,设置时区,默认即可

  • 第11步,配置磁盘,建议 使用整个磁盘

  • 第12步,配置软件包管理器,建议 No

  • 第13步,配置 popularity-contest,建议 No

  • 第14步,选择要安装的软件,取消 desktop + 选择 SSH server

  • 第15步,安装 GRUB 启动引导器,建议 是

  • 第16步,选择 GRUB 要安装到的设备,示例选择 /dev/sda

  • 第17步,安装完成,重启一下

配置ip地址

  • 第15步,进入系统,配置ip地址,参考如下:
root@localhost:~# touch /etc/systemd/network/ens33.network
root@localhost:~# cat /etc/systemd/network/ens33.network
[Match]
Name=ens33

[Network]
DHCP=no
Address=192.168.31.101/24
Gateway=192.168.31.1
DNS=223.5.5.5
DNS=223.6.6.6
  • 第15步,重启网卡服务
systemctl enable systemd-networkd
systemctl restart systemd-networkd
  • 最后,其他初始化工作:
#.开启root登录
sed -i "s/#PermitRootLogin/PermitRootLogin/" /etc/ssh/sshd_config
sed -i 's/^PermitRootLogin.*$/PermitRootLogin yes/g' /etc/ssh/sshd_config
cat /etc/ssh/sshd_config | grep PermitRootLogin
systemctl restart ssh

#.确认os版本
root@localhost:~# source /etc/os-release && echo $PRETTY_NAME
Debian GNU/Linux 13 (trixie)
root@localhost:~# cat /etc/issue
Debian GNU/Linux 13 \n \l
root@localhost:~# cat /etc/os-release | grep PRETTY_NAME | cut -d= -f2 | tr -d '"'
Debian GNU/Linux 13 (trixie)
root@localhost:~# cat /etc/os-release | grep DEBIAN_VERSION_FULL
DEBIAN_VERSION_FULL=13.5

#.查看内核版本
root@localhost:~# uname -r
6.12.86+deb13-amd64

#.设置国内镜像源
cp /etc/apt/sources.list /etc/apt/sources.list.bak
echo deb http://mirrors.aliyun.com/debian/ trixie main contrib non-free non-free-firmware > /etc/apt/sources.list
echo deb http://mirrors.aliyun.com/debian/ trixie-updates main contrib non-free non-free-firmware >> /etc/apt/sources.list
echo deb http://mirrors.aliyun.com/debian/ trixie-backports main contrib non-free non-free-firmware >> /etc/apt/sources.list
echo deb http://mirrors.aliyun.com/debian-security/ trixie-security main contrib non-free non-free-firmware >> /etc/apt/sources.list
apt update
Copyright © www.sqlfans.cn 2021 - 2026 All Right Reserved更新时间: 2026-07-09 10:54:12

results matching ""

    No results matching ""