The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > OS Specific Forums > Linux
Google UNIX.COM


Linux RedHat, Ubuntu, SUSE, Fedora, Debian, Mandriva, Slackware, Gentoo linux, PCLinuxOS. All Linux questions here!

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
/etc/passwd file been deleted gera_sachin125 SUN Solaris 5 02-11-2008 09:36 AM
Is there a way to recover files deleted using rm command??? kumarsaravana_s Shell Programming and Scripting 1 04-15-2007 01:23 PM
Passwd in the line command sandba Shell Programming and Scripting 1 08-22-2006 08:33 AM
passwd command not working rahulrathod UNIX for Dummies Questions & Answers 5 12-09-2004 11:46 AM
Deleted /etc/passwd cyno UNIX for Dummies Questions & Answers 5 08-11-2002 12:00 PM

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 06-07-2007
Registered User
 

Join Date: May 2007
Location: bangalore
Posts: 6
how to get passwd command again if it is deleted by usin rm command

hai friends i have deleted passwd command using rm command i thought it will come again at the time of rebooting but it is completely deleted how to get it worked again
Reply With Quote
Forum Sponsor
  #2 (permalink)  
Old 06-07-2007
Perderabo's Avatar
Unix Daemon
 

Join Date: Aug 2001
Location: Washington DC Area
Posts: 8,334
I think that the passwd program is in /bin on Linux, so restore the /bin/passwd file from backups just as you would any other file. And be careful when you are acting as root. If you accidentally delete a very critical file you might not be able to run the restore program. In the worst case you will need to re-install the OS. But /bin/passwd should not be needed during the restore, so you should be ok.
Reply With Quote
  #3 (permalink)  
Old 06-09-2007
Registered User
 

Join Date: May 2007
Location: bangalore
Posts: 6
thank you but...

i have deleted it when i was working in root now if want to get it again how it is possible i already used cp command to copy it from etc directory but it is not working
Reply With Quote
  #4 (permalink)  
Old 06-11-2007
zazzybob's Avatar
Registered Geek
 

Join Date: Dec 2003
Location: Melbourne, Australia
Posts: 2,100
/etc/passwd is the password database file - /bin/passwd is a binary executable used for changing passwords (amongst other things) - the two are not the same.

As Perderabo suggests, you need to restore /bin/passwd (or /usr/bin/passwd on some Linuxes) from a backup.

Cheers
ZB
Reply With Quote
  #5 (permalink)  
Old 06-11-2007
Registered User
 

Join Date: Feb 2006
Posts: 84
hello venkata.ganesh,

just get your rescue/installation CD,
go to rescue mode,
install the passwd file.

cheers.
Reply With Quote
Google UNIX.COM
Reply

Thread Tools
Display Modes




All times are GMT -7. The time now is 09:05 AM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited.
The UNIX and Linux Forums Content Copyright ©1993-2008 The CEP Blog All Rights Reserved -Ad Management by RedTyger Visit The Global Fact Book

Content Relevant URLs by vBSEO 3.2.0