2013年4月12日 星期五

install repoforge for third party application on RHEL, CENTOS

1.import GPG KEY for repoforge
#rpm --import http://apt.sw.be/RPM-GPG-KEY.dag.txt

2.get and install repoforge package
#wget http://packages.sw.be/rpmforge-release/rpmforge-release-0.5.2-2.el6.rf.x86_64.rpm
#rpm -ivh http://packages.sw.be/rpmforge-release/rpmforge-release-0.5.2-2.el6.rf.x86_64.rpm

3.install third party program
#yum install openvpn

4.repoforge include packages
http://packages.sw.be/




install kde4

1.install require package for x windows
#yum groupinstall "Desktop" "Desktop Platform" "X Window System" "Fonts"

2.install kde desktop
#yum groupinstall "KDE Desktop"

3.modify /etc/sysconfig/desktop if this file doesn't exist, please create it and add the contents as below
#touch /etc/sysconfig/desktop
#vim /etc/sysconfig/desktop

DESKTOP= "KDE"
DISPLAYMANAGER= "KDE"

4.Reboot the machine
#reboot

2013年4月11日 星期四

install oracle jdk

1. go to oracle to download jdk

2. install jdk
#chmod 777 jdk-6u41-linux-x64.bin
#./jdk-6u41-linux-x64.bin

3.mv jdk to /var/lib/jdk
#mv   jdk1.6.0_41 /var/lib/jdk

4.modify profile to add java
#vim /etc/profile

5.config java
#alternatives --install /usr/bin/java java /usr/lib/jdk/jre/bin/java 20000
#alternatives --install /usr/bin/java javaws /usr/lib/jdk/jre/bin/javaws 20000
#alternatives --install /usr/bin/java javac /usr/lib/jdk/jre/bin/javac 20000
#java -version

yum package management

yum is used to install, update, delete packages for centos. It will do dependencies analysis and auto installed required packages.

1.update all packages installed in the system
#yum update

2.install single package
#yum install nano
#yum install vim

3.remove single package
#yum remove nano

4.upgrade single package
#yum upgrade nano

5.query information single package
#yum info nano

6.query program in which package
#yum provides */nano

It will first download, etract and install fileslist.db and return the result of query

7. list a collection of  packages  like web server, mysql database server
#yum grouplist

8.install group software like MySQL Database Server
#yum groupinstall "MySQL Database Server" "MySQL Database client"

initial setting for centos6

After installation of centos 6 with minimum setting, I usually change some setting on it.

1.first modify /etc/sysconfig/network-scripts/ifcfg-eth0 to get dhcp address to update packages.
#vi /etc/sysconfig/network-scripts/ifcfg-eth0

change this line from off to yes
ONBOOT = yes

2. restart the network to enable it
#ifdown eth0
#ifup eth0

3.update all packages installed in the system
#yum update

4.install telnet and nslookup tool
#yum install telnet
#yum install bind-utils

5.install c compile for some packages use
#yum install gcc gcc-c++ autoconf automake

if you install centos on vmware esx, use this method to install vmware-tools
start vmware-tools install procedure
#mount /dev/cdrom
#cp /dev/cdrom/VMwareTools-8.6.5-621624.tar.gz .
#umont /dev/cdrom
#tar zxvf VMwareTools-8.6.5-621624.tar.gz
#cd vmware-tools-distrib
#./vmware-install.pl

6.install vim and nano editor
#yum install vim
#yum install nano

7.install man page
#yum install man

8.install ssh client
#yum install openssh-clients

9.install wget
#yum install wget

10.install telnet
#yum install telent