Setting Up NIS, Users Can't Login

I would suggest not bothering with NIS. It's old, it's vulnerable, it's rarely used anywhere nowadays. Pretty much everybody uses LDAP instead of NIS.
 
I followed the instructions at https://docs.freebsd.org/en/books/handbook/network-servers/#network-nis to the letter and I am unable to successfully log into the system as a user:

Code:
Dec 14 07:40:43 cloud sshd[898]: error: PAM: Authentication error for daniel from 192.168.0.248

Running ypcat passwd shows:

Code:
root@cloud:~ # ypcat passwd
daniel:*:1001:1001:Daniel Morante:/home/daniel:/bin/sh
...

Are the instructions missing some steps?
This is not a NIS error in the first line. It is a PAM error. And that error is due to using PAM with sshd. So you have now a "matryoshka" with sshd->pam->nis . I am expecting that you do not have enabled NIS with pam ( e.g. pam_unix(8) look for "nis_pass")
Another opportunity is to disable PAM for ssh and use PKI for ssh. The challenge with that is, that yp/nis will not synchronise the home directories ( including ~/.ssh ) . nis/yp will only focus on the meta-files like user, group, hosts, ether etc.

I also have around ten devices at home, where I love to have the same UID/GID etc. on all system. But I still not sure , if this is the effort worth to dig into an old style piece of software from ARPA net. All other softwre like LDAP/AD etc. is IMHO to shot with canons on small birds ...
But your choice :D
 
Did you add the appropriate entries to master.passwd and group? Last line in /etc/master.passwd should read something along the lines of:
Code:
+:::::::::

and /etc/group should have something like:
Code:
+::0:
 
Back
Top