Friday, August 5, 2011

Get TTY or getty

getty program. init starts a separate instance of getty for each terminal upon which logins are to be allowed. getty reads the username and runs the  correct,  because the username and password didn't match, kernel has no notion of logins, this is all handled by the loginprogram, which reads the password. If the username and password arelogin runs the shell. When the shell terminates, i.e., the user logs out, or when login terminatedinit notices this and starts a new instance of getty. Thesystem programs.
Logins from terminals (via serial lines) and the console (when not running X) are provided by the

Linux Network Logins

Network logins work a little differently than normal logins. For each person logging in via the network there
is a separate virtual network connection, and there can be any number of these depending on the available
bandwidth. It is therefore not possible to run a separate also several different ways to log in via a network,
These days many Linux system administrators consider ``secure shell'', which encrypts traffic going over the network, thereby making it far less likely that the malicious can ``sniff'' your connection and gain sensitive data like usernames and passwords. It is highly recommended you use  gettys, a single daemon per way of logging in (telnet and ssh have separate daemons) that listens for all incoming login attempts. When it notices one, it starts a new instance of itself to handle that single attempt; the original instance continues to listen for other attempts. The new instance works similarly to getty.Network logins have, instead of a herd of

Linux Services (Init)

Initialize --- Init.

init init is started as the first process ofinit starts, it continues the bootinit does depends on which flavor it is; there are several to choose from. initsingle user mode, in which no one can log in and root uses a shell at themultiuser mode. Some flavors generalize this as run levels; single and
The single most important service in a UNIX system is provided by every UNIX system, as the last thing the kernel does when it boots. When process by doing various startup chores (checking and mounting filesystems, starting daemons, etc). The exact list of things that
usually provides the concept of console; the usual mode is called multiuser modes are considered to be two run levels, and there can be additional ones as well, for example, to run X on the console.

Linux allows for up to 10 runlevels, 0−9, but usually only some of these are defined by default. Runlevel 0 is/etc/inittab usually will give some hint what the predefined
defined as ``system halt''. Runlevel 1 is defined as ``single user mode''. Runlevel 3 is defined as "multi user"
because it is the runlevel that the system boot into under normal day to day conditions. Runlevel 5 is typically
the same as 3 except that a GUI gets started also. Runlevel 6 is defined as ``system reboot''. Other runlevels
are dependent on how your particular distribution has defined them, and they vary significantly between
distributions. Looking at the contents of  runlevels are and what they have been defined as.

In normal operation,  init that is in charge of killing all other processes, unmounting all when the system is shut down, it is filesystems and stopping the processor, along with anything else it has been configured to do.
init makes sure getty is working (to allow users to log in) and to adopt orphan processes (processes whose parent has died; in UNIX all processes must be in a single tree, so orphans must be adopted).

Linux Kernel

The Linux kernel consist of several important parts: process management, memory management, hardware management, device drivers, filesystem drivers, network management and various others bits and pieces. Below figure shows few of them:

Probably the most importand part of the kernel are memory and process management.Memory management takes care of assigning memory areas and swap space areas to processes, part of the kernel, and for the buffer cache. Process management creates processes, and implement multi-tasking by context switching the active process on the processor.

At the lowest level, the kernel contains a hardware device driver for each kind of hardware it supports. Since
the world is full of different kinds of hardware, the number of hardware device drivers is large. There are
often many otherwise similar pieces of hardware that differ in how they are controlled by software. The
similarities make it possible to have general classes of drivers that support similar operations; each member of
the class has the same interface to the rest of the kernel but differs in what it needs to do to implement them.
For example, all disk drivers look alike to the rest of the kernel, i.e., they all have operations like `initialize the
drive', `read sector N', and `write sector N'.

Thursday, August 4, 2011

System Vs Application - Intro to Kernel

UNIX and 'UNIX−like' operating systems (such as Linux) consist of a
There are also some
provides provides many more services than a plain kernel.

It keeps track of files on the disk, starts programs and runs them concurrently, assigns memory and other
resources to various processes, receives packets from and sends packets to the network, and so on. The kernel does very little by itself, but it provides tools with which all services can be built. It also prevents anyone from accessing the hardware directly, forcing everyone to use the tools it provides. This way the kernel provides some protection for users from each other. The tools provided by the kernel are used via

The system program uses the tool provided by the kernel to implement the various services required for an operating system. System programs and all other programs run `on top of the kernel`, in what is called the user mode. The difference in the system and application programs is of one intent:
System Programs - needed for getting the system working (mount - one of the system program example).
Application Programs - needed for getting user work done(Playing Games is one such example)


system calls.
kernel and some system programs.application programs for doing work. The kernel is the heart of the operating system. In fact, it is often mistakenly considered to be the operating system itself, but it is not. An operating system

Linux or GNU/Linux



In a nutshell, what happened was, the FSF started developing GNU by writing things like compliers, C
libraries, and basic command line utilities before the kernel. Linus Torvalds, started Linux by writing the
Linux kernel first and using applications written for GNU.


Many people feel that Linux should really be called GNU/Linux. This is because Linux is only the kernel, not
the applications that run on it. Most of the basic command line utilities were written by the Free Software
Foundation while developing their GNU operating system. Among those utilities are some of the most basic
commands like cp, mv lsof, and dd.

Generally Not UNIX

This blog is meant for the sole purpose of increasing the visibility of Unix like Operating system and increasing the awareness of similar kind of OS. I have choosed few OS flavours which I feel will drive the reader nuts while experimenting the tweaks and playing around the os. Fedora stood the next in the line wearning RED HAT...and whose that....OMG ....my favourite...noble chameleon....isssshhhhh.....Novel Chameleon.