Tuesday, April 27, 2010

How to change grub password ?

just edit the following line in config file "grub.conf"
password 'password'


Also if you want you can use encrypted password. To generate encrypted password enter the grub command line, either by pressing 'c' in the menu or by running 'grub' under Linux, then run the command 'md5crypt'. Enter your password, it will give you the encrypted form. and now the line should like
Code:password --md5 'password'


Example :

[root@localhost ~]# grubProbing devices to guess BIOS drives. This may take a long time.
GNU GRUB version 0.97 (640K lower / 3072K upper memory)
[ 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> md5crypt
Password: ****** // shipon is the password Encrypted: $1$yGtX2/$cqOH/GCHjz5GDLvkxXj9B0

#boot=/dev/sdadefault=0timeout=5password --md5 $1$yGtX2/$cqOH/GCHjz5GDLvkxXj9B0

Format USB in Linux !

How can I format my USB flash drive (pendrive) into my Redhat Linux platform ?

Formatting a partition is done using the mkfs tool.if you type mkfs on the command line and then TAB,you will see options like mkfs.vfat, mkfs.ext2, mkfs.ext2, etc.

If your USB Pensdrive was already mounted on linux then need to give the below command :
# mkfs.vfat /dev/hda1

Make sure you know the partition type with "fdisk -l" .

Activate 177 port for Windows X-manager s/w .

For Linux Environment :
====================

XDMCP For Redhat 4 or 5:

In Red Hat® Enterprise Linux® 4 or 5 , Edit the file '/etc/gdm/custom.conf' could be modified to enable xdmcp. where xdmcp enable the port 177 .

There are two ways that xdmcp can be enabled:
Modify the file /etc/gdm/custom.conf and under the [xdmcp] section, add this line: 'Enable=true'

Alternately, the tool "gdmsetup" can be used. This is a gui-based tool to modify gdm.
Once one of these two steps are done - simply run "gdm-restart" command from gui terminal
and then login as desired user.

cat /etc/gdm/custom.conf
[xdmcp]
Enable=true


For AIX 5.3/6.1 Environment :
========================

In AIX xdmcp(177) port is not working , Then need to run the Following script :
sh /etc/rc.dt

Sunday, April 25, 2010

YUM installation on RHEL 5

Step 1 :
Copy all the rmps from the RHEL 5 DVD to a folder "/rpms/Server"

Step 2:
Edit the file '/etc/yum.repos.d/rhel-debuginfo.repo' , Like following way :[root@lpt Server]# cat /etc/yum.repos.d/rhel-debuginfo.repo
[rhel-debuginfo]name=Red Hat Enterprise Linux $releasever - $basearch - Debugbaseurl=file:///rpms/Serverenabled=1gpgcheck=0gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-release
[root@lpt Server]#

Step 3:
Download createrepo package from "
http://dag.wieers.com/rpm/packages/createrepo/" siteand install it .
[root@lpt test]# rpm -ivh createrepo-0.4.8-1.el5.rf.noarch.rpm warning: createrepo-0.4.8-1.el5.rf.noarch.rpm: Header V3 DSA signature: NOKEY, key ID 6b8d79e6Preparing... ########################################### [100%] 1:createrepo ########################################### [100%]

Step 4:
Run the 'createrepo' command :
[root@lpt test]# cd /rpms/Server/
[root@lpt Server]# createrepo /rpms/Server
2113/2113 - pango-devel-1.14.9-3.el5.i386.rpm
Saving Primary metadata
Saving file lists metadata
Saving other metadata
[root@lpt Server]#

Finally , Enjoy yum from your RHEL 5 Linux environment .