MonthMarch 2010

LG Lollipop (GD580) GMAIL IMAP setup

I bought my LG lollipop recently and have been quite excited with the J-phone alike or feel. Bigger screen, Flip, Great animation in Menu and dashboard. With the impression that Jphone can access Email easily, so i decided to enable to email in my phone as well. By referring to Gmail setup here . However, the explanation sucks! It takes me few attempt before i can successfully access to GMAIL.

Incoming Mail (IMAP) Server – requires SSL:
Use SSL: Yes
Port: 993
Outgoing Mail (SMTP) Server – requires TLS: (use authentication)
Use Authentication: Yes
Use STARTTLS: Yes (some clients call this SSL)
Port: 465 or 587
Account Name: your full email address (including Google Apps users, please enter
Email Address: your full Gmail email address ( Google Apps users, please enter
Password: your Gmail password

My Setting in Gmail

Title: Gmail

My Name: Tingwei

user name:

password: ****

Email address:

Reply email address:

Outgoing mail server:

Incoming mail server:

SMTP port number : 465


Incoming server port : 993

Incoming TSL/SSL: SSL

SMTP authentication: On

SMTP username:

SMTP password: ****

*The rest leave it as default

** If you happen to cancel the synchronization , the rest of the connection will fail for sure. Reboot your Lollipop!

*** Instead of using gmail , apply googlemail . It works like charm, thanks for a comment that i found on a blog!  —> IMPORTANT

Enjoy then!

Promote NIS Slave Server in Redhat/CentOS

Situation: You have NIS Master, you need a slave setup in your office.

This tutorial is covering steps for Redhat/CentOS/Fedora 64 bits. It might differ from what you have seen online.

1. Install ypserv in your server

yum install -y  ypserv.x86_64

2. Start the services

service ypserv start

service ypxfrd start

3. Verify the yp is ready

#rpcinfo -u localhost ypserv
program 100004 version 1 ready and waiting
program 100004 version 2 ready and waiting
4. Copy the database fro Master

/usr/lib/yp/ypinit -s master_domain_name


/usr/lib64/yp/ypinit -s master_domain_name

5. edit /etc/yp.conf

ensure you have the new slave hostname set is primary

6. Test

ypcat -k passwd | grep userid

7. Never forget to turn on

chkconfig ypserv on

chkconfig ypxfrd on

How to keep the database in sync?

1. Master push , this can be done via master. You can find it here

2.Slave pull from Master.


either one will do:

ypxfr_1perday  ypxfr_1perhour  ypxfr_2perday

Run this at your crontab 🙂

Use awk to calculate total size of files – part 1

Your boss came to you and asked for total size of files which has not been accessed for more than 30 days! Assume that you are just checking for 1 directory “/abc” . Here comes the simple command:

find /abc -atime +30 -exec ls -lk ‘{}’ \;  | awk ‘{SUM += $5} END {print SUM} ‘


find /abc -atime +30 -exec ls -lk ‘{}’ \

find command will find /abc and check for accestime which has not been access for 30 days and list it out the result

awk ‘{SUM += $5} END {print SUM} ‘

awk will sum all the result then only print out final figure.

The command is extremely useful especially you have multiple of directory residing in /abc :




Just write a simple script to generate it! I will cover this on next post.

© 2019 Thinkway

Theme by Anders NorénUp ↑