Skip to contentSkip to conversation

problem mounting using NFSv4 when using -o sec=krb5 option

DISCUSSION mehta kiran 2 participants 6 messages Mar 22, 2005

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

Missed one thing.
I used kadmin.local to create principals(on machine
runnnig KDC)

thanks,
--kiran

Quoted 28 lines · --- mehta kiran

Hi Kevin ,
I created new database and new principal and keytab files.

Kinit does not accept passowrd for principals nfs/vcslinux5.vxindia.veritas.com
and
nfs/vcslinux6.vxindia.veritas.com

Please let me know if i can provide some
info(and
how) (logs) which can point out the problem

thanks,
--kiran

Quoted 8 lines · --- Kevin Coffman
Quoted 3 lines

Hi ,
I tried things as directed by Trond

in

Quoted 1 line

his previous mail and everything seemed to

work

Quoted 2 lines

fine initally. but when i rebooted system , it started giving error whenever i start

Quoted 11 lines
Quoted 6 lines

rpc.gssd

Quoted 5 lines

on client machine.
Error is :

[root@vcslinux6 ~]# Mar 21 14:47:27 vcslinux6 rpc.gssd[3487]: WARNING: Key table entry not

found

Quoted 3 lines
Quoted 2 lines

while getting initial ticket for principal

'nfs/[email protected]'

Quoted 11 lines
Quoted 10 lines
Quoted 2 lines

from keytab 'FILE:/etc/krb5.keytab'

Mar 21 14:47:27 vcslinux6 rpc.gssd[3487]: ERROR:

No

Quoted 6 lines

usable machine credentials obtained

while #klist -k /etc/krb5.keytab gives
2

nfs/[email protected]

Quoted 38 lines
Quoted 3 lines

I'm confused by this, but I do not know what to

look

Quoted 8 lines

for.

Quoted 1 line

I even tried by recreating kerberos database but

in

Quoted 1 line

vain. I still get the same error.

If you recreated the Kerberos database, you need

to

Quoted 1 line

create new principals and keytab files. Did you

do

Quoted 4 lines

this?

Quoted 2 lines

I observed one more thing.
Whenver i create principal(other then

root/admin)

Quoted 17 lines

,

Quoted 2 lines

passwords i enter for them during their creation are not accepted by kinit.

This is also strange and _might_ be related. How
are
you creating the principals -- using kadmin or
kadmin.local?
Which principals are you referring to here?

Quoted 5 lines

Please let me know where i went wrong.

--thanks,
--kiran

Quoted 8 lines

__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com

-------------------------------------------------------

Quoted 6 lines

SF email is sponsored by - The IT Product Guide Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.

http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click

Quoted 4 lines

_______________________________________________
NFS maillist - [email protected]
https://lists.sourceforge.net/lists/listinfo/nfs

__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com

-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
_______________________________________________
NFS maillist - [email protected]
https://lists.sourceforge.net/lists/listinfo/nfs

#1 lore raw

Hi Kevin ,
God knows how , but everyting is working fine now. I could not figure out why was it failing earlier.

I have one question.
Is is possible to use common ip to access machines when kerberos is running .i:e
I want to access system1 with an ip say IP. when system1 crashes , i want to start services of system1 on system2 but want to access system2 with same IP.

what is tried was
create keys (on machine running KDC) for
for all machines in my subnet.

After this take an ip and register it with DNS with some name say NFS.domain.
Create key (on machine running kdc) for
NFS.domain
For machines those which will run nfs server , ktadd respective machine key + ktadd NFS.domain key and copy keytab file to respective machines. For all other machines just ktadd respective machine key and copy keytab file to respective machines.
In short ,
on machine running nfs server,
#klist -k /etc/krb5.keytab
2 nfs/<hostname.domainname>@<realm>
2 nfs/NFS.domainname@<realm>

for other machines(nfs clients)
#klist -k /etc/krb5.keytab
2 nfs/<hostname.domainname>@<realm>

but when i try to mount exported filesystems from nfs client ,
using
#mount -t nfs4 -osec=krb5 NFS.doaminname:/ /share

Failed to create krb5 context for user with uid
0
with any credential cache for server NFS.domainname

Everything works well if genuine server name is used for mounting.Problem arises only when (virtual ip) NFS.domainname is used.

thanks,
--kiran

Quoted 28 lines · --- mehta kiran

Missed one thing.
I used kadmin.local to create principals(on machine
runnnig KDC)

thanks,
--kiran

Quoted 21 lines · --- mehta kiran

Hi Kevin ,
I created new database and new principal and keytab files.

Kinit does not accept passowrd for principals nfs/vcslinux5.vxindia.veritas.com
and
nfs/vcslinux6.vxindia.veritas.com

Please let me know if i can provide some
info(and
how) (logs) which can point out the problem

thanks,
--kiran

Quoted 1 line · --- Kevin Coffman
Quoted 1 line
Quoted 21 lines
Quoted 2 lines
Quoted 2 lines
Quoted 2 lines

