diff -rua kamailio-3.1.4/cfg_core.c kamailio-3.1.4-new/cfg_core.c
--- kamailio-3.1.4/cfg_core.c	2011-05-26 20:08:57.000000000 +0200
+++ kamailio-3.1.4-new/cfg_core.c	2011-07-26 15:37:07.000000000 +0200
@@ -120,7 +120,7 @@
 	0,  /*!< force_rport */
 	L_DBG, /*!< memlog */
 	3 /*!< mem_summary -flags: 0 off, 1 pkg_status, 2 shm_status,
-		4 pkg_sums, 8 shm_sums */
+		4 pkg_sums, 8 shm_sums, 16 short_status */
 };
 
 void	*core_cfg = &default_core_cfg;
@@ -300,12 +300,13 @@
 		"force rport for all the received messages" },
 	{"memlog",		CFG_VAR_INT|CFG_ATOMIC,	0, 0, 0, 0,
 		"log level for memory status/summary information"},
-	{"mem_summary",	CFG_VAR_INT|CFG_ATOMIC,	0, 15, 0, 0,
+	{"mem_summary",	CFG_VAR_INT|CFG_ATOMIC,	0, 31, 0, 0,
 		"memory debugging information displayed on exit (flags): "
 		" 0 - off,"
 		" 1 - dump all the pkg used blocks (status),"
 		" 2 - dump all the shm used blocks (status),"
 		" 4 - summary of pkg used blocks,"
-		" 8 - summary of shm used blocks" },
+		" 8 - summary of shm used blocks,"
+		" 16 - short status instead of dump" },
 	{0, 0, 0, 0, 0, 0}
 };
diff -rua kamailio-3.1.4/doc/cfg_list/docbook/cfg_core.xml kamailio-3.1.4-new/doc/cfg_list/docbook/cfg_core.xml
--- kamailio-3.1.4/doc/cfg_list/docbook/cfg_core.xml	2011-05-26 20:08:02.000000000 +0200
+++ kamailio-3.1.4-new/doc/cfg_list/docbook/cfg_core.xml	2011-07-26 13:36:38.000000000 +0200
@@ -511,10 +511,12 @@
         memory debugging information displayed on exit (flags):  0 -
         off, 1 - dump all the pkg used blocks (status), 2 - dump all
         the shm used blocks (status), 4 - summary of pkg used blocks, 8
-        - summary of shm used blocks.
+        - summary of shm used blocks, 16 - show only summary of used 
+	blocks instead of full dump (to use in conjuntion with flags 1 
+	and 2).
     </para>
     <para>Default value: 3.</para>
-    <para>Range: 0 - 15.</para>
+    <para>Range: 0 - 31.</para>
     <para>Type: integer.</para>
     <para>
     </para>
diff -rua kamailio-3.1.4/main.c kamailio-3.1.4-new/main.c
--- kamailio-3.1.4/main.c	2011-05-26 20:08:57.000000000 +0200
+++ kamailio-3.1.4-new/main.c	2011-07-26 17:01:20.000000000 +0200
@@ -728,6 +728,7 @@
 			}
 		}
 #endif
+
 			break;
 
 		case SIGCHLD:
diff -rua kamailio-3.1.4/mem/f_malloc.c kamailio-3.1.4-new/mem/f_malloc.c
--- kamailio-3.1.4/mem/f_malloc.c	2011-05-26 20:08:57.000000000 +0200
+++ kamailio-3.1.4-new/mem/f_malloc.c	2011-07-26 13:39:37.000000000 +0200
@@ -601,8 +601,10 @@
 	int unused;
 	unsigned long size;
 	int memlog;
+	int mem_summary;
 
 	memlog=cfg_get(core, core_cfg, memlog);
+	mem_summary=cfg_get(core, core_cfg, mem_summary);
 	LOG_(DEFAULT_FACILITY, memlog, "fm_status: ", "fm_status (%p):\n", qm);
 	if (!qm) return;
 
@@ -615,6 +617,9 @@
 	LOG_(DEFAULT_FACILITY, memlog, "fm_status: ",
 			" max used (+overhead)= %lu\n", qm->max_real_used);
 #endif
+
+	if (mem_summary & 16) return;
+
 	/*
 	LOG_(DEFAULT_FACILITY, memlog, "fm_status: ", "dumping all fragments:\n");
 	for (f=qm->first_frag, i=0;((char*)f<(char*)qm->last_frag) && (i<10);
diff -rua kamailio-3.1.4/mem/ll_malloc.c kamailio-3.1.4-new/mem/ll_malloc.c
--- kamailio-3.1.4/mem/ll_malloc.c	2011-05-26 20:08:02.000000000 +0200
+++ kamailio-3.1.4-new/mem/ll_malloc.c	2011-07-26 13:46:51.000000000 +0200
@@ -971,14 +971,19 @@
 	unsigned long size;
 	int k;
 	int memlog;
+	int mem_summary;
 
 #warning "ll_status doesn't work (might crash if used)"
 
 	memlog=cfg_get(core, core_cfg, memlog);
+	mem_summary=cfg_get(core, core_cfg, mem_summary);
 	LOG(memlog, "sfm_status (%p):\n", qm);
 	if (!qm) return;
 
 	LOG(memlog, " heap size= %ld\n", qm->size);
+
+	if (mem_summary & 16) return;
+
 	LOG(memlog, "dumping free list:\n");
 	for(h=0,i=0,size=0;h<=sfm_max_hash;h++){
 		SFM_MAIN_HASH_LOCK(qm, h);
diff -rua kamailio-3.1.4/mem/q_malloc.c kamailio-3.1.4-new/mem/q_malloc.c
--- kamailio-3.1.4/mem/q_malloc.c	2011-05-26 20:08:57.000000000 +0200
+++ kamailio-3.1.4-new/mem/q_malloc.c	2011-07-26 13:40:43.000000000 +0200
@@ -693,9 +693,10 @@
 	int h;
 	int unused;
 	int memlog;
-
+	int mem_summary;
 
 	memlog=cfg_get(core, core_cfg, memlog);
+	mem_summary=cfg_get(core, core_cfg, mem_summary);
 	LOG_(DEFAULT_FACILITY, memlog, "qm_status: ", "(%p):\n", qm);
 	if (!qm) return;
 
@@ -707,6 +708,8 @@
 	LOG_(DEFAULT_FACILITY, memlog, "qm_status: ",
 			"max used (+overhead)= %lu\n", qm->max_real_used);
 	
+	if (mem_summary & 16) return;
+
 	LOG_(DEFAULT_FACILITY, memlog, "qm_status: ",
 			"dumping all alloc'ed. fragments:\n");
 	for (f=qm->first_frag, i=0;(char*)f<(char*)qm->last_frag_end;f=FRAG_NEXT(f)
