Forgot to include this: OS Release: Red Hat Enterprise Linux Server release 6.9 (Santiago)
Packages installed: tzdata-2018c-1.el6.noarch coreutils-8.4-46.0.1.el6.x86_64 coreutils-libs-8.4-46.0.1.el6.x86_64 Jared Chagnon Systems Engineering Manager P: 781.292.6033 M: 508.566.0081 <mailto:[email protected]>[email protected]<mailto:[email protected]> www.enservio.com<http://www.enservio.com/> [cid:[email protected]] On Mar 13, 2018, at 9:10 AM, Jared Chagnon <[email protected]<mailto:[email protected]>> wrote: Please see the issue below: I setup a test script: #/bin/bash echo "`date`" echo "`date +%z`" currentdate=`date +%Y%m%d_%H%M%S` echo "current date: $currentdate" olddate=`date "+%Y%m%d_%H%M%S" --date='4 days ago'` echo "old date 4 days ago: $olddate” ————— Output ————— ./datetest.sh Tue Mar 13 09:08:34 EDT 2018 -0400 current date: 20180313_090834 old date 4 days ago: 20180309_080834 ————— Notes —————— My local time zone is America\New_York. Please note the date modification is not using EDT and resulting in EST. Jared Chagnon Systems Engineering Manager P: 781.292.6033 M: 508.566.0081 <mailto:[email protected]>[email protected]<mailto:[email protected]> www.enservio.com<http://www.enservio.com/> [cid:[email protected]]
