Mukesh Chauhan

Just another WordPress.com weblog

Gustavo Duarte’s Linux Internals Series

I have been reading Gustavo Duarte’s blog for last few days. The blog contains very good and neatly written contents on Linux internals. He has explained the things in the simplest manner using code and, especial mention to, excellent diagrams.

I would definitely recommend you to read the blog series, if you are interested in Linux internals.

August 25, 2009 Posted by | Linux | 5 Comments

Network disconnect in fedora 9 x86_64

Using a x86_64 DVD version of Fedora 9, I have installed the system and noticed an issue: the network is not active. The issue seems to be with NetworkManager service.
To resovle the issue, follow these steps –
#vim /etc/sysconfig/network-scripts/ifcfg-eth0

and add line or change it, if already there-
NM_CONTROLLED=yes

If you like to use GUI than execute this command as root
#system-config-network
it will open a Network configuration window. Edit eth0 configuration. Select the checkbox “Controlled by NetworkManager”.

Once you have made the changes by either way reboot the system. It should enable the network.

August 10, 2009 Posted by | Linux | Leave a comment

Enable root login in Fedora 10 (GNOME)

Log in as your average user, then elevate yourself to root (su -). First, make a backup of the file you’re about to edit:

# cp -a /etc/pam.d/gdm /etc/pam.d/gdm.orig

Now edit /etc/pam.d/gdm and change the line:

auth required pam_succeed_if.so user != root quiet

…to:

auth required pam_succeed_if.so user quiet

…save it, log out and now you can log back into GDM as root.

July 30, 2009 Posted by | Linux | Leave a comment

Browse linux source online

LXR (formerly “the Linux Cross Referencer”) is a toolset to browse linux source code online.

lxray-large

The sources for 0.0.1 to latest 2.6.30 kernels are available on LXR.

July 28, 2009 Posted by | Linux | 1 Comment

Brace Expansion

Brace expansion takes a list of strings separated by commas and expands those strings into separate arguments for you. The list is enclosed by braces, the symbols { and }, and there should be no spaces around the commas. For example:

$ echo {one,two,red,blue}
one two red blue
Continue reading

July 10, 2009 Posted by | Linux | Leave a comment

Install Linux Straight from an ISO without CD/DVD

GNU/Linux comes in many different flavours, apart from the fact that each individual distro has a new release almost every six months, if not less. Everytime we need to try the new distro, we burn the ISO image on the dvd and than install it. I came across a very good article on Linuxforu magzine. In this article , the author shares a simple trick by which you can install the new distro without burning it to a CD/DVD.

The only requirement is that you should have a pre-installed GNU/Linux system—which you already have, I assume.

Click here to see the article.

July 10, 2009 Posted by | Linux | Leave a comment

Installing Fedora on Dell laptops

Recently, I installed Fedora on one of my friend’s laptop. It was already having Windows vista and we wanted to make it a dual boot system. However, after installing Fedora, Windows was not able to come up. Though, GRUB shows two operating systems in the system but selecting Other was not booting Windows.
Continue reading

June 24, 2009 Posted by | Linux | Leave a comment

The Importance of Command Line

I understand, we are so much used to GUI that we almost forget the CLI. Remembering all those commands with different options seems like a big hassle. GUI has all the buttons, click on it and job done. But here we miss one part the power of CLI. If used wisely, they can speed up your working many fold.

Take an example, you want to close a tab in firefox. Take your mouse to cross button and than click or simply say CTRL-w. Interesting, right. Linux has got a really powerful shell. You can almost write a program there. See the following code –

$ for f in *.c
> do cp -p $f OLD_$f
> done

It will find every filename ending with .c in the current directory and makes a copy with OLD_ preceding the filename.

Read this to know the power of CLI. If the link asks you to register, than continue reading the blog. I have dumped the contents in the post.

Continue reading

April 10, 2009 Posted by | Linux | 3 Comments

Shortcut and commands for newbies

Here are few shortcut and commands for newbies. Click here to read. They will be very useful in your day to day life and cap really speed up your working.

-Mukesh

April 7, 2009 Posted by | Linux | Leave a comment

Creating alias in bash

You can alias any command in your .bashrc file to create shortcut.

For ex – alias l=’ls -ltr’ will create a alias for ls command with -ltr options. Now use only l to invoke this command.

Combine two or more commands in one alias,

alias cdh=”cd <home>; ls -l”

You can see aliases set by you by invoking ‘alias’ command in shell.

A more complex example for creating a shortcut,

rmdir()
{
rm -rf  $1 > /dev/null &
}

$> rmdir test will remove test directory.

March 6, 2009 Posted by | Linux | Leave a comment