Hi ,
I tried things as directed by

Trond

Quoted 4 lines
Quoted 4 lines

in

Quoted 1 line

his previous mail and everything seemed to

work

Quoted 1 line

fine initally. but when i rebooted system

,

Quoted 12 lines
Quoted 7 lines
Quoted 1 line

it started giving error whenever i start

rpc.gssd

Quoted 5 lines

on client machine.
Error is :

[root@vcslinux6 ~]# Mar 21 14:47:27 vcslinux6
rpc.gssd[3487]: WARNING: Key table entry not

found

Quoted 3 lines
Quoted 2 lines

while getting initial ticket for principal

'nfs/[email protected]'

Quoted 13 lines
Quoted 2 lines
Quoted 2 lines
Quoted 2 lines

from keytab 'FILE:/etc/krb5.keytab'

Mar 21 14:47:27 vcslinux6 rpc.gssd[3487]:

ERROR:

Quoted 9 lines
Quoted 8 lines

No

Quoted 6 lines

usable machine credentials obtained

while #klist -k /etc/krb5.keytab gives
2

nfs/[email protected]

Quoted 20 lines
Quoted 8 lines
Quoted 3 lines

I'm confused by this, but I do not know what to

look

Quoted 4 lines

for.

Quoted 1 line

I even tried by recreating kerberos database

but

Quoted 11 lines
Quoted 4 lines

in

Quoted 1 line

vain. I still get the same error.

If you recreated the Kerberos database, you need

to

Quoted 1 line

create new principals and keytab files. Did you

do

Quoted 4 lines

this?

Quoted 2 lines

I observed one more thing.
Whenver i create principal(other then

Quoted 30 lines
Quoted 3 lines

root/admin)

Quoted 2 lines

,

Quoted 1 line

passwords i enter for them during their

creation

Quoted 3 lines
Quoted 3 lines
Quoted 1 line

are not accepted by kinit.

This is also strange and _might_ be related.

How

Quoted 21 lines
Quoted 12 lines

are
you creating the principals -- using kadmin or
kadmin.local?
Which principals are you referring to here?

Quoted 5 lines

Please let me know where i went wrong.

--thanks,
--kiran

__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com

-------------------------------------------------------

Quoted 7 lines
Quoted 6 lines

SF email is sponsored by - The IT Product Guide Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.

http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click

Quoted 5 lines
Quoted 4 lines

_______________________________________________
NFS maillist - [email protected]
https://lists.sourceforge.net/lists/listinfo/nfs

Quoted 8 lines

__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com

-------------------------------------------------------

Quoted 6 lines

SF email is sponsored by - The IT Product Guide Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.

http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click

Quoted 4 lines

_______________________________________________
NFS maillist - [email protected]
https://lists.sourceforge.net/lists/listinfo/nfs

__________________________________
Do you Yahoo!?
Yahoo! Small Business - Try our new resources site!
http://smallbusiness.yahoo.com/resources/

-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
_______________________________________________
NFS maillist - [email protected]
https://lists.sourceforge.net/lists/listinfo/nfs

#2 lore raw

I'm happy to hear the normal case is working.

The Kerberos library code does a reverse lookup of the host it is trying to connect to in order to obtain the "real" host name. It uses that name to determine what principal it needs a ticket for. It would help to see the exact messages from rpc.gssd, rpc.svcgssd, and from the KDC.

Quoted 215 lines

Hi Kevin ,
God knows how , but everyting is working fine now. I could not figure out why was it failing earlier.

I have one question.
Is is possible to use common ip to access machines when kerberos is running .i:e
I want to access system1 with an ip say IP. when system1 crashes , i want to start services of system1 on system2 but want to access system2 with same IP.

what is tried was
create keys (on machine running KDC) for
for all machines in my subnet.

After this take an ip and register it with DNS with some name say NFS.domain.
Create key (on machine running kdc) for
NFS.domain
For machines those which will run nfs server , ktadd respective machine key + ktadd NFS.domain key and copy keytab file to respective machines. For all other machines just ktadd respective machine key and copy keytab file to respective machines.
In short ,
on machine running nfs server,
#klist -k /etc/krb5.keytab
2 nfs/<hostname.domainname>@<realm>
2 nfs/NFS.domainname@<realm>

for other machines(nfs clients)
#klist -k /etc/krb5.keytab
2 nfs/<hostname.domainname>@<realm>

but when i try to mount exported filesystems from nfs client ,
using
#mount -t nfs4 -osec=krb5 NFS.doaminname:/ /share

Failed to create krb5 context for user with uid
0
with any credential cache for server NFS.domainname

Everything works well if genuine server name is used for mounting.Problem arises only when (virtual ip) NFS.domainname is used.

thanks,
--kiran

Quoted 28 lines · --- mehta kiran

Missed one thing.
I used kadmin.local to create principals(on machine
runnnig KDC)

thanks,
--kiran

Quoted 21 lines · --- mehta kiran

