当前时区为 UTC + 8 小时



发表新帖 回复这个主题  [ 1 篇帖子 ] 
作者 内容
1 楼 
 文章标题 : [讨论]nfsv4_pnfs_using_spnfsd_and_nfsv4_as_back-end
帖子发表于 : 2008-07-25 14:39 

注册: 2008-07-25 14:31
帖子: 1
送出感谢: 0 次
接收感谢: 0 次
有没有人试试?NFSv4.1中的pNFS中的一种简单实现。
https://www.os3.nl/2007-2008/students/thijs_stuurman/nfsv4_pnfs_using_spnfsd_and_nfsv4_as_back-end

spNFS (Simple Parallel Network File System, by NetApp) is a Linux pNFS server implementation from NetApp who use it to develop their pNFS client. Currently it is the only working Linux implementation using the latest code. More information can be found in their presentation: dmuntz-spnfs-cthon08.pdf

The setup in a virtualized environment (Xen) looks as follows:

The client uses pNFS with a file layout driver to mount an export from the MDS (Metadata server). The MDS uses a single physical connection to mount NFSv4 exports on the DSs (Data servers). When data from the client is written to the export, pNFS is used to stripe the data over the DSs without tranferring data through the MDS. Retrieving data works the same way. For example of a file of 230M, each DS in this setup stores 115M. Retrieving data uses both DSs network connections as well to retrieve the data.

The picture is just an abstract view of the situation, it could be that the pNFS client has for example a single very fast physical network connection such as 10G Ethernet which a regular NFS setup is unable to fully utilize. With pNFS the data comes from multiple servers at once.

Some personal notes from setting up spNFS:

% spNFS:
代码:
      apt-get install cogito git-core
      git clone git://linux-nfs.org/~dmuntz/spnfs.git
      git clone git://linux-nfs.org/~dmuntz/nfs-utils.git


spNFS:

代码:
      make menuconfig
      -.config
              CONFIG_NETWORK_FILESYSTEMS=y
              CONFIG_NFS_FS=y
              CONFIG_NFSD=y
              CONFIG_NFS_V4_1=y
              CONFIG_NFSD_V4_1=y
              CONFIG_PNFS=y
              CONFIG_PNFSD=y
              CONFIG_SPNFS=y


代码:
      make
      make modules
      make modules_install
      make install


1.
→ /boot/

mkinitrd -o mkinitrd -o initrd.img-2.6.25-pnfs 2.6.25-pnfs

代码:
name    /lib/modules/2.6.25-pnfs ...
    edit /boot/grub/menu.lst


*
GRUB is installed. To automatically switch to new kernels, point your
*
default entry in menu.lst to /boot/vmlinuz-2.6.25-pnfs

%nfs-utils:

代码:
apt-get install automake libtool pkg-config
export PKG_CONFIG_PATH=/usr/lib/pkgconfig
sh autogen.sh
./configure --disable-gss (avoid dependency problems, not required for this setup anyway)
make

*do NOT install

%%% Setting things up:

On MDS:

代码:
cp /root/sPNFS/nfs-utils/utils/spnfsd/spnfsd.conf /etc/


Reconfigure for two DSs:

代码:
"""
[General]
Verbosity = 1
Stripe-size = 8192
Dense-striping = 0
Pipefs-Directory = /var/lib/nfs/rpc_pipefs
DS-Mount-Directory = /spnfs
[DataServers]
NumDS = 2
DS1_IP = 145.100.106.107
DS1_PORT = 2049
DS1_ROOT = /pnfs
DS1_ID = 1
DS2_IP = 145.100.106.108
DS2_PORT = 2049
DS2_ROOT = /pnfs
DS2_ID = 2
"""

代码:
MD:  mkdir -m 1777 /spnfs
DSs: mkdir -m 1777 /pnfs
     mkdir /pnfs/145.100.106.107
     mkdir /pnfs/145.100.106.108


On the MD, the /spnfs will contain mount points (IP address as dir) to all DSs. The root is /pnfs thus on the DSs we export the /:

etc/exports
代码:
 / *(rw,fsid=0,insecure,no_root_squash,sync,no_subtree_check)


DSs mounts on MDS:

etc/fstab
代码:
 # spNFS DS mounts
       145.100.106.107:/pnfs /spnfs/145.100.106.107 nfs    defaults        1 2
       145.100.106.108:/pnfs /spnfs/145.100.106.108 nfs    defaults        1 2

/etc/exports
代码:
 / *(rw,fsid=0,insecure,no_root_squash,sync,no_subtree_check)


On MDS and DSs:

代码:
/usr/sbin/rpc.statd
/usr/sbin/rpc.mountd
/usr/sbin/rpc.nfsd 8
exportfs -vr


on MDS, start spnfsd:
代码:
"""
debian02:/usr/sbin# spnfsd
Verbosity: 1
Stripe size: 8192
Dense striping: 0
Number of data servers: 2
DS1 IP: 145.100.106.107
DS1 PORT: 2049
DS1 ROOT: /pnfs
DS1 DSID: 1
DS2 IP: 145.100.106.108
DS2 PORT: 2049
DS2 ROOT: /pnfs
DS2 DSID: 2
"""


** be sure to mount the /pnfs/145….. 's on the MDS

on client, load layout driver:

代码:
modprobe nfslayoutdriver


mount:

代码:
mount -t nfs4 145.100.106.106:/ /mnt


附件:
文件注释: a virtualized environment (Xen)
spnfs_diagram.jpg
spnfs_diagram.jpg [ 17.36 KiB | 被浏览 822 次 ]

页首
 用户资料  
 
显示帖子 :  排序  
发表新帖 回复这个主题  [ 1 篇帖子 ] 

当前时区为 UTC + 8 小时


在线用户

正在浏览此版面的用户:没有注册用户 和 4 位游客


不能 在这个版面发表主题
不能 在这个版面回复主题
不能 在这个版面编辑帖子
不能 在这个版面删除帖子
不能 在这个版面提交附件

前往 :  
本站点为公益性站点,用于推广开源自由软件,由 DiaHosting VPSBudgetVM VPS 提供服务。
我们认为:软件应可免费取得,软件工具在各种语言环境下皆可使用,且不会有任何功能上的差异;
人们应有定制和修改软件的自由,且方式不受限制,只要他们自认为合适。

Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
简体中文语系由 王笑宇 翻译