<?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-3073346646886801977</id><updated>2011-12-08T06:31:18.362-05:00</updated><title type='text'>Computer Tips and Tricks</title><subtitle type='html'>Computers from Unix, Linux to Windows</subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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>70</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-3073346646886801977.post-7699535421432693289</id><published>2011-06-20T08:41:00.004-04:00</published><updated>2011-06-20T08:51:06.017-04:00</updated><title type='text'>Install Sun Java on Ubuntu 11.04</title><content type='html'>1. sudo add-apt-repository "deb http://archive.canonical.com/ lucid partner"&lt;br /&gt;&lt;br /&gt;2. sudo apt-get update&lt;br /&gt;&lt;br /&gt;3. sudo apt-get install sun-java6-bin sun-java6-jre sun-java6-jdk&lt;br /&gt;&lt;br /&gt;4. set JAVA_HOME=/usr/lib/jvm/java-6-sun&lt;br /&gt;&lt;br /&gt;5. set PATH=$JAVA_HOME/bin:$PATH&lt;br /&gt;&lt;br /&gt;6. java -version&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-7699535421432693289?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/7699535421432693289/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=7699535421432693289' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/7699535421432693289'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/7699535421432693289'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2011/06/install-sun-java-on-ubuntu-1104.html' title='Install Sun Java on Ubuntu 11.04'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-3768302064341306509</id><published>2011-04-24T12:36:00.003-04:00</published><updated>2011-04-24T12:39:46.841-04:00</updated><title type='text'>Mount NTFS disk to CentOS 5.5</title><content type='html'>1. Find out the hardware platform:&lt;br /&gt;uname -i&lt;br /&gt;&lt;br /&gt;2. Download the rpmforge-release package.&lt;br /&gt;&lt;br /&gt;i386 - http://packages.sw.be/rpmforge-release/rpmforge-release-0.5.2-2.el5.rf.i386.rpm&lt;br /&gt;x86_64 - http://packages.sw.be/rpmforge-release/rpmforge-release-0.5.2-2.el5.rf.x86_64.rpm&lt;br /&gt;&lt;br /&gt;3. Install GPG key:&lt;br /&gt;rpm --import http://apt.sw.be/RPM-GPG-KEY.dag.txt&lt;br /&gt;&lt;br /&gt;4. Install the package.&lt;br /&gt;rpm -i rpmforge-release-0.5.2-2.el5.rf.*.rpm&lt;br /&gt;&lt;br /&gt;5. Install fuse-ntfs-3g packages.&lt;br /&gt;yum install fuse fuse-ntfs-3g &lt;br /&gt;&lt;br /&gt;6. Check the NTFS partition.&lt;br /&gt;fdisk -l&lt;br /&gt;&lt;br /&gt;7. Create the mount point.&lt;br /&gt;mkdir /mnt/windows&lt;br /&gt;&lt;br /&gt;8. Mount the NTFS disk.&lt;br /&gt;mount /dev/sdb1 /mnt/windows&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-3768302064341306509?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/3768302064341306509/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=3768302064341306509' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/3768302064341306509'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/3768302064341306509'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2011/04/mount-ntfs-disk-to-centos-55.html' title='Mount NTFS disk to CentOS 5.5'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-311170144467061222</id><published>2011-04-16T06:18:00.014-04:00</published><updated>2011-04-22T03:13:30.832-04:00</updated><title type='text'>Use At to run repeated task</title><content type='html'>Following is an example, schedule.sh, to run check_process.sh script at /home/pwong every 3 minutes within 12 hours period.  &lt;br /&gt;&lt;br /&gt; &lt;br /&gt;&lt;span style="font-style:italic;"&gt;WorkDir=/home/pwong&lt;br /&gt;&lt;br /&gt;if [ ! -f off_time ]; then&lt;br /&gt;        date --date="+12 hours" +"%k" &gt; off_time&lt;br /&gt;fi&lt;br /&gt;&lt;br /&gt;if [ `date +%k` -eq `cat off_time` ]; then&lt;br /&gt;        rm off_time&lt;br /&gt;        exit 1&lt;br /&gt;fi&lt;br /&gt;&lt;br /&gt;sleep 60&lt;br /&gt;&lt;br /&gt;cd $WorkDir&lt;br /&gt;&lt;br /&gt;at -f schedule.sh +3 minutes&lt;br /&gt;&lt;br /&gt;check_process.sh&lt;br /&gt;&lt;br /&gt;exit 0&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/3073346646886801977-311170144467061222?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/311170144467061222/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=311170144467061222' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/311170144467061222'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/311170144467061222'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2011/04/use-at-to-run-repeated-task.html' title='Use At to run repeated task'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-3753928543776089574</id><published>2011-04-16T00:32:00.016-04:00</published><updated>2011-04-16T01:19:08.095-04:00</updated><title type='text'>Install and Test SNMP on CentOS 5.5</title><content type='html'>1. Install net-net-snmp and net-snmp-utils&lt;br /&gt;# yum install net-snmp-utils&lt;br /&gt;&lt;br /&gt;2. Create /etc/snmp/snmpd.conf. Following is a very simple example for the testing.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-style: italic;"&gt;rocommunity public&lt;/span&gt;&lt;br /&gt;&lt;span style="font-style: italic;"&gt;syslocation "ABC, ABC Inc."&lt;/span&gt;&lt;br /&gt;&lt;span style="font-style: italic;"&gt;syscontact me@abc.com&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;3. Startup snmpd server&lt;br /&gt;# /etc/init.c/snmpd start&lt;br /&gt;&lt;br /&gt;4. Ues snmpwalk to test SNMP setup.&lt;br /&gt;# snmpwalk -v 1 -c public -O e 127.0.0&lt;br /&gt;&lt;br /&gt;Or&lt;br /&gt;# snmpwalk -v 1 -c public localhost system&lt;br /&gt;&lt;br /&gt;If something similar to the following show up on the screen, the SNMP is working.&lt;br /&gt;&lt;br /&gt;SNMPv2-MIB::sysDescr.0 = STRING: Linux localhost.localdomain 2.6.18-194.el5 #1 SMP Fri Apr 2 14:58:35 EDT 2010 i686&lt;br /&gt;SNMPv2-MIB::sysObjectID.0 = OID: NET-SNMP-MIB::netSnmpAgentOIDs.10&lt;br /&gt;DISMAN-EVENT-MIB::sysUpTimeInstance = Timeticks: (977) 0:00:09.77&lt;br /&gt;SNMPv2-MIB::sysContact.0 = STRING: me@abc.com&lt;br /&gt;SNMPv2-MIB::sysName.0 = STRING: localhost.localdomain&lt;br /&gt;SNMPv2-MIB::sysLocation.0 = STRING: "ABC, ABC Inc."&lt;br /&gt;...&lt;br /&gt;&lt;br /&gt;5. If someting is wrong, check /etc/snmpd/snmpd.conf for error. Following commands can be used for troubleshooting as well. If everything is fine, then firewall settings should be checked.&lt;br /&gt;# /etc/init.d/snmpd status&lt;br /&gt;# snmpd -f -Le&lt;br /&gt;&lt;br /&gt;6. Enable the snmpd starts up when the system reboot.&lt;br /&gt;# chkconfig snmpd on&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-3753928543776089574?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/3753928543776089574/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=3753928543776089574' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/3753928543776089574'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/3753928543776089574'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2011/04/install-and-test-snmp-on-centos-55.html' title='Install and Test SNMP on CentOS 5.5'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-8027634254605126448</id><published>2011-04-15T20:18:00.003-04:00</published><updated>2011-04-15T20:28:47.760-04:00</updated><title type='text'>Mysqldump Performance Issue</title><content type='html'>When dumping really big tables, mysqldump was using up large amounts of memory, so it may cause no-response problem. To overcome this, --quick and --single-transaction options can used. Following are the sections for these options in the mysqldump man page.&lt;br /&gt;&lt;br /&gt;--quick, -q&lt;br /&gt;This option is useful for dumping large tables. It forces mysqldump to  retrieve rows for a table from the server a row at a time rather than  retrieving the entire row set and buffering it in memory before writing  it out.&lt;br /&gt;&lt;br /&gt;--single-transaction&lt;br /&gt;To dump big tables, you should combine this option with --quick.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-8027634254605126448?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/8027634254605126448/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=8027634254605126448' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/8027634254605126448'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/8027634254605126448'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2011/04/mysqldump-performance-issue.html' title='Mysqldump Performance Issue'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-8395629112255507379</id><published>2011-04-03T18:43:00.008-04:00</published><updated>2011-04-16T01:55:17.027-04:00</updated><title type='text'>Use Remote Variables with Rsh or Ssh</title><content type='html'>Followng are the difference between local and remote variables. $PWD is the local variable passed to remote system, but \$PWD is the variable defined in the remote system.&lt;br /&gt;&lt;br /&gt;/home/patrickw/tools $ sudo ssh host "echo $PWD"&lt;br /&gt;/home/patrickw/tools&lt;br /&gt;&lt;br /&gt;/home/patrickw/tools $ sudo ssh host "echo \$PWD"&lt;br /&gt;/root&lt;br /&gt;&lt;br /&gt;Therefore, backslashes in the following example is necessary. Without the backslashes, awk will complain syntax error since the variables are blank.&lt;br /&gt;&lt;br /&gt;sudo ssh host "top -b -n 1 | egrep sudo\|ssh\|xinet | awk '{print \$1, \$9, \$10, \$12}'"&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-8395629112255507379?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/8395629112255507379/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=8395629112255507379' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/8395629112255507379'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/8395629112255507379'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2011/04/use-remote-variables-with-rsh-or-ssh.html' title='Use Remote Variables with Rsh or Ssh'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-2382018043684646972</id><published>2011-02-28T23:55:00.008-05:00</published><updated>2011-03-08T07:31:24.129-05:00</updated><title type='text'>Install OpenNMS with postgreSQL 9 on CentOS 5.5</title><content type='html'>&lt;ol&gt;&lt;li&gt;yum install yum-fastestmirror&lt;/li&gt;&lt;li&gt;rpm -Uvh http://yum.opennms.org/repofiles/opennms-repo-stable-rhel5.noarch.rpm&lt;/li&gt;&lt;li&gt;wget http://www.pgrpms.org/9.0/redhat/rhel-5-x86_64/pgdg-centos-9.0-2.noarch.rpm&lt;/li&gt;&lt;li&gt;rpm -i pgdg-centos-9.0-2.noarch.rpm&lt;/li&gt;&lt;li&gt;yum install postgresql90-server postgresql90-devel&lt;/li&gt;&lt;li&gt;/etc/init.d/postgresql-9.0 initdb&lt;/li&gt;&lt;li&gt;vi /var/lib/pgsql/9.0/data/pg_hba.conf, to change ident to trust for all local, IPv4, and IPv6.&lt;br /&gt;&lt;/li&gt;&lt;li&gt;vi /var/lib/pgsql/9.0/data/postgresql.conf to modify work_mem, vacuum_cost_delay, wal_buffer, checkpoint_segment, etc to meet your need.&lt;br /&gt;&lt;/li&gt;&lt;li&gt;/etc/init.d/postgresql-9.0 restart&lt;/li&gt;&lt;li&gt;createdb -U postgres opennms&lt;/li&gt;&lt;li&gt;wget http://sourceforge.net/projects/opennms/files/IPLIKE/stable-2.0/iplike-2.0.0.tar.gz&lt;/li&gt;&lt;li&gt;tar xfz iplike-2.0.0.tar.gz&lt;/li&gt;&lt;li&gt;cd iplike-2.0.0&lt;/li&gt;&lt;li&gt;./configure --with-pgsql=/usr/pgsql-9.0/bin/pg_config&lt;/li&gt;&lt;li&gt;make&lt;/li&gt;&lt;li&gt;make install&lt;/li&gt;&lt;li&gt;/usr/local/sbin/install_iplike.sh&lt;/li&gt;&lt;li&gt;psql -U postgres -h localhost -d opennms -c '\df+ iplike|head'&lt;/li&gt;&lt;li&gt;yum install opennms --nogpgcheck&lt;/li&gt;&lt;li&gt;/opt/opennms/bin/runjava -s&lt;/li&gt;&lt;li&gt;/opt/opennms/bin/install -dis&lt;/li&gt;&lt;li&gt;/etc/init.d/opennms start&lt;/li&gt;&lt;/ol&gt;The OpenNMS page is at http://localhost:8980/opennms/login.jsp. Both initial user name and password are admin.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-2382018043684646972?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/2382018043684646972/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=2382018043684646972' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/2382018043684646972'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/2382018043684646972'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2011/02/install-opennms-with-postgresql-9-on.html' title='Install OpenNMS with postgreSQL 9 on CentOS 5.5'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-8521889667267834633</id><published>2011-01-28T22:35:00.010-05:00</published><updated>2011-01-28T22:59:17.374-05:00</updated><title type='text'>Add local disk to Xenserver 5.5 running under VMware</title><content type='html'>1. Find the new disk name.&lt;br /&gt;&lt;div&gt;&lt;span class="Apple-tab-span" style="white-space:pre"&gt; &lt;/span&gt;&lt;b&gt;fdisk -l&lt;/b&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;2. Create physical volume.&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-tab-span" style="white-space:pre"&gt; &lt;/span&gt;&lt;b&gt;pvcreate /dev/hdb&lt;/b&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-tab-span" style="white-space:pre"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;3. Find out the name of the disk.&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-tab-span" style="white-space:pre"&gt; &lt;/span&gt;&lt;b&gt;ll /dev/disk/by-id/&lt;/b&gt;&lt;/div&gt;&lt;div&gt;...&lt;/div&gt;&lt;div&gt;lrwxrwxrwx 1 root root  9 Jan 28 22:18 ata-VMware_Virtual_IDE_Hard_Drive_01000000000000000001 -&gt; ../../hdb&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="white-space: pre;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;4. Create SR.&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-tab-span" style="white-space:pre"&gt; &lt;b&gt;xe sr-create type=lvm content-type=user device-config:device=/dev/disk/by-id/ata-VMware_Virtual_IDE_Hard_Drive_01000000000000000001 name-label=”LOCAL &lt;/b&gt;&lt;/span&gt;&lt;b&gt;DISK&lt;span class="Apple-tab-span" style="white-space:pre"&gt;”&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-tab-span" style="white-space:pre"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-tab-span" style="white-space:pre"&gt;After the running above command, the LOCAL DISK will be in Xenserver's Storage Repositories.&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-tab-span" style="white-space:pre"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-tab-span" style="white-space:pre"&gt;N&lt;/span&gt;ote: You can name your own name-label.&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-8521889667267834633?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/8521889667267834633/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=8521889667267834633' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/8521889667267834633'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/8521889667267834633'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2011/01/add-local-disk-to-xenserver-55-running.html' title='Add local disk to Xenserver 5.5 running under VMware'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-3073346646886801977.post-6363781329607447467</id><published>2011-01-04T10:38:00.001-05:00</published><updated>2011-01-04T10:42:11.435-05:00</updated><title type='text'>Install Lighttpd With PHP5/MySQL on Ubuntu 10.10</title><content type='html'>&lt;div&gt;The following link has detailed instructions:&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;a href="http://www.howtoforge.com/installing-lighttpd-with-php5-and-mysql-support-on-ubuntu-10.10"&gt;http://www.howtoforge.com/installing-lighttpd-with-php5-and-mysql-support-on-ubuntu-10.10&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-6363781329607447467?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/6363781329607447467/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=6363781329607447467' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/6363781329607447467'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/6363781329607447467'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2011/01/install-lighttpd-with-php5mysql-on.html' title='Install Lighttpd With PHP5/MySQL on Ubuntu 10.10'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-3950154411534137243</id><published>2011-01-04T09:06:00.001-05:00</published><updated>2011-01-04T09:08:57.538-05:00</updated><title type='text'>Fix vSphere problem on Windows 7</title><content type='html'>Following link has a detailed explanation:&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;a href="http://www.techhead.co.uk/running-vmware-vsphere-client-on-windows-7"&gt;http://www.techhead.co.uk/running-vmware-vsphere-client-on-windows-7&lt;/a&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-3950154411534137243?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/3950154411534137243/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=3950154411534137243' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/3950154411534137243'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/3950154411534137243'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2011/01/fix-vsphere-problem-on-windows-7.html' title='Fix vSphere problem on Windows 7'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-7076066430974195476</id><published>2010-12-24T16:17:00.004-05:00</published><updated>2010-12-24T16:45:27.217-05:00</updated><title type='text'>Reset root password on Rad Hat Enterrpise 5</title><content type='html'>&lt;ol&gt;&lt;li&gt;Insert install CD #1 into the CD drive, then reboot system.&lt;/li&gt;&lt;li&gt;At &lt;span style="font-style: italic;"&gt;boot:&lt;/span&gt; prompt, enter &lt;span style="font-weight: bold;"&gt;linux rescue&lt;/span&gt;, then wait until &lt;span style="font-style: italic;"&gt;Choose a Language&lt;/span&gt; screen shows up.&lt;/li&gt;&lt;li&gt;Select the language, press tab to highlight OK, then press enter.&lt;/li&gt;&lt;li&gt;Select the keyboard type, press tab to highlight OK, then press enter.&lt;/li&gt;&lt;li&gt;Select Yes or No for &lt;span style="font-style: italic;"&gt;Setup Networkign&lt;/span&gt; screen, then press enter. Press enter again for Continue.&lt;/li&gt;&lt;li&gt;Press enter at &lt;span style="font-style: italic;"&gt;Your system has been mounted under /mnt/sysimage&lt;/span&gt; screen.&lt;/li&gt;&lt;li&gt;At command prompt &lt;span style="font-style: italic;"&gt;sh-3.2#&lt;/span&gt;, type in &lt;span style="font-weight: bold;"&gt;chroot /mnt/sysimage&lt;/span&gt;, then &lt;span style="font-weight: bold;"&gt;passwd&lt;/span&gt; to reset the root pass word.&lt;br /&gt;&lt;/li&gt;&lt;li&gt;Enter the the same password twice at &lt;span style="font-style: italic;"&gt;New UNIX password&lt;/span&gt; and &lt;span style="font-style: italic;"&gt;Retype new UNIX password&lt;/span&gt; prompts.&lt;/li&gt;&lt;li&gt;Type &lt;span style="font-weight: bold;"&gt;reboot&lt;/span&gt; at the command prompt to restart the server.&lt;/li&gt;&lt;/ol&gt;&lt;t&gt;&lt;/t&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-7076066430974195476?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/7076066430974195476/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=7076066430974195476' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/7076066430974195476'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/7076066430974195476'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2010/12/reset-root-password-on-rad-hat.html' title='Reset root password on Rad Hat Enterrpise 5'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-1961495747978337098</id><published>2010-11-15T22:44:00.005-05:00</published><updated>2011-03-22T03:59:52.208-04:00</updated><title type='text'>Use PSP to play You Tube videos</title><content type='html'>&lt;div&gt;PSP can be used to watch You Tube video when you travel with train or bus. For a student, this can be a great tool for study. Following is how to do it in a few steps.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;1. Download and install Free You Tube to iPod Converter from &lt;a href="http://www.dvdvideosoft.com/guides/free-youtube-to-ipod-converter.htm"&gt;http://www.dvdvideosoft.com/guides/free-youtube-to-ipod-converter.htm&lt;/a&gt;.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;2. Start the program and set the Devices to Sony PSP and the output folder, then paste the URL of video file from You Tube one by one. Down load file or files to the your PC.&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;2. Connect USB cable between PSP and your PC, and select USB connection in settings. The PSP will be named as Memory Stick on you PC like a hard drive.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;3. Copy the video file to Video folder at Memory Stick.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;4. Select Video-&gt;Memory Stick, then select the video to watch.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;    &lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-1961495747978337098?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/1961495747978337098/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=1961495747978337098' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/1961495747978337098'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/1961495747978337098'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2010/11/use-psp-to-play-you-tube-videos.html' title='Use PSP to play You Tube videos'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-4808593758646836374</id><published>2010-11-13T22:31:00.002-05:00</published><updated>2010-11-13T23:12:29.065-05:00</updated><title type='text'>Change Windows XP to a Multi Language System</title><content type='html'>Download Windows XP Multilingual User Interface Pack (Multi-Language) which has 5 CDs. This demo installs Traditional Chinese from the first CD which contains Chinese, Korean, Japanese, French, and German.&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;1. Double click mui_wxm_cd1.exe to extract all files for installation.&lt;/div&gt;&lt;div&gt;2. Double click muisetup.exe.&lt;/div&gt;&lt;div&gt;3. Accept the license agreement, then select the languages (Traditional Chinese) to install.&lt;/div&gt;&lt;div&gt;4. Reboot the system once the installation is completed, then start the Control Panel-&gt;Regional and Language Options. Select Hong Kong for location. Select Traditional Chinese for Language Used in Menus and Dialogs under the Language tab, then click OK.&lt;/div&gt;&lt;div&gt;5. Log off then log in again, the user interface has been changed from English to Traditional Chinese.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-4808593758646836374?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/4808593758646836374/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=4808593758646836374' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/4808593758646836374'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/4808593758646836374'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2010/11/change-windows-xp-to-multi-language.html' title='Change Windows XP to a Multi Language System'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-6074980510315312228</id><published>2010-10-19T22:28:00.002-04:00</published><updated>2010-10-19T22:40:50.790-04:00</updated><title type='text'>NAnt with Windows 7</title><content type='html'>In order to use either NAnt 0.85-cr2 or 0.91-alpha2 on Windows 7, you need to download and install Microsoft .NET Framework 4, dotNetFx40_Full_setup.exe, from Microsoft at&lt;div&gt;&lt;a href="http://www.microsoft.com/downloads/en/details.aspx?FamilyID=9cfb2d51-5ff4-4491-b0e5-b386f32c0992&amp;amp;displaylang=en"&gt;http://www.microsoft.com/downloads/en/details.aspx?FamilyID=9cfb2d51-5ff4-4491-b0e5-b386f32c0992&amp;amp;displaylang=en&lt;/a&gt;. &lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-6074980510315312228?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/6074980510315312228/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=6074980510315312228' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/6074980510315312228'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/6074980510315312228'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2010/10/nant-with-windows-7.html' title='NAnt with Windows 7'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-2324234639618317776</id><published>2010-10-18T16:54:00.002-04:00</published><updated>2010-10-18T23:03:41.049-04:00</updated><title type='text'>IIS 7.0 Configuration Backup</title><content type='html'>The configurations of IIS on Windows 2008 server or Windows 7 can be backup/restored with appcmd.exe.&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;1. Backup&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;C:\Windows\system32\inetsrv\appcmd add backup my-backup&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;It will create C:\Windows\system32\inetsrv\backup\my-backup with following files:&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;div&gt;2010-10-06  11:17 PM            18,258 administration.config&lt;/div&gt;&lt;div&gt;2010-10-18  02:50 PM            62,750 applicationHost.config&lt;/div&gt;&lt;div&gt;2010-10-06  11:16 PM               490 redirection.config&lt;/div&gt;&lt;div&gt;2010-10-18  10:44 PM    &lt;span class="Apple-style-span" style="font-family: monospace; font-size: medium; "&gt;&amp;lt;&lt;/span&gt;DIR&lt;span class="Apple-style-span" style="font-family: monospace; font-size: medium; "&gt;&amp;gt;&lt;/span&gt;          schema&lt;/div&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Please note that if no backup name is given, a name with date and time is used for the backup object as show below: &lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;C:\Windows\system32\inetsrv\appcmd add backup&lt;/div&gt;&lt;div&gt;BACKUP object "20101018T224909" added&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;2. Delete&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;C:\Windows\system32\inetsrv\appcmd delete backup my-backup&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;3. Restore&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;C:\Windows\system32\inetsrv\appcmd restore backup my-backup&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;4. List&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;C:\Windows\system32\inetsrv\appcmd list backup&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;  &lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-2324234639618317776?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/2324234639618317776/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=2324234639618317776' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/2324234639618317776'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/2324234639618317776'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2010/10/iis-70-configuration-backup.html' title='IIS 7.0 Configuration Backup'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-5357953264781449067</id><published>2010-06-21T18:41:00.005-04:00</published><updated>2010-06-24T12:07:39.753-04:00</updated><title type='text'>Install Broadcom driver for VMware ESXi</title><content type='html'>1. Download Broadcom NetXtreme II Ethernet network card driver CD from  http://www.vmware.com/support/vsphere4/doc/drivercd/esx40-net-bnx2x_400.1.48.107-1.0.4.html. Burn a CD from the file just downloaded.&lt;br /&gt;&lt;br /&gt;2. Because the Perl script vihostupdate.pl is used for the installation, download vSphere client CLI from VMware site http://www.vmware.com/downloads/eula.do.&lt;br /&gt;&lt;br /&gt;3. Install the vSphere client CLI which is a bundle of Active Perl and some admin tools on the administration PC. It is better to include the tools in the %PATH% before using the them.&lt;br /&gt;&lt;br /&gt;4. Switch the host to the maintenance mode before the installation. Key in the following one by one from the console:&lt;br /&gt;press alt+F1, type: unsupported, enter the root password. Run following command to switch to the maintenance mode.&lt;br /&gt;&lt;br /&gt;vim-cmd /hostsvc/maintenance_mode_enter&lt;br /&gt;&lt;br /&gt;Please note that enable ssh login is alternative way to run above command remotely.&lt;br /&gt;&lt;br /&gt;5. After the host is in the maintenance mode, following command can be used to install the driver from vSphere client command line.&lt;br /&gt;&lt;br /&gt;vihostupdate.pl --server 192.168.1.100 --install --bundle E:\offline-bundle\BCM-bnx2x-1.48.107.v40.2-offline_bundle-181332.zip&lt;br /&gt;&lt;br /&gt;6. Reboot ESXi.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-5357953264781449067?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/5357953264781449067/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=5357953264781449067' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/5357953264781449067'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/5357953264781449067'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2010/06/install-broadcom-driver-for-vmware-esxi.html' title='Install Broadcom driver for VMware ESXi'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-6330657510864095572</id><published>2010-06-20T07:25:00.002-04:00</published><updated>2010-06-20T07:42:45.940-04:00</updated><title type='text'>Run VMware ESXi 4.0 on USB devices</title><content type='html'>There are many posts in how to run VMware ESXi on USB flash in the Internet. However, the method can be applied to the USB portable disk as well. &lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;This is one of the links for running ESXi 3.5 on USB flash drive, http://www.atomicsub.net/2009/01/vmware-esxi-usb-flash/. Be very careful to select the correct disk. The image uses entire disk space, so all data on the disk will be wiped out.&lt;br /&gt;&lt;br /&gt;The steps to run ESXi 4.0 are the same as the above except the image dd file is in image.tgz instead of install.tgz. &lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-6330657510864095572?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/6330657510864095572/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=6330657510864095572' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/6330657510864095572'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/6330657510864095572'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2010/06/run-vmware-esxi-40-on-usb-devices.html' title='Run VMware ESXi 4.0 on USB devices'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-9057070025921095551</id><published>2010-05-01T01:10:00.002-04:00</published><updated>2010-05-01T01:12:51.978-04:00</updated><title type='text'>Install VirtualBox Guest Addition for Backtrack 4</title><content type='html'>1. mount /dev/hdc /mnt&lt;br /&gt;&lt;br /&gt;2. cd /mnt&lt;br /&gt;&lt;br /&gt;3. ./VBoxLinuxAddition-x86.run&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-9057070025921095551?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/9057070025921095551/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=9057070025921095551' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/9057070025921095551'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/9057070025921095551'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2010/05/install-virtualbox-guest-addition-for.html' title='Install VirtualBox Guest Addition for Backtrack 4'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-3073346646886801977.post-1915475344409095727</id><published>2010-04-01T08:53:00.020-04:00</published><updated>2010-04-01T15:14:35.280-04:00</updated><title type='text'>Simple Debug tips for PHP&amp;MySQL Program</title><content type='html'>1. Use PHP command to check if there is any syntax error. If no complains, an html file created by the script should be dumped to the screen. Because the script is check from the command line, it is quick and handy. &lt;br /&gt;&lt;br /&gt; php -l report.php&lt;br /&gt;&lt;br /&gt;2. Always use &amp;lt;?php codes... ?&amp;gt; instead of &amp;lt;? codes... ?&amp;gt; to make sure the PHP code will run in different environment. Especially for those whom cannot modify the file php.ini to enable the short tags for PHP codes.&lt;br /&gt;&lt;br /&gt;3. In the php script, always check the return value of a function such as sql_connect or sql_query with "or die(sql_error())" to make sure the function is executed as expected. Following are examples:&lt;br /&gt;&lt;br /&gt; mysql_connect("localhost", "root", "password") or die(mysql_error());&lt;br /&gt; mysql_query($sql) or die(mysql_error());&lt;br /&gt;&lt;br /&gt;4. Check web server error log such as error_log for Apache server. For example, the Apache error log is /var/log/httpd/error_log for RedHatd, CentOS, and Fedora.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-1915475344409095727?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/1915475344409095727/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=1915475344409095727' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/1915475344409095727'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/1915475344409095727'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2010/04/simple-debug-tips-for-php-program.html' title='Simple Debug tips for PHP&amp;MySQL Program'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-3933512045092134323</id><published>2009-12-22T14:11:00.003-05:00</published><updated>2009-12-22T14:39:37.034-05:00</updated><title type='text'>Use iSCSI disk on Windows 2008</title><content type='html'>&lt;div&gt;The iSCSI Initiator is part of Windows 2008, and it is located in the Control Panel. To&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;1. From iSCSI Initiator Properties, select Discovery tab, Click Add Portal, then enter the IP address with the default port number 3260 unchanged and click OK.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;2. Select Target tab, click Log on, the target name has been picked up, so just select automatically restore this connection when the computer starts, then click OK. If the configuration is right, the status of the Properties should indicate Connected. Click OK to exit the properties.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;3. From the Administrative Tools-&gt; Computer Management-&gt;Disk Management. There should be a new disk without a drive letter. From the property of the new disk it displays something like OPENFILER VIRTUAL-DISK SCSI Disk Device on my system.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;4. To use the new disk, right click on the disk, highlight Convert to Dynamic Disk, select the disk number, and then click OK. Select a drive letter, and then format the disk. After the format is completed, the new disk can be used as a normal disk for the system.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-3933512045092134323?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/3933512045092134323/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=3933512045092134323' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/3933512045092134323'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/3933512045092134323'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/12/use-iscsi-disk-on-windows-2008.html' title='Use iSCSI disk on Windows 2008'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-236455189842965499</id><published>2009-12-16T13:05:00.005-05:00</published><updated>2009-12-16T13:58:58.282-05:00</updated><title type='text'>Don't use test as the name of your program in Unix/Linux</title><content type='html'>Remember, test itself is the internal shell command in Unix/Linux OS. &lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;When you type in test, the name of the program you just wrote, you may realize your program doesn't work at all. You may spend lots of time in your program for debugging or struggle with your environment. Please don't waste your time; the puzzle is not in your program or your environment but the name, test. &lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;The trick is that when test is entered from the command prompt, shell always run its test command instead.  The only way you can start up your program is either to start your program with the full path "/PATH/test" or "bash test" if it is in the current directory.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;The simple solution for this problem is NOT to use test as your program name.   &lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-236455189842965499?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/236455189842965499/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=236455189842965499' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/236455189842965499'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/236455189842965499'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/12/dont-use-test-as-name-of-your-program.html' title='Don&apos;t use test as the name of your program in Unix/Linux'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-3150470855170634577</id><published>2009-12-16T11:12:00.006-05:00</published><updated>2009-12-16T12:58:44.902-05:00</updated><title type='text'>Connect Ubuntu 9.10 to Remote systems with Window XP SP2 VPN Server</title><content type='html'>&lt;div&gt;1. Setup Windows VPN server.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Open Network and Internet Connections in the Control panel. In the open window, click Network connections. Under Network Tasks, click Create New Connection to bring up the New Connection Wizard. Click Next, select Set up an advanced connection, and then click Next. Select Accept incoming connections, and then click Next then Next. Select Allow virtual private connection, then Next. From the User Permissions window, select or add the users allow to make the connections, and then click Next. At the Networking Software, highlight Internet Protocol (TCP/IP), and then click Properties. Either select Specify TCP/IP address, enter the address range or select to use DHCP, then click OK.Finally click Next and Finish completing the setup.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;2. Enable Remote desktop Access. Forget this; Ubuntu won't be able to make connection to Windows XP system. &lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;From Control panel, click Performance and Maintenance, then System. Select Remote tab, Select Allow users to connect remotely to this computer, and then click OK.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;3. Setup VPN client on Ubuntu.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;From Applications-&gt; Ubuntu Software Centre, enter pptp in the search box, select and install PPTP VPN Connection Manager package. Reboot Ubuntu. Click the Network Manager in the system tray, select VPN connection-&gt; Configure VPN… then makeup a connection name and enter the IP address of the VPN server with user name and pass word, then click Apply and Close. &lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;To make VPN connection, from the Network Manager-&gt; VPN Connections, then double click the connection name just created. When a lock logo showed at the upper-left corner of the Network manager, the Windows XP VPN server is connected.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;4. Startup remote desktop&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Bring up Application-&gt;Internet-&gt;Terminal Server Client. Enter the Computer IP address or hostname, select Protocol to RDP, and then click Connect.  The Terminal Server Client will display the Windows XP login screen. Enter the user name and pass word to start the remote desktop session on the Windows system. &lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-3150470855170634577?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/3150470855170634577/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=3150470855170634577' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/3150470855170634577'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/3150470855170634577'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/12/connect-ubuntu-910-to-remote-systems.html' title='Connect Ubuntu 9.10 to Remote systems with Window XP SP2 VPN Server'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-5501522802571187783</id><published>2009-12-04T23:26:00.004-05:00</published><updated>2009-12-05T15:17:26.561-05:00</updated><title type='text'>Setup CruiseControl on CentOS 5.4</title><content type='html'>1. Install Java:&lt;div&gt;yum install java java-1.6.0-openjdk-devel&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;2. Install Junit:&lt;/div&gt;&lt;div&gt;yum install junit&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;3. Install CVS &lt;/div&gt;&lt;div&gt;yum install cvs&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;4. Install CruiseControl/ANT&lt;/div&gt;&lt;div&gt;Download the current CruiseControl, cruisecontrol-bin-2.8.2.zip, from http://cruisecontrol.sourceforge.net/download.html, then unzip the file to /usr/share/cruisecontrol-bin-2.8.2. Set $ANT_HOME to /usr/share/cruisecontrol-bin-2.8.2/apache-ant-1.7.0, and PATH to include $ANT_HOME/bin and /usr/share/cruisecontrol-bin-2.8.2. Run 'ant -diagnostics' to make sure ANT is installed properly.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;After above software get installed, follow the step-by-step instructions in http://cruisecontrol.sourceforge.net/download.html to create a simple CruiseControl build environment should be pretty easy.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-5501522802571187783?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/5501522802571187783/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=5501522802571187783' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/5501522802571187783'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/5501522802571187783'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/12/setup-cruisecontrol-on-centos-54.html' title='Setup CruiseControl on CentOS 5.4'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-3073346646886801977.post-9135077278311813451</id><published>2009-12-04T12:50:00.009-05:00</published><updated>2009-12-05T15:12:10.085-05:00</updated><title type='text'>Remove the CR character with sed or tr</title><content type='html'>&lt;div&gt;Following command will redirect the content of dosfile except the CR characters to newfile:&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;sed 's/^V^M//' dosfile &amp;gt; newfile&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Note: ^ is the control key.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;tr -d  '\015' &amp;lt; dosfile &amp;gt; newfile&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-9135077278311813451?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/9135077278311813451/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=9135077278311813451' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/9135077278311813451'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/9135077278311813451'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/12/remove-cr-character-with-sed.html' title='Remove the CR character with sed or tr'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-2496135206274590415</id><published>2009-12-04T12:05:00.010-05:00</published><updated>2009-12-04T12:49:34.887-05:00</updated><title type='text'>Solaris Disk Cloning with dd and cpio</title><content type='html'>&lt;div&gt;For the disk cloning, power off the system, connect the target disk, then boot the system into single user mode. After the cloning, power off the system, disconnect the target disk which can be used as usual.&lt;/div&gt;&lt;div&gt; &lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;A. To clone a similar disk, assume the source disk is at /dev/rdsk/c0t0d0 and the target disk is at /dev/rdsk/c0t3d0 in the following example.&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;1. Clone the root partitial:&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;dd if=/dev/rdsk/c0t0d0s0 0f=/dev/rdsk/c0t3d0s0 bs=2048k count=1&lt;/div&gt;&lt;div&gt;dd if=/dev/rdsk/c0t0d0s0 of=/dev/rdsk/c0t3d0s0 bs=2048k&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;div&gt;2. Clone the entire disk:&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;dd if=/dev/rdsk/c0t0d0s2 of=/dev/rdsk/c0t3d0s2 bs=2048k&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;B. To clone a disimilar disk, assume the source is at /dev/dsk/c1t3d0s0 and the target is at /dev/dsk/c1t0d0s0.&lt;/div&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;div&gt;mount /dev/dsk/c1t3d0s0 /mnt/old&lt;/div&gt;&lt;div&gt;mount /dev/dsk/c1t0d0s0 /mnt/new&lt;/div&gt;&lt;div&gt;cd /mnt/old&lt;/div&gt;&lt;div&gt;find . -print | cpio -oac | (cd /mnt/new; cpio -imduc)&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Continue to perform the similar operation for the rest of partitions.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;If cloning is for the root disk, you may need to run installboot to fix the boot problem. Follow is the example to install the boot block on /dev/rdsk/cotodoso.  &lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;installboot /usr/platform/`uname -i`/lib/fs/ufs/bootblk /dev/rdsk/c0t0d0s0&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-2496135206274590415?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/2496135206274590415/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=2496135206274590415' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/2496135206274590415'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/2496135206274590415'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/12/solaris-disk-cloning-with-dd-and-cpio.html' title='Solaris Disk Cloning with dd and cpio'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-2563841030757207032</id><published>2009-10-25T16:20:00.004-04:00</published><updated>2009-10-25T17:37:06.474-04:00</updated><title type='text'>Speed up the Internet connection for Windows XP</title><content type='html'>1. From Windows XP, select Start-&gt;Run, enter regedit and click OK to start up Registry Editor.&lt;br /&gt;&lt;br /&gt;2. At HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings, double click MaxConnectionsPer1_0Server to edit the value. Select Decimal,  change it from default 10 to 100, then click OK to save it. Double click MaxConnectionsPerServer to edit the value. Select Decimal, change it from default 10 to 100, then click OK to save it.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-2563841030757207032?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/2563841030757207032/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=2563841030757207032' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/2563841030757207032'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/2563841030757207032'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/10/speed-up-internet-connection-for.html' title='Speed up the Internet connection for Windows XP'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-3073346646886801977.post-1505073692600990210</id><published>2009-10-20T23:54:00.011-04:00</published><updated>2009-10-21T00:51:34.798-04:00</updated><title type='text'>Transfer MySQL database</title><content type='html'>One way to transfer database from one server to an other is to use dump file created by mysqldump. However, on the new server to restore the dump file, MySQL may complains this:&lt;br /&gt;&lt;br /&gt;ERROR 1046 (3D000) at line xx: No database selected&lt;br /&gt;&lt;br /&gt;To fix this problem, insert following 2 lines in bold before the "DROP TABLE IF EXISTS 'address'", in following example, of the dump file before restoring the database:&lt;br /&gt;&lt;br /&gt;...&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;CREATE DATABASE databasename;&lt;br /&gt;USE databasename&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;DROP TABLE IF EXISTS 'address'&lt;br /&gt;...&lt;br /&gt;&lt;br /&gt;The modified dump file will create a new database and select it, then restore the dump file to this new database without problem.&lt;br /&gt;&lt;br /&gt;The command syntax to backup/restore MySQL database as root are shown below:&lt;br /&gt;&lt;br /&gt;Backup: mysqldump -u root -p databasename &gt; dumpfilename&lt;br /&gt;&lt;br /&gt;Restore: mysql -u root -p &lt; dumpfilename&lt;br /&gt;&lt;br /&gt;Note: the user has to enter the password for above commands.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-1505073692600990210?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/1505073692600990210/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=1505073692600990210' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/1505073692600990210'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/1505073692600990210'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/10/transfer-mysql-database.html' title='Transfer MySQL database'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-840833861324038777</id><published>2009-10-15T13:16:00.003-04:00</published><updated>2009-10-15T13:23:05.932-04:00</updated><title type='text'>Install PHP plugin to Eclipse on CentOS 5.3</title><content type='html'>To install the the current PHP plugins to Eclipse, downlowd and unzip the file PHPEclipse-1.2.3.200910091456PRD-bin.zip from http://sourceforge.net/projects/phpeclipse to /usr/share/eclipse/plugins, then restart Eclipse.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-840833861324038777?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/840833861324038777/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=840833861324038777' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/840833861324038777'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/840833861324038777'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/10/install-php-plugin-to-eclipse-on-centos.html' title='Install PHP plugin to Eclipse on CentOS 5.3'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-3723366696082698491</id><published>2009-10-14T22:41:00.006-04:00</published><updated>2009-10-14T23:14:29.068-04:00</updated><title type='text'>Update to current PHP on CentOS 5.3</title><content type='html'>The default version of PHP installed on CentOS 5.3 is 5.1.6. The command "yum update php" won't update to the current version. The function filter_var() is unavailable at 5.1.6, so this causes the undefined function error. Following steps will update to the current version of PHP to fix this problem.&lt;br /&gt;&lt;br /&gt;1. Run following to check the PHP version and it should be 5.1.6:&lt;br /&gt;&lt;br /&gt;php -v&lt;br /&gt;&lt;br /&gt;2. Create /etc/yum.repos.d/utterramblings.repo to contain following information:&lt;br /&gt;&lt;br /&gt;[utterramblings]&lt;br /&gt;name=Jason's Utter Ramblings Repo&lt;br /&gt;baseurl=http://www.jasonlitka.com/media/EL$releasever/$basearch/&lt;br /&gt;enabled=1&lt;br /&gt;gpgcheck=1&lt;br /&gt;gpgkey=http://www.jasonlitka.com/media/RPM-GPG-KEY-jlitka&lt;br /&gt;&lt;br /&gt;3. Run following to update PHP as root:&lt;br /&gt;&lt;br /&gt;yum update php&lt;br /&gt;&lt;br /&gt;4. Run the following to confirm the update of PHP and currently it is 5.2.11:&lt;br /&gt;&lt;br /&gt;php -v&lt;br /&gt;&lt;br /&gt;5. Restart Apache server to pickup the new version of PHP.&lt;br /&gt;&lt;br /&gt;/etc/init.d/httpd restart&lt;br /&gt;&lt;br /&gt;6. The error "undefined function filter_var() ..." will be disappeared.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-3723366696082698491?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/3723366696082698491/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=3723366696082698491' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/3723366696082698491'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/3723366696082698491'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/10/update-php-to-current-version-on-centos.html' title='Update to current PHP on CentOS 5.3'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-2963885310282327213</id><published>2009-09-08T23:38:00.006-04:00</published><updated>2009-09-09T00:00:06.799-04:00</updated><title type='text'>SSL for Apache on Ubuntu</title><content type='html'>1. Install curl:&lt;br /&gt;&lt;br /&gt;sudo apt-get install curl&lt;br /&gt;&lt;br /&gt;2. Enable SSL module:&lt;br /&gt;&lt;br /&gt;sudo a2enmod ssl&lt;br /&gt;&lt;br /&gt;3. Restart Apache server:&lt;br /&gt;&lt;br /&gt;sudo /etc/init.d/apache2 restart&lt;br /&gt;&lt;br /&gt;4. Enable site default-ssl:&lt;br /&gt;&lt;br /&gt;sudo a2ensite default-ssl&lt;br /&gt;&lt;br /&gt;5. Activate new configuration:&lt;br /&gt;&lt;br /&gt;sudo /etc/init.d/apache2 reload&lt;br /&gt;&lt;br /&gt;6. Test both http and https output with curl:&lt;br /&gt;&lt;br /&gt;curl -k http://localhost&lt;br /&gt;curl -k https://localhost&lt;br /&gt;&lt;br /&gt;Both commands will have the same output like this:&lt;br /&gt;&lt;br /&gt;&amp;lt;html&amp;gt;&amp;lt;body&amp;gt;&amp;lt;h1&amp;gt;It works!&amp;lt;/h1&amp;gt;&amp;lt;/body&amp;gt;&amp;lt;/html&amp;gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-2963885310282327213?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/2963885310282327213/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=2963885310282327213' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/2963885310282327213'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/2963885310282327213'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/09/ssl-for-apache-on-ubuntu.html' title='SSL for Apache on Ubuntu'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-3239877601637084650</id><published>2009-09-08T18:03:00.002-04:00</published><updated>2009-09-08T23:13:10.452-04:00</updated><title type='text'>Subversion and Eclipse</title><content type='html'>It needs to install subclipse plugin before Eclipse can use Subversion. Please make sure Subversion has been installed on the server and is functional.&lt;br /&gt;&lt;br /&gt;1. Start up Eclipse,from Help-&gt;Install New Software. Click Add button, type in http://subclipse.tigris.org/update in Location, click OK button. Select subclipse plugin then click Next button twice. Accept license agreement then click Finish button.   &lt;br /&gt;&lt;br /&gt;2. Restart Eclipse. From Windows-&gt;Open Perspective-&gt;Other. Highlight the new item SVN Repository Exploring then click OK button. Enter URL with the path of SVN repository, like http://localhost/svn/myproject, then click OK button. The URL just entered will be displayed under SVN Repository. The SVN exploring is ready to use. Multiple Repository can be added through Add SVN Repository button.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-3239877601637084650?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/3239877601637084650/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=3239877601637084650' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/3239877601637084650'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/3239877601637084650'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/09/subversion-and-eclipse.html' title='Subversion and Eclipse'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-2191470929014999200</id><published>2009-09-07T21:11:00.006-04:00</published><updated>2009-09-07T22:34:30.194-04:00</updated><title type='text'>Setup Subversion with Apache on Ubuntu</title><content type='html'>1. Install subversion and libapache2-svn:&lt;br /&gt;&lt;br /&gt;sudo apt-get install subversion libapache2-svn&lt;br /&gt;&lt;br /&gt;2. Add new group as subversion, and add www-data and subversion users to this group.&lt;br /&gt;&lt;br /&gt;3. Logout and login again to become the member of subversion group.&lt;br /&gt;&lt;br /&gt;4. Update/etc/apache2/mods-enabled/dav_svn.conf to something like this for the repository at /var/lib/svn/myporject:&lt;br /&gt;&lt;br /&gt;&lt;Location /svn/myproject&gt;&lt;br /&gt;DAV svn&lt;br /&gt;SVNP ath /var/lib/svn&lt;br /&gt;&lt;br /&gt;AuthType Basic&lt;br /&gt;AuthName "myproject Subversion Repository"&lt;br /&gt;AuthUserFile /etc/apache2/dav_svn.passwd&lt;br /&gt;Require valid-user&lt;br /&gt;&lt;/Location&gt;&lt;br /&gt;&lt;br /&gt;5. Create directory for repository and setup the ownership and permission:&lt;br /&gt;&lt;br /&gt;sudo mkdir /var/lib/svn&lt;br /&gt;cd /var/lib/svn&lt;br /&gt;sudo mkdir myproject&lt;br /&gt;sudo chown www-data:subversion myproject&lt;br /&gt;sudo chmod -R g+rws myproject&lt;br /&gt;&lt;br /&gt;6. Create the repository:&lt;br /&gt;&lt;br /&gt;sudo svnadmin create /var/lib/svn/myproject&lt;br /&gt;&lt;br /&gt;7. Restart Apache server:&lt;br /&gt;&lt;br /&gt;sudo /etc/init.d/apache2 restart&lt;br /&gt;&lt;br /&gt;8. Create user password:&lt;br /&gt;&lt;br /&gt;sudo htpasswd -c /etc/subversion/passwd user&lt;br /&gt;&lt;br /&gt;9. Test local svn server setup:&lt;br /&gt;&lt;br /&gt;svn co http://localhost/svn/myproject --username username&lt;br /&gt;&lt;br /&gt;Note: An empty myproject is checkout.&lt;br /&gt;&lt;br /&gt;10. Create a project structure named mywork at the current directory then import the directory to the repository:&lt;br /&gt;&lt;br /&gt;svn import -m "New import" mywork http://localhost/svn/myproject&lt;br /&gt;&lt;br /&gt;To check the repository, and mywork should be shown up:&lt;br /&gt;&lt;br /&gt;svn ls http://localhost/svn/myproject&lt;br /&gt;&lt;br /&gt;11. To checkout myproject:&lt;br /&gt;&lt;br /&gt;svn co http://localhost/svn/myproject/mywork mywork-new&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-2191470929014999200?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/2191470929014999200/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=2191470929014999200' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/2191470929014999200'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/2191470929014999200'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/09/setup-subversion-with-apache-on-ubuntu.html' title='Setup Subversion with Apache on Ubuntu'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-3290695010395931633</id><published>2009-09-06T10:35:00.009-04:00</published><updated>2009-09-06T21:48:34.393-04:00</updated><title type='text'>Setup CVS server on Ubuntu</title><content type='html'>1. Install CVS client and server:&lt;br /&gt;&lt;br /&gt;apt-get install cvs cvsd&lt;br /&gt;&lt;br /&gt;With the default installation, the root for cvsd is at /var/lib/cvsd, and the bin, dev, etc, lib, tmp, and usr directories should be created during the install. The default repositories demo and myrepos are defined in the configuration file /etc/cvsd/cvsd.conf.&lt;br /&gt;&lt;br /&gt;2. Start the CVS server:&lt;br /&gt;&lt;br /&gt;sudo /etc/init.d/cvsd start&lt;br /&gt;&lt;br /&gt;It looks like that the command /etc/init.d/cvsd status has problem to display the correct status of the CVS server, run following command to make sure if the server is running:&lt;br /&gt;&lt;br /&gt;ps -def | grep cvsd&lt;br /&gt;&lt;br /&gt;If the server is not running, modify the line with the word Listen in the configuration file /etc/cvsd/cvsd.conf:&lt;br /&gt;&lt;br /&gt;from "Listen * 2401" to "Listen 0.0.0.0 2401".&lt;br /&gt;&lt;br /&gt;Restart the server and check again.&lt;br /&gt;&lt;br /&gt;3. Create myrepos and CVSROOT directories with following command (Note: the absolute path is needed to initialize the repose):&lt;br /&gt;&lt;br /&gt;sudo cvs -d /var/lib/cvsd/myrepos init&lt;br /&gt;sudo chown -R cvsd:cvsd /var/lib/cvsd/myrepos&lt;br /&gt;&lt;br /&gt;The basic structures of cvsd and the repository $CVSROOT are ready.&lt;br /&gt;&lt;br /&gt;4. Add user to the group cvsd and create the password for users.&lt;br /&gt;&lt;br /&gt;From System-&gt;Administration-&gt;Users and Groups. Click Unlock button and enter the password, then click Manage Groups button. Highlight cvsd then click Properties and select the username from the Group Members list.&lt;br /&gt;&lt;br /&gt;Create the user password for CVS login as shown below:&lt;br /&gt;&lt;br /&gt;cvsd-passwd /var/lib/cvsd/myrepos username&lt;br /&gt;&lt;br /&gt;5. The syntax to login to the local CVS server is shown below:&lt;br /&gt;&lt;br /&gt;cvs -d :pserver:username@localhost:/myrepos login&lt;br /&gt;&lt;br /&gt;However, if the $CVSROOT is defined just simply enter "cvs login" instead. Add following line in ~/.bashrc is the easiest way to add it to the environment.&lt;br /&gt;&lt;br /&gt;export CVSROOT=:pserver:username@localhost:/myrepos&lt;br /&gt;&lt;br /&gt;If log in has no problem, CVS should be working fine.&lt;br /&gt;&lt;br /&gt;6. Following is the syntax to import an example tools project in the current directory to the repository. Please note that the CVS import function requires $CVSROOT defined.&lt;br /&gt;&lt;br /&gt;cd tools&lt;br /&gt;cvs import -m "Initial import into CVS" tools initial start&lt;br /&gt;&lt;br /&gt;A new directory, tools, is created at /var/lib/cvsd/myrepos.&lt;br /&gt;&lt;br /&gt;7. For any reason to completely uninstall cvsd, enter following command:&lt;br /&gt;&lt;br /&gt;apt-get --purge remove cvsd&lt;br /&gt;&lt;br /&gt;8. In Eclipse environment, the CVS repository location should be defined as /myrepos instead the full path.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-3290695010395931633?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/3290695010395931633/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=3290695010395931633' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/3290695010395931633'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/3290695010395931633'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/09/setup-cvs-server-on-ubuntu.html' title='Setup CVS server on Ubuntu'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-3073346646886801977.post-8357091017944460766</id><published>2009-08-31T16:32:00.007-04:00</published><updated>2009-09-05T17:19:48.998-04:00</updated><title type='text'>Setup Openfiler 2.3 iSCSI on ESXi 4 for Windows</title><content type='html'>1. Upload folder openfiler-2.3-x86 to the datastore through Datastore Browser. Right click openfiler-2.3-x86.vmx in the folder and select Add to Inventory. Enter the name then click Next button twice, and Finish button to complete the process.&lt;br /&gt;&lt;br /&gt;2. Click Edit settings for openfiler, the add hard disk from ESXi as the new iSCSI storage device for Openfiler.&lt;br /&gt;&lt;br /&gt;3. Power on the Openfiler, and open the console to confirm the URL for web administration. I use https://192.168.1.105:446 as an example.&lt;br /&gt;&lt;br /&gt;4. Logon to Openfiler with your web browser at https://192.168.1.105:446 with the openfiler and password as the user name and password respectively.&lt;br /&gt;&lt;br /&gt;5. Go to Volumes, a warning "No existing physical volumes were found, or all existing physical volumes are used. You can create new physical volumes" shows up. Click create new physical volumes, the newly added disk, /dev/sdb, has  no partition. Select /dev/sdb from the Edit Disk list, then click Create button to use the entire disk space for the single partition.&lt;br /&gt;&lt;br /&gt;6. Go to Volume Groups to create a group by entering the Volume group name and select physical volume /dev/sdb1 to add, then click Add volume group button to complete. Click Add volume, enter the volume name, description, select required space, and then select the filesystem/volume type to iSCSI, finally click Create to create the volume.&lt;br /&gt;&lt;br /&gt;7. Go to System, in Network Access Configuration section, enter 192.168.1.0 for both Name and Network/Host, select 255.255.255.0 as Netmask, and select Share as Type, then click Update button.&lt;br /&gt;&lt;br /&gt;8. Go to Services and enable iSCSI target server.&lt;br /&gt;&lt;br /&gt;9. Go to Volumes, click iSCSI targets, select target configuration, the default target name is shown up, if no changes needed, click Add button to add the new target. Select LUN Mapping, then click Map button. Select Network ACL, select Allow from the Access list, and then click Update button.&lt;br /&gt;&lt;br /&gt;10. Windows XP is used to test this iSCSI storage. Download the software from http://www.microsoft.com/downloads/details.aspx?familyid=12cb3c1a-15d6-4585-b385-befd1319f825&amp;amp;displaylang=en, and then install it to you PC.&lt;br /&gt;&lt;br /&gt;11. On Windows, from All programs, select Microsoft iSCSI Initiator for configuration. Select Discovery then click Add button to add target portal, enter the IP address of the Openfiler, then click OK.&lt;br /&gt;&lt;br /&gt;12. Select Targets then click Log On button. Select Automatically restore this connection when the system boots, then click OK button twice to finish the Windows XP setup.&lt;br /&gt;&lt;br /&gt;13. From the disk manager, the Initialize and Convert Disk Wizard pops up automatically. Click Next button to continue. Select the correct disk, then click Next button. It reminds you that the disk will be converted to dynamic disk. Reselect the disk, then click Next then Finish button. Right click on the new disk, and then select New Volume to start the Wizard, click Next button to continue. The simple volume is the default for a single disk volume, click Next button to continue. If the entire disk is used, click Next button to continue. Select the drive letter, the click Next button. Select the Volume label, the click Next button. Click Finish button to finish performing the disk format. Finally, the iSCSI disk is created like a local disk to Windows.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-8357091017944460766?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/8357091017944460766/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=8357091017944460766' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/8357091017944460766'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/8357091017944460766'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/08/setup-openfiler-23-iscsi-on-esxi-4-for.html' title='Setup Openfiler 2.3 iSCSI on ESXi 4 for Windows'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-3281646252472900525</id><published>2009-08-24T17:47:00.003-04:00</published><updated>2009-08-24T18:27:38.955-04:00</updated><title type='text'>Application Menu on Ubuntu 9.04</title><content type='html'>To add manually installed Eclipse 3.5 to the Applications-&gt;System Tools for easy start up.&lt;br /&gt;&lt;br /&gt;1. From System-&gt;Preferences-&gt;Main Menu to start the menu editing, highlight System Tools, select New Item, the Create Launcher dialog pops up.&lt;br /&gt;&lt;br /&gt;2. The default type is Application, Enter "Eclipse 3.5" in the Name field, Browse the executable /usr/local/lib/eclipse/eclipse, click OK, then enter the comment as Java Development Tool. Click OK. The new item Eclipse 3.5 is created and selected at Main Menu dialog. Click Close to finish the Main Menu editing.&lt;br /&gt;&lt;br /&gt;3. The item Eclipse 3.5 is the new item in Application-&gt;System Tools now.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-3281646252472900525?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/3281646252472900525/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=3281646252472900525' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/3281646252472900525'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/3281646252472900525'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/08/application-menu-on-ubuntu-94.html' title='Application Menu on Ubuntu 9.04'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-223885076829497468</id><published>2009-08-24T16:24:00.006-04:00</published><updated>2009-08-25T17:37:21.078-04:00</updated><title type='text'>Tools for Android development on Ubuntu 9.04</title><content type='html'>1. Install Sun Java tool kit 6:&lt;br /&gt;&lt;br /&gt;sudo apt-get install sun-java6-jdk&lt;br /&gt;&lt;br /&gt;2. Verify the Java version:&lt;br /&gt;&lt;br /&gt;java -version&lt;br /&gt;javac -version&lt;br /&gt;&lt;br /&gt;3. Download Android SDK, android-sdk-linux_x86-1.5_r3.zip, from http://developer.android.com/sdk/1.5_r3/index.html, and extract to /usr/local/lib. Update the ~/.bashrc to append the Android SDK tools to $PATH:&lt;br /&gt;&lt;br /&gt;export PATH=$PATH:/usr/local/lib/android-sdk-linux_x86-1.5_r3/tools&lt;br /&gt;&lt;br /&gt;4. Download current Eclipse 3.5, eclipse-java-galileo-linux-gtk.tar.gz, from http://www.eclipse.org/downloads/. Extract to /usr/local/lib. &lt;br /&gt;&lt;br /&gt;5. Start up Eclipse, select Help-&gt;Install New Software. In the Install dialog, click Add..., then enter http://dl-ssl.google.com/android/eclipse/ in the location then click OK. Select Developer Tool which contains Android DDMS and Android Development Tools, click Next, Next. Accept the terms of License agreement, then click Finish. Go ahead at the restart Eclipse prompt.&lt;br /&gt;&lt;br /&gt;6.Set up the Android SDK PATH in Eclipse. Select Windows-&gt;Preferences-&gt;Android. Browse the SDK Location to set the path.          &lt;br /&gt;&lt;br /&gt;7. Create an Android Virtual Device (AVD):&lt;br /&gt;android create avd --target 2 --name my_avd&lt;br /&gt;&lt;br /&gt;8. If Subversion is not on the system, run follwing to install Subversion:&lt;br /&gt;sudo apt-get install subversion &lt;br /&gt;&lt;br /&gt;Otherwise, run following command to checkout the example source from Google to learn and start:&lt;br /&gt;svn checkout http://android-examples.googlecode.com/svn/trunk/ android-examples&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-223885076829497468?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/223885076829497468/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=223885076829497468' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/223885076829497468'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/223885076829497468'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/08/tools-for-android-development-on-ubuntu.html' title='Tools for Android development on Ubuntu 9.04'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-3073346646886801977.post-3537013802077449251</id><published>2009-08-18T22:38:00.005-04:00</published><updated>2009-08-18T22:54:03.525-04:00</updated><title type='text'>Gigabit network for VMWare ESXi 4 Server</title><content type='html'>A gigabit network is a must for VMWare ESXi 4. Otherwise the slow network will cause lots of problems such as the vSphere Client is extremely slow and some times it complains the server takes to long to respond and the operation can't be completed. In addition, either upload or download from the datastore browser will complain the IO error as well.&lt;br /&gt;&lt;br /&gt;If a gigabit connection is established, all of above problems will be resolved.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-3537013802077449251?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/3537013802077449251/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=3537013802077449251' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/3537013802077449251'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/3537013802077449251'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/08/gigabit-network-for-vmware-esxi-4.html' title='Gigabit network for VMWare ESXi 4 Server'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-5905861593336153927</id><published>2009-08-11T18:41:00.003-04:00</published><updated>2009-08-11T19:34:19.278-04:00</updated><title type='text'>Transfer files between VMWare ESXi server and your computer</title><content type='html'>To enable the ssh at ESXi server, at the server console, press ALT-F1, type "unsupported", press Enter. When the password prompt shows up, enter the root password to log in.&lt;br /&gt;&lt;br /&gt;Delete the first character # in the line containing ssh in the file /etc/inetd.conf to make it similar to the line below, then reboot the server.&lt;br /&gt;&lt;br /&gt;ssh     stream  tcp     nowait  root    /sbin/dropbearmulti     dropbear ...&lt;br /&gt;&lt;br /&gt;After ssh is enabled, putty can ssh to the server from your PC. WinSCP can upload/download files with the server as well.&lt;br /&gt;&lt;br /&gt;An other tool can download files from the server is Firefox. Following example URL can browse the files at datastore1 on the server that has the IP address as 192.168.111.222:&lt;br /&gt;&lt;br /&gt;https://192.168.111.222/folder?dsName=datastore1&lt;br /&gt;&lt;br /&gt;In addition, the ESXi server's datastore browser also can upload and download files between the server and your PC.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-5905861593336153927?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/5905861593336153927/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=5905861593336153927' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/5905861593336153927'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/5905861593336153927'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/08/transfer-files-between-vmware-esxi.html' title='Transfer files between VMWare ESXi server and your computer'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-3298716714369672514</id><published>2009-08-10T08:02:00.002-04:00</published><updated>2009-08-10T08:09:36.803-04:00</updated><title type='text'>VMWare Tools on CentOS</title><content type='html'>1. Update the system.&lt;br /&gt;yum update&lt;br /&gt;&lt;br /&gt;2. Install gcc and kernel development tools.&lt;br /&gt;yum install gcc kernel-devel&lt;br /&gt;&lt;br /&gt;3. Following the instruction at http://www.vmware.com/support/ws5/doc/ws_newguest_tools_linux.html to complete the installation.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-3298716714369672514?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/3298716714369672514/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=3298716714369672514' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/3298716714369672514'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/3298716714369672514'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/08/vmware-tools-on-centos.html' title='VMWare Tools on CentOS'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-5684119973815838693</id><published>2009-07-14T16:54:00.003-04:00</published><updated>2009-07-14T17:17:53.673-04:00</updated><title type='text'>Using Flash Drive under VirtualBox</title><content type='html'>To use the flash drive on the virtual machine:&lt;br /&gt;&lt;br /&gt;1. Enable the USB Controller and USB 2.0 (EHCI) Controller from the Settings menu.&lt;br /&gt;2. Logon to the virtual machine, plug in the flash drive to the system then right click on the USB devices logo at the buttum of the window and select the flash drive just lugged in.&lt;br /&gt;3. After a few seconds, a new file folder started up at the Desktop. The flash drive can be used from now.&lt;br /&gt;4. Folloing is the list of mount point for the flash drive on popular OS.&lt;br /&gt;       &lt;pre&gt;&lt;br /&gt;       CentOS - /dev/sda1&lt;br /&gt;       OpenSolaris - /media&lt;br /&gt;       Ubuntu - /media&lt;br /&gt;       Solaris 10 - /rmdisk&lt;/pre&gt;&lt;br /&gt;5. The flash drive should be mounted and unmounted like a normal disk.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-5684119973815838693?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/5684119973815838693/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=5684119973815838693' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/5684119973815838693'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/5684119973815838693'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/07/using-flash-drive-under-virtualbox.html' title='Using Flash Drive under VirtualBox'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-7775733056302740504</id><published>2009-07-13T20:51:00.002-04:00</published><updated>2009-07-13T22:23:31.533-04:00</updated><title type='text'>Assign host name to DHCP Solaris 10 Client</title><content type='html'>Put the host name in the file /etc/nodename to assign the host name to Solaris 10 with DHCP network configuration. Otherwise, the system has the "unknown hostname" problem.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-7775733056302740504?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/7775733056302740504/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=7775733056302740504' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/7775733056302740504'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/7775733056302740504'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/07/assign-host-name-to-dhcp-solaris-10.html' title='Assign host name to DHCP Solaris 10 Client'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-6294006323115664102</id><published>2009-06-05T15:28:00.011-04:00</published><updated>2009-06-05T15:50:57.741-04:00</updated><title type='text'>Perl DBI interface to MySQL</title><content type='html'>The DBI module can be used to work with databases like Oracle, MySQL, and Informix in Perl. Following is an example to query names and phone numbers in the Info table of Supplier database with MySQL database.&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;#!/usr/bin/perl&lt;br /&gt;&lt;br /&gt;use DBI;&lt;br /&gt;use strict;&lt;br /&gt;&lt;br /&gt;my $driver = "mysql";&lt;br /&gt;my $database = "Supplier";&lt;br /&gt;my $source = "DBI:$driver:database=$database";&lt;br /&gt;my $userid = "XXX";&lt;br /&gt;my $password = "XXX";&lt;br /&gt;my $dbh = DBI-&gt;connect($source, $userid, $password ) &lt;br /&gt;     or die $DBI::errstr;&lt;br /&gt;&lt;br /&gt;my $sth = $dbh-&gt;prepare("SELECT Name, Phone FROM Info");&lt;br /&gt;$sth-&gt;execute() or die $DBI::errstr;&lt;br /&gt;print "Company, Phone:\n";&lt;br /&gt;while (my @row = $sth-&gt;fetchrow_array()) {&lt;br /&gt;   my ($name, $phone ) = @row;&lt;br /&gt;   print "$name, $phone\n";&lt;br /&gt;}&lt;br /&gt;$sth-&gt;finish();&lt;br /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-6294006323115664102?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/6294006323115664102/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=6294006323115664102' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/6294006323115664102'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/6294006323115664102'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/06/perl-dbi-interface-to-mysql.html' title='Perl DBI interface to MySQL'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-3768819682599551933</id><published>2009-06-03T13:40:00.003-04:00</published><updated>2009-06-03T13:57:11.016-04:00</updated><title type='text'>Install Guest Addition for OpenSolaris 2009.06 on VirtualBox 2.2.4</title><content type='html'>1. Click Devices -&gt; Install Guest Additions to bring up VBOXADDITION 2.2.4 47978 to the Desktop.&lt;br /&gt;&lt;br /&gt;2. Start up a terminal then change to the super user. Run "pkgadd -d /media/VBOXADDITION 2.2.4 47978/VBoxSolarisAddition.pkg". Select default and yes to start and continue the installation.&lt;br /&gt;&lt;br /&gt;3. Unmount VBOXADDITION 2.2.4 47978 from the desktop.&lt;br /&gt;&lt;br /&gt;4. Reboot the system.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-3768819682599551933?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/3768819682599551933/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=3768819682599551933' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/3768819682599551933'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/3768819682599551933'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/06/install-guest-addition-for-opensolaris.html' title='Install Guest Addition for OpenSolaris 2009.06 on VirtualBox 2.2.4'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-73743170286129773</id><published>2009-05-08T22:59:00.005-04:00</published><updated>2009-05-08T23:27:04.947-04:00</updated><title type='text'>Shared Folder in VirtualBox for Windows host/Linux Guest</title><content type='html'>Select Devices -&gt; Shared Folders from the virtual machine's menu bar, then click Add New Folder icon, from the Folder Path select the folder at Windows, enter the folder name to use, then click OK. The shared folder should be list at Transient Folders.&lt;br /&gt;&lt;br /&gt;Mount the folder from the command line as root:&lt;br /&gt;&lt;br /&gt;mount -t vboxsf folder_name mount_point&lt;br /&gt;&lt;br /&gt;For example, type in "mount -t vboxsf Music /mnt" to mount Music folder to /mnt.&lt;br /&gt;&lt;br /&gt;All files in the Music folder, at Windows, should be available at /mnt now.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-73743170286129773?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/73743170286129773/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=73743170286129773' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/73743170286129773'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/73743170286129773'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/05/shared-folder-in-virtualbox-for-windows.html' title='Shared Folder in VirtualBox for Windows host/Linux Guest'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-7443585824347556380</id><published>2009-04-30T17:24:00.023-04:00</published><updated>2009-05-11T13:47:42.765-04:00</updated><title type='text'>CVS Enhancement</title><content type='html'>Code Freeze:&lt;br /&gt;&lt;br /&gt;Following can be used to prevent developers check in any file by accident when the source tree is ready for a release.&lt;br /&gt;&lt;br /&gt;First, create a new directory $CVSROOT/CVSROOT/Freeze to keep the files for tree freeze. Each file is for a either a HEAD (at trunk) or branch. Following function check if the current tree is under freeze policy before perform the commit or import commands. This cvs function can be part of profile, so once the user login the system, it is loaded right away.&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;cvs ()&lt;br /&gt;{&lt;br /&gt;    # check for code freeze&lt;br /&gt;    if [ "$1" = commit -o "$1" = import ]; then&lt;br /&gt;        if [ ! -f "CVS/Repository" ]; then&lt;br /&gt;            echo "Cannot find CVS/Repository.Please check&lt;br&gt;you current directory."&lt;br /&gt;            return 1&lt;br /&gt;        fi&lt;br /&gt;        if [ -f CVS/Tag ]; then&lt;br /&gt;            CVSTAG=`cat CVS/Tag | sed -e 's/.//'`&lt;br /&gt;            if [ -f $CVSROOT/CVSROOT/Freeze/$CVSTAG ]; then&lt;br /&gt;                echo "Sorry. Code freeze for the branch&lt;br&gt; $CVSTAG."&lt;br /&gt;                return 2&lt;br /&gt;            fi&lt;br /&gt;        elif [ -f $CVSROOT/CVSROOT/Freeze/HEAD ]; then&lt;br /&gt;            echo "Sorry. Code freeze for the main trunk."&lt;br /&gt;            return 3&lt;br /&gt;        fi&lt;br /&gt;    fi&lt;br /&gt;    command cvs "$@"&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;Time Stamp for Tags or Branches&lt;br /&gt;&lt;br /&gt;The "cvs log" command displays the tag and branch names with the revision of the file without date information.&lt;br /&gt;&lt;br /&gt;To have a clear history for tags, create a tag history file in $CVSROOT/CVSROOT/logs/tags.history. Put following lines in the release script to append the tag to the history with the date information. To create new branch, a similar script can be created.&lt;br /&gt;&lt;pre&gt;&lt;br /&gt; HISTORY=$CVSROOT/CVSROOT/logs/tags.history&lt;br /&gt; cvs tag $1 source database document tools buildlogs&lt;br /&gt; echo "Tagged $1 source, database, document, tools, and \&lt;br&gt; buildlogs at `date`" | tee -a $HISTORY&lt;br /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-7443585824347556380?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/7443585824347556380/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=7443585824347556380' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/7443585824347556380'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/7443585824347556380'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/04/cvs-enhancement.html' title='CVS Enhancement'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-5410893177752283349</id><published>2009-04-23T11:13:00.002-04:00</published><updated>2009-04-23T12:06:12.326-04:00</updated><title type='text'>Powerful Unix find command</title><content type='html'>List the files contain the word Unix in the current tree: &lt;br /&gt;&lt;br /&gt;find . -type f -exec grep -l Unix {} \;&lt;br /&gt;&lt;br /&gt;Set permission to 644 for all files in the current tree:&lt;br /&gt;&lt;br /&gt;find . -type f -exec chmod 644 {} \;&lt;br /&gt;&lt;br /&gt;The number of files in the current tree:&lt;br /&gt;&lt;br /&gt;find . -type f -exec ls -l {} \; | wc -l&lt;br /&gt;&lt;br /&gt;All the text type files in the current tree:&lt;br /&gt;&lt;br /&gt;find . -type f -exec file {} \; |  grep text&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-5410893177752283349?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/5410893177752283349/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=5410893177752283349' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/5410893177752283349'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/5410893177752283349'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/04/powerful-unix-find-command.html' title='Powerful Unix find command'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-8185056478001014288</id><published>2009-04-22T15:38:00.004-04:00</published><updated>2009-04-22T15:57:20.419-04:00</updated><title type='text'>Power Schemes problem in Windows XP</title><content type='html'>If the Power Schemes of Power Options Properties in Windows XP is set to Portable/Laptop, The system will be switched to standby state say after 20 minutes. However, this is a problem for the systems that provide the services to others, one of the example is the build system. The scheduled build tasks won't be able to start to perform the builds. Once a system could not start up scheduled tasks and stay in standby state, make sure the power schemes is not set to Portable/Laptop.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-8185056478001014288?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/8185056478001014288/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=8185056478001014288' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/8185056478001014288'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/8185056478001014288'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/04/power-schemes-problem-in-windows-xp.html' title='Power Schemes problem in Windows XP'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-536388017743086655</id><published>2009-04-16T14:55:00.004-04:00</published><updated>2009-04-16T15:27:53.127-04:00</updated><title type='text'>Extract files from DAA/UIF disc image file with PowerISO</title><content type='html'>After download a CD/DVD image file in DAA or UIF format instead of the popular ISO, it's a headache to find a converter to open such image file, or retrieve some files from the image. I have tried daa2iso, MagicISO, and Active@ISO Burner but found various problems.&lt;br /&gt;&lt;br /&gt;PowerISO can convert CD/DVD image file formats from BIN, NRG, CDI, DAA, and UIF, etc. to ISO format, extract files from the image to the hard disk, and make image file in ISO, BIN, or DAA formats. &lt;br /&gt;&lt;br /&gt;To find out more PowerISO's features, please check http://www.poweriso.com.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-536388017743086655?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/536388017743086655/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=536388017743086655' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/536388017743086655'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/536388017743086655'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/04/extract-files-from-daauif-disc-image.html' title='Extract files from DAA/UIF disc image file with PowerISO'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-8422230784681171023</id><published>2009-03-25T17:15:00.006-04:00</published><updated>2009-03-28T15:51:17.829-04:00</updated><title type='text'>Use Expect script with Database and others</title><content type='html'>Expect is the tool for automated interactive programming, and it is available for Unix/Linux, Mac, and Windows.&lt;br /&gt;&lt;br /&gt;If you are running a command line program and want to insert, modify, or retrieve data in and out with the database, expect is the choice.&lt;br /&gt;&lt;br /&gt;It's simple and easy to learn and use. The basic commands are expect and send. Following is a piece of code to access MySQL database with Expect script. &lt;br /&gt;&lt;br /&gt;set passwrd something&lt;br /&gt;spawn mysql -u uid -p&lt;br /&gt;expect "password:"&lt;br /&gt;send "$passwrd\r"&lt;br /&gt;expect "mysql&gt;"&lt;br /&gt;send "use CustomerDB\r"&lt;br /&gt;expect "mysql&gt;"&lt;br /&gt;send "show tables;\r"&lt;br /&gt;expect "mysql&gt;"&lt;br /&gt;send "select * from Customers where City = 'New York';\r"&lt;br /&gt;expect "mysql&gt;"&lt;br /&gt;send "quit\r"&lt;br /&gt;&lt;br /&gt;However, the expect script also can be used for Oracle but it is not limited to the database application. You can use it in other interactive applications such as ftp, telnet, and software installation, and software testing, etc.&lt;br /&gt;&lt;br /&gt;Please check Don Libes' book Exploring Expect from O'Reilly for more details.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-8422230784681171023?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/8422230784681171023/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=8422230784681171023' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/8422230784681171023'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/8422230784681171023'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/03/use-expect-script-with-database.html' title='Use Expect script with Database and others'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-3332669136545626503</id><published>2009-03-25T16:14:00.006-04:00</published><updated>2009-03-28T06:27:06.431-04:00</updated><title type='text'>Use mkisofs to create data DVD for Unix file system</title><content type='html'>The popular DVD burning software for Windows like Nero and Easy Media Creator are not safe to burn the Unix file system directly on CD or DVD. If you burned a disc in this way, try to md5 files on disc and the original files. You may realize that some of the MD5 hashes are not identical! &lt;br /&gt;&lt;br /&gt;The older version of mkisofs could not create the image file larger than 2GB. However, the current version fix this problem by using a new -UDF option. Following is the syntax to create a data DVD ISO image file for the entire dirname folder: &lt;br /&gt;&lt;br /&gt;mkisofs -o file.iso -UDF -f -a -J -r -v -V "Volume ID" dirname&lt;br /&gt;&lt;br /&gt;It's safe to burn the image file with mkisofs because all files on disc will be identical to the original files.&lt;br /&gt;&lt;br /&gt;For more detailed options, please look at its man page or run "mkisofs -help".&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-3332669136545626503?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/3332669136545626503/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=3332669136545626503' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/3332669136545626503'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/3332669136545626503'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/03/use-mkisofs-to-create-data-dvd-for-unix.html' title='Use mkisofs to create data DVD for Unix file system'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-6775966908507928728</id><published>2009-03-21T10:23:00.002-04:00</published><updated>2009-03-21T10:43:35.777-04:00</updated><title type='text'>Unix sort command</title><content type='html'>The sort command has -u option for unique. Therefore, the command "sort file | uniq" can be simplified as "sort -u file".&lt;br /&gt;&lt;br /&gt;To sort in arithmetic order, use -n option, and -r option is used for reverse order.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-6775966908507928728?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/6775966908507928728/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=6775966908507928728' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/6775966908507928728'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/6775966908507928728'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/03/unix-sort-command.html' title='Unix sort command'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-8862556477657336134</id><published>2009-03-21T10:02:00.006-04:00</published><updated>2009-03-21T15:47:47.906-04:00</updated><title type='text'>Don't forget to redirect standard error for debugging</title><content type='html'>Some programs print the error messages to the standard error instead of standard output. The trick is on a computer system, they both show up on the screen. &lt;br /&gt;&lt;br /&gt;If you redirect the program's output to a file then examine the file later for troubleshooting, you may not find any error in the file. Most likely you run following from the command line.&lt;br /&gt;&lt;br /&gt;cmd &gt; file &lt;br /&gt;&lt;br /&gt;The above command line only redirect the standard output to the file. To redirect both standard output and standard error to the file, run the following from the command line.&lt;br /&gt;&lt;br /&gt;cmd &gt; file 2&gt;&amp;1&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-8862556477657336134?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/8862556477657336134/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=8862556477657336134' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/8862556477657336134'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/8862556477657336134'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/03/dont-forget-to-redirect-standard-error.html' title='Don&apos;t forget to redirect standard error for debugging'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-6893664405007725695</id><published>2009-03-20T15:16:00.002-04:00</published><updated>2009-03-20T15:38:00.405-04:00</updated><title type='text'>IE blocks the ActiveX component installation</title><content type='html'>Some times IE blocks the ActiveX component installation for the security reason. If the component is trusted, you may need to temporary change the security settings of IE, then change the settings back after the component get installed. See the following for details.&lt;br /&gt;&lt;br /&gt;From the IE, select Tools-&gt;Internet Options-&gt;Security. At the Security level for this zone, select Custom level. Look for ActiveX controls and plug-ins section, enable Download unsigned ActiveX controls, and look for Miscellaneous section, enable Installation of desktop items.&lt;br /&gt;&lt;br /&gt;After the component gets installed. reverse above settings.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-6893664405007725695?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/6893664405007725695/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=6893664405007725695' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/6893664405007725695'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/6893664405007725695'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/03/ie-blocks-activex-component.html' title='IE blocks the ActiveX component installation'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-5266222941365304182</id><published>2009-03-16T11:16:00.003-04:00</published><updated>2009-03-16T11:27:55.369-04:00</updated><title type='text'>Install VMware View Open Client on CentOS 5.2</title><content type='html'>To install the VMware View Open Client, download the current version of rpm file from http://code.google.com/p/vmware-view-open-client/downloads/list, then install it on the system.&lt;br /&gt;&lt;br /&gt;1. download VMware-view-open-client-2.1.1-153227.i386.rpm from the above location.&lt;br /&gt;&lt;br /&gt;2. Install rdesktop if the package hasn't been installed.&lt;br /&gt;&lt;br /&gt;yum install rdesktop&lt;br /&gt;&lt;br /&gt;3. Install VMware View Open Client.&lt;br /&gt;&lt;br /&gt;rpm -Uvh VMware-view-open-client-2.1.1-153227.i386.rpm &lt;br /&gt;&lt;br /&gt;The VMware View Open Client will be in the Internet group.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-5266222941365304182?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/5266222941365304182/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=5266222941365304182' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/5266222941365304182'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/5266222941365304182'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/03/install-vmware-view-open-client-on.html' title='Install VMware View Open Client on CentOS 5.2'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-7525752868602783016</id><published>2009-03-16T11:13:00.001-04:00</published><updated>2009-03-16T11:15:31.418-04:00</updated><title type='text'>Install wireshark on CentOS 5.2</title><content type='html'>To install wireshark run the following as root:&lt;br /&gt;&lt;br /&gt;    yum install wireshark&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-7525752868602783016?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/7525752868602783016/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=7525752868602783016' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/7525752868602783016'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/7525752868602783016'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/03/install-wireshark-on-centos-52.html' title='Install wireshark on CentOS 5.2'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-114613596025378646</id><published>2009-03-12T18:05:00.003-04:00</published><updated>2009-03-16T11:16:24.915-04:00</updated><title type='text'>Install Ruby on CentOS 5.2</title><content type='html'>To install Ruby and related run the following as root:&lt;br /&gt;&lt;br /&gt;yum install -y ruby&lt;br /&gt;yum install -y ruby-devel ruby-docs ruby-ri ruby-irb ruby-rdo&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-114613596025378646?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/114613596025378646/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=114613596025378646' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/114613596025378646'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/114613596025378646'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/03/install-ruby-on-centos-52.html' title='Install Ruby on CentOS 5.2'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-8175387214002278637</id><published>2009-03-06T11:52:00.005-05:00</published><updated>2009-03-06T13:17:46.221-05:00</updated><title type='text'>PHP and Form</title><content type='html'>PHP handles variable and upload file in HTML form differently.&lt;br /&gt; &lt;br /&gt;1. For Variable:&lt;br /&gt;&lt;br /&gt;Following is an example form in a HTML page that uses variable.php to process the form.&lt;br /&gt;&lt;br /&gt;&amp;lt;FORM method="POST" action="variable.php"&amp;gt;&lt;br /&gt;&amp;lt;INPUT type="text" name="variable"&amp;gt;&lt;br /&gt;&amp;lt;INPUT type="submit" name="submit" value="Submit Name"&amp;gt;&lt;br /&gt;&amp;lt;/FORM&amp;gt;&lt;br /&gt;&lt;br /&gt;In the PHP script, variable.php, $_POST['variable'] will keep the value of the variable that user entered in the above form. &lt;br /&gt;&lt;br /&gt;2. For File:&lt;br /&gt;&lt;br /&gt;Following is an example form to upload a file from the HTML page.&lt;br /&gt;&lt;br /&gt;&amp;lt;FORM enctype="multipart/form-data" method="POST" action="file.php"&amp;gt;&lt;br /&gt;&amp;lt;INPUT type="file" name="file" size="30"&amp;gt;&lt;br /&gt;&amp;lt;INPUT type="submit" name="submit" value="Upload File"&amp;gt;&lt;br /&gt;&amp;lt;/FORM&amp;gt;&lt;br /&gt;&lt;br /&gt;In the file.php script $_FILES will keep all information about the file, and details are shown below.&lt;br /&gt;&lt;br /&gt;$_FILES['file']['name'] - The file name. &lt;br /&gt;$_FILES['file']['tmp_name'] - The file name with the full path.&lt;br /&gt;$_FILES['file']['size'] - The file size in Byte.&lt;br /&gt;$_FILES['file']['type'] - The Mime type of the file.&lt;br /&gt;&lt;br /&gt;Using above information, the PHP script can save the file to the file system or insert the file name with full path or content of the file into the MySQL database.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-8175387214002278637?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/8175387214002278637/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=8175387214002278637' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/8175387214002278637'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/8175387214002278637'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/03/php-and-form.html' title='PHP and Form'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-5057823333433276794</id><published>2009-02-03T21:58:00.005-05:00</published><updated>2009-02-03T22:28:50.829-05:00</updated><title type='text'>Install and test Maven on CentOS 5.2</title><content type='html'>1. Make sure Java has been installed on the system by running:&lt;br /&gt;     java --version&lt;br /&gt;&lt;br /&gt;2. Down load the current maven, apache-maven-2.0.9-bin.tar.gz, from http://maven.apache.org/download.html.&lt;br /&gt;&lt;br /&gt;3. untar the file to /usr/local/apache-maven-2.0.9, then create symbolic link:&lt;br /&gt;     ln -s apache-maven-2.0.9 maven&lt;br /&gt;&lt;br /&gt;4. Append following to the end of ~/.bashrc:&lt;br /&gt;     export M2_HOME=/usr/local/maven&lt;br /&gt;     export PATH=${M2_HOME}/bin:${PATH}&lt;br /&gt;&lt;br /&gt;5. Bring in the environment changes:&lt;br /&gt;     . ~/.bashrc&lt;br /&gt;&lt;br /&gt;6. Check the installation:&lt;br /&gt;     mvn --version&lt;br /&gt;&lt;br /&gt;7. At a local you pick to create a project that will create my-app directory:&lt;br /&gt;     mvn archetype:create -DgroupId=com.mycompany.app -DartifactId=my-app&lt;br /&gt;&lt;br /&gt;8. Build and test the project:&lt;br /&gt;     cd my-app&lt;br /&gt;     mvn package&lt;br /&gt;     java -cp target/my-app-1.0-SNAPSHOT.jar com.mycompany.app.App&lt;br /&gt;&lt;br /&gt;  If the famous "Hello World!" comes up, the package is built correctly.&lt;br /&gt;&lt;br /&gt;9. House keeping:&lt;br /&gt;     mvn clean dependency:copy-dependencies package&lt;br /&gt;&lt;br /&gt;10. Create target:&lt;br /&gt;     mvn site&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-5057823333433276794?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/5057823333433276794/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=5057823333433276794' title='7 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/5057823333433276794'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/5057823333433276794'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/02/install-and-test-maven-on-centos-52.html' title='Install and test Maven on CentOS 5.2'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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>7</thr:total></entry><entry><id>tag:blogger.com,1999:blog-3073346646886801977.post-7194392008200015099</id><published>2009-02-03T20:47:00.002-05:00</published><updated>2009-02-03T20:56:05.058-05:00</updated><title type='text'>Fix the relogin problem for phpMyadmin CentOS 5.2</title><content type='html'>If no activity for 30 minutes, phpMyadmin will log you out for security reason. &lt;br /&gt;&lt;br /&gt;To change this, modify a line in /usr/share/phpmyadmin/config.inc.php from cookie to http from "$cfg['Servers'][$i]['auth_type'] = 'cookie';" to "$cfg['Servers'][$i]['auth_type'] = 'http';"&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-7194392008200015099?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/7194392008200015099/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=7194392008200015099' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/7194392008200015099'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/7194392008200015099'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/02/fix-relogin-problem-for-phpmyadmin.html' title='Fix the relogin problem for phpMyadmin CentOS 5.2'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-2250288079596248137</id><published>2009-02-02T20:29:00.002-05:00</published><updated>2009-02-02T20:32:59.456-05:00</updated><title type='text'>Inatall Eclipse on CentOS 5.2</title><content type='html'>To install Eclipse on CentOS, run the following command as root:&lt;br /&gt;&lt;br /&gt;yum install eclipse-*&lt;br /&gt;&lt;br /&gt;After the installation, Eclipse has been created in the Application-&gt;Programming.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-2250288079596248137?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/2250288079596248137/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=2250288079596248137' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/2250288079596248137'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/2250288079596248137'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/02/inatall-eclipse-on-centos-52.html' title='Inatall Eclipse on CentOS 5.2'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-3073346646886801977.post-468664191427642553</id><published>2009-02-02T17:00:00.004-05:00</published><updated>2009-02-02T17:08:59.782-05:00</updated><title type='text'>Rename database and table for mySQL</title><content type='html'>1. Find out the database location on the system. It is at /var/lib/mysql on my CentOS 5.2. Change to that directory:&lt;br /&gt;  cd /var/lib/mysql&lt;br /&gt;&lt;br /&gt;2. Stop mySQL server:&lt;br /&gt;  /etc/init.d/mysql stop&lt;br /&gt;&lt;br /&gt;3. Rename the name of the database.&lt;br /&gt;  mv mydb.old mydb.new&lt;br /&gt;&lt;br /&gt;4. Rename the table files in the new database directory:&lt;br /&gt;  cd mydb.new&lt;br /&gt;  mv oldtable.frm newtable.frm&lt;br /&gt;  mv oldtable.MYD newtable.MYD&lt;br /&gt;  mv oldtable.MYI newtable.MYI&lt;br /&gt;&lt;br /&gt;5. Start mySQL server:&lt;br /&gt;  /etc/init.d/mysql start&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-468664191427642553?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/468664191427642553/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=468664191427642553' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/468664191427642553'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/468664191427642553'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/02/rename-database-and-table-for-mysql.html' title='Rename database and table for mySQL'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-5699896787480668058</id><published>2009-01-28T22:22:00.008-05:00</published><updated>2009-03-21T18:49:13.674-04:00</updated><title type='text'>Tomcat 6 on CentOS 5.2</title><content type='html'>1. Download jdk-6u11-linux-i586-rpm.bin from http://java.sun.com/javase/downloads/index.jsp.&lt;br /&gt;&lt;br /&gt;2. cd Desktop; . jdk-6u11-linux-i586-rpm.bin&lt;br /&gt;&lt;br /&gt;3. As root, insert following lines in /etc/profile&lt;br /&gt;      export JAVA_HOME=/usr/java/default&lt;br /&gt;      export PATH=$PATH:$JAVA_HOME/bin&lt;br /&gt;      export CLASSPATH=.:$JAVA_HOME/jre/lib:$JAVA_HOME/lib:$JAVA_HOME/lib/tools.jar&lt;br /&gt;&lt;br /&gt;4. . /etc/profile&lt;br /&gt;&lt;br /&gt;5. mkdir /tmp; cd /tmp&lt;br /&gt;&lt;br /&gt;6. wget http://ftp.sh.cvut.cz/MIRRORS/apache/tomcat/tomcat-6/v6.0.18/bin/apache-tomcat-6.0.18.tar.gz&lt;br /&gt;&lt;br /&gt;7. tar xvzf apache-tomcat-6.0.18.tar.gz&lt;br /&gt;&lt;br /&gt;8. mv -f apache-tomcat-6.0.18 /usr/share/tomcat6&lt;br /&gt;&lt;br /&gt;9. chown -R tomcat /usr/share/tomcat6&lt;br /&gt;&lt;br /&gt;10. ln -s /usr/share/tomcat6 /usr/share/tomcat&lt;br /&gt;&lt;br /&gt;11. useradd -d /usr/share/tomcat -s /sbin/nologin tomcat&lt;br /&gt;&lt;br /&gt;12. Create /etc/init.d/tomcat as shown below:&lt;br /&gt;&lt;br /&gt;# Tomcat auto-start&lt;br /&gt;#&lt;br /&gt;# description: Auto-starts tomcat&lt;br /&gt;# processname: tomcat&lt;br /&gt;# pidfile: /var/run/tomcat.pid&lt;br /&gt;&lt;br /&gt;export JAVA_HOME=/usr/java/default&lt;br /&gt;&lt;br /&gt;case $1 in&lt;br /&gt;start)&lt;br /&gt;    sh /usr/share/tomcat6/bin/startup.sh&lt;br /&gt;    ;;&lt;br /&gt;stop)&lt;br /&gt;    sh /usr/share/tomcat6/bin/shutdown.sh&lt;br /&gt;    ;;&lt;br /&gt;restart)&lt;br /&gt;    sh /usr/share/tomcat6/bin/shutdown.sh&lt;br /&gt;    sh /usr/share/tomcat6/bin/startup.sh&lt;br /&gt;     ;;&lt;br /&gt;esac&lt;br /&gt;exit 0&lt;br /&gt;&lt;br /&gt;13. chmod +x /etc/init.d/tomcat&lt;br /&gt;&lt;br /&gt;14. chkconfig tomcat6 on&lt;br /&gt;&lt;br /&gt;15. Add following into /usr/share/tomcat/conf/tomcat-users.xml:&lt;br /&gt;&amp;lt;user username="tomcat" password="tomcat" roles="manager,admin"&amp;gt;&lt;br /&gt;&lt;br /&gt;16. Add $CATALINA_HOME to /etc/profile.&lt;br /&gt;export CATALINA_HOME=/usr/share/tomcat&lt;br /&gt;&lt;br /&gt;17. /etc/init.d/tomcat start&lt;br /&gt;&lt;br /&gt;18. If the Apache Tomcat page can be found at http://localhost:8080, the installation is correct.&lt;br /&gt;&lt;br /&gt;19. Done.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-5699896787480668058?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/5699896787480668058/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=5699896787480668058' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/5699896787480668058'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/5699896787480668058'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/01/tomcat-6-on-centos-52.html' title='Tomcat 6 on CentOS 5.2'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-3073346646886801977.post-7552340938933220541</id><published>2009-01-27T14:52:00.002-05:00</published><updated>2009-01-27T15:10:32.615-05:00</updated><title type='text'>Install Guest Addition for CentOS 5.2 on VirtualBox</title><content type='html'>1. Click Devices -&gt; Install Guest Additions to bring up VBOXADDITIONS_x.x.x_xxxxx to the Desktop.&lt;br /&gt;&lt;br /&gt;2. Startup a terminal, change to super user, then cd to /media/VBOXADDITIONS_x.x.x_xxxxx.&lt;br /&gt;&lt;br /&gt;3. Run "yum install kernel-devel gcc" to install the kernel header files and compiler for building the new modules.&lt;br /&gt;&lt;br /&gt;4. Run "VBoxLinuxAdditions.run" to build and install Guest Addition.&lt;br /&gt;&lt;br /&gt;5. Eject VBOXADDITIONS_x.x.x_xxxxx from the desktop.&lt;br /&gt;&lt;br /&gt;6. For custom screen resolutions, Insert modes in the Screen section in /etc/X11/xorg.conf as show below:&lt;br /&gt;&lt;br /&gt;SubSection "Display"&lt;br /&gt;                Viewport   0 0&lt;br /&gt;                Depth     24&lt;br /&gt;                modes "1280x1024" "1272x920" "1024x768"&lt;br /&gt;EndSubSection&lt;br /&gt;&lt;br /&gt;6. Reboot the system. From System -&gt; Preferences -&gt; Screen Resolution, select the resolution just added.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-7552340938933220541?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/7552340938933220541/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=7552340938933220541' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/7552340938933220541'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/7552340938933220541'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/01/install-guest-addition-for-centos-52-on.html' title='Install Guest Addition for CentOS 5.2 on VirtualBox'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-1047480501600614105</id><published>2009-01-27T13:53:00.010-05:00</published><updated>2009-03-21T18:42:51.042-04:00</updated><title type='text'>Install LAMP on CentOS 5.2</title><content type='html'>1. Install CentOS 5.2 on the system.&lt;br /&gt;&lt;br /&gt;2. Download http://packages.sw.be/packages/rpmforce-release/rpmforge-release-0.3.6-1.el5.rf.i386.rpm. From a terminal window run "rpm -ivh rpmforge-release-0.3.6-1.el5.rf.i386.rpm".&lt;br /&gt;&lt;br /&gt;3. From terminal terminal window, run "yum install httpd php php-mysql php-gd php-mbstring php-mcrypt mysql mysql-server phpmyadmin" as root.&lt;br /&gt;&lt;br /&gt;4.To setup Apache server, System-&gt; Administration -&gt; Server Settings -&gt; HTTP, Fill in the server name for the Apache server cwsuch as "localhost" for testing.&lt;br /&gt;&lt;br /&gt;5. To setup mysql server System-&gt; Administration -&gt; Server Settings -&gt; Services. Select mysqld, then reboot.&lt;br /&gt;&lt;br /&gt;6. To make sure Apache server is up and running, start up Firefox, entre "http://localhost" as URL, the Apache 2 Test Page should be displayed.&lt;br /&gt;&lt;br /&gt;7. Modify the line "$cfg['blowfish_secret'] = ''; /* YOU MUST FILL IN THIS FOR COOKIE AUTH! */" in&lt;br /&gt;/usr/share/phpmyadmin/config.inc.php to "$cfg['blowfish_secret'] = 'secret'; /* YOU MUST FILL IN THIS FOR COOKIE AUTH! */".&lt;br /&gt;&lt;br /&gt;8. Create a new file phpinfo.php at /var/www/html with following:&lt;br /&gt;   &amp;lt;?php phpinfo(); ?&amp;gt;.&lt;br /&gt;&lt;br /&gt;9. From the Firefox, check http://localhost/phpinfo.php. The PHP information page should be displayed if the installation is correct.&lt;br /&gt;&lt;br /&gt;10. TO assign the password for root, from the terminal window, run "mysqladmin -u root password "new password".&lt;br /&gt;&lt;br /&gt;11. To check phpmyadmin installation, from Firefox, check http://localhost/phpmyadmin. From Welcome to phpMyAdmin page, type in the password for root&lt;br /&gt;login to make sure the phpMyAdmin is installed without problem.&lt;br /&gt;&lt;br /&gt;12. Done. LAMP server is up and running.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-1047480501600614105?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/1047480501600614105/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=1047480501600614105' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/1047480501600614105'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/1047480501600614105'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/01/install-lamp-on-centos-5.html' title='Install LAMP on CentOS 5.2'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-3551442069406928968</id><published>2009-01-16T17:39:00.007-05:00</published><updated>2009-03-21T18:40:26.349-04:00</updated><title type='text'>Search files with file size or day in UNIX</title><content type='html'>To find files equal to 10KB in src directory,&lt;br /&gt;&lt;br /&gt;find src -size 10k&lt;br /&gt;&lt;br /&gt;To find files larger that 10KB in src directory,&lt;br /&gt;&lt;br /&gt;find src -size +10k&lt;br /&gt;&lt;br /&gt;To find file less than 10KB in src directory,&lt;br /&gt;&lt;br /&gt;find src -size -10k&lt;br /&gt;&lt;br /&gt;To find file was modified for 2 days in src directory,&lt;br /&gt;&lt;br /&gt;find src -mtime 2&lt;br /&gt;&lt;br /&gt;To find file was modified for less than 2 days in src directory,&lt;br /&gt;&lt;br /&gt;find src -mtime -2&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-3551442069406928968?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/3551442069406928968/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=3551442069406928968' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/3551442069406928968'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/3551442069406928968'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2009/01/find-files-with-in-unix.html' title='Search files with file size or day in UNIX'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-5554322589883764463</id><published>2008-12-16T23:09:00.021-05:00</published><updated>2009-02-05T11:04:44.939-05:00</updated><title type='text'>Install tomcat on Ubuntu 8.10</title><content type='html'>1. Check if java get installed:&lt;br /&gt;dpkg --get-selections | grep sun-java&lt;br /&gt;&lt;br /&gt;2. Install Java:&lt;br /&gt;sudo apt-get install sun-java6-jdk&lt;br /&gt;&lt;br /&gt;3. Get tomcat from apache site:&lt;br /&gt;wget http://apache.hoxt.com/tomcat/tomcat-6/v6.0.18/bin/apache-tomcat-6.0.&lt;br /&gt;18.tar.gz&lt;br /&gt;tar xvzf apache-tomcat-6.0.18.tar.gz&lt;br /&gt;&lt;br /&gt;4. Move tomcat to the location:&lt;br /&gt;sudo mv apache-tomcat-6.0.18 /usr/local/tomcat&lt;br /&gt;&lt;br /&gt;5. Add following line into .bashrc file:&lt;br /&gt;export JAVA_HOME=/usr/lib/jvm/java-6-sun&lt;br /&gt;&lt;br /&gt;6. Create /etc/init.d/tomcat&lt;br /&gt;# Tomcat auto-start&lt;br /&gt;#&lt;br /&gt;# description: Auto-starts tomcat&lt;br /&gt;# processname: tomcat&lt;br /&gt;# pidfile: /var/run/tomcat.pid&lt;br /&gt;&lt;br /&gt;export JAVA_HOME=/usr/lib/jvm/java-6-sun&lt;br /&gt;&lt;br /&gt;case $1 in&lt;br /&gt;start)&lt;br /&gt;sh /usr/local/tomcat/bin/startup.sh&lt;br /&gt;;;&lt;br /&gt;stop)&lt;br /&gt;sh /usr/local/tomcat/bin/shutdown.sh&lt;br /&gt;;;&lt;br /&gt;restart)&lt;br /&gt;sh /usr/local/tomcat/bin/shutdown.sh&lt;br /&gt;sh /usr/local/tomcat/bin/startup.sh&lt;br /&gt;;;&lt;br /&gt;esac&lt;br /&gt;exit 0&lt;br /&gt;&lt;br /&gt;7. Change mode to executable.&lt;br /&gt;sudo chmod 755 /etc/init.d/tomcat&lt;br /&gt;&lt;br /&gt;8. Create links&lt;br /&gt;sudo ln -s /etc/init.d/tomcat /etc/rc1.d/K99tomcat&lt;br /&gt;sudo ln -s /etc/init.d/tomcat /etc/rc2.d/S99tomcat&lt;br /&gt;&lt;br /&gt;9. Start up tomcat:&lt;br /&gt;/etc/init.d/tomcat start&lt;br /&gt;&lt;br /&gt;10. Check the tomcat at http://127.0.0.1:8080 with FireFox, it compains the connection rest. The port 8080 has been used by Oracle, so tomcat has to use a different port.  Modify "Connector port="8080" to "Connector port="8090" in /usr/local/tomcat/config/server.xml, then restart tomcat. Re-check tomcat at http://127.0.0.1:8090 again, it works.&lt;br /&gt;&lt;br /&gt;11. To be able to check Status and Tocat Manager, the manager ID and password have to be setup. Add following lines in /usr/local/tomcat/config/tomcat-users.xml:&lt;br /&gt;&amp;lt;user username="ABC" password="PASSWORD" roles="tomcat,manager,admin"&amp;gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-5554322589883764463?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/5554322589883764463/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=5554322589883764463' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/5554322589883764463'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/5554322589883764463'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2008/12/install-tomcat-on-ubuntu.html' title='Install tomcat on Ubuntu 8.10'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-1341944708569701156</id><published>2008-12-10T18:18:00.002-05:00</published><updated>2008-12-10T18:38:11.674-05:00</updated><title type='text'>Install PHP5/MySQL on Ubuntu 8.10</title><content type='html'>&lt;pre&gt;        sudo apt-get install mysql_server apache2 php5 \&lt;br /&gt;php5_mysql phpmyadmin&lt;br /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-1341944708569701156?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/1341944708569701156/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=1341944708569701156' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/1341944708569701156'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/1341944708569701156'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2008/12/install-php5mysql-on-ubuntu-810.html' title='Install PHP5/MySQL on Ubuntu 8.10'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-3409110396170854919</id><published>2008-12-10T18:13:00.005-05:00</published><updated>2008-12-10T18:32:24.734-05:00</updated><title type='text'>Install Oracle 10G EX on Ubuntu 8.10</title><content type='html'>&lt;pre&gt;1. Add oracle site to the resources.list file&lt;br /&gt;&lt;br /&gt;udo vi /etc/apt/sources.list&lt;br /&gt;Appen "deb http://oss.oracle.com/debian unstable \&lt;br /&gt;main non-free"&lt;br /&gt;&lt;br /&gt;2.  Get key from Oracle.&lt;br /&gt;&lt;br /&gt;wget http://oss.oracle.com/el4/RPM-GPG-KEY-oracle \&lt;br /&gt;-O- | sudo apt-key add -&lt;br /&gt;&lt;br /&gt;3. Update Oracle&lt;br /&gt;&lt;br /&gt;sudo apt-get update&lt;br /&gt;&lt;br /&gt;4. Install Oracle&lt;br /&gt;&lt;br /&gt;Increase the swap space to 1G.&lt;br /&gt;sudo dd if=/dev/zero of=/swapfile bs=1024 count=700000&lt;br /&gt;sudo mkswap /swapfile&lt;br /&gt;sudo swapon /swapfile&lt;br /&gt;Add following line into /etc/fstab:&lt;br /&gt;/swapfile none  swap sw  0 0&lt;br /&gt;&lt;br /&gt;sudo apt-get install oracle-xe&lt;br /&gt;&lt;br /&gt;5. Configure Oracle.&lt;br /&gt;&lt;br /&gt;sudo /etc/init.d/oracle-xe configure&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-3409110396170854919?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/3409110396170854919/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=3409110396170854919' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/3409110396170854919'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/3409110396170854919'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2008/12/install-oracle-10g-ex-on-ubuntu-810.html' title='Install Oracle 10G EX on Ubuntu 8.10'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-564393093608599592</id><published>2008-12-10T18:11:00.004-05:00</published><updated>2008-12-10T18:39:26.794-05:00</updated><title type='text'>Install MySQL on Ubuntu 8.10</title><content type='html'>&lt;pre&gt;1. Get MySQL server and client:&lt;br /&gt;&lt;br /&gt;sudo apt-get install mysql-server mysql-client \&lt;br /&gt;mysql-query-browser&lt;br /&gt;&lt;br /&gt;2. Comment out bind-address 127.0.0.1 in my.cnf.&lt;br /&gt;gksudo gedit /etc/mysql/my.cnf&lt;br /&gt;&lt;br /&gt;3. set password for root:&lt;br /&gt;mysqladmin -u root -p status&lt;br /&gt;then enter the passwd. It still doesn't work.&lt;br /&gt;&lt;br /&gt;4. Work around for mysql commands:&lt;br /&gt;mysqladmin|mysqlshow|mysql -u root -p&lt;br /&gt;&lt;br /&gt;Then enter the root password.&lt;br /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-564393093608599592?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/564393093608599592/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=564393093608599592' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/564393093608599592'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/564393093608599592'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2008/12/install-mysql-on-ubuntu-810.html' title='Install MySQL on Ubuntu 8.10'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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-3073346646886801977.post-6262176373022283833</id><published>2008-12-10T18:06:00.001-05:00</published><updated>2008-12-10T18:20:03.462-05:00</updated><title type='text'>Install Apache2 on Ubuntu 8.10</title><content type='html'>&lt;pre&gt;1. Get package and install Apache2&lt;br /&gt;	sudo apt-get install apache2 php5&lt;br /&gt;2. Make public_html at $HOME&lt;br /&gt;	mkdir public_html&lt;br /&gt;3. cd /etc/apache2/mods-enabled/&lt;br /&gt;4. sudo ln -s ../mods-available/userdir.conf userdir.conf&lt;br /&gt;5. sudo ln -s ../mods-available/userdir.load userdir.load&lt;br /&gt;6. sudo /etc/init.d/apache2 restart&lt;br /&gt;&lt;br /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3073346646886801977-6262176373022283833?l=pwong-tipsandtricks.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pwong-tipsandtricks.blogspot.com/feeds/6262176373022283833/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=3073346646886801977&amp;postID=6262176373022283833' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/6262176373022283833'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/3073346646886801977/posts/default/6262176373022283833'/><link rel='alternate' type='text/html' href='http://pwong-tipsandtricks.blogspot.com/2008/12/install-apache2-on-ubuntu-810.html' title='Install Apache2 on Ubuntu 8.10'/><author><name>Patrick Wong</name><uri>http://www.blogger.com/profile/00539734435134026704</uri><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>
