Actions
Bug #1357
closed[PF_RING ZC] unable to disable detect thread on STOP signal
Affected Versions:
Effort:
Difficulty:
Label:
Description
Basic information¶
- OS : CentOS 6.4 (x64)
- PF_RING ZC v.6.0.3.141221 (2 Management Threads, 22 Detect Threads)
[root@SKT-IDS src]# ./suricata -V This is Suricata version 2.1dev (rev c4e1324) [root@SKT-IDS src]# ./suricata --build-info This is Suricata version 2.1dev (rev c4e1324) Features: PCAP_SET_BUFF LIBPCAP_VERSION_MAJOR=1 PF_RING AF_PACKET HAVE_PACKET_FANOUT LIBCAP_NG LIBNET1.1 HAVE_HTP_URI_NORMALIZE_HOOK HAVE_NSS HAVE_LIBJANSSON PROFILING PROFILE_LOCKING SIMD support: SSE_4_2 SSE_4_1 SSE_3 Atomic intrisics: 1 2 4 8 16 byte(s) 64-bits, Little-endian architecture GCC version 4.4.7 20120313 (Red Hat 4.4.7-11), C version 199901 L1 cache line size (CLS)=64 compiled with LibHTP v0.5.16, linked against LibHTP v0.5.16 Suricata Configuration: AF_PACKET support: yes PF_RING support: yes NFQueue support: no NFLOG support: no IPFW support: no DAG enabled: no Napatech enabled: no Unix socket enabled: yes Detection enabled: yes libnss support: yes libnspr support: yes libjansson support: yes Prelude support: no PCRE jit: no LUA support: no libluajit: no libgeoip: yes Non-bundled htp: no Old barnyard2 support: no CUDA enabled: no Suricatasc install: yes Unit tests enabled: no Debug output enabled: no Debug validation enabled: no Profiling enabled: yes Profiling locks enabled: yes Coccinelle / spatch: no Generic build parameters: Installation prefix (--prefix): /usr/local Configuration directory (--sysconfdir): /usr/local/etc/suricata/ Log directory (--localstatedir) : /usr/local/var/log/suricata/ Host: x86_64-unknown-linux-gnu GCC binary: gcc GCC Protect enabled: no GCC march native enabled: yes GCC Profile enabled: no
Error Message¶
I get error messages when sending STOP signal(Ctrl + C).
^C [8541] 8/1/2015 -- 22:29:26 - (suricata.c:2370) <Notice> (main) -- Signal Received. Stopping engine. [8583] 8/1/2015 -- 22:29:26 - (flow-manager.c:698) <Info> (FlowManager) -- 0 new flows, 0 established flows were timed out, 0 flows in closed state [8541] 8/1/2015 -- 22:31:00 - (tm-threads.c:1577) <Error> (TmThreadDisableReceiveThreads) -- [ERRCODE: SC_ERR_FATAL(171)] - Engine unable to disable detect thread - "RxPFRzc:eth2@01". Killing engine
Files
Updated by jeongun baek almost 10 years ago
- File ReceivePfring_debug.log ReceivePfring_debug.log added
When using pfring_recv() with LIBPFRING_WAIT_FOR_INCOMING, some threads was not returned.
diff --git a/src/source-pfring.c b/src/source-pfring.c
index 6f483ff..ee299ec 100644
--- a/src/source-pfring.c
+++ b/src/source-pfring.c
@@ -310,7 +310,9 @@ TmEcode ReceivePfringLoop(ThreadVars *tv, void *data, void *slot)
}
while(1) {
+ SCLogInfo("[%s] ReceivePfringLoop", ptv->tv->name);
if (suricata_ctl_flags & (SURICATA_STOP | SURICATA_KILL)) {
+ SCLogInfo("[%s] ReceivePfringLoop end", ptv->tv->name);
SCReturnInt(TM_ECODE_OK);
}
Updated by Victor Julien almost 10 years ago
I think the problem is that the pfring api doesn't allow us to 'time out' when no traffic is received. So with no traffic pfring_recv blocks forever.
Updated by Victor Julien over 8 years ago
- Status changed from New to Closed
- Assignee set to Victor Julien
- Target version set to 3.0.1
Actions