LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Can't get GNOME to work, among other things (https://www.linuxquestions.org/questions/linux-newbie-8/cant-get-gnome-to-work-among-other-things-195433/)

Amethye 06-19-2004 04:21 PM

Can't get GNOME to work, among other things
 
I cant seem to start a session with GNOME with my normal account. It works well when I try it with the root account, but when I try using any other account, it just crashes and takes me back to the login screen. No error messages, no nothing. I *think*(heh) I screwed the permissions up, 'cos when i create any other account i cant use *neither* KDE nor GNOME(KDE gives out an error message out though, saying that I dont have write access to the home directory of the account).
I had the same KDE problem with my primary account(admin), but i fixed it logging in with root and editing the owner and permissions on /home/admin.
I think it happenned 'cos i reinstalled linux again, without uninstalling the old one(hoping for a repair heh) or reformatting the drive(I had some problems with WinXP on another HD).
So, is there a way to fix this?(Say, kill off *all* of the user accounts, refreshing the list)
Or am I screwed and should do a reinstall, with reformat?

Also, is the user account number and user account name make a difference when entered as the "owner"(Say my account is number 502, accountname is admin, so owner: 502 = owner: admin?)

And another thing, is there a way to edit the account number?(assuming its unused)

Uh, and sorry if these questions are too obvious(and for my bad english), i just have a whopping 7 hours of experience with linux

comprookie2000 06-19-2004 04:50 PM

If you only have 7 hours invested I would start over with a fresh install.

marghorp 06-19-2004 04:54 PM

You should change the permissions of the user directories(/home/username) and the home(/home) directory. Home directory must be set to 755 (rwxr-xr-x root:root). It will work either way, but it is safe to have it with these permissions. When changing the user directory permissions, set them with the command:

chmod -R 700 /home/username
chown -R username:username /home/username

the -R makes it change all the files permissions in that directory also.
the chown makes the users home directory owned by the user.

Probably GNOME wants to write the config files .gnome-xxxxxx and cannot. If this is the case, then these commands should help you. Don't worry, changing permissions to home directory, cant mess anything up.

Peace!

Andrew Benton 06-19-2004 04:56 PM

Log in as root and change the ownership of your home folder.
chown -R username:group /home/username

If the problem is permissions, like you say, then
chmod -R 755 /home/username

That's a bit of a blunt instrument changing the permissions of everything in the directory to 755 makes every file executable and allows any user to read it. I don't think I'd do that. If it was unfixable, what I'd do is move it out the way by renaming it and then make a clean, empty, home folder. Then you can copy individual files into your new home.

mv /home/username /home/usernameo
mkdir /home/username
chown username:group /home/username

Genesee 06-19-2004 04:59 PM

account #? do you mean userid? the userid is the third column if you "cat /etc/passwd"

no permissions on home dir? I assume you're in runlevel 5 - booting to a login manager? try

ctrl-alt-F1 (or F2-6)

then login as root, and check that permissions/ownership are right:

ls -l /home

also do "ls -la /home/username" (substitute your user for username) - make sure the user owns all the stuff listed there (owner is third column)

Mara 06-19-2004 05:03 PM

Re: Can't get GNOME to work, among other things
 
Quote:

Originally posted by Amethye

I had the same KDE problem with my primary account(admin), but i fixed it logging in with root and editing the owner and permissions on /home/admin.
I think it happenned 'cos i reinstalled linux again, without uninstalling the old one(hoping for a repair heh) or reformatting the drive(I had some problems with WinXP on another HD).
So, is there a way to fix this?(Say, kill off *all* of the user accounts, refreshing the list)
Or am I screwed and should do a reinstall, with reformat?

It looks like chown or changing user id number would help. It looks like you have now diffeent numbers that there were with previous install.

Quote:

Also, is the user account number and user account name make a difference when entered as the "owner"(Say my account is number 502, accountname is admin, so owner: 502 = owner: admin?)
Number is more important. If they match in /etc/passwd, you can use them both.

Quote:

And another thing, is there a way to edit the account number?(assuming its unused)
Yes. /etc/passwd
A line looks this way
Code:

username:x:UID:GID::/home/username:/bin/bash
where
UID is user ID, GID is group ID (groups are configured in /etc/group). If you change UID in /etc/passwd, the user will chave user ID changed.

Amethye 06-20-2004 04:54 AM

I solved the issue, turns out GNOME wanted permission to write its settings to /tmp/gconfd-admin, but the ownership was set to uid 501(uid of my old accout with the same name from a previous install), while mine was 502.
Thanks for the help.


All times are GMT -5. The time now is 10:21 AM.