LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 07-17-2005, 07:52 PM   #1
Salad Shooter
LQ Newbie
 
Registered: Aug 2004
Posts: 10

Rep: Reputation: 0
New User, Can no longer login


Okay...I did it, broke the cardinal rule and was running in root. It was only for a few minutes, right after the install, while I was trying to figure out how to get a non-root user added.

I'm not the most experienced Linux user, most of my time has been at school just simply using GCC and KDE.

I tried to change it so that it would login with bash (using chsh) and put in the wrong directory for bash (just put bash instead of the actual directory).

Unfortunately, now I cannot login as root, and I have no other accounts created yet.

The machine I'm running on is an ancient pentium, I've installed Slackware 8.0.0, using the 2.4.5. kernel.

I have a copy of Knoppix that I can use to boot up and change things, that way, but I'm not sure which file I would have to edit to get rid of the bad shell stuff.

If there's nothing I can do, this was a fresh install, so if I must, I can trash the install and start again, without losing anything but an hour or so of time.

Thanks!
 
Old 07-17-2005, 07:59 PM   #2
egag
Senior Member
 
Registered: Jul 2004
Location: Netherlands
Distribution: Slackware
Posts: 2,721

Rep: Reputation: 53
did you try to boot from the cd and follow onscreen instructions to start your system.
( bare.i mount root=/dev......etc ) ?

egag
 
Old 07-17-2005, 08:20 PM   #3
Salad Shooter
LQ Newbie
 
Registered: Aug 2004
Posts: 10

Original Poster
Rep: Reputation: 0
I can use the CD to log as root, but under the 2.2.something kernel, and only after cancelling out of the install.

Booting from the HDD gets me to the login section, I login as root, it logs in, then tells me "Cannot execute bash: No such file or directory"

Hopefully I'm not coming off as a complete idiot.
 
Old 07-17-2005, 08:28 PM   #4
KimVette
Senior Member
 
Registered: Dec 2004
Location: Lee, NH
Distribution: OpenSUSE, CentOS, RHEL
Posts: 1,794

Rep: Reputation: 46
does /bin/bash exist any more? if not, edit passwd to point the root user at /bin/tcsh or /bin/zsh so you can log in and re-install bash - or you could try copying /bin/bash from a live CD, overwriting the /bin/bash on your hard drive.
 
Old 07-17-2005, 08:41 PM   #5
Salad Shooter
LQ Newbie
 
Registered: Aug 2004
Posts: 10

Original Poster
Rep: Reputation: 0
Could you expound upon that? Sorry, as I said before, I am new to Linux, and perhaps Slack wasn't the best of options for me.

Which lines should I edit in passwd?

Thanks!
 
Old 07-17-2005, 09:13 PM   #6
Salad Shooter
LQ Newbie
 
Registered: Aug 2004
Posts: 10

Original Poster
Rep: Reputation: 0
It seems that I can't edit passwd. I change it, use cat the the file to see if it is changed, it is, and upon reboot, its back to the way it was before

I changed the line reading
root:x:0:0::/root:/bin/bash

to read
root:x:0:0::/root:/bin/ksh

but it keeps reverting upon rebooting

This is some stupid easy fix, and I know it. Just wish I knew what it was, so I didn't have to keep wasting all your time.
 
Old 07-17-2005, 10:55 PM   #7
Salad Shooter
LQ Newbie
 
Registered: Aug 2004
Posts: 10

Original Poster
Rep: Reputation: 0
Change took finally

Problem solved, thanks for your help!
 
  


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
Can no longer log in as user dive Slackware 7 07-31-2005 11:42 AM
Can no longer login.. TotalLinuxNoob Linux - General 1 05-14-2005 12:24 PM
System no longer boots to graphical login will103 Debian 3 01-08-2005 03:56 PM
KDE: kmix no longer start automatic on login Yalla-One Linux - Software 2 11-27-2004 04:22 PM
No longer able to login in GUI mode marvc Linux - Newbie 4 08-22-2002 06:06 PM

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

All times are GMT -5. The time now is 03:29 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