LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Two Questions about VMLINUX (https://www.linuxquestions.org/questions/linux-newbie-8/two-questions-about-vmlinux-4175450856/)

Inert 02-19-2013 05:12 PM

Two Questions about VMLINUX
 
In my efforts to learn Linux I have learned that VMLINUX is the "core" of the Linux OS. Yet I have also learned (mostly through trying) that you can't always install/run programs across distributions--that is, I could not make a Debian based application run on TinyCore. (Admittedly this might have been due to my own ignorance of how to properly install/configure/execute programs.) With this in mind I have two questions:

1. Are there different versions of the Linux core for different distributions? In other words, does Debian have its own version of VMLINUX, which would be different than the VMLINUX RedHat might use?

2. To what extent are Linux programs limited to their parent distributions? (Would a program written for RedHat, for example, run on a OpenBSD system?)

Please forgive my ignorance, as I'm just learning. Thanks!

Kustom42 02-19-2013 05:16 PM

VMLINUX is a statically linked version of the current running kernel that is executable. The kernel may very well be the exact same from one system to the next but that does not mean that programs will run the same under both. There are so many other variables here, what is the architecture of the kernel? What libraries are linked? And so on.

Kustom42 02-19-2013 05:18 PM

http://www.linuxquestions.org/questi...-it-do-136823/

Read acid's post there at the end. Linux is the that core kernel file, all the rest of the software is used by the Linux kernel but is not technically Linux.

Inert 02-19-2013 05:22 PM

Kustom, thank you for replying. I think this is what you meant in your explanation:

1. The Linux kernel, by itself, is not responsible for executing programs.
2. To execute certain programs, one needs to access additional resources (libraries).

Is this correct?

sundialsvcs 02-19-2013 05:25 PM

You see, there's a chunk of software that's always resident, the entire time that the system is running. It's loaded into memory at boot time and it stays there until you shut the power off. That piece is called "the kernel." (Technically, "kernel modules," which can come and go, become part of "the kernel" also while they are loaded.) The lowest-level responsibilities of device and hardware control reside here. The kernel creates the virtual-memory / multi-tasking environment in which every process runs. It also hosts file system drivers.

There are many, many other parts of the total software system that, colloquially speaking, is referred to as "Linux." The kernel is the always-resident, low-level hardware control portion of it ... what IBM likes to call a SCP = System Control Program, which I actually think is a much more descriptive name.

Kustom42 02-19-2013 05:32 PM

First, must give credit to sundials further explanation on this.


Quote:

Originally Posted by Inert (Post 4895502)
Kustom, thank you for replying. I think this is what you meant in your explanation:

1. The Linux kernel, by itself, is not responsible for executing programs.
2. To execute certain programs, one needs to access additional resources (libraries).

Is this correct?


1. See Sundial's response, it should answer this question. If you want more clarification just ask.
2. Correct, in order for functions to execute the appropriate library must be linked and accessible by the kernel. See the "ldconfig" and "ldd" man pages for info on library linking. If you want to see some of this run the "ldd" command on a binary:

Code:

ldd /bin/cat
        libc.so.6 => /lib64/libc.so.6 (0x0000003b75a00000)
        /lib64/ld-linux-x86-64.so.2 (0x0000003b75600000)

So you can see that the cat binary requires the libc.so.6 library which is linked to /lib64/libc.so.6 on the system.


All times are GMT -5. The time now is 12:02 PM.