LinuxQuestions.org
Support LQ: Use code LQ3 and save $3 on Domain Registration
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices

Reply
 
LinkBack Search this Thread
Old 12-11-2005, 10:17 PM   #1
dwarf007
Member
 
Registered: Sep 2004
Location: Malaysia
Posts: 181

Rep: Reputation: 30
Set root password unexpired


Hi all,

I am facing a problem on the expiration on root account login. Can we actually set unexpired password to root account?

Anyone knows please help

Thank You.....
 
Old 12-11-2005, 11:18 PM   #2
btmiller
Senior Member
 
Registered: May 2004
Location: In the DC 'burbs
Distribution: Arch, Scientific Linux, Debian, Ubuntu
Posts: 3,995

Rep: Reputation: 261Reputation: 261Reputation: 261
Look at the -x option to passwd which specifies how many days before the password expires. You xcan set this to some huge value like 99999.
 
Old 12-12-2005, 01:22 AM   #3
dwarf007
Member
 
Registered: Sep 2004
Location: Malaysia
Posts: 181

Original Poster
Rep: Reputation: 30
Can we do this in the Init 5 level? Do we need to open the file /etc/passwd and look for row which have root?

Thank You.....
 
Old 12-12-2005, 01:33 AM   #4
btmiller
Senior Member
 
Registered: May 2004
Location: In the DC 'burbs
Distribution: Arch, Scientific Linux, Debian, Ubuntu
Posts: 3,995

Rep: Reputation: 261Reputation: 261Reputation: 261
No, just open up a terminal (as root) and do "passwd -x 99999 root". That should work, AFAIK.
 
Old 12-12-2005, 01:49 PM   #5
RaelOM
Member
 
Registered: Dec 2004
Posts: 110

Rep: Reputation: 16
You can also edit the /etc/shadow file directly (Not the best idea) and remove the expiration information at the end of the string.

usually like:

<user>:<hash>:13118:0:90:14:::

Just remove the 0, 90 and 14 and the account will be non-expiring.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
How could normal user obtain root password or change root password ckamheng Debian 18 02-18-2009 10:28 PM
Cannot Log into MySQL root password I just set... k41184 Linux - Software 3 07-18-2005 10:57 AM
unable to install LILO nor set root password aquilolumen Slackware - Installation 10 07-07-2005 01:15 PM
What should I do to set root password backpacker Linux - Newbie 1 06-10-2005 03:19 AM
Logged in as root, prompted for root password ta0kira Slackware 13 04-25-2005 01:29 AM


All times are GMT -5. The time now is 11:10 AM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration