LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   Passwd and Shadow files synchronisation (https://www.linuxquestions.org/questions/linux-software-2/passwd-and-shadow-files-synchronisation-213218/)

sandras 08-04-2004 05:26 AM

Passwd and Shadow files synchronisation
 
Hi Everyone, newbies and Gurus,

I'm a newbie. I just installed Redhat 9 on an HP machine. I set up Squid, Samba and Sendmail. O'course with a lot of help from this site. Thanx.

However, I've encountered another hitch.

I copied the mailboxes, var/spool/mail/*, from the old linux machine to the new one using scp. I moved the home directories, /home/*; passwords /etc/passwd; shadow password file /etc/shadow; using scp to the respective directories on the new machine. I changed the permissions for the mailboxes to -rw-rw---- or 660.

The problem is when I open the Users and Groups under system settings it brings up the error "The user database cannot be read. The program will now exit". Then I got help that if there is a mismatch in the passwd and shadow files, then you'd have that problem. So I renamed the shadow file to shadow1 so that it could not be read and the Users and Groups opened. However, the root password was not being accepted for any connections. I tried to put back the shadow and root login was accepted but Users and Groups couldn't open. All this time the users could not access their mailboxes on port 110 because the passwords were being rejected

So, now I have removed the shadow file, set the root password and I can log in as root. And for each user whose password I set again they can login. Now my questions are:
1. Is there a way of synchronising the passwd and shadow files so that I could have no problem opening the Users and Groups Window?
2. How risky is it to run a mail server without the shadow file?

Please suggest what I should do.

Regards,
Sandras.

whansard 08-04-2004 05:42 AM

pwconv and pwunconv to convert between shadow, and regular passwords. maybe running them both will fix things.

have a look at this.
http://www.tldp.org/LDP/lame/LAME/li...e-formats.html

sandras 08-04-2004 09:00 AM

Thanks whansard. I ran both the commands and the shadow has been restored.

Mara 08-04-2004 10:09 AM

Moved: This thread is more suitable in Linux-Software and has been moved accordingly to help your thread/question get the exposure it deserves.


All times are GMT -5. The time now is 06:13 PM.