Friday, October 31, 2014

Set linux date n time

set date and time:
(date --set="YYYYmmdd HH:MM")

date --set="2 OCT 2006 18:00:00"

or

date +%Y%m%d -s "20081128"

set only time:
date +%T -s "10:13:13"


set only year:
date --set="$(date +'2013%m%d %H:%M')"


set hardware clock in line with linux time
hwclock --systohc

or  
hwclock -w

Thursday, October 23, 2014

add feature NTOP pada Centos

Install Ntop in Centos


Download ntop from RPM

yum localinstall ntop


Start ntop
/usr/sbin/ntop -i "eth0,eth1" -d -L -u ntop -P /etc/ntop --skip-version-check --use-syslog=daemon

Open iptables on ntop port

Saturday, October 18, 2014

Email -Test smtp via telnet

Open a CMD prompt
type  TELNET MAIL.THEIRDOMAIN.COM 25 

You should see something like this as a response:
220 mx.google.com ESMTP 6si6253627yxg.6

test sending mail:

ehlo mydomain.com
mail from:<fedrik@mydomain.com>
rcpt to:<recipient@theirdomain.com>
data 

"This is a test, please do not respond "
.
quit