LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - General (https://www.linuxquestions.org/questions/linux-general-1/)
-   -   FATAL: Module binfmt_misc not found. (https://www.linuxquestions.org/questions/linux-general-1/fatal-module-binfmt_misc-not-found-745088/)

MrUmunhum 08-04-2009 01:19 PM

FATAL: Module binfmt_misc not found.
 
Hi group,
I starting having this problem at boot time. In my rc.local I have rgese lines:
Code:

modprobe binfmt_misc

echo ':rexx:M::/*::/usr/bin/rexx:'    >> /proc/sys/fs/binfmt_misc/register
echo ':rexxcmd:E::cmd::/usr/bin/rexx:' >> /proc/sys/fs/binfmt_misc/register

All worked well for a long time, since FC5.

Now for some reason I get this:
Code:

$ modprobe binfmt_misc
FATAL: Module binfmt_misc not found.
FATAL: Error running install command for binfmt_misc

I am running Fedora Core 10 on a Fujitsu LifeBook.

Any ideas?

Thanks for your time.

bathory 08-04-2009 05:02 PM

It looks like your FC 10 kernel does not have the binfmt_misc module compiled in, unlike your old FC 5. If you still need it (to run rexx as I see in your rc.local), then you have to recompile your kernel adding it. Quoting from kernel help:
Quote:

CONFIG_BINFMT_MISC:
If you say Y here, it will be possible to plug wrapper-driven binary formats into the kernel. You will like this especially when you use programs that need an interpreter to run like Java, Python, .NET or Emacs-Lisp.
...
Once you have registered such a binary class with the kernel, you can start one of those programs simply by typing in its name at a shell prompt; Linux will automatically feed it to the correct interpreter.
...
To use binfmt_misc, you will need to mount it:
mount binfmt_misc -t binfmt_misc /proc/sys/fs/binfmt_misc You may say M here for module support and later load the module when you have use for it; the module is called binfmt_misc. If you don't know what to answer at this point, say Y.
Symbol: BINFMT_MISC [=m]
Prompt: Kernel support for MISC binaries
Defined at fs/Kconfig.binfmt:139
Location:
-> Executable file formats / Emulations

MrUmunhum 08-05-2009 12:58 PM

It was working
 
Quote:

Originally Posted by bathory (Post 3631496)
It looks like your FC 10 kernel does not have the binfmt_misc module compiled in, unlike your old FC 5. If you still need it (to run rexx as I see in your rc.local), then you have to recompile your kernel adding it. Quoting from kernel help:

It was working until about a week ago. I just updated the kernel and it still is broken.

bathory 08-05-2009 05:19 PM

Quote:

$ modprobe binfmt_misc
FATAL: Module binfmt_misc not found.
FATAL: Error running install command for binfmt_misc
Try to run it as root and see what happens.
Also what is the output of
Code:

grep BINFMT_MISC /boot/config-`uname -r`

MrUmunhum 08-06-2009 01:45 PM

Quote:

Originally Posted by bathory (Post 3632894)
Try to run it as root and see what happens.
Also what is the output of
Code:

grep BINFMT_MISC /boot/config-`uname -r`

$ grep BINFMT_MISC /boot/config-`uname -r`
500:CONFIG_BINFMT_MISC=y

[root@laptop ~]# modprobe binfmt_misc
FATAL: Module binfmt_misc not found.
FATAL: Error running install command for binfmt_misc

bathory 08-06-2009 03:33 PM

So you have binfmt_misc built-in the kernel and not as a module. This means that you can skip the modprobe command and use the rest to do what you want.

MrUmunhum 08-07-2009 12:41 PM

Quote:

Originally Posted by bathory (Post 3634013)
So you have binfmt_misc built-in the kernel and not as a module. This means that you can skip the modprobe command and use the rest to do what you want.

But it is not working. Not sure why?

MrUmunhum 08-07-2009 01:07 PM

fixed
 
Quote:

Originally Posted by MrUmunhum (Post 3634944)
But it is not working. Not sure why?

OK, I figured it out. The problem was that the entry pointed /usr/local/bin/rexx and not /usr/bin/rexx. Don't know why this has changed?
The quick fix was 'sudo ln -s /usr/bin/rexx /usr/local/bin/rexx'.
This was the give away.
Code:

# cat /proc/sys/fs/binfmt_misc/rexx
enabled
interpreter /usr/local/bin/rexx
flags:
offset 0
magic 2f2a

Working on proper fix.


All times are GMT -5. The time now is 06:22 AM.