Linux Study Notes Chapter 2

1. View the whole process of baidu.com domain name resolution:

   dig @8.8.8.8 www.baidu.com +trace (nslookup, host can also)

2. Add virtual IP and VIP:

  ip addr add 172.16.1.234 dev eth0:1

  /etc/sysconfig/network-scripts/ifcfg-eth0:1 (permanent)

3. Check the occupancy of port 22:

  lsof -i tcp:22      &       netstat -antup|grep 22

4. Check whether the web service port is normal:

  telnet www.qq.com 80         &  nmap www.qq.com -p 80

5. Add a route to segment 4:

    route add -net 172.16.4.1 mask 255.255.255.0 gw 172.16.1.1 dev eth0

-----------------disk partition-----------------------

1. Enterprise partition scheme:

  /boot   200m

  1.5 times the swap memory, up to 8G

  / rest all

2. File system selection:

  Lots of small files (under 100k): reiserfs

  centots6: ext4

  centos7:   xfs

 

3. Parted partitions for disks larger than 2T:
    parted /dev/sdb mklabel gpt yes (initialize partition table)

   parted /dev/sdb mkpart primary ext4 0GB 1000GB ignore (divide a 1000G ext4 partition)

   parted /dev/sdb mkpart primary ext4 1001GB 2000GB ignore (dividing a 1000G ext4 partition)

   parted /dev/sdb mkpart primary linux-swap 2001GB 2050GB ignore (in dividing a 50G swap partition)

   parted /dev/sdb p (view)

 

3. Parted partitions for disks larger than 2T: parted /dev/sdb mklabel gpt yes (initialize the partition table)

Guess you like

Origin http://10.200.1.11:23101/article/api/json?id=326566596&siteId=291194637