diff --git a/src/vnet/lisp-cp/control.c b/src/vnet/lisp-cp/control.c
index 7aa3b41..42b5b8b 100644
--- a/src/vnet/lisp-cp/control.c
+++ b/src/vnet/lisp-cp/control.c
@@ -1027,7 +1027,7 @@
 }
 
 int
-vnet_lisp_add_del_l2_arp_entry (gid_address_t * key, u8 * mac, u8 is_add)
+vnet_lisp_add_del_l2_arp_ndp_entry (gid_address_t * key, u8 * mac, u8 is_add)
 {
   if (vnet_lisp_enable_disable_status () == 0)
     {
@@ -1054,7 +1054,7 @@
     {
       if (res == GID_LOOKUP_MISS_L2)
 	{
-	  clib_warning ("ONE ARP entry %U not found - cannot delete!",
+	  clib_warning ("ONE entry %U not found - cannot delete!",
 			format_gid_address, key);
 	  return -1;
 	}
diff --git a/src/vnet/lisp-cp/control.h b/src/vnet/lisp-cp/control.h
index d40f6f5..0df18f4 100644
--- a/src/vnet/lisp-cp/control.h
+++ b/src/vnet/lisp-cp/control.h
@@ -393,7 +393,8 @@
 int vnet_lisp_map_register_enable_disable (u8 is_enable);
 u8 vnet_lisp_map_register_state_get (void);
 u8 vnet_lisp_rloc_probe_state_get (void);
-int vnet_lisp_add_del_l2_arp_entry (gid_address_t * key, u8 * mac, u8 is_add);
+int vnet_lisp_add_del_l2_arp_ndp_entry (gid_address_t * key, u8 * mac,
+					u8 is_add);
 u32 *vnet_lisp_l2_arp_bds_get (void);
 lisp_api_l2_arp_entry_t *vnet_lisp_l2_arp_entries_get_by_bd (u32 bd);
 int vnet_lisp_nsh_set_locator_set (u8 * locator_set_name, u8 is_add);
diff --git a/src/vnet/lisp-cp/one_api.c b/src/vnet/lisp-cp/one_api.c
index 96b3d2c..ae52381 100644
--- a/src/vnet/lisp-cp/one_api.c
+++ b/src/vnet/lisp-cp/one_api.c
@@ -1567,7 +1567,7 @@
   /* vpp keeps ip4 addresses in network byte order */
   ip_address_set (&gid_address_arp_ndp_ip (arp), &mp->ip4, IP4);
 
-  rv = vnet_lisp_add_del_l2_arp_entry (arp, mp->mac, mp->is_add);
+  rv = vnet_lisp_add_del_l2_arp_ndp_entry (arp, mp->mac, mp->is_add);
 
   REPLY_MACRO (VL_API_ONE_ADD_DEL_L2_ARP_ENTRY_REPLY);
 }
@@ -1584,7 +1584,7 @@
   gid_address_ndp_bd (g) = clib_net_to_host_u32 (mp->bd);
   ip_address_set (&gid_address_arp_ndp_ip (g), mp->ip6, IP6);
 
-  rv = vnet_lisp_add_del_l2_arp_entry (g, mp->mac, mp->is_add);
+  rv = vnet_lisp_add_del_l2_arp_ndp_entry (g, mp->mac, mp->is_add);
 
   REPLY_MACRO (VL_API_ONE_ADD_DEL_NDP_ENTRY_REPLY);
 }
diff --git a/src/vnet/lisp-cp/one_cli.c b/src/vnet/lisp-cp/one_cli.c
index 1e52c9a..700bfd6 100644
--- a/src/vnet/lisp-cp/one_cli.c
+++ b/src/vnet/lisp-cp/one_cli.c
@@ -277,6 +277,70 @@
 /* *INDENT-ON* */
 
 static clib_error_t *
+lisp_add_del_ndp_entry_command_fn (vlib_main_t * vm,
+				   unformat_input_t * input,
+				   vlib_cli_command_t * cmd)
+{
+  unformat_input_t _line_input, *line_input = &_line_input;
+  clib_error_t *error = NULL;
+  int rc = 0;
+  u8 hw_addr[6], bd = 0;
+  ip6_address_t ip6;
+  u32 hw_addr_set = 0, ip_set = 0, is_add = 1;
+  gid_address_t _g, *g = &_g;
+
+  memset (&ip6, 0, sizeof (ip6));
+  memset (hw_addr, 0, sizeof (hw_addr));
+  memset (g, 0, sizeof (*g));
+
+  if (!unformat_user (input, unformat_line_input, line_input))
+    return 0;
+
+  while (unformat_check_input (line_input) != UNFORMAT_END_OF_INPUT)
+    {
+      if (unformat (line_input, "mac %U", unformat_mac_address, hw_addr))
+	hw_addr_set = 1;
+      else if (unformat (line_input, "ip %U", unformat_ip6_address, &ip6))
+	ip_set = 1;
+      else if (unformat (line_input, "del"))
+	is_add = 0;
+      else if (unformat (line_input, "bd %d", &bd))
+	;
+      else
+	{
+	  error = clib_error_return (0, "parse error");
+	  goto done;
+	}
+    }
+
+  if (!ip_set || (!hw_addr_set && is_add))
+    {
+      vlib_cli_output (vm, "expected IP and MAC addresses!");
+      return 0;
+    }
+
+  /* build GID address */
+  ip_address_set (&gid_address_arp_ndp_ip (g), &ip6, IP6);
+  gid_address_ndp_bd (g) = bd;
+  gid_address_type (g) = GID_ADDR_NDP;
+  rc = vnet_lisp_add_del_l2_arp_ndp_entry (g, hw_addr, is_add);
+  if (rc)
+    clib_warning ("Failed to %s ndp entry!", is_add ? "add" : "delete");
+
+done:
+  unformat_free (line_input);
+  return error;
+}
+
+/* *INDENT-OFF* */
+VLIB_CLI_COMMAND (one_add_del_ndp_entry_command) = {
+    .path = "one ndp",
+    .short_help = "one ndp [del] bd <bd> mac <mac> ip <ipv6>",
+    .function = lisp_add_del_ndp_entry_command_fn,
+};
+/* *INDENT-ON* */
+
+static clib_error_t *
 lisp_add_del_l2_arp_entry_command_fn (vlib_main_t * vm,
 				      unformat_input_t * input,
 				      vlib_cli_command_t * cmd)
@@ -323,7 +387,7 @@
   gid_address_arp_ip4 (arp) = ip4;
   gid_address_arp_bd (arp) = bd;
   gid_address_type (arp) = GID_ADDR_ARP;
-  rc = vnet_lisp_add_del_l2_arp_entry (arp, hw_addr, is_add);
+  rc = vnet_lisp_add_del_l2_arp_ndp_entry (arp, hw_addr, is_add);
   if (rc)
     clib_warning ("Failed to %s l2 arp entry!", is_add ? "add" : "delete");
 
