Find the answer to your Linux question:
Results 1 to 7 of 7
Hi all, Using my phone to send this due to this problem. I am the admin on my little netbook running fedora 17 xfce. I was tinkering with settings and ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    Jun 2012
    Posts
    4

    Locked out from log in due to /nologin mess up


    Hi all,
    Using my phone to send this due to this problem. I am the admin on my little netbook running fedora 17 xfce. I was tinkering with settings and messed up by choosing sbin/bash/nologin under accounts and then logging out. N ow, I can no longer log in (obviously) and can't help but think that I have screwed myself. I have research data on hdd and really can't afford a fresh install that would wipe my data. Then again, it may already be too late. Any assistance would be grand.
    Thanks
    Jim

  2. #2
    Linux Guru Lazydog's Avatar
    Join Date
    Jun 2004
    Location
    The Keystone State
    Posts
    2,677
    Grab the install CD and boot with it in RESCUE Mode and mount the systems disk. Then you an editor and edit /etc/passwd file and look for the user, which I am going to assume is root since you say you cannot log in at all, and change the shell to bash. This should allow you to log in then.

    If you have root access then you do not have to use the install cd, you can just edit the file.

    Regards
    Robert

    Linux
    The adventure of a life time.

    Linux User #296285
    Get Counted

  3. #3
    Just Joined!
    Join Date
    Jun 2012
    Posts
    4
    Thanks, Robert. I am having a devil of a time booting into rescue mode. I'll search the forum; however, do you have any advice?
    Thanks,
    Jim

  4. #4
    Just Joined!
    Join Date
    Jun 2012
    Posts
    4
    Found my answer.

    Jim

  5. #5
    Administrator jayd512's Avatar
    Join Date
    Feb 2008
    Location
    Kentucky
    Posts
    5,023
    Just for the sake of others who may be facing similar issues, what was your fix?
    Was it similar to what Lazydog suggested? Or something else?
    Jay

    New users, read this first.
    New Member FAQ
    Registered Linux User #463940
    I do not respond to private messages asking for Linux help. Please keep it on the public boards.

  6. #6
    Just Joined!
    Join Date
    Jun 2012
    Posts
    4
    I booted into single server. As root, I then ran the following:

    $ which bash

    (output of the above) was /usr/local/bin/bash

    $ chsh -s /usr/local/bin/bash <<user account name to change>>

    done.

    I found this at cybercity.biz under Setting bash as default shell.

  7. #7
    Linux Guru Lazydog's Avatar
    Join Date
    Jun 2004
    Location
    The Keystone State
    Posts
    2,677
    For those looking for a link
    Howto: Changing Linux Login Shell

    I had totally forgotten about this command, thus the old school way of doing this.

    Regards
    Robert

    Linux
    The adventure of a life time.

    Linux User #296285
    Get Counted

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •