LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > DamnSmallLinux
User Name
Password
DamnSmallLinux This forum is for the discussion of DamnSmallLinux.

Notices


Reply
  Search this Thread
Old 08-23-2009, 08:23 PM   #1
mkjohnson1977
LQ Newbie
 
Registered: Aug 2009
Posts: 4

Rep: Reputation: 0
DSL root password...stupid mistake


Must admit to probably the stupidest mistake one can make short of using the CD tray for a coffee cup holder...have apparently forgotten the root password in Damn Small Linux. Had DSL installed on HD, had everything configured, rebooted the computer, got to the "Box Login" prompt, entered DSL for the dsl user, and entered the password...or what I thought was the password and sorry, no dice. Same if trying to log in as root.

Booted the computer from a DSL iso CD and mounted hda2. Opened a terminal session and entered "sudo su". Got a command prompt as root. Edited /etc/passwd and /etc/shadow with vi. Removed everything between the first and second colon for both root and DSL users so I think neither should have a password. Saved both passwd and shadow files, rebooted computer without the CD. Still got the "Box Login" prompt. Tried logging in as DSL without a password and as root without a password, again, no dice.

Where do I go from here? I can reinstall DSL but will lose everything configured so far. Would probably serve me right, but would like to avoid that if possible.

Any advice appreciated.

Michael
 
Old 08-23-2009, 08:30 PM   #2
linus72
LQ Guru
 
Registered: Jan 2009
Location: Gordonsville-AKA Mayberry-Virginia
Distribution: Slack14.2/Many
Posts: 5,573

Rep: Reputation: 470Reputation: 470Reputation: 470Reputation: 470Reputation: 470
whats up bro?

you might have to reinstall

this time, when installing,
choose single user and you'll just autologin as root
like livecd

you did a frugal install or full install?
 
Old 08-23-2009, 11:15 PM   #3
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Rocky 9.2
Posts: 18,369

Rep: Reputation: 2753Reputation: 2753Reputation: 2753Reputation: 2753Reputation: 2753Reputation: 2753Reputation: 2753Reputation: 2753Reputation: 2753Reputation: 2753Reputation: 2753
Try again, only this time when you get in as root, just provide passwds you can remember, using the passwd cmd. For root its just

passwd
<enter new root passwd>
<repeat>

for other user, still logged in as root, provide username as well thus

passwd <username>
<enter new user passwd>
<repeat>
 
Old 08-24-2009, 07:45 AM   #4
mkjohnson1977
LQ Newbie
 
Registered: Aug 2009
Posts: 4

Original Poster
Rep: Reputation: 0
Reply to linus72: I believe I did a full install. I intended this PC to be a computer to download and configure software for a compact flash from which a little hard drive-less car computer will boot.

Reply to Chrism01: I think I have tried that but I will do it again to be sure. I've tried so many times to edit /etc/passwd and /etc/shadow that I can't remember the exact steps I've taken each time. I think though that I've booted from the iso cd and made it to the xvesa desktop environment. From there I've opened a terminal window, typed sudo su, then passwd and I've changed the root password. Then I've done the same as root for the dsl user. Once I reboot from the hard drive, the password I've just set doesn't work. After examining /etc/passwd, it looks the same as it did before I changed the password. I wonder if when I boot from the cd if I don't have write permissions on /etc/passwd? I am logged in as root so you'd think I should have rwx privileges on just about anything. I'll try as you suggested when I return home this evening and see what happens.

Thanks all for the advice.
 
  


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
Stupid mistake - changed root shell to /bin/false Kholnuu Linux - General 8 01-04-2005 03:48 AM
Big stupid Bad Mistake... GRUB dasz Linux - Software 7 12-09-2004 09:35 AM
DSL root password Joey.Dale Linux - General 1 08-04-2004 12:13 PM
What's the root password on DSL? Jestrik DamnSmallLinux 4 01-09-2004 10:07 PM
Stupid Mistake, WPC54G, not WPC11 Rv5 Red Hat 1 09-02-2003 01:50 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > DamnSmallLinux

All times are GMT -5. The time now is 03:39 PM.

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