Hi Kevin ,
I created new database and new principal and keytab files.

Kinit does not accept passowrd for principals nfs/vcslinux5.vxindia.veritas.com
and
nfs/vcslinux6.vxindia.veritas.com

Please let me know if i can provide some
info(and
how) (logs) which can point out the problem

thanks,
--kiran

Quoted 1 line · --- Kevin Coffman
Quoted 1 line
Quoted 21 lines
Quoted 2 lines
Quoted 2 lines
Quoted 2 lines

Hi ,
I tried things as directed by

Trond

Quoted 4 lines
Quoted 4 lines

in

Quoted 1 line

his previous mail and everything seemed to

work

Quoted 1 line

fine initally. but when i rebooted system

,

Quoted 12 lines
Quoted 7 lines
Quoted 1 line

it started giving error whenever i start

rpc.gssd

Quoted 5 lines

on client machine.
Error is :

[root@vcslinux6 ~]# Mar 21 14:47:27 vcslinux6
rpc.gssd[3487]: WARNING: Key table entry not

found

Quoted 3 lines
Quoted 2 lines

while getting initial ticket for principal

'nfs/[email protected]'

Quoted 13 lines
Quoted 2 lines
Quoted 2 lines
Quoted 2 lines

from keytab 'FILE:/etc/krb5.keytab'

Mar 21 14:47:27 vcslinux6 rpc.gssd[3487]:

ERROR:

Quoted 9 lines
Quoted 8 lines

No

Quoted 6 lines

usable machine credentials obtained

while #klist -k /etc/krb5.keytab gives
2

nfs/[email protected]

Quoted 20 lines
Quoted 8 lines
Quoted 3 lines

I'm confused by this, but I do not know what to

look

Quoted 4 lines

for.

Quoted 1 line

I even tried by recreating kerberos database

but

Quoted 11 lines
Quoted 4 lines

in

Quoted 1 line

vain. I still get the same error.

If you recreated the Kerberos database, you need

to

Quoted 1 line

create new principals and keytab files. Did you

do

Quoted 4 lines

this?

Quoted 2 lines

I observed one more thing.
Whenver i create principal(other then

Quoted 30 lines
Quoted 3 lines

root/admin)

Quoted 2 lines

,

Quoted 1 line

passwords i enter for them during their

creation

Quoted 3 lines
Quoted 3 lines
Quoted 1 line

are not accepted by kinit.

This is also strange and _might_ be related.

How

Quoted 21 lines
Quoted 12 lines

are
you creating the principals -- using kadmin or
kadmin.local?
Which principals are you referring to here?

Quoted 5 lines

Please let me know where i went wrong.

--thanks,
--kiran

__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com

-------------------------------------------------------

Quoted 7 lines
Quoted 6 lines

SF email is sponsored by - The IT Product Guide Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.

http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click

Quoted 5 lines
Quoted 4 lines

_______________________________________________
NFS maillist - [email protected]
https://lists.sourceforge.net/lists/listinfo/nfs

Quoted 8 lines

__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com

-------------------------------------------------------

Quoted 6 lines

SF email is sponsored by - The IT Product Guide Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.

http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click

Quoted 4 lines

_______________________________________________
NFS maillist - [email protected]
https://lists.sourceforge.net/lists/listinfo/nfs

__________________________________
Do you Yahoo!?
Yahoo! Small Business - Try our new resources site!
http://smallbusiness.yahoo.com/resources/

Quoted 8 lines

-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
_______________________________________________
NFS maillist - [email protected]
https://lists.sourceforge.net/lists/listinfo/nfs

-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
_______________________________________________
NFS maillist - [email protected]
https://lists.sourceforge.net/lists/listinfo/nfs

#3 lore raw

Hi Kevin ,

As you told , kerberos library does reverse lookup to get hostname to determine the principal it needs ticket for.
I followed the steps as mentioned in my previous mail so that i can access nfs using same ip on system2 if system1 crashes.
while mounting i used NFS.domainname(entry i added to DNS : NFS.domainname <virtual_ip>) As key for NFS.domainname is present on nfs server shouldn't mount be successful?

But this is not the case.
Messages on server(vcslinux6)

Mar 22 14:04:08 vcslinux6 rpc.svcgssd[4969]: WARNING:
gss_accept_sec_context failed
Mar 22 14:04:08 vcslinux6 rpc.svcgssd[4969]: ERROR:
GSS-API: error in handle_nullreq:
gss_accept_sec_context(): Miscellaneous failure -
Wrong principal in request
Mar 22 14:04:08 vcslinux6 rpc.svcgssd[4969]: WARNING:
failed to write message
Mar 22 14:05:01 vcslinux6 crond(pam_unix)[6083]:

session opened for user root by (uid=0)

Messsages on client (vcslinux5)

[root@vcslinux5 ~]# Mar 22 14:04:49 vcslinux5 rpc.gssd[4117]: WARNING: Failed to create krb5 context for user with uid 0 with any credentials cache for server vcsnfs.vxindia.veritas.com

