Debian 初始化命令备忘

本文地址:blog.lucien.ink/archives/541

以 Debian 11 为例,主要用于备忘。

plain 复制代码
deb https://mirrors.tuna.tsinghua.edu.cn/debian/ bullseye main contrib non-free
deb https://mirrors.tuna.tsinghua.edu.cn/debian/ bullseye-updates main contrib non-free
deb https://mirrors.tuna.tsinghua.edu.cn/debian-security bullseye-security main contrib non-free
shell 复制代码
apt update && apt install vim curl wget git cifs-utils -y

export DOWNLOAD_URL="https://mirrors.tuna.tsinghua.edu.cn/docker-ce"
curl -fsSL https://get.docker.com/ | sh

pip config set global.index-url https://pypi.tuna.tsinghua.edu.cn/simple

hostnamectl set-hostname your_host
hostname your_host
/etc/hosts

timedatectl set-timezone Asia/Shanghai

groupmod -g 3000 foo  # 添加用户组
adduser  # 添加用户
usermod -aG group_name user_name  # 将用户添加至组
相关推荐
凡人叶枫1 天前
Effective C++ 条款28:避免使用 handles 指向对象内部
linux·服务器·开发语言·c++·嵌入式开发
AI帮小忙1 天前
Debian系linux操作系统里安装OpenClaw
linux·运维·debian
极创信息1 天前
Linux挖矿病毒深度清理实战教程,从进程隐藏、Rootkit驻留到彻底根除
java·大数据·linux·运维·安全·tomcat·健康医疗
志栋智能1 天前
超自动化巡检剧本(Playbook):运维经验的数字化封装
运维·自动化
ElevenS_it1881 天前
Nginx日志监控告警实战:access_log解析+5xx突增+慢请求+异常IP自动告警完整方案(Filebeat+Zabbix)
运维·网络·tcp/ip·nginx·zabbix
weixin_307779131 天前
Python写入Shell文件使用Linux系统的换行符
linux·开发语言·python·自动化
liulilittle1 天前
Linux Swap 文件配置与持久化(虚拟内存)
linux·运维·服务器
未若君雅裁1 天前
日志采集与ELK:从本地日志到集中检索分析
运维·elk·jenkins
青梅橘子皮1 天前
Linux---进程控制(2)(进程程序替换)
linux·c++·算法
零陵上将军_xdr1 天前
从沙子到CPU——计算机硬件基础入门
linux·运维·硬件架构