Excel vs Unix Timestemp : excel datevalue to java dateformat Hint!

Unix Timestamp from 1970 Excel Timestamp from 1900 Gap : (1970-1900) Days = 25569 Days     String rtn = ""; try{ DateFormat format = new SimpleDateFormat("yyyyMMdd"); //format.setTimeZone(TimeZone.getTimeZone("UTC")); double excelDays = Double.parseDouble((String)valv.elementAt(0)); double unixDays = (excelDays-25569); java.util.Date unixTime = new java.util.Date((long) ( 86400000l * unixDays)); rtn = format.format(unixTime); out.println(rtn); } catch(Exception e) {}  

Read More

centos 7 : ntpd kernel level time sync Hint, NTP synchronized timedatectl

centos 7 NTP synchronized   # timedatectl  status     # timedatectl set-ntp true   More Hint! # timedatectl | grep -i 'time zone' # ls -l /etc/localtime # timedatectl list-timezones | grep Asia/Seoul # timedatectl set-timezone Asia/Seoul Asia/Seoul => KST     yum install -y ntp firewall-cmd --add-service=ntp --permanent firewall-cmd --reload systemctl enable ntpd systemctl […]

Read More