Net::NTPTime - Retrieve NTP and UNIX timestamp (unsigned integer) from an NTP server.
use Net::NTPTime; my $unix_time = get_unix_time; my $unix_time = get_unix_time('ntp.server.com'); my $ntp_time = get_ntp_time; my $ntp_time = get_ntp_time('ntp.server.com');
Retrieves timestamps in NTP and UNIX formats from an NTP server.
Returns an integer timestamp indicating the number of elapsed seconds since 00:00 01-JAN-1970. You may include a specific NTP server to ping, or a default server will be used.
Returns an integer timestamp indicating the number of elapsed seconds since 00:00 01-JAN-1900. You may include a specific NTP server to ping, or a default server will be used.
Copyright(C) 2009, phatWares, USA. All rights reserved.
Permission is granted to use this software under the same terms as Perl itself. Refer to the Perl Artistic license for details.
To install Net::NTPTime, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Net::NTPTime
CPAN shell
perl -MCPAN -e shell install Net::NTPTime
For more information on module installation, please visit the detailed CPAN module installation guide.