Feeds:
Posts
Comments

Ubuntu 9.10 Karmic Koala has been released. The major features are

Linux kernel 2.6.31

ext4 by default

GRUB 2 by default

Ubuntu One file sharing

You may find more details in http://www.ubuntu.com/testing/karmic/beta



We all will be having tendencies to install multiple OS in our computers. While installing multiple OS one of the common procedures is installing Windows  first and after that then install Ubuntu. But some times we may be forced to reinstall Windows due to various reasons(eg:Virus Attack, lack of performance etc…..). Then the major problem arises. Recovering Ubuntu after Windows reinstallation. Here comes the solution for that.

The thing is that you need to reinstall GRUB to the MBR which was overwritten while installing Windows.Here is the procedure for recovering GRUB.

1)Insert the Live CD adn boot from it.

2)After Ubuntu is loaded from the CD,go to a terminal

3)Type sudo grub-install /dev/sda

4) Done, the GRUB will be installed now.

5)Reboot PC

Sometimes the above said method fails,here comes another method to recover GRUB.

This option will use the Desktop/Live CD to install Grub into your MBR (Master Boot Record). This option will overwrite your Windows Boot Loader It is OK to do this, in fact that is the goal of this how to (in order to boot Ubuntu)

1. Boot the Desktop/Live CD.

2. Open a terminal (Applications -> Accessories -> Terminal)

3. Start grub as root with the following command :

sudo grub

4. You will get a grub prompt (see below) which we will use to find the root partition and install grub to the MBR (hd0,0)

   [ Minimal BASH-like line editing is supported.   For
         the   first   word,  TAB  lists  possible  command
         completions.  Anywhere else TAB lists the possible
         completions of a device/filename. ]

grub>

Type the following and press enter:

find /boot/grub/stage1

Using this information, set the root device:

grub> root (hd0,1)

Install Grub:

grub> setup (hd0)

Exit Grub

grub>quit

5. Reboot (to hard drive). Grub should be installed and both Ubuntu and Windows should have been automatically detected.

6. If, after installing grub, Windows will not boot you may need to edit /boot/grub/menu.lst (That is a small “L” and not the number 1 in menu.lst)
 Open a terminal and enter :
 gksu gedit /boot/grub/menu.lst

Or, in Kubuntu:

kdesu kate /boot/grub/menu.lst

Your Windows stanza should look something like this :

 title Windows XP/Vista # You can use any title you wish, this will appear on your grub boot menu
 rootnoverify (hd0,0) #(hd0,0) will be most common, you may need to adjust accordingly
 makeactive
 chainloader +1

It is possible that sometimes we may forget the root password for your Linux. On Linux, recovering root password can be done by booting Linux under a specific mode: single user mode.

During normal usage, a Linux OS runs under runlevels between 2 and 5 which corresponds to various multi-user modes. Booting Linux under runlevel 1 will allow one to enter into a specific mode, single user mode. Under such a level, you directly get a root prompt.

How to Enter Single User mode

Some Linux distribution, such as Ubuntu for instance, offer a specific boot menu entry where it is stated “Recovery Mode” or “Single-User Mode”. If this is your case, selecting this menu entry will boot your machine into single user mode, you can carry on with the next part. If not, you might want to read this part.

Using GRUB, you can manually edit the proposed menu entry at boot time. To do so, when GRUB is presenting the menu list (you might need to press ESC first), follow those instructions:

  • Use the arrows to select the boot entry you want to modify.
  • Press e to edit the entry.
  • Use the arrow keys to go to the kernel line.
  • Press e to edit this entry.
  • At the end of the line add the word single or simply s.
  • Press ESC to go back to the parent menu.
  • Press b to boot this kernel.

