You are not logged in.
After installing GNOME on a fresh install (besides installing and removing kde plasma), I can't login to my unpriveleged account "ben." When I enter the correct password, an identical screen like I was on reappears. Login is working with my root user.
A related problem with this is when I logout and switch user, the screen goes black and my computer suspends.
Logs
My /var/log/gdm folder is empty.
Output of journalctl -b
/var/log/Xorg.0.log
Above is also the error that is returned when doing ^C to stop startx
/var/log/Xorg.1.log
/etc/gdm/custom.conf
I have a feeling this is related as well:
(Logged in as root) if I go to /
[root@benpc ~]# cd /
[root@benpc /]# and ls
[root@benpc /]# ls
bin boot dev etc home lib lib64 lost+found New_York opt proc root run sbin srv sys tmp usr varbut if I cd into /home
[root@benpc /]# cd home
[root@benpc home]# and ls
[root@benpc home]# ls
[root@benpc home]# it is empty.
If I go to the ~ directory
[root@benpc home]# cd
[root@benpc ~]# Then ls
[root@benpc ~]# ls
Desktop Documents Downloads Music Pictures Public Templates VideosIs this normal behaviour or have I misconfigured something and if so what is it?
When logged in to GNOME as root, I open the 'files' application, then click the 'Home' tab, all files I would expect are here.
What directory is this showing? (Since my /home is empty)
Also, if it helps at all, according to GParted, my home partition (/dev/sda4) is mounted to /home. The home partition has no flags according to GParted.
I will be happy to provide any information for the purpose of resolving this issue.
I have done
pacman -Syuas root
Please let me know if anything in the post is not according to the rules or if anything has been done wrong, it is my first time posting here.
Last edited by kinru (2019-03-30 21:43:46)
Offline
Welcome to the arch linux forums kinru. What command did you use to create the user ben? When you try and log into the ben account from the console what is the result?
What is the output of
getent passwd ben
passwd -S benEdit:
Mar 30 10:55:59 benpc useradd[15943]: new user: name=ben, UID=1000, GID=1000, home=/home, shell=/bin/bashSee Users_and_groups#User_management
Mar 30 11:07:45 benpc useradd[16652]: new user: name=ben, UID=1000, GID=985, home=/root, shell=/bin/bashThis invocation is mixing up root and none root and system and user groups.
Edit2:
I advise against running startx as root.
Last edited by loqs (2019-03-30 17:52:38)
Offline
Thanks for replying!
What is the output of
getent passwd ben passwd -S ben
My output for the first is:
ben:x:1000:985::/root:/bin/bashAnd the second is;
ben P 03/30/2019 0 99999 7 -1I will check out the Users_and_groups#User_management as soon as I can.
Also, why is running startx as root bad? Is it because running it as root gives it the permissions to mess up other things?
Thank you for your help so far!
EDIT:
I forgot to add that I used
useradd -G wheel -M -d ~ benTo add "ben' user.
Last edited by kinru (2019-03-30 19:27:40)
Offline
useradd -G wheel -M -d ~ benThe call to useradd does not use -m
-m, --create-home
Create the user's home directory if it does not exist. The files
and directories contained in the skeleton directory (which can be
defined with the -k option) will be copied to the home directory.
By default, if this option is not specified and CREATE_HOME is not
enabled, no home directories are created.It does use -M
-M, --no-create-home
Do no create the user's home directory, even if the system wide
setting from /etc/login.defs (CREATE_HOME) is set to yes.and -d ~
-d, --home-dir HOME_DIR
The new user will be created using HOME_DIR as the value for the
user's login directory. The default is to append the LOGIN name to
BASE_DIR and use that as the login directory name. The directory
HOME_DIR does not have to exist but will not be created if it is
missing.So a home directory is not created but it is set to ~ which will be /root as the command was run as root. A none root user can not access /root so the user can not access their home directory.
Something went wrong on the second invocation of useradd in addition to the above instead of creating the primary group ben for the user ben the primary group has been set to 985.
As the wiki documents you would normally use the following to create user ben with default group ben creating home directory /home/ben and add ben to the group wheel.
useradd -m -G wheel benWhat is the output of
#ls -la /home #to check if the first useradd invocation placed any files in /homeIf there are any files in /home such as .bashrc (which will have been copied from /etc/skel) I would remove them
I would advise deleting the user ben then creating it with the options above. Set the password for the user then see if that user can login with GDM.
Running commands as root when they can be run as none root is an avoidable increase in attack / bug surface.
Offline
I forgot to add that I used
useradd -G wheel -M -d ~ benTo add "ben' user.
What guide did you use to install Arch?
Offline
your Xorg.0.log said the xserver is already running, and the other log (Xorg.1.log) looks like a successful run of X. are you sure that X isn't running?
ps -fC xinitif it is, then kill it
pkill xinitand try again. post relevant logs if you still have issues
Offline
My issue is fixed (will mark solved) but,
What is the output of
#ls -la /home #to check if the first useradd invocation placed any files in /home
was
total 12
drwxr-xr-x 3 root root 4096 Mar 28 20:55 .
drwxr-xr-x 16 root root 4096 Mar 28 16:10 ..Before the issue was corrected but is now
Now it is:
total 12
drwxr-xr-x 3 root root 4096 Mar 28 20:55 .
drwxr-xr-x 16 root root 4096 Mar 28 16:10 ..
drwx------ 13 ben ben 4096 Mar 30 17:32 benAlso:
What guide did you use to install Arch?
I used the official guide and search for solved posts on the forums when something didn't work for me (or when I did something wrong) for the actual install.
After the install though, I deviated from Users_and_groups#User_management when adding a user, because, I most likely initally followed instructions wrongly.
Offline