HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials

HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials (http://www.howtoforge.com/forums/index.php)
-   HOWTO-Related Questions (http://www.howtoforge.com/forums/forumdisplay.php?f=2)
-   -   Perfect Server Ubuntu 9.10 ISPConfig2 AppArmor Issue (http://www.howtoforge.com/forums/showthread.php?t=40889)

dwtj01 11th November 2009 06:56

Perfect Server Ubuntu 9.10 ISPConfig2 AppArmor Issue
 
Hello All,

After following the Perfect Server Ubuntu 9.10 ISPConfig2 tutorial, everything runs great. However, I notice a brief error msg at boot concerning apparmor. Even though I followed the instructions to disable and uninstall it, there's a file "/etc/apparmor/functions" trying to call on individual apparmor files and failing because they're no longer there. Do you know how to get rid of this message.

I followed these 3 steps:
/etc/init.d/apparmor stop
update-rc.d -f apparmor remove
aptitude remove apparmor apparmor-utils

After I got the error message, I thought I may have done somthing wrong, so I reinstalled AppArmor, and then uninstalled again using the purge option.

/etc/init.d/apparmor stop
update-rc.d -f apparmor remove
aptitude remove --purge apparmor apparmor-utils

falko 12th November 2009 18:47

Do you know the exact error message? Do you see it when you run
Code:

dmesg
?

dwtj01 13th November 2009 01:36

Hey Timme,

It's an honor to talk with you. The error msg at boot is as follows:

/etc/apparmor/functions: Line 40: /sbin/apparmor_parser: No such file or directory

Thanks for your reply.

Dave

falko 13th November 2009 15:44

Well, I guess it's safe to ignore this error.
Anyway, what are the outputs of
Code:

ls -l /etc/default/
and
Code:

ls -l /etc/init.d/
?

dwtj01 15th November 2009 11:54

Hey Falko,

Sorry it took a few days for me to get back to you.

ls -l /etc/default displays:

provost@cerver2:~$ ls -l /etc/default/
total 84
-rw-r--r-- 1 root root 637 2009-08-18 08:01 apache2
-rw-r--r-- 1 root root 243 2009-11-14 15:32 apport
-rw-r--r-- 1 root root 103 2009-11-15 01:45 bind9
-rw-r--r-- 1 root root 47 2009-09-07 13:58 bootlogd
-rw-r--r-- 1 root root 1695 2009-11-14 15:19 console-setup
-rw-r--r-- 1 root root 92 2009-09-07 13:58 devpts
-rw-r--r-- 1 root root 327 2009-08-14 06:22 fetchmail
-rw-r--r-- 1 root root 797 2009-11-14 15:24 grub
-rw-r--r-- 1 root root 86 2009-09-07 13:58 halt
-rw-r--r-- 1 root root 19 2009-11-14 15:20 locale
-rw-r--r-- 1 root root 15 2009-10-22 23:30 ntp
-rw-r--r-- 1 root root 456 2009-10-22 23:30 ntpdate
-rw-r--r-- 1 root root 211 2009-06-08 05:56 proftpd
-rw-r--r-- 1 root root 123 2009-10-15 10:30 quota
-rw-r--r-- 1 root root 261 2009-11-14 15:25 rcS
-rw-r--r-- 1 root root 1352 2009-06-25 08:14 rsync
-rw-r--r-- 1 root root 1964 2009-11-15 02:29 saslauthd
-rw-r--r-- 1 root root 381 2009-10-22 14:58 ssh
-rw-r--r-- 1 root root 289 2009-09-07 13:58 tmpfs
-rw-r--r-- 1 root root 1670 2009-09-23 19:41 ufw
-rw-r--r-- 1 root root 1118 2009-07-31 08:59 useradd


ls -l /etc/init.d displays:

provost@cerver2:~$ ls -l /etc/init.d/
total 252
-rwxr-xr-x 1 root root 6461 2009-08-18 08:01 apache2
-rwxr-xr-x 1 root root 3314 2009-10-16 23:44 apparmor
lrwxrwxrwx 1 root root 21 2009-11-14 15:32 apport -> /lib/init/upstart-job
lrwxrwxrwx 1 root root 21 2009-11-14 15:23 atd -> /lib/init/upstart-job
-rwx------ 1 root root 3176 2009-11-15 03:40 bastille-firewall
-rwxr-xr-x 1 root root 3215 2009-08-19 16:55 bind9
-rwxr-xr-x 1 root root 2341 2009-09-07 13:58 bootlogd
-rwxr-xr-x 1 root root 1670 2009-07-06 06:10 console-setup
-rwxr-xr-x 1 root root 1010 2009-05-09 15:37 courier-authdaemon
-rwxr-xr-x 1 root root 2451 2009-09-18 18:12 courier-imap
-rwxr-xr-x 1 root root 2686 2009-09-18 18:12 courier-imap-ssl
-rwxr-xr-x 1 root root 2304 2009-09-18 18:12 courier-pop
-rwxr-xr-x 1 root root 2690 2009-09-18 18:12 courier-pop-ssl
lrwxrwxrwx 1 root root 21 2009-11-14 15:19 cron -> /lib/init/upstart-job
-rwxr-xr-x 1 root root 2038 2009-09-18 06:52 dcerpcd
lrwxrwxrwx 1 root root 21 2009-11-14 15:19 dmesg -> /lib/init/upstart-job
-rwxr-xr-x 1 root root 1235 2009-02-20 11:56 dns-clean
-rwxr-xr-x 1 root root 1995 2009-09-18 06:52 eventlogd
-rwxr-xr-x 1 root root 7401 2009-08-14 06:22 fetchmail
-rwxr-xr-x 1 root root 1105 2009-10-29 11:30 grub-common
-rwxr-xr-x 1 root root 1329 2009-09-07 13:58 halt
lrwxrwxrwx 1 root root 21 2009-11-14 15:19 hwclock -> /lib/init/upstart-job
lrwxrwxrwx 1 root root 21 2009-11-14 15:19 hwclock-save -> /lib/init/upstart-job
-rwx------ 1 root root 3759 2009-11-15 03:40 ispconfig_server
-rwxr-xr-x 1 root root 1404 2009-07-06 06:10 keyboard-setup
-rwxr-xr-x 1 root root 1293 2009-09-07 13:58 killprocs
-rwxr-xr-x 1 root root 2042 2009-09-18 06:52 lsassd
lrwxrwxrwx 1 root root 21 2009-11-14 15:19 module-init-tools -> /lib/init/upstart-job
-rwxr-xr-x 1 root root 5609 2009-10-07 09:59 mysql
-rwxr-xr-x 1 root root 1999 2009-09-18 06:52 netlogond
-rwxr-xr-x 1 root root 2070 2009-09-14 16:11 networking
-rwxr-xr-x 1 root root 1995 2009-09-18 06:52 npcmuxd
-rwxr-xr-x 1 root root 1909 2009-10-22 23:30 ntp
-rwxr-xr-x 1 root root 882 2009-09-07 13:58 ondemand
-rwxr-xr-x 1 root root 2338 2009-08-20 21:32 openbsd-inetd
-rwxr-xr-x 1 root root 4695 2009-09-22 08:56 postfix
-rwxr-xr-x 1 root root 420 2009-02-20 12:25 pppd-dns
lrwxrwxrwx 1 root root 21 2009-11-14 15:19 procps -> /lib/init/upstart-job
-rwxr-xr-x 1 root root 4981 2009-06-08 05:56 proftpd
-rwxr-xr-x 1 root root 3091 2009-10-15 10:30 quota
-rwxr-xr-x 1 root root 1705 2009-10-15 10:30 quotarpc
-rwxr-xr-x 1 root root 8863 2009-09-07 13:58 rc
-rwxr-xr-x 1 root root 801 2009-09-07 13:58 rc.local
-rwxr-xr-x 1 root root 117 2009-09-07 13:58 rcS
-rw-r--r-- 1 root root 1510 2009-09-07 13:58 README
-rwxr-xr-x 1 root root 639 2009-09-07 13:58 reboot
-rwxr-xr-x 1 root root 4310 2009-06-25 08:14 rsync
lrwxrwxrwx 1 root root 21 2009-11-14 15:19 rsyslog -> /lib/init/upstart-job
lrwxrwxrwx 1 root root 21 2009-11-14 15:19 rsyslog-kmsg -> /lib/init/upstart-job
-rwxr-xr-x 1 root root 8055 2009-08-20 20:47 saslauthd
-rwxr-xr-x 1 root root 1055 2009-07-06 00:36 screen-cleanup
-rwxr-xr-x 1 root root 2283 2009-09-07 13:58 sendsigs
-rwxr-xr-x 1 root root 590 2009-09-07 13:58 single
-rw-r--r-- 1 root root 4271 2009-09-07 13:58 skeleton
-rwxr-xr-x 1 root root 3878 2009-10-22 14:58 ssh
-rwxr-xr-x 1 root root 519 2009-09-07 13:58 stop-bootlogd
-rwxr-xr-x 1 root root 1095 2009-09-07 13:58 stop-bootlogd-single
lrwxrwxrwx 1 root root 21 2009-11-14 15:32 udev -> /lib/init/upstart-job
lrwxrwxrwx 1 root root 21 2009-11-14 15:32 udev-finish -> /lib/init/upstart-job
lrwxrwxrwx 1 root root 21 2009-11-14 15:32 udevmonitor -> /lib/init/upstart-job
lrwxrwxrwx 1 root root 21 2009-11-14 15:32 udevtrigger -> /lib/init/upstart-job
lrwxrwxrwx 1 root root 21 2009-11-14 15:23 ufw -> /lib/init/upstart-job
-rwxr-xr-x 1 root root 2746 2009-10-13 23:15 umountfs
-rwxr-xr-x 1 root root 2075 2009-10-13 23:16 umountnfs.sh
-rwxr-xr-x 1 root root 1683 2009-10-13 23:20 umountroot
-rwxr-xr-x 1 root root 1997 2009-09-07 13:58 urandom
-rwxr-xr-x 1 root root 2327 2009-09-19 16:04 wpa-ifupdown
-rwxr-xr-x 1 root root 1777 2008-12-04 18:44 x11-common

Looks like there's an entry for apparmor in init.d. Should I remove that?

Dave

falko 16th November 2009 13:50

Can you run
Code:

update-rc.d -f apparmor remove
again?

dwtj01 17th November 2009 07:02

Hey Falko,

Ran it again, and I still get the message. I also performed a complete reinstall and got the same result. Something is still trying to start apparmor.

Dave

dwtj01 18th November 2009 06:30

Confirmed the exact same behaviour on the 32 bit edition of Ubuntu server on a different machine. One apparmor is uninstalled and removed from rc.d, something still triest to start it.

Dave

dwtj01 18th November 2009 06:58

If figured out the issue. The file /etc/apparmor/initramfs tries to start the file /etc/apparmor/functions which in turn begins to try and load the apparmor modules that aren't there after an uninstall. I simply edited /etc/apparmor/initramfs with vi and commented out the following lines:

set -e

. /etc/apparmor/functions

mount -n -t securityfs none "${SECURITYFS}"
load_configured_profiles_without_caching


The boot message is now gone. Since apparmor in uninstalled at this point, would it be okay to just delete the /etc/apparmor directly entirely???

Dave

falko 18th November 2009 14:47

Quote:

Originally Posted by dwtj01 (Post 211070)
Since apparmor in uninstalled at this point, would it be okay to just delete the /etc/apparmor directly entirely???

I think it doesn't hurt to just leave the directory alone.


All times are GMT +2. The time now is 21:01.

Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.