1.1apt-get
apt-getinstall apache2 #安装apache
设置apt-get本地源
http://www.upantool.com/sense/2014/4679_4.html
1.2Networking
@H_404_10@Ubuntu
Centos
vim /etc/hosts
vi /etc/hosts
vim /etc/network/interfaces
auto eth0 #设置自动启动eth0接口
iface eth0 inet static #配置静态IP
address xxx.xxx.xxx.xxx #IP地址
netmask xxx.xxx.xxx.xxx #子网掩码
gateway xxx.xxx.xxx.xxx #网关
auto enp0s3
iface enp0s3 inet dhcp
vi /etc/sysconfig/network-scripts/ifcfg-eth0
sudo vim /etc/resolv.conf
search localdomain
nameserver 172.16.3.4 希望修改成的DNS
nameserver 172.16.3.3 希望修改成的DNS
vi /etc/resolv.conf
/etc/init.d/networking restart
sudo /etc/init.d/resolvconf restart
service networking restart
service network restart
ifconfig
ifconfig
1.3开机自执行
@H_404_10@Ubuntu
Centos
vim /etc/rc.d/rc.local
chkconfig --add xxx
chkconfig --level 345 xxx on
1.4首次安装开启root用户
sudopasswd root
su -root
vi/etc/ssh/sshd_config
#PermitRootLoginprohibit-password
PermitRootLogin yes
servicessh restart
1.5查看glibc版本
ldd--version (或getconf GNU_LIBC_VERSION)