Is there an easy method to do an on the fly conversion of a standard epoch time (seconds from 1970) to more readable date format?
Does Unix have anything built in to do this? (4 Replies)
Hi guys,
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... (5 Replies)
Hi,
Is there any easy way to convert date time(stored in shell variable ) to epoch time in solaris box? As +%s is working on linux but not on solaris, also -d option is not working.
Any suggestion please? (6 Replies)
Hello
I have a the creation date of a file stored in a variable in the following format:
Wed May 06 10:14:58 2009Is there a way I can echo the variable and display it in epoch time?
I've done a lot of searching on this topic, but haven't managed to get a solution. I'm on Solaris 10.
... (2 Replies)
Dear experts,
I have an epoch time input file such as : -
1302451209564
1302483698948
1302485231072
1302490805383
1302519244700
1302492787481
1302505299145
1302506557022
1302532112140
1302501033105
1302511536485
1302512669550
I need the epoch time above to be converted into real... (4 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)
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)
Team,
I am working on a shell script and i am extracting a date string in "SunOS server" with below format.
Mon Jan 21 04:13:48 EST 2021
Can you please assist me the best way to convert the extracted string to epoch time like "date +%s" in Linux.
Thanks in advance (1 Reply)
Discussion started by: Girish19
1 Replies
LEARN ABOUT DEBIAN
io::async::file
IO::Async::File(3pm) User Contributed Perl Documentation IO::Async::File(3pm)NAME
"IO::Async::File" - watch a file for changes
SYNOPSIS
use IO::Async::File;
use IO::Async::Loop;
my $loop = IO::Async::Loop->new;
my $file = IO::Async::File->new(
filename => "config.ini",
on_mtime_changed => sub {
my ( $self ) = @_;
print STDERR "Config file has changed
";
reload_config( $self->handle );
}
);
$loop->add( $file );
$loop->run;
DESCRIPTION
This subclass of IO::Async::Notifier watches an open filehandle or named filesystem entity for changes in its "stat()" fields. It invokes
various events when the values of these fields change. It is most often used to watch a file for size changes; for this task see also
IO::Async::FileStream.
While called "File", it is not required that the watched filehandle be a regular file. It is possible to watch anything that stat(2) may be
called on, such as directories or other filesystem entities.
EVENTS
The following events are invoked, either using subclass methods or CODE references in parameters.
on_dev_changed $new_dev, $old_dev
on_ino_changed $new_ino, $old_ino
...
on_ctime_changed $new_ctime, $old_ctime
Invoked when each of the individual "stat()" fields have changed. All the "stat()" fields are supported apart from "blocks" and "blksize".
Each is passed the new and old values of the field.
on_devino_changed $new_stat, $old_stat
Invoked when either of the "dev" or "ino" fields have changed. It is passed two File::stat instances containing the complete old and new
"stat()" fields. This can be used to observe when a named file is renamed; it will not be observed to happen on opened filehandles.
on_stat_changed $new_stat, $old_stat
Invoked when any of the "stat()" fields have changed. It is passed two File::stat instances containing the old and new "stat()" fields.
PARAMETERS
The following named parameters may be passed to "new" or "configure".
handle => IO
The opened filehandle to watch for "stat()" changes if "filename" is not supplied.
filename => STRING
Optional. If supplied, watches the named file rather than the filehandle given in "handle". The file will be opened for reading and
then watched for renames. If the file is renamed, the new filename is opened and tracked similarly after closing the previous file.
interval => NUM
Optional. The interval in seconds to poll the filehandle using stat(2) looking for size changes. A default of 2 seconds will be
applied if not defined.
METHODS
$handle = $file->handle
Returns the filehandle currently associated with the instance; either the one passed to the "handle" parameter, or opened from the
"filename" parameter.
AUTHOR
Paul Evans <leonerd@leonerd.org.uk>
perl v5.14.2 2012-10-24 IO::Async::File(3pm)