NFS trouble on Centos
On both Linodes, I've installed NFS + Port Mapper.
On Linode X, I have following on my /etc/exports:
/path/to/shared/directory ip-linodeY(ro)
Oddly, doing
/usr/sbin/showmount –exports just hangs
however doing this
/usr/sbin/showmount --exports 127.0.0.1
displays:
Export list for 127.0.0.1:
/path/to/shared/directory ip-linodeY(ro)
So, am I right to assume that it's exported fine (subject to firewall allowing access ?)
On Linode Y, I try this:
mount ip-linodeX:/path/to/shared/directory /mnt/share
and I get :
mount: wrong fs type, bad option, bad superblock on
ip-linodeX:/path/to/shared/directory
If I try:
mount -t ext3 ip-linodeX:/path/to/shared/directory /mnt/share
I get:
mount: special device ip-linodeX:/path/to/shared/directory
does not exist.
For the purpose of this exercise I've stopped iptables on both machines.
What am I doing wrong ?
5 Replies
Follow these directions, except perhaps disable SELinux in order to eliminate some complication.
@wtogami:
Have you tried switching from the Linode kernel to the official CentOS kernel?
Thankyou for taking time to answer my query, unfortunately following those instructions didn't work.
The commands executed fine, but after changing the kernel to pv-grub-x84_64 it wouldn't boot, I get:
****Booting 'CentOS (2.6.18-194.26.1.el5xen)'
root (hd0)
Filesystem type is ext2fs, using whole disk
kernel /boot/vmlinuz-2.6.18-194.26.1.el5xen root=/dev/xvda
Error 15: File not found****
Switching back to Stable 2.6.18 and it boots fine. I tried it with and without Xenify + Automount options
Debugging the error in my previous post I noticed that instead of /boot/vmlinuz-2.6.18-194.26.1.el5xen being in my /boot directory I had vmlinuz-2.6.18-238.1.1.1.el5xen (same goes for the initrd references)
So incase that may fix it, I changed the references in grub.conf a menu.1st and now it won't boot at all.
This seems awfully convoluted to get what I thought was quite a simple feature such as NFS working.
Next you need to look at the logs on the server; if you're exporting to hostnames then the entry must match EXACTLY what the IP address resolves to on the host. A mismatch will show. Since linode IPs are relatively static (only if you change datacenter would they change) you may be safer to export to the IP address.