Skip to main content

Posts

Latest post

What is Initial RAM FileSystem (INITRAMFS)?

Initramfs is a CPIO format archive, that every Linux kernel contains, which is extracted into rootfs when the kernel boots up. It contains a complete root file system for Linux. It then helps to assemble and mount the real root file system. The initramfs or early userspace is necessary for complex setups, like network boot, LVM, raid, which needs additional user space utilities to get rootfs accessed. initramfs does not need to contain every module that a user might want to use, instead it only contains the modules which are required to access the root filesystem. Rest major modules will be loaded later by udev during init process. After extracting, kernel checks for /init file. If it finds, then it is executed as PID 1. This /init program helps in finding real root device if there is any. If kernel does not find /init in rootfs, it falls back to older code to locate and mount a root partition and then executes /sbin/init . Thanks Ayush
Recent posts

What is Master Boot Record (MBR) ?

Master Boot Record is the information stored in the first sector (cylinder 0, head 0) of a disk, which contains primary bootloader, which is a 512 byte image. It contains both program and a partition table. 446 bytes out of 512 bytes contains executable codes and error messages text. Next 64 bytes are partition table. Each table of 16 bytes. That is the reason why in MBR labled disks, maximum 4 partitions can be created (16 * 4 = 64 bytes). Last 2 bytes is for validation check for MBR. The job of the primary boot loader is to find stage-2 or secondary bootloader from the partition table. Then it loads boot record from the device into RAM. MBR content can be extracted by running dd command as a root user. [ dd if=/dev/sda of=/tmp/mbr bs=512 count=1 ] where /dev/sda is our HDD, /tmp/mbr is the destination file where MBR will be extracted to. As MBR is of size 512 byte,  512 block size is mentioned. As it is in binary format, to view this file in ASCII format enter [ od -xa /tmp/mbr

A COMPLETE WALK THROUGH LINUX BOOTING PROCESS

Many of us are using Linux, but how many have ever wondered what exactly happens when a system is powered on, how Linux kernel is loaded, how a login screen prompts? Let's have a deep walk though Linux booting process. After reading this, one would have understanding not only on Linux booting process, but also on BIOS, UEFI firmware, MBR & GPT partitions, bootloaders like GRUB, Linux kernel etc. Let's get started . . . . In order to boot Linux, a Linux capable bootloader such as syslinux or GRUB is needed. They need to be installed in Master Boot Record (MBR) or in GUID Partition Table (GPT). Boot loader loads the kernel and initial ramdisk before actual boot process is initialized. This process is different for different firmwares such as BIOS and UEFI. When the power is on, Power On Self Test (POST) begins which ensures hardwares are ready. After it, BIOS or UEFI firmware is loaded which initializes required hardwares for booting. WHAT IS BIOS? BIOS (Basic Input

How to install Arch Linux?

What is arch linux? Arch Linux is a GNU/Linux distribution, which aims at providing the latest stable version of most of the softwares by following a rolling release model. It defines simplicity without adding unnecessary modifications. It is designed to boot on-line, so that you will get the latest version of Arch in any way. If you have already arch installed on your system then you can always upgrade it by using [pacman -Syu] command. When you boot arch Linux from USB it will automatically start DHCPCD and drop a ZSH shell . you can use nano, VIM to modify any file. Before installation: - Verify the boot mode [ ls /sys/firmware/efi/efivars ] If the directory does not exist then your system might be booted in BIOS or CSM mode, else it is UEFI. - Connect to Internet: If Arch did not get any IP address do run [ dhcpcd ] manually. - for wireless connectivity:- [ iw dev ] to get wireless interface name. [ iw dev INTERFACE link ] to get the status of the interface. [ iw dev

WHY LINUX?

Linux is open source, which means we are free to download, edit its source codes and share. GNU General Public License ensures Linux remains free and standardized. Like most popular versions of UNIX, Linux is also POSIX-compliant (Portable Operating System Interface for Computer Environments). Linux is highly stable, fast and in its simplest format it can run on only 2MB of RAM. Although there is only one standard version of Linux, different companies and groups have packaged Linux and its softwares in different ways to build different distributions (in sort distros). Distributions like SUSE, Arch, Red Hat, Ubuntu etc are designed to satisfy any user needs and many aimed at providing comprehensive solutions & support for any tasks. Almost all Linux distributions provide option to run it as a Live-CD, so that we can run and experience complete Linux without even installing it. Linux offers many window-managers and desktop environments like GNOME, KDE, XFCE, I3 etc which are hig

GNU/Linux

WHAT IS LINUX? People often consider Linux as a complete operating system, but technically it is an operating system kernel, which is the part originally developed by Linus Torvalds. WHAT IS GNU/LINUX? Linux is a kernel which makes system hardware usable by providing an interface to the operating system, but only cosidering linux is of no use. We need an operating system with bunch of applications which would use the hardware resources by the help of kernel to get our jobs done. Richard Stallman's free software foundation had created many softwares but what they were missing was the kernel, which Torvald had developed. So they merged to get a complete operational OS, which is known as GNU/Linux today. GNU/Linux is licenced under GNU General Public License(GPL) which allows distribution and sale of possibly modified and unmodified versions of Linux but requires that all those copies be released under the same license and be accompanied by the complete correspoding source co