Skip to main content
Cisco SD-WAN
Product Documentation
Viptela Documentation

Configuring Time and Location

This article describes how to configure time and location services on Viptela devices.

Configure Network-Wide Time with NTP

To coordinate and synchronize time across all devices in the Viptela overlay network, configure the IP address or DNS server address of an NTP server on each device. The IP address must be an IPv4 address; it cannot be an IPv6 address. If necessary, specify the VPN through which the server is reachable.

Viptela(config)# system ntp server (dns-server-address | ipv4-address)
Viptela(config-system)# ntp server (dns-server-address | ipv4-address) vpn vpn-id

You can configure up to four NTP servers, and they must all be located or reachable in the same VPN. The software uses the server at the highest stratum level. If more than one server is at the same stratum level, you can configure the preference to use a specific server:

Viptela(config-ntp)# ntp server (dns-server-address | ipv4-address) prefer

You can configure an MD5 authentication key to use as a password to access an NTP server:

Viptela(config-system)# ntp keys
Viptela(config-keys)# authentication key-id md5 md5-key

key-id is a number that identifies the MD5 authentication key. It can be a number from 1 through 65535.

md5-key is the MD5 authentication key. You can enter it as cleartext or as an AES-encrypted key.

To use an MD5 authentication key for an NTP server, the key must be configured to be trusted:

Viptela(config-system)# ntp keys trusted key-id

Finally, associate the MD5 authentication key with the NTP time server:

Viptela(config-system)# ntp server (dns-server-address | ipv4-address) key key-id

You can configure NTP packets to exit from a specific interface on the router. The interface must be located in the same VPN as the NTP server. If it is not, the configuration is ignored.

Viptela(config-system)# ntp server (dns-server-address | ipv4-address) source-interface interface-name

The following example configures three NTP servers. One of the NTP servers is at the NTP pool project at the Network Time Foundation and uses no authentication. The other two are internal servers and are configured with MD5 authentication:

Viptela# show running-config system ntp
   authentication 1001 md5 $4$KXLzYT9k6M8zj4BgLEFXKw==
   authentication 1002 md5 $4$KXLzYTxk6M8zj4BgLEFXKw==
   authentication 1003 md5 $4$KXLzYT1k6M8zj4BgLEFXKw==
   trusted 1001 1002
   key     1001
   vpn     512
   version 4
   key     1002
   vpn     512
   version 4
   vpn     512
   version 4

Configuring NTP on a Viptela device allows that device to contact NTP servers to synchronize time. Other devices are allowed to ask a Viptela device for the time, but no devices are allowed to use the Viptela device as an NTP server.

Configure the Timezone

The default timezone on all Viptela devices is UTC.If your devices are located in multiple timezones (and even if they are not), we recommend that you use the default timezone, which is UTC, on all device so that the times in all logging and archive files are consistent.

To change the timezone on a device:

Viptela(config-system)# clock timezone timezone

Set the Time Locally

For Viptela devices that are part of a test or local network, you can set the time locally without using NTP because you do not need to ensure that time is synchronized across an entire network of devices. You can also set the time locally on any device as it is joining the network, in addition to configuring an NTP server, and this time will be overwritten by the official NTP time once the device contacts the NTP server.

To set the local time and date, issue the following operational commands:

Viptela# clock set time hh:mm:ss[.sss]
Viptela# clock set date ccyy-mm-dd

You can also issue these commands as a single command:

Viptela# clock set date ccyy-mm-dd timehh:mm:ss[.sss]


Viptela# clock set timehh:mm:ss[.sss] date ccyy-mm-dd

To set the timezone, specify it in the configuration:

Viptela(config)# system clock timezone timezone

Configure a Device's Geographic Location

Configuring a device's geographic location by setting its latitude and longitude allows the device to be placed properly on the vManage NMS's network map.

To set a device's latitude and longitude:

Viptela(config-system)# gps-location latitude degrees.minutes-and-seconds longitude degrees.minutes-and-seconds

You can also set these values using two separate commands:

Viptela(config-system)# gps-location latitude degrees. minutes-and-seconds
Viptela(config-system)# gps-location longitude degrees. minutes-and-seconds

For example:

vEdge(config-system)# gps-location latitude 37.0000 longitude 122.0600 


vEdge(config-system)# gps-location latitude 37.000 
vEdge(config-system)# gps-location longitude 122.0600 

vEdge(config-system)# show full-configuration 
 host-name         vEdge
 gps-location latitude 36.972
 gps-location longitude 122.0263

You can also configure a text description of the device's location:

Viptela(config-system)# location "description of location"

For example:

vEdge(config-system)# location "UCSC in Santa Cruz, California" 
vEdge(config-system)# show full-configuration 
 host-name         vEdge
 location          "UCSC in Santa Cruz, California"
 gps-location latitude 37.0000
 gps-location longitude 122.0600
  • Was this article helpful?