前言:
今天你们对“centos65设置时区”大体比较讲究,同学们都需要知道一些“centos65设置时区”的相关内容。那么小编在网络上汇集了一些关于“centos65设置时区””的相关文章,希望同学们能喜欢,同学们一起来了解一下吧!关闭防火墙与selinux
```shell
systemctl stop firewalld
systemctl disable firewalld
setenforce 0
sed -i 's/SELINUX=enforcing/SELINUX=disabled/g' /etc/sysconfig/selinux
```
##
## 配置history时间戳
```shell
echo 'HISTTIMEFORMAT="%F %T "' >> /etc/profile && source /etc/profile
```
## 配置时区
```shell
localectl set-locale LANG=zh_CN.UTF8
localectl set-locale LANG=en_US.UTF8
CentOS7 更改时区:
ln -sf /usr/share/zoneinfo/Asia/Shanghai /etc/localtime
```
## 配置公共DNS
```shell
echo "nameserver 119.29.29.29" > /etc/resolv.conf
echo "nameserver 114.114.114.114" >> /etc/resolv.conf
```
标签: #centos65设置时区