Message on KDC(vcslinux1)

Mar 22 14:33:18 vcslinux1 krb5kdc[4134]: AS_REQ (7

etypes {18 17 16 23 1 3 2}) 10.212.99.13: ISSUE:
authtime 1111482198, etypes {rep=1 tkt=23 ses=16}, nfs/[email protected] for krbtgt/[email protected]

Mar 22 14:33:41 vcslinux1 krb5kdc[4134]: TGS_REQ (7

etypes {18 17 16 23 1 3 2}) 10.212.99.13: ISSUE:
authtime 1111482198, etypes {rep=16 tkt=1 ses=1}, nfs/[email protected] for nfs/[email protected]

Mar 22 14:33:41 vcslinux1 krb5kdc[4134]: TGS_REQ (7

etypes {18 17 16 23 1 3 2}) 10.212.99.13: ISSUE:
authtime 1111482198, etypes {rep=16 tkt=1 ses=1}, nfs/[email protected] for nfs/[email protected]

thanks,
--kiran

Quoted 126 lines · --- Kevin Coffman

I'm happy to hear the normal case is working.

The Kerberos library code does a reverse lookup of the host it is
trying to connect to in order to obtain the "real" host name. It uses
that name to determine what principal it needs a ticket for. It would
help to see the exact messages from rpc.gssd, rpc.svcgssd, and from the
KDC.

Quoted 2 lines

Hi Kevin ,
God knows how , but everyting is working fine

now.

Quoted 1 line

I could not figure out why was it failing

earlier.

Quoted 6 lines

I have one question.
Is is possible to use common ip to access
machines when kerberos is running .i:e
I want to access system1 with an ip say IP.
when system1 crashes , i want to start

services

Quoted 1 line

of system1 on system2 but want to access

system2

Quoted 7 lines

with same IP.

what is tried was
create keys (on machine running KDC) for
for all machines in my subnet.

After this take an ip and register it with

DNS

Quoted 4 lines

with some name say NFS.domain.
Create key (on machine running kdc) for
NFS.domain
For machines those which will run nfs server

,

Quoted 1 line

ktadd respective machine key + ktadd

NFS.domain

Quoted 1 line

key and copy keytab file to respective

machines.

Quoted 2 lines

For all other machines just ktadd respective
machine key and copy keytab file to

respective

Quoted 7 lines

machines.
In short ,
on machine running nfs server,
#klist -k /etc/krb5.keytab
2 nfs/<hostname.domainname>@<realm>
2 nfs/NFS.domainname@<realm>

Quoted 8 lines

for other machines(nfs clients)
#klist -k /etc/krb5.keytab
2 nfs/<hostname.domainname>@<realm>

but when i try to mount exported filesystems
from nfs client ,
using
#mount -t nfs4 -osec=krb5 NFS.doaminname:/

/share

Quoted 2 lines

Failed to create krb5 context for user with

uid

Quoted 5 lines

0
with any credential cache for server
NFS.domainname

Everything works well if genuine server name

is

Quoted 12 lines

used for mounting.Problem arises only when
(virtual ip) NFS.domainname is used.

thanks,
--kiran

Quoted 2 lines · --- mehta kiran

Missed one thing.
I used kadmin.local to create principals(on

machine

Quoted 5 lines
Quoted 5 lines

runnnig KDC)

thanks,
--kiran
--- mehta kiran <[email protected]>

Quoted 2 lines · wrote:
Quoted 2 lines
Quoted 2 lines

Hi Kevin ,
I created new database and new principal

and

Quoted 3 lines
Quoted 3 lines
Quoted 3 lines

keytab files.

Kinit does not accept passowrd for

principals

Quoted 14 lines
Quoted 14 lines
Quoted 14 lines

nfs/vcslinux5.vxindia.veritas.com
and
nfs/vcslinux6.vxindia.veritas.com

Please let me know if i can provide some
info(and
how) (logs) which can point out the problem

thanks,
--kiran

Quoted 7 lines
Quoted 7 lines
Quoted 4 lines
Quoted 3 lines · --- Kevin Coffman
Quoted 3 lines

Hi ,
I tried things as directed by

Trond

Quoted 2 lines
Quoted 2 lines

in

Quoted 1 line

his previous mail and everything

seemed to

Quoted 2 lines
Quoted 2 lines
Quoted 2 lines
Quoted 2 lines

work

Quoted 1 line

fine initally. but when i rebooted

system

Quoted 2 lines
Quoted 2 lines

,

Quoted 1 line
Quoted 1 line
Quoted 1 line

it started giving error whenever i

start

Quoted 16 lines
Quoted 5 lines
Quoted 5 lines
Quoted 5 lines
Quoted 5 lines

rpc.gssd

Quoted 4 lines

on client machine.
Error is :

[root@vcslinux6 ~]# Mar 21 14:47:27

vcslinux6

Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line

rpc.gssd[3487]: WARNING: Key table entry

