From: Alan McKinnon <alan.mckinnon@gmail.com>
To: gentoo-user@lists.gentoo.org
Subject: Re: [gentoo-user] module woes
Date: Wed, 05 Feb 2014 19:57:43 +0200 [thread overview]
Message-ID: <52F27B97.7060609@gmail.com> (raw)
In-Reply-To: <loom.20140205T172700-163@post.gmane.org>
On 05/02/2014 18:50, James wrote:
> Ok,
>
> So I'm running Grub2, openrc, and a gentoo patched kernel. This is
> a new system I've been fiddling with, so the problem could easily
> be my oversite.
>
> I'v build several kernels. I go into the advanced tab upon reboot
> and boot up the latest kernel I've compiled, (3.13.1-gentoo). It
> boot fine. Printing works. lp and lpr still do not work for printing
> raw text files? I used cups and hplip (8600 pro officejet). All
> other printing is find.
>
>
> Here is what has me stumped.I started out with this kernel:
> kernel-3.10.25-gentoo. Since I have built and successfully
> ran (most things) on these kernels too: kernel-3.13.0-gentoo-r1
> and last: kernel-3.13.1-gentoo.
>
> I have built these kernels same way as all others
>
> cd /usr/src/
> ln -sf <target kernel> linux
> cd linux
> make && make modules && make modules_install
> cp arch/x86_64/boot/bzImage /boot/kernel-3.13.1-gentoo
> cp System.map /boot/System.map-3.13.1-gentoo
> cp .config /boot/config-3.13.1-gentoo
> grub2-mkconfig -o /boot/grub/grub.cfg
>
> So the new kernels work, but, besides permission problems, it only looks
> to the original /lib/modules/ dir for modules (example):
>
> # /etc/init.d/cupsd restart
> Stopping cupsd ...
> /etc/init.d/../conf.d/modules: line 25:
> /lib/modules/3.10.25-gentoo/kernel/drivers/char/kcopy/kcopy.ko: Permission
> denied
>
> <same for these modules: nf_nat_sip.ko, nf_nat_irc.ko
> xt_LOG.ko, xt_nat.ko xt_mark.ko nf_nat.ko
> nf_nat_ftp.ko ipt_MASQUERADE.ko iptable_nat.ko nf_nat_ipv4.ko>
>
> ERROR: modules failed to start
> Starting cupsd ...
>
> So what should the perms. be and what do I need to do to get it to
> point to the kernel I'm booting, 3.13.1-gentoo ?
Ordinarily permissions should not apply as it's root doing the work (the
kernel mostly pretends there are no permissions when root is involved).
FWIW, the permissions on all modules files is 644:
khamul modules # pwd
/lib/modules
khamul modules # ls -al
total 36
drwxr-xr-x 7 root root 4096 Jan 27 09:36 .
drwxr-xr-x 16 root root 12288 Feb 2 10:51 ..
drwxr-xr-x 4 root root 4096 Feb 2 09:42 3.11.10-gentoo
drwxr-xr-x 5 root root 4096 Feb 2 09:40 3.12.7-gentoo
drwxr-xr-x 5 root root 4096 Feb 2 09:40 3.12.8-gentoo
drwxr-xr-x 4 root root 4096 Feb 2 18:01 3.12.9-gentoo
drwxr-xr-x 4 root root 4096 Feb 2 09:43 3.13.0-gentoo-r1
khamul modules # find /lib/modules -type f -not -perm 644
khamul modules #
That's what I just get with make && make modules && make modules_install
with no further intervention.
But even your 600 permissions should also work as normal.
>
> It is a grub 2 thing or what?
> /lib/modules/3.13.1-gentoo/kernel/net/netfilter
> total 100K
> -rw------- 1 root root 25K Feb 4 09:17 nf_nat.ko
> -rw------- 1 root root 6.0K Feb 4 09:17 nf_nat_ftp.ko
> -rw------- 1 root root 5.6K Feb 4 09:17 nf_nat_irc.ko
> -rw------- 1 root root 15K Feb 4 09:17 nf_nat_sip.ko
> -rw------- 1 root root 22K Feb 4 09:17 xt_LOG.ko
> -rw------- 1 root root 4.5K Feb 4 09:17 xt_mark.ko
> -rw------- 1 root root 5.5K Feb 4 09:17 xt_nat.ko
>
> /lib/modules/3.10.25-gentoo/kernel/net/netfilter
> total 100K
> -rw-r--r-- 1 root root 27K Jan 14 23:28 nf_nat.ko
> -rw-r--r-- 1 root root 6.0K Jan 14 23:28 nf_nat_ftp.ko
> -rw-r--r-- 1 root root 5.5K Jan 14 23:28 nf_nat_irc.ko
> -rw-r--r-- 1 root root 16K Jan 14 23:28 nf_nat_sip.ko
> -rw-r--r-- 1 root root 22K Jan 14 23:28 xt_LOG.ko
> -rw-r--r-- 1 root root 4.5K Jan 14 23:28 xt_mark.ko
> -rw-r--r-- 1 root root 5.5K Jan 14 23:28 xt_nat.ko
>
>
> What did I miss, besides the permissions?
Do you have some MAC system like SELinux configured? Necessary
filesystems like /proc or /dev omitted in that problematic kernel?
I can't think of anything else that could interfere with root's ability
to do what root does.
--
Alan McKinnon
alan.mckinnon@gmail.com
next prev parent reply other threads:[~2014-02-05 17:58 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-02-05 16:50 [gentoo-user] module woes James
2014-02-05 17:57 ` Alan McKinnon [this message]
2014-02-05 18:16 ` [gentoo-user] " James
2014-02-05 18:28 ` James
2014-02-05 19:12 ` Alan McKinnon
2014-02-06 16:08 ` James
2014-02-06 19:17 ` Alan McKinnon
2014-02-07 8:27 ` Mick
2014-02-07 13:15 ` William Kenworthy
2014-02-10 14:51 ` James
2014-02-10 14:53 ` James
2014-02-07 22:04 ` walt
2014-02-10 14:55 ` James
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=52F27B97.7060609@gmail.com \
--to=alan.mckinnon@gmail.com \
--cc=gentoo-user@lists.gentoo.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox