Edit user mistake

I think I have made a stupid mistake. I went to YaST>Security and Users>User and Group Management and changed my username. Now I can’t do anything (open home directory, start application, login, etc).

I tried changing back the username by going to YaST at init 3 and changing back to the previous username. But the problem is still there. Help!

Remember that Linux is case sensitive.

Check the owner ship of old user home directory

as root in a terminal

ls -n /home

this lists the ownership and group as UID and GID numbers. This is important since ownershipe is based in the UID/GID not the symbolic name. Names are just for us meat bags and really don’t mean much to the system and are just used to look up the UID/GID numbers.

Make sure that the UID of the account matches the UID of the directory. And the names match exactly.

I suppose the [edit] configuration files in your /home are disordered. I suggest using ‘chmod’ and ‘chown’ to set them according to your needs.

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

If you ONLY changed the name with which you login that shouldn’t really
hurt anything since nothing on the system really cares that much about the
name anyway but rather uses your UID to tag everything (for example, in
the filesystem). Post your username line from /etc/passwd and let’s see
if anything else is wrong. When you try to login what do you get back as
far as messages? Presumably ‘root’ can get in so what shows up in
/var/log/messages during an attempt to login with your broken user? Does
a new, randomly-named user work? Can you, as root, su to your broken user?

su - brokenuserhere

Good luck.

On 05/25/2010 10:06 AM, izaak86 wrote:
>
> I think I have made a stupid mistake. I went to YaST>Security and
> Users>User and Group Management and changed my username. Now I can’t do
> anything (open home directory, start application, login, etc).
>
> I tried changing back the username by going to YaST at init 3 and
> changing back to the previous username. But the problem is still there.
> Help!
>
>
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.12 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iQIcBAEBAgAGBQJL+/ixAAoJEF+XTK08PnB5VJgQAKjix0b//cOG/KUV4hhCXglH
WRLDAvbWOshs9tgpsesyGbtYiy8HInBTCgSJmI6g/skCxQnuTIggbqkND8yF547L
mndm5EL4eD9x/xIcemiZMgVpzUHgQ3vaGZ5LT/tIpLok/6JPwwiU62cLhRbPspAG
edVXgFjav3P72DnR0FGzXP28+/QsnEbTS283tXe2F1P3XEazpr21MxvPrZe6jlqm
LKBWE4lHSm4pvki68u3DQ76pnjmY9DICVlCpWU/85ikyMKLphevAQsYpsbhSdunz
J+vzc3bzRJ9Mv5lCSkUgHBOyGuYPiXKlm0TtfU2kTQqXiuYEAly8SonceiSLCG7M
ovUt4eHLnjN4Jdse+Sz5W75sakP+Wm5LMbM5vMQLlrWUs44GOedvbUesXwqERjQG
gcQr5mSF9+CLEAbP9kdujVEwYFPkoHem16qbonhL+AdCMRYPbqhLh/5BQWON0UPo
382i2IMNMz290hCCh6ozu9LOmL2s7rR2PAvFJYR5AoK1ouwHVqw4Ynpwjy5XklPB
UsIzSA/pYzDG9pHJ11DrfFxYSKLHZhkbWeCl2WjOTb2s/ftz0+Uqoe/DFgvIpS64
WYoT1ze0gdjEw/Nyy7GJz8FIJo6P1sWNcKBhb8GPakG9/FgxsYUY7RRTYdJFy77t
Vg8yaXkia/umFRja2qJO
=oawO
-----END PGP SIGNATURE-----

Ok. When I try to login the error messages that appear are

Could not update ICEauthority file /home/izaak/.ICEauthority
and
There is a problem with the configuration server. (/usr/lib/GConf/2/gconf-sanity-check-2 exited with status 256)
and
Nautilus could not create the following required folders:/home/izaak/Desktop, /home/izaak/.nautilus. Before running Nautilus, please create these folders, or set permissions such that Nautiluis can create them.

The output for ls -n /home is
total 20
drwxr-xr-x 50 1000 10 4096 2010-05-25 22:00 Izaak
drwx------ 2 0 0 16384 2010-05-18 18:52 lost+found

What should I do now?

You missed something: linux is case sensitive. You have a user izaak, and a home folder Izaak. Please post output of:


grep zaak /etc/passwd

What we have to do, is bring the *zaak stuff back to one izaak or one Izaak.

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

You still have not posted your /etc/passwd entry for your user. Also can
you login at a terminal? Did you try the other things suggested in my
previous post? Is your username lzaak and, if so, is your user’s home
directory set to /home/lzaak with a UID of 1000? having the line from
/etc/passwd would answer all of these.

Good luck.

On 05/25/2010 11:36 AM, izaak86 wrote:
>
> The output for ls -n /home is
> total 20
> drwxr-xr-x 50 1000 10 4096 2010-05-25 22:00 Izaak
> drwx------ 2 0 0 16384 2010-05-18 18:52 lost+found
>
> What should I do now?
>
>
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.12 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iQIcBAEBAgAGBQJL/AsFAAoJEF+XTK08PnB5JM0P/ibYFPiMpRwKkxGNJoZtj/sh
5hYa3fhu7fxTwA3o6WJjVS7KngGJUpcilJxzAUDqejdEHo+0FNpp39KeLYPJwq99
smiCCEzmSYH4D2+2jHAFtDOXNkYYqO2jvlnte2ATgyfQ6ed1kWrBTG+fNURlikUf
Zzqx8Ji4T7mILlMhaSncqEx6ulQVy/yxI3yF9ccfHG+rb9oz2RrvHx21Q+1xPYP8
esj+Ekxdf/pNHtDtpvKLhmwJNnxGrL2dMkIO/Dqgm8k3Yz/fZdF7CPFy3w8YnLUV
BJINXbsERCRFEa+NtdKb1MHWNyYVacgAlLiYBTBtaDZMozHnFSu/gh+O02Q5qnyT
XU622WbPeFihRE8Kj2zXx4lROklB2Sh5/flUMFjdl0NtXyRulqejIa335QIfNPqR
iM74mVRKW1msGMX4fGKcqw6YkNh3qZc/pQYmkc8Og9LQV4uITcXYSYoXVXViDeSx
IkNIm80KnhQG58EnL+FFC3V/7HO5I79HIGd8+i8D90cj/+7lImbqgdH8I1qjlf7+
a3mgif0B64gn7Shp2VZPpJW2jJsO7t2+tiWMc3djS4RFxfN4pXhws0ZLvAH2yjoB
Ke/AR27BEIH55K1a9hkTEX6FSHSbXVrPMir+7BmbUDrQtfUKV/xjjz2rPVPRjWgB
B/D2vWyEn1fbTtwb3L3J
=XUZb
-----END PGP SIGNATURE-----

I followed your steps. But the same problem with the same error messages appear.

You don’t get output of the command I posted? I need that to see how we can solve this.
Please, don’t be scared, your /home is still there, but you cannot reach it due to permission problems you created. This can all be recovered and solved.

Ok the output of

grep zaak /etc/passwd

is

izaak:x:100:100:Izaak Khaliq:/home/izaak:/bin/bash

How do make one ‘izaak’?

Hold on, I’ll write a reply that will solve matters, Izaak.

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Your username: izaak
Your home directory setting: /home/izaak
Your home directory: /home/Izaak

Try the following (as root since you can’t get in with your regular user):

mv /home/Izaak /home/izaak

Try your login once done.

Good luck.

On 05/25/2010 12:06 PM, izaak86 wrote:
>
> Ok the output of
> Code:
> --------------------
> grep zaak /etc/passwd
> --------------------
> is
> Code:
> --------------------
> izaak:x:100:100:Izaak Khaliq:/home/izaak:/bin/bash
> --------------------
>
>
> How do make one ‘izaak’?
>
>
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.12 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iQIcBAEBAgAGBQJL/BN6AAoJEF+XTK08PnB5Nh0P/RNL+Pr20OUwC4KNdOyQZs0K
09c2ah/ewX6dlVyLsRSKYrjaU7+ofa67TPGmc+fT5VFGn9vNcSRArk3fLZsKZhDq
/ByIvTshwA5MN0nCWycBuqMMwnO5sL70Txdat/69cJx9yQNoxdjPGlIQlUbZ/799
9l5MslDo3IZ3udTEH6UMKDHj9QU3FkoJ/r1t0af7YgVuVktZ78zswHT1ETgHe3T9
L3Rj656GDGskjdWHmRVeJahJbBKVzMIQwDz44s/DYZSEyXxq5hAoIM+mtRM35qe/
oNSsIebD6g4ztuT+MA3fDHEYyUn+UQinjJbGOzGZ7J79esyWzUzJIkbSsWMLzkWD
MDxQ7w4utbMfMIzu1hFkNI3whV0QUtZzNtr6CrzOyo2MExMQxa9CvLmImaZ08kCy
dTEGuvPz4gXUmsmjMDMcnvAmGysrdxrS2YEdltIrhWGVqBjswaUR42bc/CTr2+xF
W+eyCWKUNDDj2QYUN+fqhkDX1RylkkImTSilFHvJIEr0tgDQJIyPZ87zo/7gqqaq
TrLdmDGDBIj8esFMKelbpf5y23MxbRMUdfBpo4o+AsycAkGyfAgVBvruO9xfh8yE
mK4YoS7AAxVaacWcNi9f8LO9L4zJbrIezm98Qf6cTa3b4g8YjTXfIHUhZnvdmxmL
kIb4h0UxmHYL6g+r7obM
=pmgF
-----END PGP SIGNATURE-----

No need to do other things than this:

In the console, login as root.

First we’re going to rename the folder in /home to the user’s name:


mv /home/Izaak /home/izaak

Now we need to set the permissions for /home/izaak :


chown izaak /home/izaak -R
chgrp users /home/izaak -R

There will also be folders in /tmp that should be owned by izaak:


chown izaak /tmp/*izaak*
chgrp users /tmp/*izaak*

Now reboot and see if you can login.

I suddenly see something else: your user has a user_id of 100, where 1000 is the normal value. Please also post output of:


grep 100 /etc/passwd

Sorry I did not see this before

You will need to adjust the user_id value in Yast, change it from 100 to 1000, then perform the steps in my three step post.

It works. Definitely will learn from this. Thanks guys!

You’re welcome. Great it’s sorted now. Enjoy.