LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Enterprise (https://www.linuxquestions.org/questions/linux-enterprise-47/)
-   -   Unable to change password for a specific user. (https://www.linuxquestions.org/questions/linux-enterprise-47/unable-to-change-password-for-a-specific-user-4175636603/)

gaatha2508 08-18-2018 01:08 AM

Unable to change password for a specific user.
 
Hello,

I am able to change passwords of all users except one. Any help regarding this issue will be highly appreciated. Thanks in advance.

[root@EMS003 ~]# uname -a
Linux MS003 2.6.18-408.el5 #1 SMP Fri Dec 11 14:03:08 EST 2015 x86_64 x86_64 x86_64 GNU/Linux
[root@EMS003 ~]# passwd smith
Changing password for user smith.
New UNIX password:
Retype new UNIX password:
passwd: all authentication tokens updated successfully.
[root@EMS003 ~]# passwd helpdesk
Changing password for user helpdesk.
Changing password for helpdesk
(current) password:
Account cannot be accessed at this time.
Please contact your system administrator.
passwd: Authentication information cannot be recovered

--**--

pan64 08-18-2018 03:47 AM

do you have a user named helpdesk? how is this user configured?

gaatha2508 08-18-2018 05:00 AM

Quote:

Originally Posted by pan64 (Post 5892891)
do you have a user named helpdesk? how is this user configured?

Thanks for the response, Yes I have created the user helpdesk. I also tried by deleting the user 'helpdesk' and then recreated it. user's login shell is bin/bash, group is 'helpdesk' and its home directory is /home/helpdesk

cat /etc/passwd|grep helpdesk
helpdesk:x:572:572::/home/helpdesk:/bin/bash

cat /etc/passwd-|grep helpdesk
helpdesk:x:572:572::/home/helpdesk:/bin/bash

cat /etc/shadow|grep helpdesk
helpdesk:$1$Encrypttext$Encrypttext/Encrypttext.:17761:0:99999:7:::

cat /etc/shadow-|grep helpdesk
helpdesk:$1$Encrypttext$Encrypttext/Encrypttext.:17761:0:99999:7:::

cat /etc/group|grep helpdesk
helpdesk:x:572:

cat /etc/group-|grep helpdesk
helpdesk:x:572:

pan64 08-18-2018 09:52 AM

was that home dir created?

BW-userx 08-18-2018 10:46 AM

exaclty you forgot to check
Code:

ls /home
using adduser and deluser to create your users, as adduser creates the home dir without further prompting, whereas useradd does not. if it is not there then try installing it.

gaatha2508 08-19-2018 05:29 AM

Quote:

Originally Posted by pan64 (Post 5893001)
was that home dir created?

Quote:

Originally Posted by BW-userx (Post 5893020)
exaclty you forgot to check
Code:

ls /home
using adduser and deluser to create your users, as adduser creates the home dir without further prompting, whereas useradd does not. if it is not there then try installing it.

Sorry for the late reply. Yes there is a directory in /home/ named helpdesk with the permission 700.

TheEzekielProject 08-19-2018 05:39 AM

Quote:

Originally Posted by gaatha2508 (Post 5893272)
Sorry for the late reply. Yes there is a directory in /home/ named helpdesk with the permission 700.


Exactly how did you create this user?

TB0ne 08-19-2018 08:45 AM

Quote:

Originally Posted by gaatha2508 (Post 5892873)
Hello,
I am able to change passwords of all users except one. Any help regarding this issue will be highly appreciated. Thanks in advance.
Code:

[root@EMS003 ~]# uname -a
Linux MS003 2.6.18-408.el5 #1 SMP Fri Dec 11 14:03:08 EST 2015 x86_64 x86_64 x86_64 GNU/Linux
[root@EMS003 ~]# passwd smith
Changing password for user smith.
New UNIX password:
Retype new UNIX password:
passwd: all authentication tokens updated successfully.
[root@EMS003 ~]# passwd helpdesk
Changing password for user helpdesk.
Changing password for helpdesk
(current) password:
Account cannot be accessed at this time.
Please contact your system administrator.
passwd: Authentication information cannot be recovered


I have bolded a line in what you posted for emphasis. That isn't a typical message you'd see...unless the account was created in Active Directory/LDAP. Either the account exists in multiple locations (local *AND* AD/LDAP), or there is some sort of lock on the account on the authentication server.

What version/distro of Linux are you using, what authentication methods, and how was this user created initially?

gaatha2508 08-19-2018 10:17 AM

Quote:

Originally Posted by TB0ne (Post 5893309)
I have bolded a line in what you posted for emphasis. That isn't a typical message you'd see...unless the account was created in Active Directory/LDAP. Either the account exists in multiple locations (local *AND* AD/LDAP), or there is some sort of lock on the account on the authentication server.

What version/distro of Linux are you using, what authentication methods, and how was this user created initially?

This user was created as squirrelmail mail user. I am using Linux 5.11. I am able to change all others users account password except this one. So I deleted it using administration>'users and groups' gui utility.

TB0ne 08-19-2018 10:21 AM

Quote:

Originally Posted by gaatha2508 (Post 5893333)
This user was created as squirrelmail mail user. I am using Linux 5.11. I am able to change all others users account password except this one. So I deleted it using administration>'users and groups' gui utility.

Ok...then you don't have a SYSTEM user (which is what the passwd utility addresses), but a Squirrelmail user. Use Squirrelmail to change the password.

gaatha2508 08-19-2018 10:27 AM

Quote:

Originally Posted by TB0ne (Post 5893334)
Ok...then you don't have a SYSTEM user (which is what the passwd utility addresses), but a Squirrelmail user. Use Squirrelmail to change the password.

Thank you. I will update the result shortly.

gaatha2508 08-20-2018 12:29 AM

Quote:

Originally Posted by gaatha2508 (Post 5893338)
Thank you. I will update the result shortly.

No luck.. I am not able to change squirrelmail password for this account also. Always saying incorrect user or password.

gaatha2508 08-20-2018 01:21 AM

I got this. helpdesk is a Active Directory user which was locked due to multiple login attempts using wrong passwords. I reset the password in AD and tried same password to login. Fortunately I am now able to login into squirrelmail.

Thank you all for your solution and support. Cheers!

pan64 08-20-2018 06:50 AM

Quote:

Originally Posted by gaatha2508 (Post 5893544)
I got this. helpdesk is a Active Directory user

I asked about it in post #2.

TB0ne 08-20-2018 12:33 PM

Quote:

Originally Posted by pan64 (Post 5893602)
I asked about it in post #2.

Yep...and I mentioned AD/LDAP in post #8 as well. We were both ignored.


All times are GMT -5. The time now is 05:01 PM.