Linux

Linux process execution time

Execution time A process has an execution time associated with it. The execution time comprises of two parts, the user time and the system time. The user time is the time spent by the CPU in executing instructions in user mode. The system time is the time spent by the CPU in executing instructions on …

Linux process execution time Read More »

Calendar Time Under Linux

1.0 The system calendar time since the Epoch, 1970-01-01 00:00:00, UTC The Linux kernel maintains a system calendar time, which is initialized from the hardware real time clock (RTC) at the boot time and is incremented with the timer interrupt. The system calendar time is the number of seconds passed since January 1, 1970 00:00:00 …

Calendar Time Under Linux Read More »

hwclock, the hardware clock query and set program

The hardware clock There are two clocks in a Linux system, the hardware real time clock (RTC) and the Linux system time maintained by the kernel. In this tutorial, we will look at the hardware real time clock. The hardware real time clock is an integrated circuit, a part of computer's hardware, powered by a …

hwclock, the hardware clock query and set program Read More »

Starting a network server after communication interface is up

If you have a program that communicates over the network interface, say, eth0 and you wish to start the program automatically after the system startup, you need to ensure that the program starts after the interface eth0 is up. For Linux systems using the Upstart process management daemon, this can be done by starting the …

Starting a network server after communication interface is up Read More »

kernel panic – not syncing: VFS: Unable to mount root fs on unknown-block(0,0)

A new Linux kernel was built using the commands, make gconfig, make, sudo make install and sudo make modules_install. After building a new Linux kernel and booting from it, the boot process halts with the following message: kernel panic – not syncing: VFS: Unable to mount root fs on unknown-block(0,0) A lot many drivers are …

kernel panic – not syncing: VFS: Unable to mount root fs on unknown-block(0,0) Read More »

Mounting Windows partitions under Linux

Multi-boot systems with Linux and Windows are quite common. With the following steps, it is easy to access Windows partitions under Linux. 1. Examine the disk partitions. For example, sudo fdisk -l gives the output, Disk /dev/sda: 160.0 GB, 160041885696 bytes 255 heads, 63 sectors/track, 19457 cylinders Units = cylinders of 16065 * 512 = …

Mounting Windows partitions under Linux Read More »

Using the make utility to build software (Advanced)

make is a utility for building programs based on the contents of a specially formatted text file named Makefile or makefile under Linux and Unix environments. A makefile has explicit rules, implicit rules, variable definitions, directives and comments. In the primer make tutorial, we looked at some example makefiles containing explicit rules. In this tutorial …

Using the make utility to build software (Advanced) Read More »

Using the make utility to build software (Primer)

As the number of source files and libraries required to build a software increase in number, the build process gets more complicated and the time required to build the final executable becomes more and more. Here, the classic make utility available in Linux and other Unix-like environments comes to the rescue as it automatically builds …

Using the make utility to build software (Primer) Read More »

Starting Linux services with init scripts

A Linux system provides many services to the users, like secure shell access or the print spooler service. These services need to be started and stopped at appropriate times. The start and stop of these services is controlled by init scripts. An init script for a service specifies when that service should be started and …

Starting Linux services with init scripts Read More »