1.2 node2基本配置&新建磁盘
1.2.1查看系统信息,同步时间
2.6.18-164.el5 #1 SMP Tue Aug 18 15:51:54 EDT 2009
[root@node2 ~]# cat /etc/RedHat-release
Red Hat Enterprise Linux Server release 5.4 (Tikanga)
1.2.2查看主机名称,修改查看ip地址
[root@node2 ~]# cat /etc/sysconfig/network

[root@node2 ~]# service network restart
Shutting down loopback interface: [ OK ]
Bringing up loopback interface: [ OK ]
[root@node2 ~]# ifconfig eth0
eth0 Link encap:Ethernet HWaddr 00:0C:29:D1:D4:32
inet addr:192.168.101.212 Bcast:192.168.101.255 Mask:255.255.255.0
1.2.3配置/etc/hosts文件(就不用dns了)
[root@node2 ~]# echo "192.168.101.211 node1.junjie.com node1" >>/etc/hosts
[root@node2 ~]# echo "192.168.101.212 node2.junjie.com node2" >>/etc/hosts
1.2.4构建一个新的磁盘空间有利于实现DRBD技术
Disk /dev/sda: 21.4 GB, 21474836480 bytes
255 heads, 63 sectors/track, 2610 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/sda1 * 1 13 104391 83 Linux
/dev/sda2 14 1318 10482412+ 83 Linux
/dev/sda3 1319 1579 2096482+ 82 Linux swap / Solaris
Disk /dev/sda: 21.4 GB, 21474836480 bytes
255 heads, 63 sectors/track, 2610 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/sda1 * 1 13 104391 83 Linux
/dev/sda2 14 1318 10482412+ 83 Linux
/dev/sda3 1319 1579 2096482+ 82 Linux swap / Solaris
/dev/sda4 1580 1702 987997+ 83 Linux
[root@node2 ~]# cat /proc/partitions
major minor #blocks name
8 0 20971520 sda
8 1 104391 sda1
8 2 10482412 sda2
8 3 2096482 sda3
8 4 987997 sda4
1.3 在node1和node2上配置ssh密钥信息,
1.3.1 在node1上配置ssh密钥信息
[root@node1 ~]# ssh-keygen -t rsa
[root@node1 ~]# ssh-copy-id -i .ssh/id_rsa.pub root@node2.junjie.com
1.3.2 在node2上配置ssh密钥信息
[root@node2 ~]# ssh-copy-id -i .ssh/id_rsa.pub root@node2.junjie.com
