LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
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
  Search this Thread
Old 05-25-2020, 10:06 PM   #1
gmhafiz
LQ Newbie
 
Registered: May 2006
Posts: 10

Rep: Reputation: 0
broken /etc/passwd? Cannot login. Possibly Active Directory related


For some reason I can no longer login to one of my accounts (ORGhs)

Here is my /etc/passwd content:

Code:
ORGhs:x:1002:44::/home/ORGhs:/bin/sh
hafiz:x:1000:1000:My Name Local:/home/hafiz:/bin/bash
The ORGhs account is set up for Active Directory. It used to be weirdly named ORG^hs (yes, with a caret). But to login, it is ORG\hs. This user's home locations is at /home/ORG/hs I have no idea how and why it is now changed to ORGhs and why it is using sh instead of bash.

When I try to login from `hafiz` account:
Code:
su - ORG\hs
Password:
It prompts for password, but my password fails.

I also tried
Code:
su - ORGhs
Password: 
su: Authentication failure
I've tried to change the password from a root account
Code:
sudo su
passwd ORG\hs
passwd: Authentication token manipulation error
passwd: password unchanged
I'm guessing I cannot change Microsoft's Active Directory from the computer


I also cannot select ORG\hs from login screen.
Before, I had to wait for a while before ORG\hs appears as a selection. Now, it won't appear at all and I had to login with hafiz account

OS: Ubuntu 20.04
 
Old 05-25-2020, 10:25 PM   #2
jailbait
LQ Guru
 
Registered: Feb 2003
Location: Mineral, Virginia
Distribution: Debian 8
Posts: 7,873

Rep: Reputation: 317Reputation: 317Reputation: 317Reputation: 317
I would guess that there is a problem with the way that the authentication routine is handling the special character in the user name. I suggest that you use root to change the user name to something bland using the usermod -l command. You may also have to change the home directory name and the password. See:

man usermod

---------------------
Steve Stites
 
Old 05-25-2020, 10:46 PM   #3
berndbausch
Senior Member
 
Registered: Nov 2013
Location: Tokyo
Distribution: A few
Posts: 4,783

Rep: Reputation: 1421Reputation: 1421Reputation: 1421Reputation: 1421Reputation: 1421Reputation: 1421Reputation: 1421Reputation: 1421Reputation: 1421Reputation: 1421
The backslash is a special character for the shell. su ORG\hs will be converted to su ORGhs. If the account name really contains a backslash, put single quotes around it or double the backslash, e.g. su - ORG\\hs.

The ORGhs account in /etc/password has nothing to do with AD. It's a local account.

You should be able to list all local and AD accounts with the command getent passwd. To only see AD accounts, it's probably getent -s ldap passwd.
 
1 members found this post helpful.
Old 05-26-2020, 01:03 AM   #4
gmhafiz
LQ Newbie
 
Registered: May 2006
Posts: 10

Original Poster
Rep: Reputation: 0
Hey, putting quotes around the username works!

I'll investigate on how to change username and home folder.


Thanks!
 
Old 05-26-2020, 11:29 PM   #5
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Centos 7.7 (?), Centos 8.1
Posts: 17,774

Rep: Reputation: 2537Reputation: 2537Reputation: 2537Reputation: 2537Reputation: 2537Reputation: 2537Reputation: 2537Reputation: 2537Reputation: 2537Reputation: 2537Reputation: 2537
Well, for AD, 'ORG\hs' is actually AD domain = 'ORG', user = 'hs', but you normally only see that format on the login screen in MSWin.
I doubt that you'd use that on a local linux login.
Not sure how you connect Linux to AD though.
 
  


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



Similar Threads
Thread Thread Starter Forum Replies Last Post
how to join ubnutu system with active directory also login into active directory user mani25288 Linux - Server 2 07-10-2017 09:56 AM
Problem with /etc/passwd and /etc/passwd- files linuxravindra414 Linux - Newbie 2 01-15-2011 05:17 AM
[SOLVED] /etc/passwd- & /etc/shadow- & /etc/group- Mr. Alex Linux - Newbie 1 12-31-2010 05:19 AM
/etc/passwd, /etc/shadow, /etc/group? Educate me :)! nutnut Linux - General 4 06-11-2005 07:47 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 01:08 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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration