Unix Technical Forum

Strange permissions problem

This is a discussion on Strange permissions problem within the Gentoo Linux Support forums, part of the Unix Operating Systems category; --> Hi, When I start my gentoo system up I can't log in as a user. Kde hangs on initialising ...


Go Back   Unix Technical Forum > Unix Operating Systems > Gentoo Linux Support

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 02-21-2008, 10:30 AM
entwisi
 
Posts: n/a
Default Strange permissions problem

Hi,
When I start my gentoo system up I can't log in as a user. Kde hangs
on initialising peripherals. I found that by doing a console login as
root and changing permissions of /dev/null from crw-rw---- to 666 I could
then login. However I couldn't open a terminal etc as it never responded.
No devices worked (Sound etc). Now if during that login I chmod -R 777
/dev everything works as normal. What should the permissions be on /dev
and how do I set it so that they are by default?

Thanks

--
Entwisi
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 02-21-2008, 10:30 AM
Ben Measures
 
Posts: n/a
Default Re: Strange permissions problem

entwisi wrote:
>
> When I start my gentoo system up I can't log in as a user.


Any error messages?

> I found that by doing a console login as
> root and changing permissions of /dev/null from crw-rw---- to 666 I could
> then login.


# ls -l /dev/null
crw-rw-rw- 1 root root 1, 3 Sep 27 14:35 /dev/null

Do you know of any reason why your /dev/null might revert to crw-rw----?

> What should the permissions be on /dev
> and how do I set it so that they are by default?


# ls -l / | grep 'dev'
drwxr-xr-x 16 root root 3520 Sep 27 13:36 dev


Is this a new installation? Has your system ever been working correctly?
What changed?

--
Ben M.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 02-21-2008, 10:30 AM
entwisi
 
Posts: n/a
Default Re: Strange permissions problem

On Tue, 27 Sep 2005 14:46:02 +0000, Ben Measures wrote:

> entwisi wrote:
>>
>> When I start my gentoo system up I can't log in as a user.

>
> Any error messages?


Nope, just hangs, nothing in /var/log/everything/current I have to kill X
to get control back

>
>> I found that by doing a console login as root and changing permissions
>> of /dev/null from crw-rw---- to 666 I could then login.

>
> # ls -l /dev/null
> crw-rw-rw- 1 root root 1, 3 Sep 27 14:35 /dev/null


Fine, that is what my other gentoo laptop is as well
>
> Do you know of any reason why your /dev/null might revert to crw-rw----?
>


Absolutely no idea that's why I'm asking. I'm wondering if something was
updated during an emerge -u world

>> What should the permissions be on /dev and how do I set it so that they
>> are by default?

>
> # ls -l / | grep 'dev'
> drwxr-xr-x 16 root root 3520 Sep 27 13:36 dev
>
>
> Is this a new installation? Has your system ever been working correctly?
> What changed?

It is a relatively new install but was working fine until a couple of
weeks ago. Unfortunately the lappy had to go back as it developed a screen
fault so I'm not sure of an exact date it started doing it. It gets reset
everytime I restart the laptop. What process sets up the /dev hierarchy on
bootup?

--
Entwisi

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #4 (permalink)  
Old 02-21-2008, 10:31 AM
Ben Measures
 
Posts: n/a
Default Re: Strange permissions problem

entwisi wrote:
> On Tue, 27 Sep 2005 14:46:02 +0000, Ben Measures wrote:
>>entwisi wrote:
>>
>>>When I start my gentoo system up I can't log in as a user.

>>
>>Any error messages?

>
> Nope, just hangs, nothing in /var/log/everything/current I have to kill X
> to get control back


Oh, an X login as user. If not explicitly stated, a console login is
assumed (we are on *nix, you know).

>>Do you know of any reason why your /dev/null might revert to crw-rw----?

>
> Absolutely no idea that's why I'm asking. I'm wondering if something was
> updated during an emerge -u world
>
> [...] What process sets up the /dev hierarchy on
> bootup?


Do you have udev? If so, check you have the following line in
/etc/udev/rules.d/50-udev.rules :
> KERNEL=="null", NAME="%k", MODE="0666"


Also, check /etc/udev/permissions.d/50-udev.permissions for:
> null:root:root:0666


Hth,
--
Ben M.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #5 (permalink)  
Old 02-21-2008, 10:31 AM
entwisi
 
Posts: n/a
Default Re: Strange permissions problem

On Wed, 28 Sep 2005 10:05:47 +0000, Ben Measures wrote:

>
> Do you have udev? If so, check you have the following line in
> /etc/udev/rules.d/50-udev.rules :
>> KERNEL=="null", NAME="%k", MODE="0666"

>

This exists but I noticed that a lot of stuff is set to 0600, Am I right
in thinking that I can change these to 0666?

--
Entwisi
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #6 (permalink)  
Old 02-21-2008, 10:31 AM
Ben Measures
 
Posts: n/a
Default Re: Strange permissions problem

entwisi wrote:
> Ben Measures wrote:
>
>>Do you have udev? If so, check you have the following line in
>>/etc/udev/rules.d/50-udev.rules :
>>
>>>KERNEL=="null", NAME="%k", MODE="0666"

>
> This exists but I noticed that a lot of stuff is set to 0600, Am I right
> in thinking that I can change these to 0666?


No, some things do need to be 0600.

Since udev is creating /dev/null with mode="0666" there must be
something else changing the mode afterwards. What it is I'm not sure -
all out of ideas here.

--
Ben M.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 05:04 PM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0
www.UnixAdminTalk.com