---------- Post updated at 10:34 AM ---------- Previous update was at 10:15 AM ----------
now iam stuck again !
perl is not translating the variable . without variable it gives me the correct date value but if i try to use a variable its giving me wrong values.
---------- Post updated at 10:35 AM ---------- Previous update was at 10:34 AM ----------
now iam stuck again !
perl is not translating the variable . without variable it gives me the correct date value but if i try to use a variable its giving me wrong values.
I have a file named "suspected" with series of line like these :
{'protocol': 17, 'service': 'BitTorrent KRPC', 'server': '219.78.120.166', 'client_port': 52044, 'client': '10.64.68.44', 'server_port': 8291, 'time': 1226506312L, 'serverhostname': ''}
{'protocol': 17, 'service': 'BitTorrent... (3 Replies)
Hi everybody,
I want to get the current time in epoch format (in UNIX or Korn Shell) and store it in a variable called
currentTime. Any response will be highly appreciated:)
Thanks in advance,
omoyne:D (8 Replies)
Hi,
Thanks bartus11 yesterday's code worked fine for me.
In meantime I've found another "issue".
As you can see highlighted, the time format in my original input in case of two rows which should be duplicited ,is differentwhat I need to do is to convert to this format "20110607-08:03:22"... (4 Replies)
Hi all ,
I need to know how to convert a time stamp entered by the user to be converted to GMT/UTC(epoch time) using mktime() and gmtime()
for exapample the input will be put in the form
ptm.tm_sec = 0;
ptm.tm_min = 59;
ptm.tm_hour = 11;
ptm.tm_mday = 20;... (2 Replies)
Looking for some help and usually when I do a search this site comes up. Hopefully someone can give me a little direction as to how to use one of these two commands to achieve what I'm trying to do.
What am I trying to do?
I need to take the time value in epoch format returned from the... (5 Replies)
# date +%s -d "Mon Feb 11 02:26:04"
1360567564
# perl -e 'print scalar localtime(1360567564), "\n";'
Mon Feb 11 02:26:04 2013
the epoch conversion is working fine. but one of my application needs 13 digit epoch time as input
1359453135154
rather than 10 digit epoch time 1360567564... (3 Replies)
I have a Raspberry Pi that logs some temperatures using Onewire. Data is collected with RRDTool.
The command sudo rrdtool fetch ute_temp.rrd AVERAGE -s -1h > ./test.log
and then cat test.log gives the result
1388608500: 2.3579639836e+00
.
How do I write a script that converts the Epoch time... (4 Replies)
Can someone help me to write a shell script to convert epoch timestamp into human readable format
1394553600,"test","79799776.0","19073982.728571","77547576.0","18835699.285714"
1394553600,"test1","80156064.0","19191275.014286","62475360.000000","14200554.720000"... (10 Replies)
I am trying to create a script that will take epoch (input from command line) and convert it into a readable format in bash/shell
---------- Post updated at 08:03 PM ---------- Previous update was at 07:59 PM ----------
#!bin/bash
read -p "Please enter a number to represent epoch time:"... (9 Replies)
Discussion started by: sprocket
9 Replies
LEARN ABOUT CENTOS
localtime
LOCALTIME(5) localtime LOCALTIME(5)NAME
localtime - Local timezone configuration file
SYNOPSIS
/etc/localtime -> ../usr/share/zoneinfo/...
DESCRIPTION
The /etc/localtime file configures the system-wide timezone of the local system that is used by applications for presentation to the user.
It should be an absolute or relative symbolic link pointing to /usr/share/zoneinfo/, followed by a timezone identifier such as
"Europe/Berlin" or "Etc/UTC". The resulting link should lead to the corresponding binary tzfile(5) timezone data for the configured
timezone.
Because the timezone identifier is extracted from the symlink target name of /etc/localtime, this file may not be a normal file or
hardlink.
The timezone may be overridden for individual programs by using the TZ environment variable. See environ(7).
You may use timedatectl(1) to change the settings of this file from the command line.
SEE ALSO systemd(1), tzset(3), localtime(3), timedatectl(1), systemd-timedated.service(8)systemd 208LOCALTIME(5)