not

Quoted 7 lines
Quoted 6 lines
Quoted 5 lines

found

Quoted 3 lines
Quoted 2 lines

while getting initial ticket for principal

'nfs/[email protected]'

Quoted 7 lines
Quoted 7 lines
Quoted 7 lines
Quoted 2 lines
Quoted 2 lines
Quoted 2 lines

from keytab 'FILE:/etc/krb5.keytab'

Mar 21 14:47:27 vcslinux6 rpc.gssd[3487]:

ERROR:

Quoted 4 lines
Quoted 4 lines

No

Quoted 3 lines

usable machine credentials obtained

Quoted 8 lines
Quoted 7 lines
Quoted 6 lines
Quoted 5 lines
Quoted 4 lines
Quoted 3 lines

while #klist -k /etc/krb5.keytab gives
2

nfs/[email protected]

Quoted 28 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines

I'm confused by this, but I do not know what

to

Quoted 5 lines
Quoted 5 lines
Quoted 5 lines

look

Quoted 4 lines

for.

Quoted 1 line

I even tried by recreating kerberos

database

Quoted 5 lines
Quoted 5 lines

but

Quoted 4 lines
Quoted 4 lines

in

Quoted 1 line

vain. I still get the same error.

If you recreated the Kerberos database, you

need

Quoted 2 lines
Quoted 2 lines
Quoted 2 lines

to

Quoted 1 line

create new principals and keytab files. Did

you

Quoted 9 lines
Quoted 9 lines
Quoted 8 lines

do

Quoted 4 lines

this?

Quoted 2 lines

I observed one more thing.
Whenver i create principal(other then

root/admin)

Quoted 2 lines

,

Quoted 1 line

passwords i enter for them during their

creation

Quoted 17 lines
Quoted 7 lines
Quoted 7 lines
Quoted 3 lines
Quoted 3 lines
Quoted 1 line

are not accepted by kinit.

This is also strange and _might_ be related.

How

Quoted 2 lines
Quoted 2 lines

are
you creating the principals -- using kadmin

or

Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines

kadmin.local?
Which principals are you referring to here?

Quoted 5 lines

Please let me know where i went wrong.

--thanks,
--kiran

=== message truncated ===

__________________________________
Do you Yahoo!?
Yahoo! Small Business - Try our new resources site!
http://smallbusiness.yahoo.com/resources/

-------------------------------------------------------
This SF.net email is sponsored by: 2005 Windows Mobile Application Contest Submit applications for Windows Mobile(tm)-based Pocket PCs or Smartphones for the chance to win $25,000 and application distribution. Enter today at
http://ads.osdn.com/?ad_id=6882&alloc_id=15148&op=click
_______________________________________________
NFS maillist - [email protected]
https://lists.sourceforge.net/lists/listinfo/nfs

#4 lore raw

The server code is expecting a ticket for 'nfs/vcslinux6.vxindia.veritas .com', but it is getting a ticket for 'nfs/vcsnfs.vxindia.veritas.com'.
This is a limitation of the rpcsec_gss library. This is on my list of
things to try and change.

Kevin

Quoted 272 lines

Hi Kevin ,

As you told , kerberos library does reverse lookup to get hostname to determine the principal it needs ticket for.
I followed the steps as mentioned in my previous mail so that i can access nfs using same ip on system2 if system1 crashes.
while mounting i used NFS.domainname(entry i added to DNS : NFS.domainname <virtual_ip>) As key for NFS.domainname is present on nfs server shouldn't mount be successful?

But this is not the case.
Messages on server(vcslinux6)

Mar 22 14:04:08 vcslinux6 rpc.svcgssd[4969]: WARNING:
gss_accept_sec_context failed
Mar 22 14:04:08 vcslinux6 rpc.svcgssd[4969]: ERROR:
GSS-API: error in handle_nullreq:
gss_accept_sec_context(): Miscellaneous failure -
Wrong principal in request
Mar 22 14:04:08 vcslinux6 rpc.svcgssd[4969]: WARNING:
failed to write message
Mar 22 14:05:01 vcslinux6 crond(pam_unix)[6083]:

session opened for user root by (uid=0)

Messsages on client (vcslinux5)

[root@vcslinux5 ~]# Mar 22 14:04:49 vcslinux5 rpc.gssd[4117]: WARNING: Failed to create krb5 context for user with uid 0 with any credentials cache for server vcsnfs.vxindia.veritas.com

Message on KDC(vcslinux1)

Mar 22 14:33:18 vcslinux1 krb5kdc[4134]: AS_REQ (7

etypes {18 17 16 23 1 3 2}) 10.212.99.13: ISSUE:
authtime 1111482198, etypes {rep=1 tkt=23 ses=16}, nfs/[email protected] for krbtgt/[email protected]

Mar 22 14:33:41 vcslinux1 krb5kdc[4134]: TGS_REQ (7

etypes {18 17 16 23 1 3 2}) 10.212.99.13: ISSUE:
authtime 1111482198, etypes {rep=16 tkt=1 ses=1}, nfs/[email protected] for nfs/[email protected]

