Technowine

The Search Ends Here

How To Set A Password For Grub At Boot Time in linux?

Posted by admin On June - 27 - 2009

1Grub is the linux default bootloader.

Setting up a password in grub is quite an easy task.you can set the password just at boot time to prevent anyone from logging into the system in any mode.

here is how to do it.

Enter the command line and type


#grub-md5-crypt

you will be prompted to enter the password..after entering the password twice you will be provided with a encrypted value as shown below..

grub pass

copy this encrypted value.

now open the grub.conf file.

#vi /boot/grub/grub.conf

and enter the line

passwd   –md5    $1$Tqro5/$pkEbG8f4igg0oZRCoWznb1

where the above encrpted value is the one generated at the time when you entered the password.

also enter

lock

at the end of the red hat container as shown in the figure below.

dca

come out of the editor and then reboot.

#init 6

now at startup you will be asked for the password.

rh

press ‘p’ for password.

and enter the password.


Bookmark and Share

5 Responses to “How To Set A Password For Grub At Boot Time in linux?”

  1. [...] Related articles How to set password for grub in linux [...]

  2. shamrat says:

    how can we activate telnet service in linux……..can u provide it…

  3. admin says:

    ya..we’ll provide you with this post very soon..make use of xinetd services..

  4. gaurav says:

    during installation of vmware what to choose in network mode 1. Bridge
    2. Nat

  5. admin says:

    depends on your usage…what type of network you want to add..if you want to give your guest OS direct access to external ethernet network use bridged ..but if you want to your guest OS to access host computer’s IP address..use NAT ..i wud suggest NAT.

Leave a Reply

Sponsors

About Me

Hello everyone, My name is Jaskiran Singh and I am currently pursuing B. Tech final year from Maharaja Agrasen Institute of technology.I am currently RHCT,RHCE,RHCSS certified.

Twitter

    Photos

    Activate the Flickrss plugin to see the image thumbnails!