awk/nawk/gawk is unsuitable for this task. You need to use something like Perl or Python
For the purposes of demonstration I have trimmed the Apache log file (infile) down to
The following Python code with convert the time field to UTC - 0700
Here is the output
To include the remaining parts of the log file, you need to extend log_re to handle the various patterns and
then add the additional elements to the output print statement. I leave that and better error handling to you.
I need to convert the given datetime from PST to UTC, i gone through multiple forum examples but everywhere it mentioned about converting the server datetime. So could someone help me on this.
I will be getting arguments for my script in the format of yyyymmddhh (eg:2015101004 - it will be pst),... (4 Replies)
Hello everyone,
Can you please help me with this problem?
I want to change the timezone of my Solaris 10 system. I found on internet that I should do the following steps:
1- Edit the /etc/TIMEZONE file
2- restart the system : init 6
My question is : In the file /etc/TIMEZONE I should... (5 Replies)
Hi,
how to calculate the time difference between PST date and PDT date in perl scripting.
date1: Mon Dec 31 16:00:01 PST 2015
date2: Tue Mar 19 06:09:30 PDT 2013
and also difference between PST-PST and PDT-PDT
need difference in months or days (months prefereble). (3 Replies)
I have a file which is tab delimited, it contains the GMT date.
Please tell me how to convert from GMT to PST time and if the date and time is of 2 days ago from the current date store the lines in a file or else remove the line.
10.1.10.178 - - -
10.1.10.178 - - ... (2 Replies)
Hi
I'm trying to change my sys clock from PST to UTC.
I've read the man date page
it helpfully says :-
-u, --utc, --universal
print or set Coordinated Universal Time
as root I have tried date --universal, date -u, date --utc,
I have checked the /etc/sysinfo/clock file the... (5 Replies)