Debian10安装与配置电脑软件系统

印迹发布于:2019-11-29 1339

简介:

Debian 10 Buster 是 Debian 社区于 2019-07-06 推出的继 Debian 9 之后的下一代 Debian 系统。Buster 是 Debian 10 的系统代号。

下载:

https://www.debian.org/distrib/netinst

https://cdimage.debian.org/debian-cd/current-live/amd64/iso-hybrid/

安装

更新源:

从 Debian 的官网中发现可以使用清华源、国防科技大学的源,配置使用清华源。

source.list 中添加如下行:

 # tsinghua source
    deb https://mirrors.tuna.tsinghua.edu.cn/debian/ buster main contrib non-free
    deb-src https://mirrors.tuna.tsinghua.edu.cn/debian/ buster main contrib non-free
    deb https://mirrors.tuna.tsinghua.edu.cn/debian/ buster-updates main contrib non-free
    deb-src https://mirrors.tuna.tsinghua.edu.cn/debian/ buster-updates main contrib non-free
    deb https://mirrors.tuna.tsinghua.edu.cn/debian/ buster-backports main contrib non-free
    deb-src https://mirrors.tuna.tsinghua.edu.cn/debian/ buster-backports main contrib non-free
    deb https://mirrors.tuna.tsinghua.edu.cn/debian-security/ buster/updates main contrib non-free
    deb-src https://mirrors.tuna.tsinghua.edu.cn/debian-security/ buster/updates main contrib non-free

分区

根据喜好,可以手动设置分区:

引导目录 /boot——512M
根目录 /——80G
用户目录 /home——220G
交换空间 SWAP——6G

卸载自带Firefox

dpkg --get-selections | grep firefox
sudo apt-get purge firefox

卸载libreoffice

sudo apt-get remove --purge libreoffice*

若提示

vim ~/.zshrc

按i输入

setopt no_nomatch

按esc接着按:wq推出保存

source  ~/.zshrc

安装基本软件

sudo apt install curl
sudo apt install git
sudo apt install vim

改SSH服务端口

1.备份原sshd配置文件

cp /etc/ssh/sshd_config /etc/ssh/sshd_config.backup

2.修改sshd配置文件 可以使用winscp、nano、vim之类的软件编辑 vi /etc/ssh/sshd_config找到#port 22将前面的#去掉,修改端口 port 1234;

3.重启SSH服务器 重启SSH服务器命令:

systemctl restart sshd

4.防火墙、安全组规则设置 

安装网络管理工具

运行 ifconfig 发现找不到命令。直接以 ifconfig 为包名安装发现找不到这样的包。搜索发现这个命令包含在 net-tools 这个包中,安装这个包就可以使用了。

/etc/network/interfaces

配置界面字体

我的屏幕分辨率较高,显示的字非常小,我需要调整界面显示的字体。这可以通过在 【gnome-tweaks】 中配置来完成。Buster 中已经安装了这个程序,直接打开进行配置即可。

Debian系统时间问题

在linux中与时间相关的文件有

 /etc/localtime
 /etc/timezone

其中,/etc/localtime是用来描述本机时间,而 /etc/timezone是用来描述本机所属的时区。

修改本机时间

cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime

   在/usr/share/zoneinfo下存放着不同时区格式的时间文件,执行以下命令,可以将本机时间调整至目标时区的时间格式。但是调整了时间格式,本机所属的时区是保持不变的!

修改本机时区

在linux中,有一些程序会自己计算时间,不会直接采用带有时区的本机时间格式,会根据UTC时间和本机所属的时区等计算出当前的时间。比如jdk应用,时区为“Etc/UTC”,本机时间改为北京时间,通过java代码中new 出来的时间还是utc时间,所以必须得修正本机的时区。

echo 'Asia/Shanghai' >/etc/timezone

其它处理方法

rm -f /etc/localtime
ln -s /usr/share/zoneinfo/Asia/Shanghai /etc/localtime



http://www.virplus.com/thread-373.htm
转载请注明:2019-11-29 于 VirPlus 发表

推荐阅读
最新回复 (0)

    ( 登录 ) 后,可以发表评论!

    返回