Mar 22 14:33:41 vcslinux1 krb5kdc[4134]: TGS_REQ (7

etypes {18 17 16 23 1 3 2}) 10.212.99.13: ISSUE:
authtime 1111482198, etypes {rep=16 tkt=1 ses=1}, nfs/[email protected] for nfs/[email protected]

thanks,
--kiran

Quoted 126 lines · --- Kevin Coffman

I'm happy to hear the normal case is working.

The Kerberos library code does a reverse lookup of the host it is
trying to connect to in order to obtain the "real" host name. It uses
that name to determine what principal it needs a ticket for. It would
help to see the exact messages from rpc.gssd, rpc.svcgssd, and from the
KDC.

Quoted 2 lines

Hi Kevin ,
God knows how , but everyting is working fine

now.

Quoted 1 line

I could not figure out why was it failing

earlier.

Quoted 6 lines

I have one question.
Is is possible to use common ip to access
machines when kerberos is running .i:e
I want to access system1 with an ip say IP.
when system1 crashes , i want to start

services

Quoted 1 line

of system1 on system2 but want to access

system2

Quoted 7 lines

with same IP.

what is tried was
create keys (on machine running KDC) for
for all machines in my subnet.

After this take an ip and register it with

DNS

Quoted 4 lines

with some name say NFS.domain.
Create key (on machine running kdc) for
NFS.domain
For machines those which will run nfs server

,

Quoted 1 line

ktadd respective machine key + ktadd

NFS.domain

Quoted 1 line

key and copy keytab file to respective

machines.

Quoted 2 lines

For all other machines just ktadd respective
machine key and copy keytab file to

respective

Quoted 7 lines

machines.
In short ,
on machine running nfs server,
#klist -k /etc/krb5.keytab
2 nfs/<hostname.domainname>@<realm>
2 nfs/NFS.domainname@<realm>

Quoted 8 lines

for other machines(nfs clients)
#klist -k /etc/krb5.keytab
2 nfs/<hostname.domainname>@<realm>

but when i try to mount exported filesystems
from nfs client ,
using
#mount -t nfs4 -osec=krb5 NFS.doaminname:/

/share

Quoted 2 lines

Failed to create krb5 context for user with

uid

Quoted 5 lines

0
with any credential cache for server
NFS.domainname

Everything works well if genuine server name

is

Quoted 12 lines

used for mounting.Problem arises only when
(virtual ip) NFS.domainname is used.

thanks,
--kiran

Quoted 2 lines · --- mehta kiran

Missed one thing.
I used kadmin.local to create principals(on

machine

Quoted 5 lines
Quoted 5 lines

runnnig KDC)

thanks,
--kiran
--- mehta kiran <[email protected]>

Quoted 2 lines · wrote:
Quoted 2 lines
Quoted 2 lines

Hi Kevin ,
I created new database and new principal

and

Quoted 3 lines
Quoted 3 lines
Quoted 3 lines

keytab files.

Kinit does not accept passowrd for

principals

Quoted 14 lines
Quoted 14 lines
Quoted 14 lines

nfs/vcslinux5.vxindia.veritas.com
and
nfs/vcslinux6.vxindia.veritas.com

Please let me know if i can provide some
info(and
how) (logs) which can point out the problem

thanks,
--kiran

Quoted 7 lines
Quoted 7 lines
Quoted 4 lines
Quoted 3 lines · --- Kevin Coffman
Quoted 3 lines

Hi ,
I tried things as directed by

Trond

Quoted 2 lines
Quoted 2 lines

in

Quoted 1 line

his previous mail and everything

seemed to

Quoted 2 lines
Quoted 2 lines
Quoted 2 lines
Quoted 2 lines

work

Quoted 1 line

fine initally. but when i rebooted

system

Quoted 2 lines
Quoted 2 lines

,

Quoted 1 line
Quoted 1 line
Quoted 1 line

it started giving error whenever i

start

Quoted 16 lines
Quoted 5 lines
Quoted 5 lines
Quoted 5 lines
Quoted 5 lines

rpc.gssd

Quoted 4 lines

on client machine.
Error is :

[root@vcslinux6 ~]# Mar 21 14:47:27

vcslinux6

Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line

rpc.gssd[3487]: WARNING: Key table entry

not

Quoted 7 lines
Quoted 6 lines
Quoted 5 lines

found

Quoted 3 lines
Quoted 2 lines

while getting initial ticket for principal

'nfs/[email protected]'

Quoted 7 lines
Quoted 7 lines
Quoted 7 lines
Quoted 2 lines
Quoted 2 lines
Quoted 2 lines

from keytab 'FILE:/etc/krb5.keytab'

Mar 21 14:47:27 vcslinux6 rpc.gssd[3487]:

ERROR:

Quoted 4 lines
Quoted 4 lines

No

Quoted 3 lines

