LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Security
User Name
Password
Linux - Security This forum is for all security related questions.
Questions, tips, system compromises, firewalls, etc. are all included here.

Notices


Reply
  Search this Thread
Old 02-11-2007, 04:07 PM   #1
humbletech99
Member
 
Registered: Jun 2005
Posts: 374

Rep: Reputation: 30
passwd: Critical error - immediate abort


I have just discovered a very unusual thing. Trying to change any password on my gentoo laptop is now not possible using the standard passwd utility. It seems that every time I try to type this on the command line even as root it quits with an error that doesn't tell what the problem is.
Code:
# passwd
passwd: Critical error - immediate abort
The permissions on the passwd and shadow files is as follows
Code:
# ll /etc/passwd /etc/shadow 
-rw-r--r-- 1 root root 2219 Feb 11 21:53 /etc/passwd
-rw------- 1 root root 1000 Feb 11 21:56 /etc/shadow
An strace seems to indicate that the last thing that the passwd utility does is to open /etc/shadow and then do some seeking and then close it and write the error message.

I have found references to this all over the internet, mainly old redhat. The only solution I could see was to make sure the source was compiled with the right dict reference or something but I can't see how this could suddenly be a problem.

The shadow file seems to be in order having checked it out, as does the passwd file. Both have what look like fully functional lines for the root user and my regular user.
The last thing I did before trying to change the passwd of a new test user was to run unshadow from jtr. I guess this could have corrupted the original files but they look perfectly intact so my guess is there may be some file lock on /etc/shadow so I did an lsof /etc/shadow but this revealed nothing. I can still add and delete users using useradd and userdel but I can't set their passwords.

Any ideas how to check out if there is a file lock or how to fix this problem?
 
Old 02-11-2007, 04:10 PM   #2
stress_junkie
Senior Member
 
Registered: Dec 2005
Location: Massachusetts, USA
Distribution: Ubuntu 10.04 and CentOS 5.5
Posts: 3,873

Rep: Reputation: 335Reputation: 335Reputation: 335Reputation: 335
The shadow file should be owned by the shadow group, so ownership should be user root, group shadow.
 
Old 02-12-2007, 03:57 AM   #3
humbletech99
Member
 
Registered: Jun 2005
Posts: 374

Original Poster
Rep: Reputation: 30
I don't think so, on my other workstation which still works normally it is owned by root:root. That appears to be the default on gentoo.
 
Old 02-12-2007, 11:19 AM   #4
prasanta
Member
 
Registered: Mar 2005
Location: India
Distribution: Debian
Posts: 368

Rep: Reputation: 37
Just try running grpck on the group and shadow files. As stress_junkie said shadow file should be owned by the shadow group and user root.

--
Prasanta
 
Old 02-12-2007, 11:24 AM   #5
humbletech99
Member
 
Registered: Jun 2005
Posts: 374

Original Poster
Rep: Reputation: 30
ok I ran grpck and it returned without error and gave a return code of 0 for success.

I then tried to run passwd again and it failed again with exactly the same error.
 
Old 02-13-2007, 12:52 AM   #6
btmiller
Senior Member
 
Registered: May 2004
Location: In the DC 'burbs
Distribution: Arch, Scientific Linux, Debian, Ubuntu
Posts: 4,290

Rep: Reputation: 378Reputation: 378Reputation: 378Reputation: 378
The pwck command (to check /etc/passwd and /etc/shadow) might also help. IIRC grpck only checks /etc/group, but I may be wrong on that.
 
Old 02-13-2007, 11:06 PM   #7
prasanta
Member
 
Registered: Mar 2005
Location: India
Distribution: Debian
Posts: 368

Rep: Reputation: 37
What about using a brute force method of deleting the password from the shadow file and then using the passwd command for setting the password? Hope that this solves your problem.

--
Prasanta
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Error -> CRITICAL **: egg_desktop_entries ninoanima Fedora 2 10-11-2005 06:06 AM
GLib-GObject-CRITICAL ERROR Gerardoj Linux - Software 0 07-05-2004 08:52 PM
critical error in apache 1.3.29 linuxboy_inside Linux - General 2 12-07-2003 08:54 PM
Critical error while upgrading from 8.1>9 PLEASE HELP!!! stelmed Slackware 2 04-07-2003 07:36 PM
passwd: Critical error - immediate abort dojit Linux - General 2 03-07-2001 01:04 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Security

All times are GMT -5. The time now is 06:23 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration