You are not logged in.
Pages: 1
Something wrong happened with my users group. I can't figure out what it is:
[mk@linux ~]$ chown mk.users /home/mk/6.jpg
chown: wrong user: `mk.users'
[mk@linux ~]$ chown mk:users /home/mk/6.jpg
chown: wrong group: `mk:users'
[mk@linux ~]$ chown mk:100 /home/mk/6.jpg
(that's ok)
[mk@linux ~]$ chown root.root /home/mk/6.jpg
chown: wrong user: `root.root'
[mk@linux ~]$ chown root:root /home/mk/6.jpg
chown: wrong group: `root:root'
/etc/group: http://wklej.org/id/561293/
/etc/passwd: http://wklej.org/id/561294/
http://pliki.netau.net/images/screen23.png
It "works" this way on every file. Thanks for help.
--mod edit: use thumbnails, see https://wiki.archlinux.org/index.php/Fo … s_and_Code
Last edited by mkkot (2011-07-13 15:17:07)
Offline
Instead of posting a big screenshot in Polish you can show us the output of
ls -l /home/mk/6.jpg
[karol@black ~]$ touch foo
[karol@black ~]$ ls -l foo
-rw-r--r-- 1 karol users 0 07-13 15:47 foo
Seems pretty normal (you can change the defaults if you like).
Unfortunately I don't know what's wrong.
Offline
Isn't that big for me (and it shows 100 group instead of users group).
[mk@linux ~]$ ls -l /home/mk/6.jpg
-rw-r--r-- 1 mk 100 16882 2010-12-30 /home/mk/6.jpg
[mk@linux ~]$ touch foo
[mk@linux ~]$ ls -l foo
-rw-r--r-- 1 mk 100 0 07-13 15:46 foo
No idea as well. It worked before. The only thing I did recently is adding mk to wireshark group.
Last edited by mkkot (2011-07-13 13:47:15)
Offline
You have 'users::100:' in your /etc/group and I have
[karol@black ~]$ grep users /etc/group
users::100:karol
Try adding your user to the 'users' group.
Offline
Have you tried grpck -r?
Looks like some of your groups have been converted to shadow (gshadow) but not all.
Last edited by StuBouyer (2011-07-13 14:03:12)
Offline
I think you might have wrong. Asked my friend for pasting /etc/group and he also isn't in users. I believe that line in /etc/passwd:
mk:x:1000:100::/home/mk:/bin/bash
states, that 100 (users) group is a base group for user mk.
BTW chown works properly from root.
Last edited by mkkot (2011-07-13 14:02:02)
Offline
Have you tried grpck -r?
Looks like some of your groups have been converted to shadow (gshadow) but not all.
Umm, thanks, I didn't know about gshadow file at all. Here's what it says:
[root@linux mk]# grpck -r
group root has an entry in /etc/gshadow, but its password field in /etc/group is not set to 'x'
'mk' is a member of the 'bin' group in /etc/group but not in /etc/gshadow
group bin has an entry in /etc/gshadow, but its password field in /etc/group is not set to 'x'
group daemon has an entry in /etc/gshadow, but its password field in /etc/group is not set to 'x'
group sys has an entry in /etc/gshadow, but its password field in /etc/group is not set to 'x'
group adm has an entry in /etc/gshadow, but its password field in /etc/group is not set to 'x'
group tty has an entry in /etc/gshadow, but its password field in /etc/group is not set to 'x'
'mk' is a member of the 'disk' group in /etc/group but not in /etc/gshadow
group disk has an entry in /etc/gshadow, but its password field in /etc/group is not set to 'x'
group lp has an entry in /etc/gshadow, but its password field in /etc/group is not set to 'x'
group mem has an entry in /etc/gshadow, but its password field in /etc/group is not set to 'x'
group kmem has an entry in /etc/gshadow, but its password field in /etc/group is not set to 'x'
'mk' is a member of the 'wheel' group in /etc/group but not in /etc/gshadow
group wheel has an entry in /etc/gshadow, but its password field in /etc/group is not set to 'x'
group ftp has an entry in /etc/gshadow, but its password field in /etc/group is not set to 'x'
group mail has an entry in /etc/gshadow, but its password field in /etc/group is not set to 'x'
group uucp has an entry in /etc/gshadow, but its password field in /etc/group is not set to 'x'
'mk' is a member of the 'log' group in /etc/group but not in /etc/gshadow
group log has an entry in /etc/gshadow, but its password field in /etc/group is not set to 'x'
group locate has an entry in /etc/gshadow, but its password field in /etc/group is not set to 'x'
group smmsp has an entry in /etc/gshadow, but its password field in /etc/group is not set to 'x'
group http has an entry in /etc/gshadow, but its password field in /etc/group is not set to 'x'
'mk' is a member of the 'games' group in /etc/group but not in /etc/gshadow
group games has an entry in /etc/gshadow, but its password field in /etc/group is not set to 'x'
'mk' is a member of the 'video' group in /etc/group but not in /etc/gshadow
'mk' is a member of the 'audio' group in /etc/group but not in /etc/gshadow
group audio has an entry in /etc/gshadow, but its password field in /etc/group is not set to 'x'
'mk' is a member of the 'optical' group in /etc/group but not in /etc/gshadow
group optical has an entry in /etc/gshadow, but its password field in /etc/group is not set to 'x'
'mk' is a member of the 'floppy' group in /etc/group but not in /etc/gshadow
'mk' is a member of the 'storage' group in /etc/group but not in /etc/gshadow
'mk' is a member of the 'power' group in /etc/group but not in /etc/gshadow
group nobody has an entry in /etc/gshadow, but its password field in /etc/group is not set to 'x'
group users has an entry in /etc/gshadow, but its password field in /etc/group is not set to 'x'
'mk' is a member of the 'dbus' group in /etc/group but not in /etc/gshadow
'mk' is a member of the 'hal' group in /etc/group but not in /etc/gshadow
grpck: no changes
Offline
I think you might have wrong. Asked my friend for pasting /etc/group and he also isn't in users. I believe that line in /etc/passwd:
mk:x:1000:100::/home/mk:/bin/bash
states, that 100 (users) group is a base group for user mk.
BTW chown works properly from root.
I get it, maybe that's why it shows '100' and not 'users' as the group.
Offline
Add 'x' to all the entries in /etc/group that doesn't have them
So that they look like
network:x:90:
video:x:91:mk
Then add 'mk' to all the entries on /etc/ghadow that match /etc/group
In my gshadow some of the enties have 'x' and some have '!', but all entries in /etc/group have 'x'
Offline
Done. Removed hal group and fixed other minor things, now grpck -r shows empty output. Problem remains the same unfortunately.
/etc/group: http://wklej.org/id/561331/
/etc/passwd: http://wklej.org/id/561333/
/etc/gshadow: http://wklej.org/id/561334/
[mk@linux ~]$ chown mk.users /home/mk/cechy.pdf
chown: wrong user: `mk.users'
[mk@linux ~]$ chown mk:users /home/mk/cechy.pdf
chown: wrong group: `mk:users'
[mk@linux ~]$ chown root.root /home/mk/cechy.pdf
chown: wrong user: `root.root'
[mk@linux ~]$ chown root:root /home/mk/cechy.pdf
chown: wrong group: `root:root'
[mk@linux ~]$ su
Password:
[root@linux mk]# chown mk.users /home/mk/cechy.pdf
[root@linux mk]# ls -l /home/mk/cechy.pdf
-rw-r--r-- 1 mk users 38296 2010-08-12 /home/mk/cechy.pdf
[root@linux mk]# exit
exit
[mk@linux ~]$ ls -l /home/mk/cechy.pdf
-rw-r--r-- 1 mk 100 38296 2010-08-12 /home/mk/cechy.pdf
//edit: please note that from root's account it shows right group "mk users", and from mk's account it shows "mk 100".
Last edited by mkkot (2011-07-13 14:46:39)
Offline
I can't believe!
[mk@linux ~]$ ls -l /etc/group
-rw------- 1 root 0 557 07-13 16:29 /etc/group
[mk@linux ~]$ ls -l /etc/passwd
-rw-r--r-- 1 root 0 635 07-13 14:30 /etc/passwd
[mk@linux ~]$ ls -l /etc/gshadow
-rw-r--r-- 1 root 0 485 07-13 16:27 /etc/gshadow
su
chmod 644 /etc/group
Works!
Thank you all for the help
Last edited by mkkot (2011-07-13 15:17:36)
Offline
Pages: 1