diff --git a/src/vlib/buffer.c b/src/vlib/buffer.c
index 674f15d..5ba4227 100644
--- a/src/vlib/buffer.c
+++ b/src/vlib/buffer.c
@@ -663,7 +663,7 @@
 				  u8 unpriv)
 {
   vlib_buffer_main_t *bm = vm->buffer_main;
-  u32 buffers_per_numa = bm->buffers_per_numa;
+  u32 buffers_per_numa = bm->buffers_per_numa[numa_node];
   clib_error_t *error;
   u32 buffer_size;
   uword n_pages, pagesize;
@@ -680,6 +680,9 @@
 			      "size (%llu)", buffer_size, pagesize);
 
   if (buffers_per_numa == 0)
+    buffers_per_numa = bm->default_buffers_per_numa;
+
+  if (buffers_per_numa == 0)
     buffers_per_numa = unpriv ? VLIB_BUFFER_DEFAULT_BUFFERS_PER_NUMA_UNPRIV :
       VLIB_BUFFER_DEFAULT_BUFFERS_PER_NUMA;
 
@@ -906,18 +909,48 @@
 }
 
 static clib_error_t *
+vlib_buffers_numa_configure (vlib_buffer_main_t *bm, u32 numa_node,
+			     unformat_input_t *input)
+{
+  u32 buffers = 0;
+
+  if (numa_node >= VLIB_BUFFER_MAX_NUMA_NODES)
+    return clib_error_return (0, "invalid numa node");
+
+  if (!input)
+    return 0;
+
+  unformat_skip_white_space (input);
+  while (unformat_check_input (input) != UNFORMAT_END_OF_INPUT)
+    {
+      if (unformat (input, "buffers %u", &buffers))
+	;
+      else
+	return unformat_parse_error (input);
+    }
+
+  bm->buffers_per_numa[numa_node] = buffers;
+  return 0;
+}
+
+static clib_error_t *
 vlib_buffers_configure (vlib_main_t * vm, unformat_input_t * input)
 {
   vlib_buffer_main_t *bm;
+  u32 numa_node;
+  unformat_input_t sub_input;
+  clib_error_t *error = 0;
 
   vlib_buffer_main_alloc (vm);
 
   bm = vm->buffer_main;
   bm->log2_page_size = CLIB_MEM_PAGE_SZ_UNKNOWN;
+  memset (bm->buffers_per_numa, 0, sizeof (bm->buffers_per_numa));
 
   while (unformat_check_input (input) != UNFORMAT_END_OF_INPUT)
     {
-      if (unformat (input, "buffers-per-numa %u", &bm->buffers_per_numa))
+      if (unformat (input, "buffers-per-numa %u",
+		    &bm->default_buffers_per_numa))
 	;
       else if (unformat (input, "page-size %U", unformat_log2_page_size,
 			 &bm->log2_page_size))
@@ -925,6 +958,15 @@
       else if (unformat (input, "default data-size %u",
 			 &bm->default_data_size))
 	;
+      else if (unformat (input, "numa %u %U", &numa_node,
+			 unformat_vlib_cli_sub_input, &sub_input))
+	{
+	  error = vlib_buffers_numa_configure (bm, numa_node, &sub_input);
+	  unformat_free (&sub_input);
+
+	  if (error)
+	    return error;
+	}
       else
 	return unformat_parse_error (input);
     }
diff --git a/src/vlib/buffer.h b/src/vlib/buffer.h
index 7d45689..aad9701 100644
--- a/src/vlib/buffer.h
+++ b/src/vlib/buffer.h
@@ -508,7 +508,8 @@
   u8 default_buffer_pool_index_for_numa[VLIB_BUFFER_MAX_NUMA_NODES];
 
   /* config */
-  u32 buffers_per_numa;
+  u32 default_buffers_per_numa;
+  u32 buffers_per_numa[VLIB_BUFFER_MAX_NUMA_NODES];
   u16 ext_hdr_size;
   u32 default_data_size;
   clib_mem_page_sz_t log2_page_size;
