I know that this topic has been discuss numerous times, and I have search the net and this forum for it.
However, non able to address the problem I faced so far.
I am on Solaris Platform and unable to install additional packages like the GNU date and gawk to make use of their functions.
Hence, I intend to go for Perl and include a one-liner command in the shell script for the conversion.
As you can see below, I have no problem converting Epoch to Standard Date/Time.
But for converting Standard Date/Time to Epoch, I am not getting the correct Epoch value.
I found out that the month parameter for perl timelocal() need to "- 1".
As in Jan to specify "0", Dec to specify 11.
I got the value wrong, thats why epoch is not returning a consistent value.