Welcome to the Linux Foundation Forum!

Is kernel basically a large executable program ??

The kernel is basically a large executable program that runs in the background.

Is it true?

Secondly, Will the following command HIST=".bash_history" will assign the value .bash_history to the shell variable HIST??

Comments

  • jabirali
    jabirali Posts: 157
    ruchika_sachdeva wrote:
    The kernel is basically a large executable program that runs in the background.
    I'm tempted to anwer yes, but I'm not sure if "running in the background" is the best way to describe it. The kernel handles all the communication with the hardware of your computer, and is a necessary abstraction layer between the other executable programs on your system and your hardware.
    Will the following command HIST=".bash_history" will assign the value .bash_history to the shell variable HIST?
    Yes, it will. Note that this command will only affect the current shell session (put the command somewhere in the file ~/.bashrc to make it permanent), and it will not be accessible by applications you start from that shell (for the variable to be available for child processes too, use export HIST=".bash_history") .

    If the point of running that command was to set your Bash history file to $HOME/.bash_history, you should instead run export HISTFILE="~/.bash_history", where '~' is automatically substituted for your home directory by the shell.
  • gomer
    gomer Posts: 158
    Well, not to split hairs, but the kernel is not strictly necessary. The kernel *is* the operating system, yes, and the kernel facilitates the user's ability to run multiple programs at once, and to interact with the computer's resources. However, it is not strictly necessary to operate a computer with an operating system or kernel. A computer user could always chose to load and run programs directly into the processor and peripherals, ala pre-1980's computing.

    So, ruchika, yes, the kernel is a large executable program, in so much as any other operating system is. The benefit of a kernel (or any operating system) is that it allows for easier access to hardware resources by abstracting a lot of the machine and architecture specific language into a more "frienly" set of APIs. What that really means, is it makes it easier for programmers to write things like the shells and GUI tools you use. They no longer need to worry about interacting with the hardware directly, or manipulating memory directly. Rather, the kernel will handle the memory management for them, and the kernel will interact with the hardware for them (like the hard drives, and the keyboard, and the video card and monitor, etc).

    So to that point, the kernel isn't really in the background. It's not really in the foreground either. It's sort of the environement that allows there to be a gackground and a foreground.

    Does that make sense?
  • altNull
    altNull Posts: 65
    Kernel
    Monolithic Kernel
    Linux Kernel
    Hybrid Kernel
    NT Kernel (Windows)

    I'll just leave this hear. And if your wondering about Mac - its freeBSD, which is Monolithic Kernel. As a point, You really should google questions like this. Not that we don't mind answering the question, but its more efficient.
  • chekkizhar
    chekkizhar Posts: 182
    Kernel is the heart, we can say. It wont run always. It depends on usage. For simple home applications like music, videos,chats etc., it wont come to play much.

    If you are a programmer, then you can drill your kernel with out giving a milli second time of rest.

    I dont think so , Kernel is a single program. Group of core modules together form Kernel.

    regarding, shell quest, are you sure about assigning a file to a variable ?
  • marc
    marc Posts: 647
    linustorvalds wrote:
    Kernel is the heart, we can say. It wont run always. It depends on usage. For simple home applications like music, videos,chats etc., it wont come to play much.

    If you are a programmer, then you can drill your kernel with out giving a milli second time of rest.

    I dont think so , Kernel is a single program. Group of core modules together form Kernel.

    regarding, shell quest, are you sure about assigning a file to a variable ?

    I *REFUSE* to write again the message I just wrote.

    You can go ahead and thank the fr***king flood protection.
  • chekkizhar
    chekkizhar Posts: 182
    I *REFUSE* to write again the message I just wrote.

    You can go ahead and thank the fr***king flood protection.

    can't get what you are telling?
  • marc
    marc Posts: 647
    There's a flood protection in the forum system that really annoyes me, that's the thing
  • Goineasy9
    Goineasy9 Posts: 1,114
    We've all been hit Marc, if I have a long post going I copy it before submitting. I've lost too many long posts, I've learned my lesson.
    Sorry, but they tell me they are working on it.

Categories

Upcoming Training