zoukankan      html  css  js  c++  java
  • [转]centos6 与 7 其中的一些区别

    # vi /etc/ssh/sshd_config

       #将MaxAuthTries注释去掉

       MaxAuthTries 5(登录次数)

    UseDNS no   默认是yes 的,把这个改为no,可以大大减少认证的时间

    centos7

    yum装的服务器,或者自带的,启动命令有区别

    现在是   systemctl   sshd.serviec start

    centos6 是  service sshd  start

    修改语系有区别

    centos7:   vim   /etc/locale.conf

              LANG="en_US.UTF-8"

    centos6 :   vim  /etc/sysconfig/i18n

              LANG="en_US.UTF-8"

    cento7 开放防火墙端口

          firewall-cmd --zone=public --add-port=80/tcp --permanent

          --zone #作用域

          --add-port=80/tcp  #添加端口,格式为:端口/通讯协议

          --permanent  #永久生效,没有此参数重启后失效

          firewall-cmd --reload  重启防火墙生效

    centos6 

          永久生效话直接修改/etc/sysconfig/iptables

    修改名字

    centos7 :   vim /etc/hostname

    centos6:     vim /etc/sysconfig/network

    暂时改名直接hostname + name

    时间同步

    centos7   自带chrony,可以设置时间,vim /etc/chrony.conf

    centos6    vim  /etc/ntp.conf

    /etc/profile环境变量配置是否生效

    centos 6  可以

    centos 7  临时生效,现在需要修改/etc/bashrc

  • 相关阅读:
    数据链路层
    补码加减法
    matlab函数
    HDU2159_二维完全背包问题
    HDU2844买表——多重背包初探
    HDU1025贫富平衡
    最大m段子段和
    01背包浮点数情况
    第K大01背包
    HDU2955 01背包
  • 原文地址:https://www.cnblogs.com/horizonli/p/5525768.html
Copyright © 2011-2022 走看看