Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How do you get-around password for Linux?

Status
Not open for further replies.

baxwink

Programmer
Feb 7, 2000
69
US
I have a Linux server that I bought at an auction but can't get into the OS (I don't know a lot about Linux) because it has a password. Is there a way to get around this? Thanks.
 
what Linux version,

i know in Red hat u can go into single usr mode with no passwd and root priv, i think i had to press tab during the lilo when it ask if i wanted to boot into linux, when i pressed TAB, it showed another installation ( single user) and that lets u write in
 
Hi,















If it boots to Linux but you don't know the root password its frighteningly to get round by default. All you do is reboot to the lilo 'boot:' prompt (if there's a graphical boot screen you will have to exit that with control-x or something first) then you type 'linux single' to boot into single user maintenance mode and you are root without logging in. You can then just change the root password. If its a Suse system then you'd do 'S' instead on 'single' :















boot: linux single















The system should stop with the superuser (root) prompt :















#















You just change the root password with the passwd command :















# passwd

(it prompts)













to shutdown (halt) do :















# /sbin/shutdown -h now















to reboot :















# /sbin/shutdown -r now















The problem you might have is that a shrewd user would have put a password on the lilo bootloader to protect against this scenario. In that case, you'd have to boot from CD or bootfloppy .















Hope this helps







 
another way would be to type this at the LILO prompt:

linux single init=/bin/bash

that should take u to single user mode and straight away into a valid shell.

good luck

 
Uhm.. A few comments:

1) if you just got the machine at auction, reinstall it so that it is "clean" ... then you wont have this problem

2) If you are trying to get around "root" locally, do as the above said...

3) if you are trying remotely... dont :)

-john ---
John Hoke<br>
 
I have written a faq in the FAQ section of this forum to do just what you need. Please check it out and let me know if it was helpful. d3funct
zimmer.jon@cfwy.com
The software required `Windows 95 or better', so I installed Linux.

 
I agree with johnhoke. You never know what someone might have done with that box. You could manage to get in, get your internet connection, etc... and then discover a year later that someone has been logging all your activites on that machine, and emailing your passwords and other info elsewhere. Or, someone might have left tools on the system to turn your box into a DoS attack station. Or, who knows what else.

Clean install is always the best choice in these cases. It will take you far longer to inspect the whole system and make sure it is safe. -------------------------------------------

&quot;Calculus is just the meaningless manipulation of higher symbols&quot;
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;-unknown F student
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top