The kernel should be booting as usual (except for the graphical splash screen you might be used to), and you will finally get a root prompt (sh#).

Here we are, we have gained root access to the filesystem, let’s finally change the password.

2. Changing root password

As root, changing password does not ask for your old password, therefore running the command:

#passwd

will prompt you for your new password and will ask you to confirm it to make sure there is no typo.

That’s it, you can now reboot your box and gain root access again

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. Normally we all have the habit of testing the new distro once it is published.

Ordering the CD’s or waiting for the magazines to provide the CD’s is a very time consuming procedure as it may take the patience out of us. Since the ISO images are available in the websites we tend to download those. After that the major issue pops up, CD’s. If you dont have the CD at that moment you are unable to install the new distro and again you are put in the waiting queue.Here is 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.

Linux installers use two files to boot a computer: a kernel and an initial root filesystem—also known as the RAM disk or initrd image. This initrd image contains a set of executables and drivers that are needed to mount the real root filesystem. When the real root filesystem mounts, the initrd is unmounted and its memory is freed. These two files are named differently in different distros.

Names of kernel and RAM disk images in some popular distros are shown below.

Distro                  Kernel path                      RAM disk path
******                ***********                    *************

Fedora         /isolinux/vmlinuz         /isolinux/initrd.img
RHEL5/CentOS5     /isolinux/vmlinuz         /isolinux/initrd.img
openSUSE     /boot/i386/loader/linux     /boot/i386/loader/initrd
Mandriva     /i586/isolinux/alt0/vmlinuz     /i586/isolinux/alt0/all.rdz
Ubuntu         /casper/vmlinuz         /casper/initrd.gz
Debian         /install.386/vmlinuz     /isolinux/initrd.img

The first thing you need to do is place the ISO image(s) inside a directory. Some installers are not able to read the ISO images if they are placed inside a directory. So, just to be on the safe side, place them in the root of the file system. The partition on the hard disk holding the ISO files must be formatted with the ext2, ext3 or vfat files system.

In our example, let’s go ahead and do it with an old Fedora 9 ISO image. Follow these steps to begin with:

# mkdir /fedora
# cp /home/jaikrishnan/Fedora-9-i386-DVD.iso /fedora/fedora9.iso

Now extract the kernel and initrd files from the ISO image and place them in the same directory in which you placed the ISO. You can use File Roller, the archive manager for GNOME, to extract the files. Just right click on the ISO and select “Open with File Roller”. It displays the contents of the ISO image. Then navigate to the isolinux directory—in Fedora 9 these two files are placed inside the isolinux directory; it’s often different for other distros. Select the kernel and initrd files, and extract them to the location where your ISO image exists.

The second method is to mount the ISO image and extract the files. Run the following commands to do this:

# mount -o loop /fedora/fedora9.iso /media/iso
# cd /media/iso/isolinux
# cp vmlinuz initrd.img /fedora/

I have mounted the ISO image without providing the -t iso9660 option (to specify the type of media as an ISO filesystem). It worked for me. If the above mount command doesn’t work, do add this option along with the rest of the mount command above.

Note: Fedora 10 has introduced a change in the Anaconda installer. So, in addition to the vmlinuz and initrd.gz files, you will also need to copy the images/install.img file, create a directory called /fedora/images, and place the install.img file there.

Now, it’s time to edit the /boot/grub/menu.lst file on the system I’m currently using—Ubuntu 8.10. Note that this is the location of the Grub menu in almost all distros, except for Fedora/Red Hat, where it’s called /boot/grub/grub.conf. Append the following entry there:

title Install Linux
root (hdX,Y)
kernel /distro/Linux_kernel
initrd /distro/Ram_disk

In this case…

1. ‘title’ is the name you want to display in your GRUB menu
2. ‘root’ is the hard disk partition that contains the ISO image
3. ‘kernel’ is the Linux kernel
4. ‘initrd’ is the initial RAM disk image

Likewise, the menu.lst entry for the ISO file looks like what’s shown below:

title Install Fedora 9
root (hd4,0)
kernel /fedora/vmlinuz
initrd /fedora/initrd.img

Now you are ready to install your new Linux distro directly from the hard disk without the need for a CD/DVD drive. Reboot your system and select the ‘Install Fedora 9’ entry from your GRUB menu.

1. Install phonon-backend-xine.
2. Remove phonon-backend-gstreamer.Phonon

The BSNL guys came and installed a Huawei SmartAX MT880 ADSL router today. As my place is about 4 KM away from the telephone exchange, I will not be getting the full 256Kbps promised by the telecom department (it seems ADSL has a distance limit of about 3.5Km for good quality).
The telecom department still seems to be not very conversant with Linux – but the people who came to do the installation were very helpful and friendly. I was given the phone number of a person who was using the router with Linux in case I had trouble setting it up – but that was not required as the configuration was very simple.
Here are the things to do to get DataOne working on Linux:
Plug in a LAN card and make sure that the required driver is present in the kernel, either compiled-in or loaded as a module.
Connect the router to the ethernet card.
Assign an IP address for the ethernet card; the router has a fixed interface address of 192.168.1.1, so you can use 192.9.168.2 for your ethernet interface. Just do `ifconfig eth0 192.168.1.2′.
Set up the route – just do `route add default gw 192.168.1.1′.
Enter the address of some DNS servers in /etc/resolv.conf ( eg: 61.1.96.69, 61.1.96.71)
Try doing a `ping www.google.co.in’. If it works, great! If not, check whether it is some problem with the DNS settings by pinging a machine with the I/P address rather than the name. If that too doesn’t work, you will have to do some configuration on the router.
You can access the router via a browser – just enter the I/P address 192.168.1.1. You basically have to set the connection type to `PPPoE’; on my MT880 box, this comes under `WAN Settings’. You will then have to enter your user name and password (username is of the form xyz@dataone) and reset the router. It will take 2-3 minutes for the box to come up again – when it comes up, it will `automagically’ talk with the box at the exchange (via PPP?) and will be assigned a proper IP address. You need not bother about this address as you always see the router at a fixed address of 192.168.1.1.
Try pinging google.com again – it should work! You are now on DataOne!
I am getting connection speeds of about 190Kbps consistently; that should be OK, given the distance. Some of my students who are staying near the telephone exchange report that they are even getting speeds greater than the promised 256Kbps!

Follow

Get every new post delivered to your Inbox.