Bug 138860

Summary: autorun does not work
Product: [Fedora] Fedora Reporter: Orion Poplawski <orion>
Component: autorunAssignee: Harald Hoyer <harald>
Status: CLOSED RAWHIDE QA Contact: Mike McLean <mikem>
Severity: medium Docs Contact:
Priority: medium    
Version: 3CC: derrien
Target Milestone: ---   
Target Release: ---   
Hardware: i386   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2005-02-02 11:01:08 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
Updated version of the above patch that works for me none

Description Orion Poplawski 2004-11-11 17:29:34 UTC
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.3)
Gecko/20040913

Description of problem:
autorun -v exits with:

No more devices to check.

Presumably /etc/fstab has changed sufficiently to break it.

Version-Release number of selected component (if applicable):
autorun-3.14-1

How reproducible:
Always

Steps to Reproduce:
1. Install fc3
2. Try to run autorun
3.
    

Additional info:

Comment 1 Derrien 2004-11-19 14:35:32 UTC
From man autorun :

To allow an ordinary user to do this you have to add the op-
tions user,exec in /etc/fstab to the CDROMs you want to use.

With HAL we have : pamconsole,ro,exec,noauto,managed
so you need to add user with something like this :

<?xml version="1.0" encoding="ISO-8859-1"?> <!-- -*- SGML -*- -->

<deviceinfo version="0.2">

<device>
    <match key="storage.drive_type" string="cdrom">
       <merge key="storage.policy.mount_option.user"
type="bool">true</merge>
    </match>
 </device>

</deviceinfo>

in /usr/share/hal/fdi/95userpolicy/storage-policy.fdi

Comment 2 Orion Poplawski 2004-11-19 16:55:33 UTC
The above changes hal to satisfy autorun.  We could also change
autorun to satisfy the hal changes.  It seems to me that the
"pamconsole" option has essentially replaced "owner".  Perhaps autorun
could be altered to recognized that option:

--- autorun.cc  2004-01-29 03:13:56.000000000 -0700
+++ autorun.cc.hal      2004-11-19 09:58:32.351219817 -0700
@@ -165,7 +165,8 @@
        continue;

       stat(mep->mnt_fsname, &sbuf);
-      if (((::strstr(mep->mnt_opts, "owner") &&
+      if ((((::strstr(mep->mnt_opts, "owner") ||
+           (::strstr(mep->mnt_opts, "pamconsole")) &&
            (sbuf.st_mode & S_IRUSR)) ||
           ::strstr(mep->mnt_opts, "user")) &&
          (::strstr(mep->mnt_type, MNTTYPE_ISO9660) ||


Comment 3 Orion Poplawski 2004-12-08 00:14:39 UTC
Created attachment 108075 [details]
Updated version of the above patch that works for me

Comment 4 Harald Hoyer 2005-02-02 11:01:08 UTC
ok, rawhide has a new version