usable machine credentials obtained

Quoted 8 lines
Quoted 7 lines
Quoted 6 lines
Quoted 5 lines
Quoted 4 lines
Quoted 3 lines

while #klist -k /etc/krb5.keytab gives
2

nfs/[email protected]

Quoted 28 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines

I'm confused by this, but I do not know what

to

Quoted 5 lines
Quoted 5 lines
Quoted 5 lines

look

Quoted 4 lines

for.

Quoted 1 line

I even tried by recreating kerberos

database

Quoted 5 lines
Quoted 5 lines

but

Quoted 4 lines
Quoted 4 lines

in

Quoted 1 line

vain. I still get the same error.

If you recreated the Kerberos database, you

need

Quoted 2 lines
Quoted 2 lines
Quoted 2 lines

to

Quoted 1 line

create new principals and keytab files. Did

you

Quoted 9 lines
Quoted 9 lines
Quoted 8 lines

do

Quoted 4 lines

this?

Quoted 2 lines

I observed one more thing.
Whenver i create principal(other then

root/admin)

Quoted 2 lines

,

Quoted 1 line

passwords i enter for them during their

creation

Quoted 17 lines
Quoted 7 lines
Quoted 7 lines
Quoted 3 lines
Quoted 3 lines
Quoted 1 line

are not accepted by kinit.

This is also strange and _might_ be related.

How

Quoted 2 lines
Quoted 2 lines

are
you creating the principals -- using kadmin

or

Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines

kadmin.local?
Which principals are you referring to here?

Quoted 5 lines

Please let me know where i went wrong.

--thanks,
--kiran

=== message truncated ===

Quoted 4 lines

__________________________________
Do you Yahoo!?
Yahoo! Small Business - Try our new resources site!
http://smallbusiness.yahoo.com/resources/

-------------------------------------------------------
This SF.net email is sponsored by: 2005 Windows Mobile Application Contest Submit applications for Windows Mobile(tm)-based Pocket PCs or Smartphones for the chance to win $25,000 and application distribution. Enter today at
http://ads.osdn.com/?ad_id=6882&alloc_id=15148&op=click
_______________________________________________
NFS maillist - [email protected]
https://lists.sourceforge.net/lists/listinfo/nfs

#5 lore raw

So this will work sometime later !!!! gr8
Thanks a lot , Kevin

Quoted 44 lines · --- Kevin Coffman

The server code is expecting a ticket for
'nfs/vcslinux6.vxindia.veritas
.com', but it is getting a ticket for
'nfs/vcsnfs.vxindia.veritas.com'.
This is a limitation of the rpcsec_gss library.
This is on my list of
things to try and change.

Kevin

Quoted 6 lines

Hi Kevin ,

As you told , kerberos library does reverse
lookup to get hostname to determine the
principal it needs ticket for.
I followed the steps as mentioned in my

previous

Quoted 1 line

mail so that i can access nfs using same ip

on

Quoted 10 lines

system2 if system1 crashes.
while mounting i used NFS.domainname(entry i added to DNS : NFS.domainname <virtual_ip>) As key for NFS.domainname is present on nfs server shouldn't mount be successful?

But this is not the case.
Messages on server(vcslinux6)

Mar 22 14:04:08 vcslinux6 rpc.svcgssd[4969]:

WARNING:

Quoted 2 lines

gss_accept_sec_context failed

Mar 22 14:04:08 vcslinux6 rpc.svcgssd[4969]:

ERROR:

Quoted 4 lines

GSS-API: error in handle_nullreq:
gss_accept_sec_context(): Miscellaneous failure -
Wrong principal in request

Mar 22 14:04:08 vcslinux6 rpc.svcgssd[4969]:

WARNING:

Quoted 5 lines

failed to write message

Mar 22 14:05:01 vcslinux6 crond(pam_unix)[6083]:

session opened for user root by (uid=0)

Quoted 15 lines
Quoted 4 lines

Messsages on client (vcslinux5)

[root@vcslinux5 ~]# Mar 22 14:04:49 vcslinux5
rpc.gssd[4117]: WARNING: Failed to create krb5

context

Quoted 9 lines

for user with uid 0 with any credentials cache for server vcsnfs.vxindia.veritas.com

Message on KDC(vcslinux1)

Mar 22 14:33:18 vcslinux1 krb5kdc[4134]: AS_REQ (7

etypes {18 17 16 23 1 3 2}) 10.212.99.13: ISSUE:
authtime 1111482198, etypes {rep=1 tkt=23 ses=16},

nfs/[email protected]

Quoted 7 lines
Quoted 2 lines

for krbtgt/[email protected]

Mar 22 14:33:41 vcslinux1 krb5kdc[4134]: TGS_REQ

(7

Quoted 3 lines

etypes {18 17 16 23 1 3 2}) 10.212.99.13: ISSUE:
authtime 1111482198, etypes {rep=16 tkt=1 ses=1},

nfs/[email protected]

