Operating System - HP-UX
1834622 Members
2901 Online
110069 Solutions
New Discussion

nsswitch.conf ... changed policy at 11i

 
Charles Keenan
Occasional Advisor

nsswitch.conf ... changed policy at 11i

I think I have detected a change in the Name Service Switch policy, but can't find any documentation to suuport my theory. I have a system at 11.0 whose policy = SUCCESS=return NOTFOUND=return UNAVAIL=continue TRYAGAIN=return
Whereas my 11i(11.11) has the policy
SUCCESS=return NOTFOUND=continue UNAVAIL=continue TRYAGAIN=continue
neither system has a nsswitch.conf file. Interestingly the 11.0 manual page states it should be RCCC but it blatantly isn't ... Who is right ???
ochayethinoojimmy
7 REPLIES 7
harry d brown jr
Honored Contributor

Re: nsswitch.conf ... changed policy at 11i

RCCC is correct, well it's what I would and DO use.

If it continues to be confusing, then explicitly state your desired results by creating the nsswitch.conf file. Basically, don't leave things to chance!


live free or die
harry
Live Free or Die
Pete Randall
Outstanding Contributor

Re: nsswitch.conf ... changed policy at 11i

I'm curious (and maybe a little slow) - if you don't have an nsswitch.conf file, how are you viewing the RRCR behavior?

Pete

Pete
Jean-Louis Phelix
Honored Contributor

Re: nsswitch.conf ... changed policy at 11i

Charles,

As you mentionned, switch policy has changed but it should be the same for 11.00 and 11i and different for 10.20

On 10.20 it is RRCR (man 4 switch), after it is RCCC (man nsswitch.conf). A problem that I have seen is that if a system doesn't have any nsswitch.conf file, then the default policy is 'harcoded' in some functions. So, on the same system without a nsswitch.conf file, if a binary has been compiled with libc.1 (from 10.20) it will use RRCR, if it has been compiled with libc.2 (from 11.x) it will use RCCC. You can check it using chatr on the binary.

Don't think it's a minor detail because if you use chatr on /usr/sbin/swlist on a 11i for example, you will see libc.1 ...

So as Harry said "don't leave things to chance!" and use your own nsswitch.conf ...

Regards,

Jean-Louis.
It works for me (© Bill McNAMARA ...)
Charles Keenan
Occasional Advisor

Re: nsswitch.conf ... changed policy at 11i

Im reviewing the policy y using nslookup

# nslookup
> policy
#Lookups = 3
dns[RRCR] nis[RRCR] files[RRRR]

... does anyone no - FOR DEFINITE - that this changed in 11i, it's just I work for/with HP customers and they are asking "where's the documentation for this change???" ... mucho-ta
ochayethinoojimmy
Pete Randall
Outstanding Contributor

Re: nsswitch.conf ... changed policy at 11i

Thanks, Charles, I learned something new (or that I should have already known) today.

Pete

Pete
Pete Randall
Outstanding Contributor

Re: nsswitch.conf ... changed policy at 11i

Charles,

Here's the info from 2 of my systems (one 11.0, one 11.11):

# uname -r
B.11.00
# nslookup
Using /etc/hosts on: yukon

> policy
#Lookups = 3
files [RCCC] dns [RCCR] nis [RRRR]
> exit


$ uname -r
B.11.11
$ nslookup
Using /etc/hosts on: tsws1

> policy
#Lookups = 3
files [RCCC] dns [RCCR] nis [RRRR]
> exit
$

They look the same to me.

Pete

Pete
Pete Randall
Outstanding Contributor

Re: nsswitch.conf ... changed policy at 11i

Disregard, Charles. Since I'm using nsswitch, it's like comparing apples and kumquats. Sorry.

Pete

Pete