exited with code 255

257 views
Skip to first unread message

hajji wajdi

unread,
Sep 28, 2017, 4:57:20 PM9/28/17
to ns-3-users
Hye friends and teachers,

Please, Anyone know, How to resolve this issue? 
Command [...] exited with code 255

thank you for helping 
runus.png

Tom Henderson

unread,
Sep 28, 2017, 8:12:07 PM9/28/17
to ns-3-...@googlegroups.com
On 09/28/2017 01:57 PM, hajji wajdi wrote:
Hye friends and teachers,

Please, Anyone know, How to resolve this issue? 
Command [...] exited with code 255

You should try a debugger.

$ sudo apt-get install gdb
$ ./waf --command-template="gdb %s" --run HadoopSim

(gdb) r 0 0 0 examples/HadoopSim/bench-trace/star.nettopo examples/HadoopSim/bench-trace/bayes/Trace 11 0

and see where it breaks, and then backtrace (bt) at the gdb prompt to look further, or perhaps step upwards with the 'up' command.

(gdb) bt
(gdb) up
(gdb) up
...

- Tom


thank you for helping 
--
Posting to this group should follow these guidelines https://www.nsnam.org/wiki/Ns-3-users-guidelines-for-posting
---
You received this message because you are subscribed to the Google Groups "ns-3-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to ns-3-users+...@googlegroups.com.
To post to this group, send email to ns-3-...@googlegroups.com.
Visit this group at https://groups.google.com/group/ns-3-users.
For more options, visit https://groups.google.com/d/optout.


Tom Henderson

unread,
Sep 28, 2017, 8:22:43 PM9/28/17
to ns-3-...@googlegroups.com
On 09/28/2017 05:11 PM, Tom Henderson wrote:
On 09/28/2017 01:57 PM, hajji wajdi wrote:
Hye friends and teachers,

Please, Anyone know, How to resolve this issue? 
Command [...] exited with code 255

You should try a debugger.

$ sudo apt-get install gdb
$ ./waf --command-template="gdb %s" --run HadoopSim

(gdb) r 0 0 0 examples/HadoopSim/bench-trace/star.nettopo examples/HadoopSim/bench-trace/bayes/Trace 11 0

and see where it breaks, and then backtrace (bt) at the gdb prompt to look further, or perhaps step upwards with the 'up' command.

(gdb) bt
(gdb) up
(gdb) up
...

Further, it is likely (in your case) that the program actually exited and you will have no stack to inspect:  gdb may report:
[Inferior 1 (process ...) exited with code 0377]

In this case, there is probably an 'exit (-1);' statement that is executing somewhere.

You can instead ask gdb to break on exit, such as

$ ./waf --command-template="gdb %s" --run HadoopSim

(gdb) break exit
Breakpoint 1 at 0x...
(gdb)
r 0 0 0 examples/HadoopSim/bench-trace/star.nettopo examples/HadoopSim/bench-trace/bayes/Trace 11 0

and it should break at the point of exit(), at which time you can look at the backtrace to find where in the code that exit() is being called.

- Tom

hajji wajdi

unread,
Oct 2, 2017, 6:04:21 AM10/2/17
to ns-3-users
hye Sir,
After I try, use the debugger to show the result of the command
see it in pictuer 

gdb01.png
gdb02.png
gdb03.png
Reply all
Reply to author
Forward
0 new messages