Quoted 8 lines
Quoted 1 line

for

nfs/[email protected]

Quoted 1 line
Mar 22 14:33:41 vcslinux1 krb5kdc[4134]: TGS_REQ

(7

Quoted 3 lines

etypes {18 17 16 23 1 3 2}) 10.212.99.13: ISSUE:
authtime 1111482198, etypes {rep=16 tkt=1 ses=1},

nfs/[email protected]

Quoted 113 lines
Quoted 1 line

for

nfs/[email protected]

Quoted 14 lines

thanks,
--kiran

Quoted 3 lines · --- Kevin Coffman

I'm happy to hear the normal case is working.

The Kerberos library code does a reverse lookup

of

Quoted 2 lines
Quoted 2 lines

the host it is
trying to connect to in order to obtain the

"real"

Quoted 10 lines
Quoted 10 lines

host name. It uses
that name to determine what principal it needs a
ticket for. It would
help to see the exact messages from rpc.gssd,
rpc.svcgssd, and from the
KDC.

Quoted 2 lines

Hi Kevin ,
God knows how , but everyting is working

fine

Quoted 8 lines
Quoted 8 lines

now.

Quoted 1 line

I could not figure out why was it failing

earlier.

Quoted 5 lines

I have one question.
Is is possible to use common ip to access
machines when kerberos is running .i:e
I want to access system1 with an ip say

IP.

Quoted 11 lines
Quoted 11 lines
Quoted 1 line

when system1 crashes , i want to start

services

Quoted 1 line

of system1 on system2 but want to access

system2

Quoted 7 lines

with same IP.

what is tried was
create keys (on machine running KDC) for
for all machines in my subnet.

After this take an ip and register it

with

Quoted 5 lines
Quoted 5 lines

DNS

Quoted 4 lines

with some name say NFS.domain.
Create key (on machine running kdc) for
NFS.domain
For machines those which will run nfs

server

Quoted 6 lines
Quoted 6 lines

,

Quoted 1 line

ktadd respective machine key + ktadd

NFS.domain

Quoted 1 line

key and copy keytab file to respective

machines.

Quoted 1 line

For all other machines just ktadd

respective

Quoted 9 lines
Quoted 9 lines
Quoted 1 line

machine key and copy keytab file to

respective

Quoted 7 lines

machines.
In short ,
on machine running nfs server,
#klist -k /etc/krb5.keytab
2 nfs/<hostname.domainname>@<realm>
2 nfs/NFS.domainname@<realm>

Quoted 5 lines
Quoted 5 lines
Quoted 5 lines

for other machines(nfs clients)
#klist -k /etc/krb5.keytab
2 nfs/<hostname.domainname>@<realm>

but when i try to mount exported

filesystems

Quoted 3 lines
Quoted 3 lines
Quoted 3 lines

from nfs client ,
using
#mount -t nfs4 -osec=krb5

NFS.doaminname:/

Quoted 3 lines
Quoted 3 lines

/share

Quoted 2 lines

Failed to create krb5 context for user

with

Quoted 6 lines
Quoted 6 lines

uid

Quoted 5 lines

0
with any credential cache for server
NFS.domainname

Everything works well if genuine server

name

Quoted 2 lines
Quoted 2 lines

is

Quoted 1 line

used for mounting.Problem arises only

when

Quoted 8 lines
Quoted 8 lines
Quoted 8 lines

(virtual ip) NFS.domainname is used.

thanks,
--kiran

--- mehta kiran <[email protected]>

Quoted 6 lines · wrote:
Quoted 6 lines
Quoted 3 lines
Quoted 3 lines

Missed one thing.
I used kadmin.local to create principals(on

machine

Quoted 2 lines
Quoted 2 lines

runnnig KDC)

Quoted 15 lines
Quoted 6 lines
Quoted 6 lines
Quoted 3 lines
Quoted 3 lines

thanks,
--kiran
--- mehta kiran <[email protected]>

Quoted 2 lines · wrote:
Quoted 2 lines
Quoted 2 lines

Hi Kevin ,
I created new database and new

principal

Quoted 7 lines
Quoted 7 lines

and

Quoted 3 lines
Quoted 3 lines
Quoted 3 lines

keytab files.

Kinit does not accept passowrd for

principals

Quoted 2 lines
Quoted 2 lines
Quoted 2 lines

nfs/vcslinux5.vxindia.veritas.com
and

=== message truncated ===

__________________________________
Do you Yahoo!?
Yahoo! Small Business - Try our new resources site!
http://smallbusiness.yahoo.com/resources/

-------------------------------------------------------
This SF.net email is sponsored by: 2005 Windows Mobile Application Contest Submit applications for Windows Mobile(tm)-based Pocket PCs or Smartphones for the chance to win $25,000 and application distribution. Enter today at
http://ads.osdn.com/?ad_id=6882&alloc_id=15148&op=click
_______________________________________________
NFS maillist - [email protected]
https://lists.sourceforge.net/lists/listinfo/nfs