Wednesday, April 24, 2013
Ubuntu Relaying Postfix SMTP (gmail)
The purpose is to sent mail through my Linux laptop with mailutils...
1. # apt-get install postfix
2. Edit /etc/postfix/main.cf by edit any exist entry as below values:
relayhost = [smtp.gmail.com]:587
smtp_sasl_auth_enable = yes
smtp_sasl_password_maps = hash:/etc/postfix/sasl_passwd
smtp_sasl_security_options = noanonymous
smtp_tls_CAfile = /etc/postfix/cacert.pem
smtp_use_tls = yes
3. Saved your gmail authentication info to /etc/postfix/sasl_passwd as below:
[smtp.gmail.com]:587 user.name@gmail.com:password
4. Change permissions
#sudo chmod 400 /etc/postfix/sasl_passwd
#sudo postmap /etc/postfix/sasl_passwd
5. Tell it where it can validate the certificate.
# cat /etc/ssl/certs/Thawte_Premium_Server_CA.pem | sudo tee -a /etc/postfix/cacert.pem
6. Restart & Test
#sudo service postfix restart
# echo 'test' | mail user.name@gmail.com
end.
[ref :https://help.ubuntu.com/community/Postfix]
Thursday, April 18, 2013
SVN merge between trunk & branch
Branched out 'branch_xxx' for feature AA, after branch out 'trunk' is continue changes, now need all changes on 'trunk' merge to 'branch_xxx'.
1. Find out the version since branch_xxx copy.
svn log -v --stop-on-copy
<comment>
------------------------------------------------------------------------
r503 | <user> | 2013-03-06 10:56:01 +0800 (Wed, 06 Mar 2013) | 1 line
2. svn merge -r 503:519 svn+ssh://user@svnurl/var/local/svn/proj/trunk
ver 519 is trunk latest ver, you might have some conflicts need to resolve.
3. svn ci -m "comment"
Friday, April 5, 2013
Enable flash player for Chromium on Ubuntu
1 sudo apt-get install flashplugin-nonfree
2 sudo cp /usr/lib/flashplugin-installer/libflashplayer.so /usr/lib/chromium-browser/plugins
3 chromium-browser --enable-plugins
Tuesday, April 2, 2013
SSH to ESXi host with public key
cat ~/.ssh/id_rsa.pub | ssh root@esxi.local 'cat >> /etc/ssh/keys-root/authorized_keys'
Thursday, March 7, 2013
Wednesday, March 6, 2013
Wash machine need maintenance ? YES!
Wash machine need maintenance ? YES!
I buy the wash machine 3 years ago, last month I buy some chlorine bleach to clean it. The result is bad, I can't use the wash machine anymore because there is a lot small piece of dust leak out and attache on my cloths.
So I decided to disassemble the wash machine to clean up the dust inside, below is some pictures.
Saturday, January 12, 2013
Network speed test with iPerf
If you have more than 1 wifi adapter, sometime you may curious which is perform better. Below is 1 of most common way to test your adapters.
What you need for test setup :
- 1 or more wifi adapter.
- 1 Linux/Unix machine.
1. Start terminal and run "sudo apt-get install iperf" on both machine.
2. Login to machine A, run "iperf -s -p 50000"
option "-s" : server mode.
option "-p" : listen to port 50000
3. On machine B, run "iperf -c [machine B IP] -p 50000
option "-c" : client mode.
4. Results
# iperf -s -p 50000
------------------------------------------------------------
Server listening on TCP port 50000
TCP window size: 85.3 KByte (default)
------------------------------------------------------------
[ 4] local 192.168.10.198 port 50000 connected with 192.168.10.134 port 42691
[ ID] Interval Transfer Bandwidth
[ 4] 0.0-10.1 sec 48.5 MBytes 40.1 Mbits/sec
[ 5] local 192.168.10.198 port 50000 connected with 192.168.10.134 port 42710
[ 5] 0.0-10.1 sec 48.4 MBytes 40.1 Mbits/sec
What you need for test setup :
- 1 or more wifi adapter.
- 1 Linux/Unix machine.
1. Start terminal and run "sudo apt-get install iperf" on both machine.
2. Login to machine A, run "iperf -s -p 50000"
option "-s" : server mode.
option "-p" : listen to port 50000
3. On machine B, run "iperf -c [machine B IP] -p 50000
option "-c" : client mode.
4. Results
# iperf -s -p 50000
------------------------------------------------------------
Server listening on TCP port 50000
TCP window size: 85.3 KByte (default)
------------------------------------------------------------
[ 4] local 192.168.10.198 port 50000 connected with 192.168.10.134 port 42691
[ ID] Interval Transfer Bandwidth
[ 4] 0.0-10.1 sec 48.5 MBytes 40.1 Mbits/sec
[ 5] local 192.168.10.198 port 50000 connected with 192.168.10.134 port 42710
[ 5] 0.0-10.1 sec 48.4 MBytes 40.1 Mbits/sec
From the both performance is similar, suspect bottleneck is on machine A, I re-test with another machine with LAN, below is the result.
------------------------------------------------------------
Client connecting to 192.168.10.10, TCP port 50000
TCP window size: 22.9 KByte (default)
------------------------------------------------------------
[ 3] local 192.168.10.100 port 37808 connected with 192.168.10.10 port 50000
[ ID] Interval Transfer Bandwidth
[ 3] 0.0-10.0 sec 74.5 MBytes 62.3 Mbits/sec
------------------------------------------------------------
Client connecting to 192.168.10.10, TCP port 50000
TCP window size: 22.9 KByte (default)
------------------------------------------------------------
[ 3] local 192.168.10.134 port 37344 connected with 192.168.10.10 port 50000
[ ID] Interval Transfer Bandwidth
[ 3] 0.0-10.0 sec 43.6 MBytes 36.5 Mbits/sec
Subscribe to:
Posts (Atom)




