Centos7日常使用点滴

Centos7点滴

1、Centos7修改默认时区为北京时间

同步时间

$>yum install -y ntpdate
$>ntpdate -u cn.pool.ntp.org

设置中国时区

$>timedatectl set-timezone Asia/Shanghai

2、让命令行提示符显式完整路径

$>vi /etc/profile

export PS1='[\u@\h `pwd`]\$'

$>source /etc/profile

3、修改主机名

$>hostnamectl set-hostname gyg

猜你喜欢

转载自www.cnblogs.com/guyuangang/p/13396805.html