Skip to main content
Skip table of contents

Configuring the clock and timezone for the gateway

The gateway allows you to manually set the date/time and timezone of the server. The command to set the date/time is available in operational mode only. The command to set the timezone is available in configuration mode only. The default timezone setting for the gateway is UTC.

Note: NTP must be disabled before configuring the time and date manually. If NTP is enabled, you cannot manually set the time and date. NTP is mutually exclusive with the manual option for setting the clock. You can enable NTP after you manually set the clock to ensure that the time and date stay in sync with a common clock source. Blue Cedar highly recommends using NTP to ensure a synchronized clock. This is critical for verifying time-sensitive objects such as certificate expiration and renewal dates. See Configuring system protocols and services for details on enabling and disabling NTP.

When configuring the timezone, you can only set this parameter manually. NTP does not modify timezone.

Setting the current date and time

To set the date/time, use the request command with the current-datetime parameter in operational mode.

Valid values for the time and dates are the Internet Date/Time Format standards established in RFC 3339/ISO-8601, which can be found at http://tools.ietf.org/html/rfc3339#section-5.6.

Example

BASH
> request set-current-datetime current-datetime "2018-03-30 02:26:15-0400"
old-datetime "2018-03-30 02:49:43+0200";
new-datetime "2018-03-30 02:26:15-0400";


Viewing the current date/time

To view the current date and time, use the show status command and the clock-info parameter in operational mode.

BASH
> show status operational context default system-operational clock-info
clock-info {
  current-datetime "2017-09-30 08:28:26+0200";
  boot-datetime "2017-09-27 00:46:47+0200";
}


The boot-datetime shows the last time the gateway was rebooted.

Setting the current timezone for the gateway

Use the timezone-location parameter to set the timezone for the gateway in configure mode. The default timezone is UTC.

Valid values for the timezones are the NETCONF/YANG definitions for IANA-registered timezones that can be found at http://www.iana.org/time-zones.

The following example sets a new timezone as Berlin, Germany:

BASH
% set system clock timezone timezone-location Europe/Berlin
% commit
Commit succeeded.


To confirm the timezone change, use the show command:

BASH
% show system clock timezone timezone-location
timezone-location Europe/Berlin;

On this page

You can perform these commands from the CLI for configuring the gateway clock:

JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.