Nmap Development mailing list archives

Help debugging hang with epoll_engine


From: Daniel Miller <bonsaiviking () gmail com>
Date: Thu, 07 Jun 2012 13:09:52 -0500

List,

I think this may be the same issue I reported here: http://seclists.org/nmap-dev/2012/q1/435

This time, I was doing a large IPv6 scan (sudo ./nmap -6 -d2 -oA ../top-1m-v6 -A -iL alexa-top-1m --log-errors -T4), which hung on NSE scanning:

NSE Timing: About 99.24% done; ETC: 12:38 (0:00:19 remaining)
NSE Timing: About 99.24% done; ETC: 12:39 (0:00:19 remaining)
NSE Timing: About 99.24% done; ETC: 12:39 (0:00:20 remaining)
NSE Timing: About 99.24% done; ETC: 12:40 (0:00:20 remaining)
NSE Timing: About 99.24% done; ETC: 12:40 (0:00:20 remaining)
NSE Timing: About 99.24% done; ETC: 12:41 (0:00:20 remaining)
NSE Timing: About 99.24% done; ETC: 12:41 (0:00:21 remaining)
NSE Timing: About 99.24% done; ETC: 12:42 (0:00:21 remaining)
This time, I was running under sudo, which meant I couldn't get a traceback or detailed status line due to the issue in this thread: http://seclists.org/nmap-dev/2011/q3/413 (confirmed in this thread: http://seclists.org/nmap-dev/2012/q2/44)

I was, however, able to attach with strace, which contained lots of repetitions of these calls:

gettimeofday({1339090519, 54857}, NULL) = 0
ioctl(4, TIOCGPGRP, [135333485]) = -1 ENOTTY (Inappropriate ioctl for device)
gettimeofday({1339090519, 55094}, NULL) = 0
gettimeofday({1339090519, 55202}, NULL) = 0
epoll_wait(7, {}, 128, 50)              = 0
gettimeofday({1339090519, 105501}, NULL) = 0
gettimeofday({1339090519, 105596}, NULL) = 0
ioctl(4, TIOCGPGRP, [135333485]) = -1 ENOTTY (Inappropriate ioctl for device)
gettimeofday({1339090519, 105835}, NULL) = 0
The epoll_wait call led me to the epoll_loop function in nsock/src/engine_epoll.c, but the loop must be higher up, since epoll_wait is returning 0, and the condition of the inner loop is on its return value being -1.

I'll be testing this with a debug build, and try to get a full backtrace (NSE and C), but I thought perhaps someone could reason something out from this.

Dan
_______________________________________________
Sent through the nmap-dev mailing list
http://cgi.insecure.org/mailman/listinfo/nmap-dev
Archived at http://seclists.org/nmap-dev/


Current thread: