GlusterFS文件系统2

之前我们看了gluster的五种卷标模式,今天也做了两次扩展测试:

1、类似raid10的扩展:
QQ图片20140722162505

# gluster volume create rs stripe 2 replica 2 transport tcp 192.168.1.63:/data/rs1/ 192.168.1.64:/data/rs3/ 192.168.1.66:/data/rs2/ 192.168.1.244:/data/rs4/
volume create: rs: success: please start the volume to access data
# gluster volume start rs
volume start: rs: success
# gluster volume info rs
 
Volume Name: rs
Type: Striped-Replicate
Volume ID: ddf05998-2ee2-4085-9161-d21ee5c82c34
Status: Started
Number of Bricks: 1 x 2 x 2 = 4
Transport-type: tcp
Bricks:
Brick1: 192.168.1.63:/data/rs1
Brick2: 192.168.1.64:/data/rs3
Brick3: 192.168.1.66:/data/rs2
Brick4: 192.168.1.244:/data/rs4

客户端挂载:

# mount -t glusterfs 192.168.1.63:rs /data/sr/
[root@YQD-Intranet-Web-SR1 data]# df -h
Filesystem            Size  Used Avail Use% Mounted on
/dev/sda2              20G  1.5G   17G   9% /
tmpfs                 1.9G     0  1.9G   0% /dev/shm
/dev/sda1             194M   27M  158M  15% /boot
/dev/mapper/vg_web-LogVol00
                      251G   13G  226G   6% /data
/dev/sda3              20G  710M   18G   4% /home
192.168.1.63:rs       683G   63G  586G  10% /data/sr

上传数据测试(CentOS-6.4-x86_64-minimal.iso):

[root@YQD-Intranet-Web-SR1 sr]# ll -h
total 343M
-rw-r--r-- 1 root root 343M Nov  6  2013 CentOS-6.4-x86_64-minimal.iso
四台服务器的目录:
[root@YQD-Intranet-DB-NO1 data]# ll -h rs2/
total 172M
-rw-r--r-- 2 root root 172M Nov  6  2013 CentOS-6.4-x86_64-minimal.iso
[root@YQD-Intranet-DB-NO2 data]# ll -h rs3/
total 172M
-rw-r--r-- 2 root root 172M Nov  6  2013 CentOS-6.4-x86_64-minimal.iso
[root@YQD-Intranet-DB-NO3 data]# ll -h rs4/
total 172M
-rw-r--r-- 2 root root 172M Nov  6  2013 CentOS-6.4-x86_64-minimal.iso
[root@YQD-intranet-salt-master data]# ll -h rs1/
total 172M
-rw-r--r-- 2 root root 172M Nov  6  2013 CentOS-6.4-x86_64-minimal.iso

2、Distributed Striped Replicated 卷标
QQ图片20140722163928

# gluster volume create dsr stripe 2 replica 2 transport tcp 192.168.1.63:/data/exp1/ 192.168.1.66:/data/exp3/ 192.168.1.63:/data/exp2/ 192.168.1.66:/data/exp4/ 192.168.1.64:/data/exp5/ 192.168.1.244:/data/exp7/ 192.168.1.64:/data/exp6/ 192.168.1.244:/data/exp8
volume create: dsr: success: please start the volume to access data
# gluster volume start dsr
......
# gluster volume info dsr
 
Volume Name: dsr
Type: Distributed-Striped-Replicate
Volume ID: 4b4d6f5e-a440-4bca-83d3-2a21305ac125
Status: Created
Number of Bricks: 2 x 2 x 2 = 8
Transport-type: tcp
Bricks:
Brick1: 192.168.1.63:/data/exp1
Brick2: 192.168.1.66:/data/exp3
Brick3: 192.168.1.63:/data/exp2
Brick4: 192.168.1.66:/data/exp4
Brick5: 192.168.1.64:/data/exp5
Brick6: 192.168.1.244:/data/exp7
Brick7: 192.168.1.64:/data/exp6
Brick8: 192.168.1.244:/data/exp8

客户端挂载后,分区情况;

[root@YQD-Intranet-Web-SR1 data]# df -h
Filesystem            Size  Used Avail Use% Mounted on
/dev/sda2              20G  1.5G   17G   9% /
tmpfs                 1.9G     0  1.9G   0% /dev/shm
/dev/sda1             194M   27M  158M  15% /boot
/dev/mapper/vg_web-LogVol00
                      251G   13G  226G   6% /data
/dev/sda3              20G  710M   18G   4% /home
192.168.1.63:dsr      1.4T  124G  1.2T  10% /data/dsr

上传数据测试:

客户端:
[root@YQD-Intranet-Web-SR1 dsr]# ll -h
total 343M
-rw-r--r-- 1 root root 343M Nov  6  2013 CentOS-6.4-x86_64-minimal.iso
四台服务器:
[root@YQD-intranet-salt-master data]# ll -h exp1/
total 0
[root@YQD-intranet-salt-master data]# ll -h exp2/
total 0
[root@YQD-Intranet-DB-NO1 data]# ll -h exp3/
total 0
[root@YQD-Intranet-DB-NO1 data]# ll -h exp4/
total 0
[root@YQD-Intranet-DB-NO2 data]# ll -h exp5/
total 172M
-rw-r--r-- 2 root root 172M Nov  6  2013 CentOS-6.4-x86_64-minimal.iso
[root@YQD-Intranet-DB-NO2 data]# ll -h exp6/
total 172M
-rw-r--r-- 2 root root 172M Nov  6  2013 CentOS-6.4-x86_64-minimal.iso
[root@YQD-Intranet-DB-NO3 data]# ll -h exp7/
total 172M
-rw-r--r-- 2 root root 172M Nov  6  2013 CentOS-6.4-x86_64-minimal.iso
[root@YQD-Intranet-DB-NO3 data]# ll -h exp8/
total 172M
-rw-r--r-- 2 root root 172M Nov  6  2013 CentOS-6.4-x86_64-minimal.iso

还没有评论,快来抢沙发!

发表评论

  • 😉
  • 😐
  • 😡
  • 😈
  • 🙂
  • 😯
  • 🙁
  • 🙄
  • 😛
  • 😳
  • 😮
  • emoji-mrgree
  • 😆
  • 💡
  • 😀
  • 👿
  • 😥
  • 😎
  • ➡
  • 😕
  • ❓
  • ❗
  • 67 queries in 0.407 seconds