[Bug 510740] New: /lib/apparmor/rc.apparmor.functions: line 435: echo: write error: No such file or directory
http://bugzilla.novell.com/show_bug.cgi?id=510740 Summary: /lib/apparmor/rc.apparmor.functions: line 435: echo: write error: No such file or directory Classification: openSUSE Product: openSUSE 11.1 Version: Final Platform: Other OS/Version: openSUSE 11.1 Status: NEW Severity: Normal Priority: P5 - None Component: AppArmor AssignedTo: jeffm@novell.com ReportedBy: suse-beta@cboltz.de QAContact: qa@suse.de Found By: Beta-Customer rcapparmor reload causes an error message on openSUSE 11.1: # rcapparmor reload Reloading AppArmor profiles done /lib/apparmor/rc.apparmor.functions: line 435: echo: write error: No such file or directory -- Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
http://bugzilla.novell.com/show_bug.cgi?id=510740 User jeffm@novell.com added comment http://bugzilla.novell.com/show_bug.cgi?id=510740#c1 Jeff Mahoney <jeffm@novell.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |NEEDINFO Info Provider| |suse-beta@cboltz.de --- Comment #1 from Jeff Mahoney <jeffm@novell.com> 2009-10-15 13:42:34 MDT --- Do you recall if that happened every time or just occasionally? The only way that can happen is if /sys/kernel/security/apparmor isn't mounted. -- Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
http://bugzilla.novell.com/show_bug.cgi?id=510740 User suse-beta@cboltz.de added comment http://bugzilla.novell.com/show_bug.cgi?id=510740#c2 Christian Boltz <suse-beta@cboltz.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEEDINFO |NEW Info Provider|suse-beta@cboltz.de | --- Comment #2 from Christian Boltz <suse-beta@cboltz.de> 2009-10-16 01:44:32 CEST --- I just tested this on three 11.1 servers - two (always) show the error message on a "rcapparmor restart", the other never does (tested 5 times on each server to be sure it happens every time). /sys/kernel/security is mounted on all servers - this probably means there _is_ another way that causes this error message ;-) Thinking about it, the two servers that show the error message share nearly the same set of profiles. I just addded some debugging code and found out it only happens on my /usr/lib/postfix/local profile. /usr/lib/postfix/local { #include <abstractions/base> [...] profile "^/usr/lib/postfix/local " { /usr/lib/mailman/mail/mailman Px, } } Needless to say that this sub-profile looks a bit strange. I especially wonder about the space at the end of the name. (The question why this sub-profile exists at all is another issue, but I have no idea about this.) After running "rcapparmor stop", the strange subprofile is still loaded: # cat /sys/kernel/security/apparmor/profiles /usr/lib/postfix/local//^/usr/lib/postfix/local (enforce) The script echo's "/usr/lib/postfix/local//^/usr/lib/postfix/local" (without space!) to /sys/kernel/security/apparmor/.remove I just verified that this really causes the error message by removing the sub-profile and calling echo -n '/usr/lib/postfix/local//^/usr/lib/postfix/local ' > /sys/kernel/security/apparmor/.remove Now rcapparmor restart works without the error message. -> the space must be lost somewhere - maybe there's variable quoting missing somewhere in the script. -- Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
http://bugzilla.novell.com/show_bug.cgi?id=510740 User suse-beta@cboltz.de added comment http://bugzilla.novell.com/show_bug.cgi?id=510740#c3 --- Comment #3 from Christian Boltz <suse-beta@cboltz.de> 2009-10-16 02:07:54 CEST --- some more debugging: the file $MODULE_PLIST contains the space. This means the space must be lost in this line: sort "$PNAMES_LIST" | comm -2 -3 "$MODULE_PLIST" - | while read profile ; do comm worked fine on some test files, therefore I googled for "bash read space" and found http://dbaspot.com/forums/shell/372688-bash-read-string-preceding-trailing-s... The solution is to unset $IFS in /lib/apparmor/rc.apparmor.functions line 434: - sort "$PNAMES_LIST" | comm -2 -3 "$MODULE_PLIST" - | while read profile ; do + sort "$PNAMES_LIST" | comm -2 -3 "$MODULE_PLIST" - | while IFS= read profile ; do # ignore the line break in bugzilla Please apply this fix to the rc.apparmor.functions script. BTW: You'll get the "No such file or directory" message if you try to remove a profile that is not loaded (or doesn't exist). Try yourself: echo '/does/not_exist' > /sys/kernel/security/apparmor/.remove -- Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
http://bugzilla.novell.com/show_bug.cgi?id=510740 User jeffm@novell.com added comment http://bugzilla.novell.com/show_bug.cgi?id=510740#c4 Jeff Mahoney <jeffm@novell.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |ASSIGNED --- Comment #4 from Jeff Mahoney <jeffm@novell.com> 2009-10-15 18:47:49 MDT --- Great! Thanks for the debugging effort. I'll work this into the package tomorrow morning. -- Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
http://bugzilla.novell.com/show_bug.cgi?id=510740 http://bugzilla.novell.com/show_bug.cgi?id=510740#c5 --- Comment #5 from Jeff Mahoney <jeffm@novell.com> 2010-01-21 22:54:50 UTC --- I've committed this fix to the security:apparmor:factory and will backport the fix to the various products later tonight. -- Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
http://bugzilla.novell.com/show_bug.cgi?id=510740 http://bugzilla.novell.com/show_bug.cgi?id=510740#c6 Jeff Mahoney <jeffm@novell.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |aj@novell.com, | |ast@novell.com --- Comment #6 from Jeff Mahoney <jeffm@novell.com> 2010-03-15 19:35:41 UTC --- I've submitted fixes for SLE11 SP1 and openSUSE 11.2. openSUSE 11.1 is out of scope. Anja, I have three fixes queued up for apparmor-parser. SR 34867 -- Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
http://bugzilla.novell.com/show_bug.cgi?id=510740 http://bugzilla.novell.com/show_bug.cgi?id=510740#c Jeff Mahoney <jeffm@novell.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |NEEDINFO Info Provider| |ast@novell.com -- Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
http://bugzilla.novell.com/show_bug.cgi?id=510740 http://bugzilla.novell.com/show_bug.cgi?id=510740#c7 Christian Dengler <cdengler@novell.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEEDINFO |ASSIGNED CC| |cdengler@novell.com Info Provider|ast@novell.com | --- Comment #7 from Christian Dengler <cdengler@novell.com> 2010-03-17 12:07:28 UTC --- ok, we so kind and submit a patchinfo for 11.2; swampID: 32010 -- Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
http://bugzilla.novell.com/show_bug.cgi?id=510740 http://bugzilla.novell.com/show_bug.cgi?id=510740#c8 Swamp Workflow Management <swamp@suse.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status Whiteboard| |maint:running:32010 --- Comment #8 from Swamp Workflow Management <swamp@suse.com> 2010-03-18 18:10:43 UTC --- The SWAMPID for this issue is 32010. Please submit the patch and patchinfo file using this ID. (https://swamp.suse.de/webswamp/wf/32010) -- Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
http://bugzilla.novell.com/show_bug.cgi?id=510740 http://bugzilla.novell.com/show_bug.cgi?id=510740#c9 Swamp Workflow Management <swamp@suse.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status Whiteboard|maint:running:32010 |maint:running:32010 | |maint:released:11.2:32215 --- Comment #9 from Swamp Workflow Management <swamp@suse.com> 2010-04-06 11:53:43 UTC --- Update released for: apparmor-parser, apparmor-parser-debuginfo, apparmor-parser-debugsource, apparmor-utils Products: openSUSE 11.2 (debug, i586, x86_64) -- Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
http://bugzilla.novell.com/show_bug.cgi?id=510740 http://bugzilla.novell.com/show_bug.cgi?id=510740#c Swamp Workflow Management <swamp@suse.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status Whiteboard|maint:running:32010 |. |maint:released:11.2:32215 | -- Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=510740 https://bugzilla.novell.com/show_bug.cgi?id=510740#c10 Christian Boltz <suse-beta@cboltz.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Component|AppArmor |AppArmor Version|Final |Factory Product|openSUSE 11.1 |openSUSE 11.3 --- Comment #10 from Christian Boltz <suse-beta@cboltz.de> 2010-11-27 22:53:17 CET --- Unfortunately this fix was lost again in 11.3 :-( A update just for this would be exaggeratedly, but you should include it if you ever release an update for apparmor-parser on 11.3. More important: The 2.5.1 packages in security:apparmor also miss this fix - please apply the fix from comment #3 there! -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=510740 https://bugzilla.novell.com/show_bug.cgi?id=510740#c Christian Boltz <suse-beta@cboltz.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Component|AppArmor |AppArmor Product|openSUSE 11.3 |openSUSE 11.4 -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=510740 https://bugzilla.novell.com/show_bug.cgi?id=510740#c11 Alexandr Mityunin <avm-xandry@yandex.ru> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |avm-xandry@yandex.ru --- Comment #11 from Alexandr Mityunin <avm-xandry@yandex.ru> 2010-11-28 06:22:11 UTC --- I'm replaced line 434 /lib/apparmor/rc.apparmor.functions on + sort "$PNAMES_LIST" | comm -2 -3 "$MODULE_PLIST" - | while IFS= read profile ; do # ignore the line break in bugzilla but now i see new error:
sudo /etc/init.d/boot.apparmor start /lib/apparmor/rc.apparmor.functions: line 439: syntax error near unexpected token `;' /lib/apparmor/rc.apparmor.functions: line 439: ` ; do # ignore the line break in bugzilla' /lib/apparmor/rc.apparmor.functions: line 345: configure_owlsm: command not found Loading AppArmor profiles done
done What's wrong? P.S.: openSUSE 11.3
susepaste /lib/apparmor/rc.apparmor.functions Pasted as: http://susepaste.org/57531528
-- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=510740 https://bugzilla.novell.com/show_bug.cgi?id=510740#c12 --- Comment #12 from Christian Boltz <suse-beta@cboltz.de> 2010-11-28 17:57:12 CET --- (In reply to comment #11)
I'm replaced line 434 /lib/apparmor/rc.apparmor.functions on + sort "$PNAMES_LIST" | comm -2 -3 "$MODULE_PLIST" - | while IFS= read profile ; do # ignore the line break in bugzilla
but now i see new error: .. What's wrong?
The line has to be: sort "$PNAMES_LIST" | comm -2 -3 "$MODULE_PLIST" - | while IFS= read profile ; do It looks like you did something wrong, maybe you added a linebreak in front of the ";" or you accidently included the "+" when copying the line.
http://susepaste.org/57531528 gives me a "404 not found" :-(
-- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=510740 https://bugzilla.novell.com/show_bug.cgi?id=510740#c13 --- Comment #13 from Alexandr Mityunin <avm-xandry@yandex.ru> 2010-11-29 11:50:30 UTC --- (In reply to comment #12) You are right. Thanks.
http://susepaste.org/57531528 gives me a "404 not found" :-(
Yeah, me too. :) -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=510740 https://bugzilla.novell.com/show_bug.cgi?id=510740#c14 --- Comment #14 from Jeff Mahoney <jeffm@novell.com> 2010-12-01 16:38:47 UTC --- Ok, thanks for the update. I've fixed this in the apparmor package in security:apparmor:factory and in the apparmor-parser package for openSUSE 11.3. I'll submit it to maintenance after I check to see if there are any other pending apparmor-parser reports for 11.3. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=510740 https://bugzilla.novell.com/show_bug.cgi?id=510740#c15 Jeff Mahoney <jeffm@novell.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |NEEDINFO InfoProvider| |maintenance@opensuse.org --- Comment #15 from Jeff Mahoney <jeffm@novell.com> 2010-12-01 19:00:55 UTC --- openSUSE 11.3 SR 54281 -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=510740 https://bugzilla.novell.com/show_bug.cgi?id=510740#c16 --- Comment #16 from Marcus Meissner <meissner@novell.com> 2010-12-01 21:37:56 UTC --- looks good +1 -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=510740 https://bugzilla.novell.com/show_bug.cgi?id=510740#c17 Swamp Workflow Management <swamp@suse.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status Whiteboard|. |. maint:running:37584:low --- Comment #17 from Swamp Workflow Management <swamp@suse.com> 2010-12-03 15:51:10 UTC --- The SWAMPID for this issue is 37584. This issue was rated as low. Please submit fixed packages until 2010-12-31. Also create a patchinfo file using this link: https://swamp.suse.de/webswamp/wf/37584 -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=510740 https://bugzilla.novell.com/show_bug.cgi?id=510740#c18 Christian Dengler <cdengler@novell.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEEDINFO |ASSIGNED InfoProvider|maintenance@opensuse.org | --- Comment #18 from Christian Dengler <cdengler@novell.com> 2010-12-06 13:16:23 UTC --- update started ... be so kind and add a patchinfo. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=510740 https://bugzilla.novell.com/show_bug.cgi?id=510740#c Swamp Workflow Management <swamp@suse.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status Whiteboard|. maint:running:37584:low |. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=510740 https://bugzilla.novell.com/show_bug.cgi?id=510740#c19 Jeff Mahoney <jeffm@novell.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |RESOLVED Resolution| |FIXED --- Comment #19 from Jeff Mahoney <jeffm@novell.com> 2011-01-11 14:40:01 UTC --- Looks like this was released w/o a patch info. Sorry for dragging my feet on that. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=510740 https://bugzilla.novell.com/show_bug.cgi?id=510740#c20 Christian Boltz <suse-beta@cboltz.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |VERIFIED --- Comment #20 from Christian Boltz <suse-beta@cboltz.de> 2011-01-11 17:27:50 CET --- VERIFIED on 11.3 VERIFIED in apparmor-parser-2.5.1 from security:apparmor - which hopefully arrives in Factory soon (I've seen the mail about the pending SR on opensuse-factory) -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
http://bugzilla.novell.com/show_bug.cgi?id=510740 http://bugzilla.novell.com/show_bug.cgi?id=510740#c21 --- Comment #21 from Bernhard Wiedemann <bwiedemann@suse.com> --- This is an autogenerated message for OBS integration: This bug (510740) was mentioned in https://build.opensuse.org/request/show/34867 11.2:Test / apparmor-parser https://build.opensuse.org/request/show/54281 11.3:Test / apparmor-parser https://build.opensuse.org/request/show/57759 11.2:Test / apparmor-parser -- You are receiving this mail because: You are on the CC list for the bug.
participants (1)
-
bugzilla_noreply@novell.com