Question about nsswitch.conf

Hi,

I was told to add the "nis" in front of "files" for below lines in /etc/nsswitch.conf was not in a good practise. I tried to search in google and man page for nsswitch.conf and can't find the answer. could someone please help me?

passwd: nis files
shadow: nis files
group: nis files
hosts: nis files

Thanks

Well......that depends.

If you would like it to use NIS to find names, for name resolution, before looking in the hosts file, then it makes sense. If you are not using NIS for resolution of names and instead using DNS or hosts files, then it is a poor choice.

When discussing things like the passwd and shadow, have you thought about resiliency in the NIS setup, clustering, etc?

Are there even local users for those who would go to your NIS domain?

Thanks for your reply. We have NIS setup but I'm just curious if there is any negative affect if I put "nis" in front of "files" in this nsswitch.conf file. Thanks again.