4

我是 Lustre 文件系统的新手,我希望在 Ubuntu 12.10 上安装它,Lustre 网站上没有相关信息。

是否有可能以及如何在 Ubuntu 中安装 Lustre?

4

1 回答 1

3

Lustre是一个透明的全局文件系统,客户端可以透明地访问集群文件系统的数据,而不必知道数据的实际存储位置。客户端通过网络读取服务器上的数据,存储服务器负责实际的文件系统读写操作。Lustre 文件作为由元数据服务器定位的对象,元数据服务器将实际的文件 I/O 请求引导到存储服务器,存储服务器管理基于对象的物理存储在磁盘组上。

由于元数据和存储数据相分离技术可以完全分离计算和存储资源,从而使客户端计算机可以专注于用户和应用程序的请求。

luster 的文章很多,但是很少有关于ubuntu 的文章,因为luster 编译器的安装确实够麻烦,但只要看懂了,也就无所谓了!

mds: 192.168.6.6
ost1: 192.168.6.119
ost2: 192.168.6.137
client: 192.168.6.137 because the resource problem, I put in ost2 client machines operate.

在mds内核中 下载一个linux-2.6.22内核,因为lustre-1.6.5最高支持linux-2.6.22

apt-get install quilt linux-patch-lustre libncurses5-dev module-assistant dpatch lustre-utils
shell $> cd / usr / src
shell $> ls
kernel-patches linux-2.6.22.tar.bz2
shell $> tar jxvf linux-2.6.22.tar.bz2
shell $> cd linux-2.6.22
shell $> ln-s / usr/src/kernel-patches/lustre/series/2.6.22-vanilla.series series
shell $> ln-s / usr / src / kernel-patches / lustre / patches / patches
shell $> quilt setup series-d patches
# Patch for the kernel to fight lustre
shell $> quilt push-av
shell $> quilt refresh
shell $> make clean
shell $> make mrproper
shell $> cp / boot/config-2.6.27.7-server. config
shell $> make menuconfig
# Compile the kernel , I believe we all know what they need , and here I will use the default does not make any changes !
shell $> make-kpkg - added-patches = lustre - initrd - append-to-version "-lustre" - revisionn ludy.1 kernel_image
# version and revision followed by the version number !
shell $> dpkg-i linux-image-2.6.22-lustre_2.6.22-lustre-ludy.1_amd64.deb
shell $> reboot
# From the start after the selection of the newly compiled kernel
shell $> uname-r
2.6.22-lustre
shell $> m-a auto-install lustre
# Install kernel module containing lustre
# After a long wait finally finished compiling !

将 lustre-modules-2.6.22-lustre_1.6.5_amd64.deb linux-image-2.6.22-lustre_2.6.22-lustre-ludy.1_amd64.deb 复制到客户端机器上,两个ost都选择安装内核2.6。 22进系统!

去测试:

1.修改三台服务器/etc/hosts    

192.168.6.6 mds
192.168.6.119 ost
192.168.6.137 cls

2.在md server中执行以下动作

modprobe lustre
modprobe ldiskfs
modprobe lnet 'network = "tcp0 (eth0)"'
mkfs.lustre - reformat - fsname = testfs - mdt - mgs / dev/sda5
# If the hard disk is not formatted , or there are data , then need to add - reformat parameter formatting !
mkdir-p / opt / mds
mount-t lustre / dev/sda5 / opt / mds

3.对两个ost做如下动作

modprobe lustre
modprobe ldiskfs
modprobe lnet 'network = "tcp0 (eth0)"'
mkfs.lustre - fsname = testfs - ost - mgsnode = mds @ tcp0 / dev/sdb1
# Similarly, if sdb1 is not formatted or the data must be added - reformat parameters
mount-t lustre / dev/sdb1 / opt

4.在客户端服务器实现(即ost2)

mount-t lustre mds @ tcp0 :/ testfs / mnt
Good three servers have even made it !
We have a large file tests to establish

5.在客户端服务器实现

 dd if = / dev / zero of = test1 bs = 1024 count = 40000
    40000 +0 records in
    40000 +0 records out
    40960000 bytes (41 MB) copied, 2.85257 s, 14.4 MB / s

在 ost1 服务器执行 df -lh 查看

/ dev/sdb1 1004M 57M 897M 6% / opt

在 ost2 服务器执行 df -lh 查看

/ dev/sdb1 1004M 17M 897M 2% / opt

显然 ost1 写入了 40M 的数据 ost2 现在在第二次执行

dd if = / dev / zero of = test2 bs = 1024 count = 40000
40000 +0 records in
40000 +0 records out
40960000 bytes (41 MB) copied, 4.66784 s, 8.8 MB / s

在 ost1 服务器执行 df -lh 查看

/ dev/sdb1 1004M 57M 897M 6% / opt

没有变化 在 ost2 服务器执行 df -lh 查看

/ dev/sdb1 1004M 57M 897M 6% / opt
ost2 data is written to the 40M !

6.停止光泽文件系统

umount-f / opt

我对光泽作品做了一点简单的解释!

mds可能是存放元数据的地方 文件列表也是一样的东西,他知道服务器上存放的文件,其中台ost文件存放在服务器上

我只是不能研究光泽准确地说什么。希望高手多多指教!

注意:启动mds ost 后跳过mkfs.lustre 不是新创建的文件系统 只需要mount -t luster 挂在文件系统中即可!本帮助来自“linuxer”博客

你也可以试试这个光泽客户端 ubuntu ......这里..

于 2013-11-04T08:58:13.457 回答