Operating System - HP-UX
1827286 Members
1669 Online
109717 Solutions
New Discussion

Re: Computer's identity for NFS mount

 
SOLVED
Go to solution
Steve Post
Trusted Contributor

Computer's identity for NFS mount

I have two computers with 2 lan cards
BoxA
lan1-hostA1
lan2-hostA2
BoxB
lan1-hostB1
lan2-hostB2

I have a filesytem on boxA called /dirA.
I want to nfs boxA:/dirA to boxB:/nfs_dirA.

I run from BoxB " mount -F nfs boxA:/dirA /nfs_dirA"
BoxA sees an NFS request from BoxB.

Question: What host does BoxA see? Why?
Is it hostB1 or hostB2?

I should put both hostB1 and hostB2 into file boxA:/etc/exports? Is there a way I could pin down the cards to use for the NFS connection?

thanks. steve
8 REPLIES 8
Robert-Jan Goossens
Honored Contributor

Re: Computer's identity for NFS mount

Hi Steve,

>What host does BoxA see?
mount -F nfs ipadress:/dirA /nfs_dirA

Why?
I changed the boxa into the ipadress (either hostA1 or hostA2) does this solve your question.

Hope it helps,

Robert-Jan.
Steve Post
Trusted Contributor

Re: Computer's identity for NFS mount

Yeah what does boxA see? That's the question.
Using ip address gives me the same question.

Here's a hostfile on BOTH boxes.
1.2.3.1 boxA1
1.2.3.2 boxA2
1.2.3.3 boxB1
1.2.3.4 boxB2

Does boxA see the nfs request from
1.2.3.3 or 1.2.3.4?
Does boxA see the nfs request from
boxB1 or boxB2?

Steve Post
Trusted Contributor

Re: Computer's identity for NFS mount

ok. I'll be more specific. NO. Your answer did not help. But it's good in repeating my QUESTION.

I have a new giga-lan card in BoxB. The nfs mount failed because the request for nfs came from this NEW card. The new card was not set up for nfs. The request could have come from 2 OTHER cards with no problem. It's worked great for two years. But it used the NEW card.

So........how does hpux decide? I, the human, would have chosen the lan card that had a hostname with permission to use nfs. HPUX decided not to. How does it decide?
Geoff Wild
Honored Contributor

Re: Computer's identity for NFS mount

It should use the same route as when you ping the host...

IE - traceroute to boxa1 or boxa2

Depends on the subnet(s) you are using.
If hosta1 is in a different subnet then hosta2 and hostb1 is the same as hosta1 and hostb2 is the same as hosta2 - then this will work:

exportfs the filesystem on BoxA
If you want to use hosta2 - then add hostb2 to /etc/exports

On hostB - when you traceroute to hosta2 - it should use hostb2 interface - then just nfs mount it:

mount -F nfs hosta2:/dirA /nfs_dirA


Rgds...Geoff

Proverbs 3:5,6 Trust in the Lord with all your heart and lean not on your own understanding; in all your ways acknowledge him, and he will make all your paths straight.
Ramkumar Devanathan
Honored Contributor

Re: Computer's identity for NFS mount

Just for some more learning - What happens in a case where all interfaces are on the same subnet and having the same subnet mask?

Steve, if Geoff answers this right - can you please hand him the points. my knowledge is minimal here. So, the forums and you decide if he's right.

- ramd.
HPE Software Rocks!
Michael Steele_2
Honored Contributor

Re: Computer's identity for NFS mount

From the client:

rpcinfo -p

Will or won't provide information if it does then that's who you're mounted to. Also check:

cat /etc/mnttab

Also check df and syslog.log :

df -g
df -F NFS

syslog.log:

Jan 17 12:56:26 cchp39 vmunix: NFS server 10.254.6.66 not responding still trying

Which should note the server.

Also use lsof:

lsof -i udp:2049

From the server

issue 'showmount' to see what clients have mounted:

showmount -a
showmount -e
Support Fatherhood - Stop Family Law
Steve Post
Trusted Contributor

Re: Computer's identity for NFS mount

Yeah you're right. I'll assign points later. But I haven't gotten the answer yet. If I assign points now, I won't get an answer. But believe me, I do assign points. So, don't fret. :)

Trace route will tell me which cards are in use, but not why.

I know about subnet. All 4 lan cards are on the same subnet. They are staying that way. I'll not waste anybody's time explaining why I won't mess with the subnets. Besides my big question of WHY is still unanswered.

Why does nfs choose one lan card over another?
Ok...fine. Why does ping, telnet, ssh, traceroute, etc etc etc, choose one lan card over another?

The question is still there.

steve
Geoff Wild
Honored Contributor
Solution

Re: Computer's identity for NFS mount

> Why does nfs choose one lan card over another?
> Ok...fine. Why does ping, telnet, ssh, traceroute, etc etc etc, choose one lan card over another?

This is to do with routing - tcp follows default routes.

You could put in a static route - thus forcing any tcp connections through a particular lan card.

RGds...Geoff

Proverbs 3:5,6 Trust in the Lord with all your heart and lean not on your own understanding; in all your ways acknowledge him, and he will make all your paths straight.