≡ Menu

centos linux

Download CentOS 6 CD / DVD ISO

CentOS Linux version 6 has been released. It is a community-supported operating system based on Red Hat Enterprise Linux (RHEL) version 6. CentOS Linux is considered as the most popular Linux distribution for web servers with almost 30% of all Linux servers using it.
[click to continue…]

After cloning a VMWare image I had noticed that my CentOS Linux server renamed eth0 as eth1, eth1 as eth2 and so on. This is due to wrong or duplicate mac address. To fix this problem login to your CentOS Linux server using console and type the following commands:
[click to continue…]

Perl version supplied with RHEL has bug, which will result code running at least 100 times slower than expected speed. Now, Red Hat updated perl packages that fix a performance issue. Earlier only solution was installing your own perl under /usr/local or other location. This fix will now take care of performance penalty.

Perl is a high-level programming language commonly used for system administration utilities and Web programming.

These updated packages fix a large performance degradation. This issue was most noticeable when using "bless" and "overload" combinations, as well as when using the Perl DBI modules.

Users of perl are advised to upgrade to these updated packages, which resolve this issue.

How do I update perl under RHEL / CentOS Linux?

Type the following command
# yum update

Postfix MTA updated to fix security vulnerabilities such as incorrectly checks the ownership of a mailbox. In some configurations, this allows for appending data to arbitrary files as root. This update has been rated as having moderate security impact.

All users of postfix should upgrade to these updated packages.

How do I patch Postfix under Debian / Ubuntu Linux?

First, update the internal database, enter:
# apt-get update
Install corrected Postfix package, enter:
# apt-get upgrade

How do I patch Postfix under RHEL / CentOS Linux?

Type the following command under RHEL / CentOS 5.x:
# yum update
Type the following command under RHEL <= 4.x: # up2date -u

Red Hat has shipped a new version of its dnsmasq caching software to plug source UDP port bug. This could have made DNS spoofing attacks (CVE-2008-1447) easier. Dnsmasq is lightweight ultra fast dns cache server forwarder and DHCP server. It is designed to provide DNS and, optionally, DHCP, to a small network.

This update has been rated as having moderate security impact, to upgrade your software, type the following command:
# yum update

This software only available under RHEL 5 / CentOS Linux 5.x. If you are using Debian / Ubuntu Linux, enter:
# apt-get update
# apt-get upgrade

How To Upgrade CentOS Linux To Version 5.2

CentOS Linux 5.2 has been released and available for immediate update via yum command or
the i386 and x86_64 Architectures. From the announcement page:

CentOS-5.2 is based on the upstream release EL 5.2.0, and includes packages from all variants including Server and Client. All upstream repositories have been combined into one, to make it easier for end users to work with. And the option to further enable external repositories at install time is now available in the installer.

How do I update from CentOS-5.0 and 5.1 to 5.2?

Simply type the following command as root user:
# yum update
OR
# yum upgrade
Sample output:

......
....
shadow-utils-4.0.17-13.el 100% |=========================|  50 kB    00:00
---> Package shadow-utils.i386 2:4.0.17-13.el5 set to be updated
---> Downloading header for cups to pack into transaction set.
cups-1.2.4-11.18.el5_2.1. 100% |=========================| 165 kB    00:00
Transaction Summary
=============================================================================
Install      8 Package(s)
Update     191 Package(s)
Remove       2 Package(s)
Total download size: 298 M
Is this ok [y/N]: y

Finally, reboot your computer, enter:
# reboot

I've received a couple of email about setting up iSCSI under CentOS 4 or RHEL ES 4 server. Previously, I wrote about iSCSI under CentOS 5 / RHEL 5 server.

Requirements

[a] Following instructions tested on RHEL ES 4 and CentOS 4 only. (See RHEL 5/ CentOS 5 / Debian/ Ubuntu Linux specific instructions here).
[b] You need following information
[c] ISCSI Username
[d] ISCSI Password
[e] ISCSI Server IP / hostname

CentOS Linux v4.x - Install iscsi-initiator-utils

Type the following command:
# yum install iscsi-initiator-utils

Redhat ES Linux v4.x - Install iscsi-initiator-utils

Type the following command:
# up2date iscsi-initiator-utils

Configure iSCSI

Open /etc/iscsi.conf file, enter:
# vi /etc/iscsi.conf
Setup it as follows:

DiscoveryAddress=ISCSI_TARGET_HOST_OR_IP
 OutgoingUserName=ISCSI_USER_NAME
 OutgoingPassword=ISCSI_PASSWORD
 LoginTimeout=15

Save and close the file.

Start the iscsi service

Type the following command to start iscsi service so that you can see block device:
# chkconfig iscsi on
# /etc/init.d/iscsi start

Run any one of the following to find out new block device name:
# fdisk -l
# tail -f /var/log/messages
# find /sys/devices/platform/host* -name "block*"

Format iSCSI device

Use fdisk and mkfs.ext3 commands. First, create a partition (assuming that /dev/sdc is a new block device assigned to iscsi) :
# fdisk /dev/sdc
# mkfs.ext3 /dev/sdc1

Create /mnt/iscsi directory:
# mkdir -p /mnt/iscsi
Open /etc/fstab file and append config directive:
/dev/sdc1 /mnt/iscsi ext3 _netdev 0 0
Save and close the file. Mount the parition /dev/sdc1:
# mount -a
# df -H