<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:georss='http://www.georss.org/georss' xmlns:gd='http://schemas.google.com/g/2005' xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-34286671</id><updated>2011-11-28T06:03:01.513+05:30</updated><category term='linux runlevels'/><title type='text'>tail -f /var/log/messages</title><subtitle type='html'></subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://midhunramadas.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/34286671/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://midhunramadas.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>Midhun Ramadas</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>14</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-34286671.post-3719161021288374683</id><published>2008-10-17T08:06:00.001+05:30</published><updated>2008-10-17T08:07:55.082+05:30</updated><title type='text'></title><content type='html'>&lt;strong style="font-family: verdana;"&gt;Ubuntu - How to disable extra TTYs in upstart&lt;br /&gt;&lt;/strong&gt;&lt;br /&gt;&lt;span style="font-size:85%;"&gt;&lt;span style="font-family: verdana;"&gt;You have to edit /etc/default/console-setup file. This file defines how many ttys should you get. Change ACTIVE_CONSOLES="/dev/tty[1-6]" to the number of consoles you want. Lets say, 2 ttys, then change it to "/dev/tty[1-2]".&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family: verdana;"&gt; And then goto /etc/event.d/ and change the ttyx files that you DONOT want. Edit them and comment lines starting with "start on runlevel". So, in this case, you'll comment the start line in tty3..tty6 files.&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: verdana;"&gt;NOTE: X will  still on Alt-F7.&lt;/span&gt;&lt;/span&gt; &lt;br /&gt;&lt;strong&gt;&lt;br /&gt;&lt;/strong&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/34286671-3719161021288374683?l=midhunramadas.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://midhunramadas.blogspot.com/feeds/3719161021288374683/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=34286671&amp;postID=3719161021288374683' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/34286671/posts/default/3719161021288374683'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/34286671/posts/default/3719161021288374683'/><link rel='alternate' type='text/html' href='http://midhunramadas.blogspot.com/2008/10/ubuntu-how-to-disable-extra-ttys-in.html' title=''/><author><name>Midhun Ramadas</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-34286671.post-7255697475570136998</id><published>2008-09-16T13:27:00.000+05:30</published><updated>2008-09-16T13:28:15.967+05:30</updated><title type='text'></title><content type='html'>&lt;span style="font-size:130%;"&gt;&lt;span style="font-weight: bold;"&gt;Perl - change first letter to upper case&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;echo $name | perl -pe 's/^(.{0})(.)/$1\U$2/;'`&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/34286671-7255697475570136998?l=midhunramadas.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://midhunramadas.blogspot.com/feeds/7255697475570136998/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=34286671&amp;postID=7255697475570136998' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/34286671/posts/default/7255697475570136998'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/34286671/posts/default/7255697475570136998'/><link rel='alternate' type='text/html' href='http://midhunramadas.blogspot.com/2008/09/perl-change-first-letter-to-upper-case.html' title=''/><author><name>midhunramdas@gmail.com</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-34286671.post-7154827947776321102</id><published>2007-12-03T13:30:00.001+05:30</published><updated>2007-12-03T16:02:38.713+05:30</updated><title type='text'></title><content type='html'>&lt;span style="font-size:100%;"&gt;&lt;span style="font-weight: bold;font-size:180%;" &gt;&lt;span style="font-family:verdana;"&gt;Linux Booting Procedure&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:verdana;"&gt;The boot sequence varies in details among systems but can be roughly divided to the following steps: (i) hardware boot, (ii) OS loader, (iii) kernel startup, (iv) init and inittab, (v) boot scripts. We will describe each of these in more detail below.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;font-family:verdana;" &gt;Hardware-boot&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:verdana;"&gt;After power-on or hard reset, control is given to a program stored on read only memory (normally PROM). In PC we usually call this program the BIOS.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:verdana;"&gt;This program normally makes a basic self-test of the machine and accesses non-volatile memory to read further parameters. This memory in the PC is battery-backed CMOS memory, so most people refer to it as the CMOS, although outside of the PC world, it is usually called nvram (non-volatile ram).&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:verdana;"&gt;The parameters stored in the nvram vary between systems, but as a minimum, the hardware boot program should know what is the boot device, or which devices to probe as possible boot devices.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:verdana;"&gt;Then the hardware boot stage accesses the boot device, loads the OS Loader, which is located on a fixed position on the boot device, and transfers control to it.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;font-family:verdana;" &gt;OS Loader&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:verdana;"&gt;In PC, the OS Loader is located in the first sector of the boot device - this is the MBR (Master Boot Record).&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:verdana;"&gt;In most systems, this primary loader is very limited due to various constraints. Even on non-PC systems there are some limitations to the size and complexity of this loader, but the size limitation of the PC MBR (512 bytes including the partition table) makes it almost impossible to squeeze a full OS Loader into it.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:verdana;"&gt;Therefore, most operating systems make the primary loader call a secondary OS loader which may be located on a specified disk partition.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:verdana;"&gt;In Linux the OS loader is normally &lt;a href="http://www.rt.com/man/lilo.8.html"&gt;lilo(8)&lt;/a&gt; or &lt;a href="http://linux.die.net/man/8/grub"&gt;grub(8)&lt;/a&gt;. Both of them may install either as secondary loaders (where the DOS installed MBR points to them), or as a two part loader where they provide special MBR containing the bootstrap code to load the second part of the loader from the root partition.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:verdana;"&gt;The main job of the OS Loader is to locate the kernel on the disk, load it and run it. Most OS loaders allow interactive use, to enable specification of alternative kernel (maybe a backup in case the last compiled one isn’t functioning) and to pass optional parameters to the kernel.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;font-family:verdana;" &gt;Kernel Startup&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:verdana;"&gt;When the kernel is loaded, it initializes the devices (via their drivers), starts the swapper (it is a "kernel process", called kswapd in modern Linux kernels), and mounts the root file system (/).&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:verdana;"&gt;Some of the parameters that may be passed to the kernel relate to these activities (e.g: You can override the default root file system). For further information on Linux kernel parameters read &lt;a href="http://www.phpman.info/index.php/man/bootparam/7"&gt;bootparam(7)&lt;/a&gt;.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:verdana;"&gt;Only then the kernel creates the first (user land) process which is numbered 1. This process executes the program /sbin/init, passing any parameters that weren’t handled by the kernel already.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;font-family:verdana;" &gt;init and inittab&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:verdana;"&gt;When init starts it reads /etc/inittab for further instructions. This file defines what should be run in different run-levels.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:verdana;"&gt;This gives the system administrator an easy management scheme, where each run-level is associated with a set of services (e.g: S is single-user, on 2 most network services start, etc.). The administrator may change the current run-level via &lt;a href="http://www.phpman.info/index.php/man/init/8"&gt;init(8)&lt;/a&gt; and query the current run-level via &lt;a href="http://www.phpman.info/index.php/man/runlevel/8"&gt;runlevel(8)&lt;/a&gt;.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:verdana;"&gt;However, since it is not convenient to manage individual services by editing this file, inittab only bootstraps a set of scripts that actually start/stop the individual services.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;font-family:verdana;" &gt;Boot Scripts&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:verdana;"&gt;Note: The following description applies to System V release 4 based system, which currently covers most commercial Unices (Solaris, HP-UX, Irix, Tru64) as well as the major Linux distributions (RedHat, Debian, Mandrake, Suse, Caldera). Some systems (Slackware Linux, FreeBSD, OpenBSD) have a somewhat different scheme of boot scripts.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:verdana;"&gt;For each managed service (mail, nfs server, cron, etc.) there is a single startup script located in a specific directory (/etc/init.d in most versions of Linux). Each of these scripts accepts as a single argument the word ’start’ -- causing it to start the service, or the word ’stop’ -- causing it to stop the service. The script may optionally accept other "convenience" parameters (e.g: ’restart’, to stop and then start, ’status’ do display the service status). Running the script without parameters displays the possible arguments.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;font-family:verdana;" &gt;Sequencing Directories&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:verdana;"&gt;To make specific scripts start/stop at specific run-levels and in specific order, there are sequencing directories. These are normally in /etc/rc[0-6S].d. In each of these directories there are links (usually symbolic) to the scripts in the init.d directory.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:verdana;"&gt;A primary script (usually /etc/rc) is called from &lt;a href="http://swoolley.org/man.cgi/5/inittab"&gt;inittab(5)&lt;/a&gt; and calls the services scripts via the links in the sequencing directories. All links with names that begin with ’S’ are being called with the argument ’start’ (thereby starting the service). All links with names that begin with ’K’ are being called with the argument ’stop’ (thereby stopping the service).&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:verdana;"&gt;To define the starting or stopping order within the same run-level, the names of the links contain order-numbers.&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:verdana;"&gt;Also, to make the names clearer, they usually end with the name of the service they refer to. Example: the link /etc/rc2.d/S80sendmail starts the sendmail service on runlevel 2. This happens after /etc/rc2.d/S12syslog is run but before /etc/rc2.d/S90xfs is run.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:verdana;"&gt;To manage the boot order and run-levels, we have to manage these links. However, on many versions of Linux, there are tools to help with this task (e.g: &lt;a href="http://www.phpman.info/index.php/man/chkconfig/8"&gt;chkconfig(8)&lt;/a&gt;).&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;font-family:verdana;" &gt;Boot Configuration&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:verdana;"&gt;Usually the daemons started may optionally receive command line options and parameters. To allow system administrators to change these parameters without editing the boot scripts themselves, configuration files are used.&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:verdana;"&gt;These are located in a specific directory (/etc/sysconfig on RedHat systems) and are used by the boot scripts.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:verdana;"&gt;In older Unices, these files contained the actual command line options for the daemons, but in modern Linux systems (and also in HP-UX), these files just contain shell variables. The boot scripts in /etc/init.d source the configuration files, and then use the variable values.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/34286671-7154827947776321102?l=midhunramadas.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://midhunramadas.blogspot.com/feeds/7154827947776321102/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=34286671&amp;postID=7154827947776321102' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/34286671/posts/default/7154827947776321102'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/34286671/posts/default/7154827947776321102'/><link rel='alternate' type='text/html' href='http://midhunramadas.blogspot.com/2007/12/linux-booting-procedure-boot-sequence_03.html' title=''/><author><name>midhunramdas@gmail.com</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-34286671.post-368611980056710285</id><published>2007-12-03T13:02:00.000+05:30</published><updated>2007-12-03T13:14:19.133+05:30</updated><title type='text'></title><content type='html'>&lt;span style="font-family: verdana;font-size:180%;" &gt;GRUB v/s LILO&lt;br /&gt;&lt;br /&gt;&lt;/span&gt;&lt;ul style="font-family: verdana;"&gt;&lt;li&gt;LILO has no interactive command interface, whereas GRUB does.&lt;/li&gt;&lt;li&gt;LILO does not support booting from a network, whereas GRUB does.&lt;/li&gt;&lt;li&gt;LILO stores information about the location of the kernel or other operating system on the Master Boot Record (MBR). Every time a new operating system or kernel is added to the system, the Stage 1 LILO bootloader has to be manually overwritten, otherwise there is no way to boot the new OS or kernel. This method is more risky than the method used by GRUB because a mis-configured LILO configuration file may leave the system unbootable (a popular way to fix this problem is to boot from Knoppix or another live CD, chroot into the partition with mis-configured lilo.conf and correct the problem). On the other hand, correcting a mis-configured GRUB is comparatively simple as GRUB will default to its command line interface where the user can boot the system manually. This flexibility is probably the main reason why many users nowadays prefer GRUB over LILO.&lt;/li&gt;&lt;/ul&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/34286671-368611980056710285?l=midhunramadas.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://midhunramadas.blogspot.com/feeds/368611980056710285/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=34286671&amp;postID=368611980056710285' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/34286671/posts/default/368611980056710285'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/34286671/posts/default/368611980056710285'/><link rel='alternate' type='text/html' href='http://midhunramadas.blogspot.com/2007/12/grub-vs-lilo-lilo-has-no-interactive.html' title=''/><author><name>midhunramdas@gmail.com</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-34286671.post-8414795273539539558</id><published>2007-11-21T12:35:00.000+05:30</published><updated>2007-11-21T12:47:58.971+05:30</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux runlevels'/><title type='text'></title><content type='html'>&lt;span style="font-family: verdana;font-size:180%;" &gt;Runlevels on Linux&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;&lt;ul&gt;&lt;li&gt;&lt;span style="font-weight: bold; font-family: verdana;"&gt;Runlevel 0&lt;/span&gt;&lt;span style="font-family: verdana;"&gt;  The halt runlevel - this is the runlevel at which the system shuts down. For obvious reasons it is unlikely you would want this as your default runlevel.&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="font-weight: bold; font-family: verdana;"&gt;Runlevel 1&lt;/span&gt;&lt;span style="font-family: verdana;"&gt;  Single runlevel. This causes the system to start up in a single user mode under which only the root user can log in. In this mode the system does not start any networking or X windowing, X or multi-user services. This run level is ideal for system administrators to perform system maintenance or repair activities.&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="font-weight: bold; font-family: verdana;"&gt;Runlevel 2&lt;/span&gt;&lt;span style="font-family: verdana;"&gt;  Boots the system into a multi-user mode with text based console login capability. This runlevel does not, however, start the network.&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="font-weight: bold; font-family: verdana;"&gt;Runlevel 3&lt;/span&gt;&lt;span style="font-family: verdana;"&gt;  Similar to runlevel 2 except that networking services are started. This is the most common runlevel for server based systems that do not require any kind of graphical desktop environment.&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="font-weight: bold; font-family: verdana;"&gt;Runlevel 4&lt;/span&gt;&lt;span style="font-family: verdana;"&gt;  Undefined runlevel. This runlevel can be configured to provide a custom boot state.&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="font-weight: bold; font-family: verdana;"&gt;Runlevel 5&lt;/span&gt;&lt;span style="font-family: verdana;"&gt;  Boots the system into a networked, multi-user state with X Window System capability. By default the graphical desktop environment will start at the end of the boot process. This is the most common run level for desktop or workstation use.&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="font-weight: bold; font-family: verdana;"&gt;Runlevel 6&lt;/span&gt;&lt;span style="font-family: verdana;"&gt;  Reboots the system. Another runlevel that you are unlikely to want as your default.&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/34286671-8414795273539539558?l=midhunramadas.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://midhunramadas.blogspot.com/feeds/8414795273539539558/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=34286671&amp;postID=8414795273539539558' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/34286671/posts/default/8414795273539539558'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/34286671/posts/default/8414795273539539558'/><link rel='alternate' type='text/html' href='http://midhunramadas.blogspot.com/2007/11/runlevels-on-linux-runlevel-0-halt.html' title=''/><author><name>midhunramdas@gmail.com</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-34286671.post-8988210635850095099</id><published>2007-08-01T14:59:00.000+05:30</published><updated>2007-08-03T12:16:33.845+05:30</updated><title type='text'></title><content type='html'>&lt;span style="font-size:130%;"&gt;To enable rpmforge repo for yum &lt;/span&gt;&lt;br /&gt;&lt;span style="font-size:130%;"&gt;&lt;/span&gt;&lt;br /&gt;in Fedora Core 4&lt;br /&gt;&lt;span style="font-size:78%;"&gt;rpm -Uvh &lt;a href="http://ftp.belnet.be/packages/dries.ulyssis.org/fedora/fc4/i386/RPMS.dries/rpmforge-release-0.2-2.2.fc4.rf.i386.rpm"&gt;http://ftp.belnet.be/packages/dries.ulyssis.org/fedora/fc4/i386/RPMS.dries/rpmforge-release-0.2-2.2.fc4.rf.i386.rpm&lt;/a&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-size:78%;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-size:78%;"&gt;&lt;/span&gt;&lt;br /&gt;in CentOS 4.4&lt;br /&gt;&lt;span style="font-size:78%;"&gt;rpm -Uhv &lt;/span&gt;&lt;a href="http://apt.sw.be/packages/rpmforge-release/rpmforge-release-0.3.6-1.el4.rf.i386.rpm"&gt;&lt;span style="font-size:78%;"&gt;http://apt.sw.be/packages/rpmforge-release/rpmforge-release-0.3.6-1.el4.rf.i386.rpm&lt;/span&gt;&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/34286671-8988210635850095099?l=midhunramadas.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://midhunramadas.blogspot.com/feeds/8988210635850095099/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=34286671&amp;postID=8988210635850095099' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/34286671/posts/default/8988210635850095099'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/34286671/posts/default/8988210635850095099'/><link rel='alternate' type='text/html' href='http://midhunramadas.blogspot.com/2007/08/to-enable-rpmforge-repo-for-yum-in.html' title=''/><author><name>Midhun Ramadas</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-34286671.post-4235753031632111493</id><published>2007-07-17T15:07:00.000+05:30</published><updated>2007-07-17T15:09:06.241+05:30</updated><title type='text'></title><content type='html'>&lt;span style="font-weight: bold;font-size:130%;" &gt;To install sar (System Activity Report) on CentOS&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=";font-family:courier new;font-size:130%;"  &gt;# yum install sysstat&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;:)&lt;br /&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/34286671-4235753031632111493?l=midhunramadas.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://midhunramadas.blogspot.com/feeds/4235753031632111493/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=34286671&amp;postID=4235753031632111493' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/34286671/posts/default/4235753031632111493'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/34286671/posts/default/4235753031632111493'/><link rel='alternate' type='text/html' href='http://midhunramadas.blogspot.com/2007/07/to-install-sar-on-centos-yum-install.html' title=''/><author><name>Midhun Ramadas</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-34286671.post-3333580513551993996</id><published>2007-07-17T14:57:00.000+05:30</published><updated>2007-07-17T15:03:10.011+05:30</updated><title type='text'></title><content type='html'>&lt;span style="font-weight: bold;font-family:arial;" &gt;Issues in passwordless ssh (using ssh-keygen) to remote host !!&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-size:85%;"&gt;&lt;span style="font-family:arial;"&gt;If after the configuration, still it asks for password, check the permissions of authorized_keys (should be 600) and ~/.ssh (should be 700).&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:arial;"&gt;:)&lt;/span&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/34286671-3333580513551993996?l=midhunramadas.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://midhunramadas.blogspot.com/feeds/3333580513551993996/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=34286671&amp;postID=3333580513551993996' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/34286671/posts/default/3333580513551993996'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/34286671/posts/default/3333580513551993996'/><link rel='alternate' type='text/html' href='http://midhunramadas.blogspot.com/2007/07/issues-in-passwordless-ssh-to-remote.html' title=''/><author><name>Midhun Ramadas</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-34286671.post-4895276861364503647</id><published>2007-04-11T15:57:00.000+05:30</published><updated>2007-04-12T09:59:03.358+05:30</updated><title type='text'></title><content type='html'>&lt;span style=";font-family:verdana;font-size:85%;"  &gt;&lt;span style="font-weight: bold;font-size:130%;" &gt;Creating SSL Certificates for Apache&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Create a folder, say ssl &lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;[root@host ~]# mkdir /root/ssl&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;[root@host ~]# cd /root/ssl&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Creating your new private key (privkey.pem) and server.csr&lt;br /&gt;&lt;br /&gt;&lt;/span&gt;It will ask you for a PEM pass phrase. Enter a pass phrase, confirm it and remember it !!!&lt;br /&gt;Then it will ask you for few informations.&lt;br /&gt;The most important is to set Common Name (eg, your name or your server's hostname) exactly as your hostname&lt;span style="font-weight: bold;"&gt;&lt;br /&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style="font-family:courier new;"&gt;[root@host ssl]# &lt;span style="font-weight: bold;"&gt;openssl req -config /usr/share/ssl/openssl.cnf -new -out server.csr&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;Generating a 1024 bit RSA private key&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;............++++++&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;...................++++++&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;writing new private key to 'privkey.pem'&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;Enter PEM pass phrase:&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;Verifying - Enter PEM pass phrase:&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;-----&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;You are about to be asked to enter information that will be incorporated&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;into your certificate request.&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;What you are about to enter is what is called a Distinguished Name or a DN.&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;There are quite a few fields but you can leave some blank&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;For some fields there will be a default value,&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;If you enter '.', the field will be left blank.&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;-----&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;Country Name (2 letter code) [GB]:&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;State or Province Name (full name) [Berkshire]:&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;Locality Name (eg, city) [Newbury]:&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;Organization Name (eg, company) [My Company Ltd]:&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;Organizational Unit Name (eg, section) []:&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;Common Name (eg, your name or your server's hostname) []:&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;Email Address []:&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;Please enter the following 'extra' attributes&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;to be sent with your certificate request&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;A challenge password []:  &lt;span style="font-weight: bold;font-family:verdana;" &gt;&lt;--- Dont type anything here. Press Enter&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;An optional company name []:  &lt;/span&gt;&lt;/span&gt;&lt;span style="font-weight: bold;font-family:verdana;font-size:85%;"  &gt;&lt;span style="font-family:courier new;"&gt;&lt;span style="font-family:verdana;"&gt;&lt;--- Dont type anything here. Press Enter&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=";font-family:verdana;font-size:85%;"  &gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;[root@hostssl]#&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Creating the server.key file&lt;/span&gt;&lt;br /&gt;&lt;span style="font-style: italic;"&gt;You must enter the PEM pass phrase&lt;br /&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style="font-family:courier new;"&gt;[root@host ssl]# &lt;span style="font-weight: bold;"&gt;openssl rsa -in privkey.pem -out server.key&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;Enter pass phrase for privkey.pem:&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;writing RSA key&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;[root@hostssl]#&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Creating server.crt&lt;br /&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style="font-family:courier new;"&gt;[root@host ssl]# &lt;span style="font-weight: bold;"&gt;openssl x509 -in server.csr -out server.crt -req -signkey server.key -days 1825&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;Signature ok&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;subject=/C=US/ST=Maryland/L=Annapolis/O=CompanyName/OU=Department/CN=host.domain.com/emailAddress=mailid@domain.com&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;Getting Private key&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Now take the backup of old files and copy the newly created files&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;[root@host ssl]# &lt;span style="font-weight: bold;"&gt;cp /etc/httpd/conf/ssl.crt/server.crt&lt;/span&gt; /etc/httpd/conf/ssl.crt/server.crt.orig&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;[root@host ssl]# &lt;span style="font-weight: bold;"&gt;cp /etc/httpd/conf/ssl.key/server.key&lt;/span&gt;   /etc/httpd/conf/ssl.key/server.key.orig&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;[root@host ssl]# &lt;span style="font-weight: bold;"&gt;cp server.crt /etc/httpd/conf/ssl.crt/&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;cp: overwrite `/etc/httpd/conf/ssl.crt/server.crt'? y&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;[root@hostssl]# &lt;span style="font-weight: bold;"&gt;cp server.key  /etc/httpd/conf/ssl.key/&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;cp: overwrite `/etc/httpd/conf/ssl.key/server.key'? y&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Now restart apache&lt;br /&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style="font-family:courier new;"&gt;[root@hosts ssl]#/&lt;span style="font-weight: bold;"&gt;etc/init.d/httpd restart&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/34286671-4895276861364503647?l=midhunramadas.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://midhunramadas.blogspot.com/feeds/4895276861364503647/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=34286671&amp;postID=4895276861364503647' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/34286671/posts/default/4895276861364503647'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/34286671/posts/default/4895276861364503647'/><link rel='alternate' type='text/html' href='http://midhunramadas.blogspot.com/2007/04/creating-ssl-certificates-for-apache.html' title=''/><author><name>Midhun Ramadas</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-34286671.post-5374752612342022246</id><published>2007-01-05T10:57:00.000+05:30</published><updated>2007-04-11T17:18:49.471+05:30</updated><title type='text'></title><content type='html'>&lt;span style="font-weight: bold;font-family:verdana;" &gt;Upgrading multiple instance MySQL  DB to new version&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;&lt;span style="font-weight: bold;"&gt;&lt;br /&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="font-family:verdana;"&gt;After upgradation, we need to convert the system tables to current format.&lt;br /&gt;For this we need to run &lt;span style="font-family:courier new;"&gt;mysql_fix_privilege_tables&lt;/span&gt; command.&lt;br /&gt;&lt;br /&gt;If we are having multiple instances, we need to specify the socket file as shown below:&lt;br /&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style="font-family:verdana;"&gt;&lt;span style="font-family:courier new;"&gt;&lt;span style="font-size:85%;"&gt;# mysql_fix_privilege_tables --socket=/path/to/socket_file&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="font-family:verdana;"&gt;&lt;br /&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style="font-weight: bold;font-family:verdana;" &gt;&lt;span style="font-weight: bold;"&gt;&lt;span style="font-weight: bold;"&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/34286671-5374752612342022246?l=midhunramadas.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://midhunramadas.blogspot.com/feeds/5374752612342022246/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=34286671&amp;postID=5374752612342022246' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/34286671/posts/default/5374752612342022246'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/34286671/posts/default/5374752612342022246'/><link rel='alternate' type='text/html' href='http://midhunramadas.blogspot.com/2007/01/upgrading-multiple-instance-mysql-db-to.html' title=''/><author><name>Midhun Ramadas</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-34286671.post-116351997131148364</id><published>2006-11-14T21:27:00.000+05:30</published><updated>2006-11-14T21:28:35.476+05:30</updated><title type='text'></title><content type='html'>&lt;h1 style="font-weight: bold;font-family:verdana;" &gt;&lt;span style="font-size:100%;"&gt;Soft and Hard Links&lt;/span&gt;&lt;/h1&gt;                                                                           &lt;p style="font-family: verdana;"&gt; &lt;/p&gt;&lt;h3  style="font-family:verdana;"&gt;&lt;span style="font-size:100%;"&gt;   Soft links&lt;/span&gt; &lt;/h3&gt; &lt;ul  style="font-family:verdana;"&gt;&lt;li&gt;&lt;span style="font-size:85%;"&gt;Pointers to programs, files, or directories located elsewhere.&lt;br /&gt;&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="font-size:85%;"&gt;If the original program, file, or directory is renamed, moved, or deleted, the soft link is broken. &lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="font-size:85%;"&gt;If you type &lt;span class="emphasis"&gt;ls -F &lt;/span&gt;you can see which files are soft links because they end with &lt;span class="emphasis"&gt;@&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="font-size:85%;"&gt;To create a soft link called filelink.txt that points to a file called file.txt, use this: &lt;/span&gt;&lt;span class="emphasis"&gt;&lt;span style="font-size:85%;"&gt;ln -s file.txt filelink.txt&lt;/span&gt; &lt;/span&gt;&lt;/li&gt;&lt;/ul&gt; &lt;h3  style="font-family:verdana;"&gt;&lt;span style="font-size:100%;"&gt;   Hard links&lt;/span&gt; &lt;/h3&gt; &lt;ul  style="font-family:verdana;"&gt;&lt;li&gt;&lt;span style="font-size:85%;"&gt;Pointers to programs and files, but NOT directories&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="font-size:85%;"&gt;If the original program or file is renamed, moved, or deleted, the hard link is NOT broken&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="font-size:85%;"&gt;Hard links cannot span disk drives, so you CANNOT have a hard link on /dev/hdb that refers to a program or file on /dev/hda&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="font-size:85%;"&gt;To create a hard link called hardlink.txt that points to a file called file.txt, use this: &lt;span class="emphasis"&gt;ln file.txt hardlink.txt&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/34286671-116351997131148364?l=midhunramadas.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://midhunramadas.blogspot.com/feeds/116351997131148364/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=34286671&amp;postID=116351997131148364' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/34286671/posts/default/116351997131148364'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/34286671/posts/default/116351997131148364'/><link rel='alternate' type='text/html' href='http://midhunramadas.blogspot.com/2006/11/soft-and-hard-links-soft-links.html' title=''/><author><name>Midhun Ramadas</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-34286671.post-116351961962303746</id><published>2006-11-14T21:22:00.000+05:30</published><updated>2006-11-14T21:28:35.392+05:30</updated><title type='text'></title><content type='html'>&lt;span style="font-size:130%;"&gt;&lt;span style="font-family: arial; font-weight: bold;"&gt;Hard and Soft Mounts in NFS&lt;br /&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style="font-family: arial;"&gt;&lt;span style="font-size:100%;"&gt;This is a UNIX terminology as to what the client does when it can't talk to an NFS Server. If you just mount a file system without specifying hard or soft, the default is a hard mount. Hard mounts are preferable because of the stateless nature of NFS. If a client sends an I/O request to the server (such as an ls -la), and the server gets rebooted, the client will wait until the server comes back on line. This preserves data transfers in the event of a server failure. There are disadvantages to this, as a simple mount request could hang. A soft mount will return with an error and fail. This kills the wait time, but can cause problems with data transfers.&lt;/span&gt;&lt;/span&gt;&lt;span style="font-family: arial; font-weight: bold;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/34286671-116351961962303746?l=midhunramadas.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://midhunramadas.blogspot.com/feeds/116351961962303746/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=34286671&amp;postID=116351961962303746' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/34286671/posts/default/116351961962303746'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/34286671/posts/default/116351961962303746'/><link rel='alternate' type='text/html' href='http://midhunramadas.blogspot.com/2006/11/hard-and-soft-mounts-in-nfs-this-is.html' title=''/><author><name>Midhun Ramadas</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-34286671.post-115808145006553295</id><published>2006-09-12T22:44:00.000+05:30</published><updated>2006-11-14T21:28:35.299+05:30</updated><title type='text'></title><content type='html'>&lt;span style="font-size:130%;"&gt;&lt;strong&gt;How to import the public.gpg.key for yum &lt;/strong&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-size:78%;"&gt;&lt;span style="font-family:courier new;"&gt;[root@midhun~]# yum update sendmail &lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;Repository base already added, not adding again You have enabled checking of packages via GPG keys. This is a good thing.However, you do not have any GPG public keys installed. You need to download the keys for packages you wish to install and install them.You can do that by running the command: &lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;rpm --import public.gpg.key &lt;/span&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style="font-family:courier new;"&gt;&lt;span style="font-size:78%;"&gt;Alternatively you can specify the url to the key you would like to usefor a repository in the 'gpgkey' option in a repository section and yum will install it for you. For more information contact your distribution or package provider.&lt;/span&gt; &lt;/span&gt;&lt;br /&gt;&lt;br /&gt;When you get the above message, just import it from web (Here I am using CentOS) as shown below&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:courier new;font-size:78%;"&gt;[root@midhun ~]# rpm --import &lt;/span&gt;&lt;a href="http://mirror.centos.org/centos/RPM-GPG-KEY-CentOS-4"&gt;&lt;span style="font-family:courier new;font-size:78%;"&gt;http://mirror.centos.org/centos/RPM-GPG-KEY-CentOS-4&lt;/span&gt;&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/34286671-115808145006553295?l=midhunramadas.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://midhunramadas.blogspot.com/feeds/115808145006553295/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=34286671&amp;postID=115808145006553295' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/34286671/posts/default/115808145006553295'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/34286671/posts/default/115808145006553295'/><link rel='alternate' type='text/html' href='http://midhunramadas.blogspot.com/2006/09/how-to-import-public.html' title=''/><author><name>Midhun Ramadas</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-34286671.post-115808092165283029</id><published>2006-09-12T22:28:00.000+05:30</published><updated>2006-11-14T21:28:35.172+05:30</updated><title type='text'></title><content type='html'>&lt;span style="font-family:arial;"&gt;&lt;span style="font-size:180%;"&gt;MySQL Replication &lt;/span&gt;&lt;br /&gt;1. Settings to be done in Master DB server:&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:arial;"&gt;Edit my.cnf file (/etc/my.cnf) and enter the following:&lt;/span&gt;&lt;br /&gt;&lt;span style="color: rgb(0, 0, 153);font-family:courier new;" &gt;server-id = 1 &lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:arial;"&gt;&lt;span style="color: rgb(0, 0, 153);font-family:courier new;" &gt;log-bin&lt;/span&gt; &lt;/span&gt;&lt;br /&gt; &lt;br /&gt;&lt;span style="font-family:arial;"&gt;2. Login to mysql DB in master server and run the following command: &lt;/span&gt;&lt;br /&gt;&lt;span style="color: rgb(0, 0, 153);font-family:courier new;" &gt;mysql&gt; show master status; &lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:arial;"&gt;Note down the following values: MASTER_LOG_FILE &amp; MASTER_LOG_POS &lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:arial;"&gt;Then give permission for the slave server &lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:arial;"&gt;&lt;span style="color: rgb(0, 0, 153);font-family:courier new;" &gt;mysql&gt;GRANT REPLICATION SLAVE ON *.* TO user@slave_IP IDENTIFIED BY 'password'; &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:arial;"&gt;&lt;span style="color: rgb(0, 0, 153);font-family:courier new;" &gt;mysql&gt;GRANT FILE ON *.* to user@ slave__IP identified by 'password';&lt;/span&gt; &lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:arial;"&gt;3. Take the DB dump in master server and restore it in slave server. &lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:arial;"&gt;4. Edit my.cnf file in slave server (/etc/my.cnf) and enter the following: &lt;/span&gt;&lt;br /&gt;&lt;span style="color: rgb(0, 0, 153);font-family:courier new;" &gt;server-id = 2 &lt;/span&gt;&lt;br /&gt;&lt;span style="color: rgb(0, 0, 153);font-family:courier new;" &gt;master-host = Master_Server_IP &lt;/span&gt;&lt;br /&gt;&lt;span style="color: rgb(0, 0, 153);font-family:courier new;" &gt;master-user = user &lt;/span&gt;&lt;br /&gt;&lt;span style="color: rgb(0, 0, 153);font-family:courier new;" &gt;master-password = password &lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:arial;"&gt;&lt;span style="color: rgb(0, 0, 153);"&gt;&lt;span style="font-family:courier new;"&gt;log-warnings&lt;/span&gt; &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:arial;"&gt;5. Login to mysql DB in slave server and run the following command: &lt;/span&gt;&lt;br /&gt;&lt;span style="color: rgb(0, 0, 153);font-family:courier new;" &gt;mysql&gt;CHANGE MASTER TO MASTER_HOST='Master_Server_IP', MASTER_USER='user', &lt;/span&gt;&lt;br /&gt;&lt;span style="color: rgb(0, 0, 153);font-family:courier new;" &gt;MASTER_PASSWORD='password', &lt;/span&gt;&lt;br /&gt;&lt;span style="color: rgb(0, 0, 153);font-family:courier new;" &gt;MASTER_LOG_FILE='Log filename', &lt;/span&gt;&lt;br /&gt;&lt;span style="color: rgb(0, 0, 153);font-family:courier new;" &gt;MASTER_LOG_POS= number; &lt;/span&gt;&lt;br /&gt;&lt;span style="color: rgb(0, 0, 153);font-family:courier new;" &gt;mysql&gt;start slave; &lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:arial;"&gt;6. Restart mysql service in both the servers.&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/34286671-115808092165283029?l=midhunramadas.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://midhunramadas.blogspot.com/feeds/115808092165283029/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=34286671&amp;postID=115808092165283029' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/34286671/posts/default/115808092165283029'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/34286671/posts/default/115808092165283029'/><link rel='alternate' type='text/html' href='http://midhunramadas.blogspot.com/2006/09/mysql-replication-1.html' title=''/><author><name>Midhun Ramadas</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry></feed>
