6,534
edits
Changes
NFS
,→Prepare the HN
This page describes how to mount use '''NFS partition client''' inside VEa container.
You will need the following software:
# [http://openvz.org/download/utils#vzctl vzctl] version 3.0.13 or higher (do <code>vzctl --version</code>)# [http://openvz.org/download/kernel/ kernel] version 2.6.18-028test006 or higher (2.6.18-028stab* will do), or any recent RHEL5-based or 2.6.20-based kernel.
Note: In all the kernels earlier than 028stab038, kernel NFS support can be given to a VE container by setting:
sunrpc.ve_allow_rpc = 1
This can be done by adding the above lines into /etc/sysctl.conf on the hardware node, and then running <code>sysctl -p</code>.
# modprobe nfs You will probably want the nfs module to load automatically on reboots. One way to do this is to put the modprobe command in your /etc/rc.d/rc.local file: modprobe nfs Alternatively, you can add a new line with <code>nfs<pre/code>to your /etc/modules or /etc/modules.conf file. === Prepare the container ===# modprobe To allow a container to use NFS filesystem, you will need to start it with "nfs" feature enabled. If the container is running while you set the <code>--features nfs:on</precode>, you will need to reboot it.
After this you may see nfs in <code>/proc/filesystems</code>
</pre>
<pre>
# vzctl enter 100
</pre>
For more details on how to setup NFS mount , see [http://nfs.sourceforge.net/nfs-howto/ar01s04.htm html NFS-client HOWTO] == Known issues ==* There are quite a few parameters in NFS, so sometimes it doesn't work due to misconfiguration. We've created a separate page describing such situations: [[NFS doesn't work]].* Package nfs-common can not be installed. Make sure you start <code>portmap</code> before trying to install nfs-common.** For Ubuntu/Debian OpenVZ containers, the <code>portmap/rpcbind</code> service may not start automatically. However, you can enable it by editing the <code>/etc/default/nfs-common</code> configuration file.
=== Known issues =See also ==There are quite a few parameters in NFS, so sometimes it doesn't work due to misconfiguration* [http://nfs.sourceforge.net/nfs-howto/ar01s04. We created a separatepage for discribing such situation: [[ html NFS doesn't work ]-client HOWTO]
[[Category: HOWTO]]