Bug 132099 - /sbin/start_udev is using /usr/sbin/setfiles
Summary: /sbin/start_udev is using /usr/sbin/setfiles
Keywords:
Status: CLOSED RAWHIDE
Alias: None
Product: Fedora
Classification: Fedora
Component: udev
Version: 3
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Harald Hoyer
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks: FC3Blocker
TreeView+ depends on / blocked
 
Reported: 2004-09-08 19:44 UTC by Michal Jaegermann
Modified: 2007-11-30 22:10 UTC (History)
1 user (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2004-09-14 16:23:48 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Michal Jaegermann 2004-09-08 19:44:07 UTC
Description of problem:

When booting with UDEV_TMPFS=yes I see in startup messages:

/sbin/start_udev: line 86: setfiles: command not found

This is not a big surprise as 'setfiles' lives in /usr/sbin
and is not yet available.  Either it has to be moved to /sbin
if it is really necessary on boot or 'start_udev' needs to do
something else.

Version-Release number of selected component (if applicable):
udev-030-20

How reproducible:
Always

Comment 1 Harald Hoyer 2004-09-09 07:34:36 UTC
already fixed... thx!

Comment 2 sangu 2004-09-09 16:23:45 UTC
The same problem happenes in udev-030-23.

Comment 3 Harald Hoyer 2004-09-10 09:12:12 UTC
/sbin/start_udev:

if [ -x /usr/sbin/setfiles
     -a -f /etc/selinux/$SELINUXTYPE/contexts/files/file_contexts ];then
   /usr/sbin/setfiles -q \
    /etc/selinux/$SELINUXTYPE/contexts/files/file_contexts /dev
fi

huh?? cannot be... are you sure this message comes after "Making extra
nodes" ???

Comment 4 sangu 2004-09-10 13:40:53 UTC
cat /sbin/start_udev
[...]
 if [ -f /etc/selinux/config ]; then
                . /etc/selinux/config
                if [ -x /usr/sbin/setfiles -a -f \
                       
/etc/selinux/$SELINUXTYPE/contexts/files/file_contexts ];then
                        /usr/sbin/setfiles -q \
                          
/etc/selinux/$SELINUXTYPE/contexts/files/file_contexts /dev
                fi
        fi
[...]

----
/etc/selinux/config in my linuxbox

cat /etc/selinux/config
# This is a comment field in /etc/sysconfig/selinux
#
# Allowable values are:
#     enforcing  -  enables enforcing mode
#     permissive -  enables permissive mode
#     disabled   -  disables SELinux
SELINUX=disabled

# SELINUXTYPE= can take one of these two values:
#       targeted - Only targeted network daemons are protected.
#       strict - Full SELinux protection.
SELINUXTYPE=strict

Is "/sbin/start_udev" stripts wrong?

SELinux is disabled in my linux box.

Because /sbin/start_udev scripts is checking whether
/etc/selinux/config file is or not, "/sbin/setfiles" file always works.


Comment 5 Michal Jaegermann 2004-09-10 15:50:03 UTC
> huh?? cannot be... are you sure this message comes after 
> "Making extra nodes" ???

I am confused.  This is a question about what and to whom?
The original report simply stated that 'start_udev' calls something
which may be not yet available because /usr partition will be
mounted only later.  Sticking in a call an explicit path is
obviously of no help.

Comment 6 Michal Jaegermann 2004-09-11 18:36:04 UTC
Unless you mean some other version then udev-030-24 which recently
showed up in rawhide this is still broken although possibly in
a different way.  This detail that you are checking now if
' ... -x /usr/sbin/setfiles -a ...' before trying to run it simply
means that file contexts will be not set properly if selinux is
turned on but /usr not mounted yet when this runs. 

'start_udev' should not run anything from /usr under any circumstances.


Note You need to log in before you can comment on or make changes to this bug.