Solved

enabling nfs rpc.mountd rpc.quotad on RHES Linux & permit them to be mounted on one NIC port

Posted on 2011-09-15
6
370 Views
Last Modified: 2012-05-12

I have an RHES 5.x box but seems like it may have been hardened because
"service nfslockd start" or "service nfs start" just hang there.

I know & have set up /etc/exports (to permit which server to mount it).
Now I need the steps to bring up nfs daemon on this RHES 5.x box so
that other servers could mount it.

Also, let me know how I can ensure the NFS service is listening to a
specific LAN / NIC port only (ie can only be mounted via this NIC port)
0
Comment
Question by:sunhux
6 Comments
 
LVL 39

Assisted Solution

by:noci
noci earned 130 total points
ID: 36547677
For the specific port , just allow the rpc protocol (SUNRPC, port 111 tcp & udp)  on the specified interface.

Did you also enable the portmapper? Any message in /var/log/* regarding nfslockd & rpc.bind?
0
 
LVL 20

Assisted Solution

by:Daniel McAllister
Daniel McAllister earned 200 total points
ID: 36552230
Hmmm... you've decided to to implement NFS at an odd time... specifically, when we're in the middle of upgrading from NFSv3 & the newer NFSv4.
If you want to read about it (high level, not too techie] try here HERE

Believe it or not, but I have found that, in general, the CentOS documentation and howto collections are superior to RedHat's -- even though CentOS is basically exploiting the GPL and re-releasing RHEL with different branding. (At least in the open-source market vendors tell the truth - usually - when the beg, borrow, or steal from someone else!)

So... here's another link to help you get your NFS running HERE

In closing, at first glance, I'd say that it appears you're trying to start NFSv3 and that you haven't started the portmapper service, so when the NFS daemons try to register, there is no answering portmapper service. The NFSv3 reliance on the portmapper is both a strength and a weakness... regardless, it is what it is and you have to run the portmapper (it listens on the port 111 that noci referred to above).

Good Luck!

Dan
IT4SOHO

PS: I'll say just this on the suitability of NFS:
 - If you're only using it on the LAN, use NFSv3 -- it's less secure and less optimal in performance, but FAR easier to get setup and running and over LAN circuits, should meet all but the most strenuous criteria.
 - If you're using NFS over the Internet, definitely go for the NFSv4 -- it's far more stable and secure. The tradeoff is that the added security makes implementation and administration harder.

0
 
LVL 2

Accepted Solution

by:
ind_selva earned 170 total points
ID: 36555890
To make sure the proper nfs RPC-based services enabled for portmap issue this command

rpcinfo -p
showmount -e localhost - it shows nfs shares. on local system
showmount -e remotepc - it shows nfs share from the remotepc
0
Windows Server 2016: All you need to know

Learn about Hyper-V features that increase functionality and usability of Microsoft Windows Server 2016. Also, throughout this eBook, you’ll find some basic PowerShell examples that will help you leverage the scripts in your environments!

 

Author Comment

by:sunhux
ID: 36585897

# rpcinfo -p
rpcinfo: can't contact portmapper: RPC: Remote system error - Connection refused

#/etc/init.d/portmap start
Starting portmap:                                          [  OK  ]
# rpcinfo -p
   program vers proto   port
    100000    2   tcp    111  portmapper
    100000    2   udp    111  portmapper


# service nfs start
Starting NFS services:                                     [  OK  ]
Starting NFS quotas:                                       [  OK  ]
Starting NFS daemon:                                       [  OK  ]
Starting NFS mountd:                                       [  OK  ]
Starting RPC idmapd:                                       [  OK  ]


I've also set the required remote nfs clients that need to be
able to mount in /etc/exports

So is that all I have to do & my NFS server is ready to serve?
0
 

Author Comment

by:sunhux
ID: 36585948

Think I'm still missing something as "exportfs" returned nothing :

[root@localhost ~]# exportfs
[root@localhost ~]#
[root@localhost ~]# cat /etc/exports
/exports/nfs_export1    192.168.0.254(rw,insecure,no_root_squash,async)
/VolGroup00/test_nfs    192.168.0.10(rw,insecure,no_root_squash,async)
/VolGroup00/Nfs_lv2     192.168.0.10(rw,insecure,no_root_squash,async)
/VolGroup00/local-storage1      192.168.0.254(rw,insecure,no_root_squash,async)
[root@localhost ~]# df
Filesystem           1K-blocks      Used Available Use% Mounted on
/dev/mapper/VolGroup00-LogVol00
                      29741864   4734832  23471852  17% /
/dev/cciss/c0d0p1       101086     12024     83843  13% /boot
tmpfs                  2043604         0   2043604   0% /dev/shm
/dev/mapper/VolGroup00-test_nfs
                      10095152   1824980   7757356  20% /VolGroup00/test_nfs
/dev/mapper/VolGroup00-Nfs_lv2
                      10095152   1051376   8530960  11% /VolGroup00/Nfs_lv2
/dev/mapper/VolGroup00-local--storage1
                      10095152    153760   9428576   2% /VolGroup00/local-storage1
0
 

Author Closing Comment

by:sunhux
ID: 37234101
Thanks
0

Featured Post

How to improve team productivity

Quip adds documents, spreadsheets, and tasklists to your Slack experience
- Elevate ideas to Quip docs
- Share Quip docs in Slack
- Get notified of changes to your docs
- Available on iOS/Android/Desktop/Web
- Online/Offline

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
Linux : adding the new user with password option, 11 89
Parsing a file using ksh 10 48
Oracle Finace 3 46
How to clone solaris 10 machine 33 76
Introduction Regular patching is part of a system administrator's tasks. However, many patches require that the system be in single-user mode before they can be installed. A cluster patch in particular can take quite a while to apply if the machine…
Every server (virtual or physical) needs a console: and the console can be provided through hardware directly connected, software for remote connections, local connections, through a KVM, etc. This document explains the different types of consol…
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
In a previous video, we went over how to export a DynamoDB table into Amazon S3.  In this video, we show how to load the export from S3 into a DynamoDB table.

757 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now