connection refused while trying to mount nfs
Andrew Henderson
Nothing I've googled out helped me yet including questions asked here.
While issuing :
mount -t nfs -o proto=tcp,port=2049 192.168.243.148:/home/nfs/ /mnt/nfsI've got response
mount: mounting 192.168.243.148:/home/nfs/ on /mnt/nfs failed: Connection refusedconfigs I'm currently running are listed below
/etc/export :
/home/nfs/ 192.168.243.0/24(rw,sync,fsid=0,anonuid=0,no_root_squash,subtree_check) rpcinfo -p
program vers proto port service 100000 4 tcp 111 portmapper 100000 3 tcp 111 portmapper 100000 2 tcp 111 portmapper 100000 4 udp 111 portmapper 100000 3 udp 111 portmapper 100000 2 udp 111 portmapper 100003 2 tcp 2049 nfs 100003 3 tcp 2049 nfs 100003 4 tcp 2049 nfs 100227 2 tcp 2049 100227 3 tcp 2049 100003 2 udp 2049 nfs 100003 3 udp 2049 nfs 100003 4 udp 2049 nfs 100227 2 udp 2049 100227 3 udp 2049 100005 1 udp 56039 mountd 100005 1 tcp 50063 mountd 100005 2 udp 34246 mountd 100005 2 tcp 59882 mountd 100005 3 udp 49752 mountd 100005 3 tcp 49991 mountdshowmount -e
Export list for mkoz-10320:
/home/nfs 192.168.243.0/24iptables -L -n
Chain INPUT (policy ACCEPT)
target prot opt source destination
ACCEPT udp -- 192.168.243.0/24 0.0.0.0/0 ctstate NEW,RELATED,ESTABLISHED udp dpt:111
ACCEPT udp -- 192.168.243.0/24 0.0.0.0/0 ctstate NEW,RELATED,ESTABLISHED udp dpt:111
ACCEPT tcp -- 192.168.243.0/24 0.0.0.0/0 ctstate NEW,RELATED,ESTABLISHED tcp dpt:111
ACCEPT tcp -- 192.168.243.0/24 0.0.0.0/0 ctstate NEW,RELATED,ESTABLISHED tcp dpt:2049
ACCEPT udp -- 192.168.243.0/24 0.0.0.0/0 ctstate NEW,RELATED,ESTABLISHED udp dpt:2049I've disabled ufw. Not sure what else I can do. I'm running Ubuntu 14.04. I don't have any problem mounting nfs on machine running nfs server.
21 Answer
i tried centos 7 for me also got this same connection refused problem..
dont worry just run rpcinfo -p it shows some tcp and udp ports you should
allow all this ports into your system firewall and retry it will works...