Summary of problems during NS2.

Source: Internet
Author: User

I installed NS today and encountered some problems. I collected some information online and put it here for a summary, hoping to help myself and everyone.

From http://prolqspace.spaces.live.com/blog/cns! 7240de3b63f5b841! 878. Entry

1. First thing to do:
To prevent problems such as "unmatched parentheses", replace. relid'' with. relid' in the following file ':

Ns-allinone-2.27/tcl8.4.5/Unix/configure
Ns-allinone-2.27/tcl8.4.5/Unix/TCL. M4
Ns-allinone-2.27/tk8.4.5/Unix/configure
Ns-allinone-2.27/tk8.4.5/Unix/TCL. M4
Ns-allinone-2.27/otcl-1.8/configure

2. Problem log:
Ore-I./Asim/-I./QS-I./DiffServ-I./satellite-I./WPAN-o
Trace/trace. o
Trace/trace. CC
./Sctp. h: 705: Error: extra qualification
'Sctpagent: 'on member
'Dumpsendbuffer'
Make: *** [trace/trace. O]
Error 1

Solution:
Remove 'sctpagent: 'from the first row of dumpsendbuffer function in the file sctp. h.

3. Problem log:
./Mobile/God. h: 88: Error: there are additional limitations: 'vector: 'on the member 'operator ='
./Mobile/God. h: 93: Error: there are additional limitations: 'vector: 'on the member 'operator + ='
./Mobile/God. h: 98: Error: there are additional limitations: 'vector: 'on the member 'operator ='
./Mobile/God. h: 101: Error: there are additional limitations: 'vector: 'In the member 'operator! = 'Upper
Make: *** [src_rtg/sragent. O] Error 1
NS make failed!
See
: URL: http://www.isi.edu/nsnam/ns/ns-problems.html for Problems

Solution:
Remove 'vector: 'from these files.

4. Problem log:

Queue/CBQ. CC: 112: Error: iso c ++ forbids declaration of 'cbqueue 'with no type

Use the following patch (@... @ represents the row and column number, + represents the row to be added,-represents the row to be deleted, and others represent the original text. Same below)
@-87,6 + 87,8 @@
# Define leaf_level 1/* level # For leaves */
# Define poweroftwo 16

+ Class cbqueue;
+

Class cbqclass: Public connector {
Public:
Friend class cbqueue;

5. Problem log:

Tora_neighbor.h:
./Tora/tora_neighbor.h: 72: Error: iso c ++ forbids declaration of 'toraagent' with no type
./Tora/tora_neighbor.h: 72: Error: Expected '; 'before' * 'token
Make: *** [Tora/Tora. O] Error 1

Use the following patch:
@-41,6 + 41,8 @@
# Ifndef _ tora_neighbor_h __
# DEFINE _ tora_neighbor_h __

+ Class toraagent;
+

Enum linkstatus {
Link_up = 0x0001, // upstream
Link_dn = 0x0002, // downstream

6. Problem log:

Diffusion3/ns/diffagent. CC error,
./Diffusion3/diffusion. hh: 97: Error: Expected ') 'before' * 'token

Use the following patch
-99,6 + 99,7 @@
Class diffusioncoreagent;
Class hashentry;
Class neighborentry;

+ Class diffroutingagent;

Typedef list neighborlist;
Typedef list hashlist;

7. Problem log:
Ore-I./Asim/-I./QS-I./DiffServ-I./satellite-I./WPAN-o
Trace/trace. o
Trace/trace. CC
./Sctp. h: 705: Error: extra qualification
'Sctpagent: 'on member
'Dumpsendbuffer'
Make: *** [trace/trace. O]
Error 1
Solution:
Remove 'sctpagent: 'from the first row of dumpsendbuffer function in the file sctp. h.

8. Problem log:
Checking System Version (for dynamic loading).../configure: Line 7624:
Syntax Error near unexpected token ')'./configure: Line 7624: 'osf *)'
Tcl8.3.2 configuration failed! Exiting...
TCL is not part of
NS project. Please see
Www.scriptics.com <: URL: http://www.scriptics.com/> to see
If they have a fix for your platform.
Solution:
(1) Go to the following directories respectively:
Tcl8.x. X/Unix/TCL. M4,
Tk8.x. X/Unix/TCL. M4,
Otcl-1.x/configure. In.
Replace
System = MP-RAS-'awk' {print $3} '/etc/. relid''
Changed:
System = MP-RAS-'awk' {print $3} '/etc/. relid'

(2)
Tcl8.x. X/Unix/
Tk8.x. X/Unix/
Otcl-1.x/
Run in Directory
Antoconf ).

9. Problem log:
./Mobile/God. h: 88: Error: there are additional limitations: 'vector: 'on the member 'operator ='
./Mobile/God. h: 93: Error: there are additional limitations: 'vector: 'on the member 'operator + ='
./Mobile/God. h: 98: Error: there are additional limitations: 'vector: 'on the member 'operator ='
./Mobile/God. h: 101: Error: there are additional limitations: 'vector: 'In the member 'operator! = 'Upper
Make: *** [src_rtg/sragent. O] Error 1
NS make failed!
See
: URL: http://www.isi.edu/nsnam/ns/ns-problems.html for Problems
Solution:
Remove 'vector: 'from these files. (Same as Issue 1)

10. Problem log:
DSR/dsragent. CC: 828: Error: 'xmitflowfailurecallback' has not been declared in this scope
DSR/dsragent. CC: In member function 'void dsragent: sendoutpacketwithroute (srpacket &, bool, time )':
DSR/dsragent. CC: 1385: Error:
'Xmitfailurecallback' has not been declared in this scope
DSR/dsragent. CC: 1386: Error:
'Xmitflowfailurecallback' has not been declared in this scope
DSR/dsragent. CC: 1403:
Error: 'xmitfailurecallback' has not been declared in this scope
Make :***
[DSR/dsragent. O] Error 1
NS make failed!
See: URL: http://www.isi.edu/nsnam/ns/ns-
Problems.html for Problems
Solution:
(You just need to make a pre-declaration for these functions)
They were declared at the end of the file without a Forward Declaration. if so, you just need to move it to the beginning of the file or add an Forward Declaration for the function at the beginning.

11. Problem log:
Diffusion/diffusion. CC: 427: Error: 'xmitfailedcallback' has not been declared in this scope
Make: *** [diffusion/diffusion. O] Error 1
NS make failed!
The solution is the same as problem 10.

12. Problem log:
TCP/tcp-sack-rh.cc: 68: Error: there are additional limits 'sackrhtcpagent ::'
On the member 'newack'
Make: *** [TCP/tcp-sack-rh.o] Error 1
NS make failed!
See: URL: http://www.isi.edu/nsnam/ns/ns-problems.html for Problems
The solution is the same as problem 2 or 3.

13. Problem log:
PGM/pgm-agent.cc: 307: Error: there are additional limits 'pgmagent: 'on the member 'trace _ event'
Make: *** [PGM/pgm-agent.o] Error 1
NS make failed!
The solution is the same as problem 2 or 3.

14. Problem log:
PGM/pgm-sender.cc: 189: Error: there are additional limits 'pgmsender: 'on the member 'trace _ event'
Make: *** [PGM/pgm-sender.o] Error 1
NS make failed!
The solution is the same as problem 2 or 3.

15. Problem log:
PGM/pgm-receiver.cc: 186: Error: there are additional limits 'pgmexper: 'on the member 'trace _ event'
Make: *** [PGM/pgm-receiver.o] Error 1
NS make failed!
The solution is the same as problem 2 or 3.

16. Problem log:
Netgraph. h: 71: Error: there are additional limitations: 'netgraph: 'on the member 'render'
Make: *** [graphview. O] Error 1
Nam make failed! Continue...
The solution is the same as problem 2 or 3.

17. Problem log:
Parser. h: 97: Error: there are additional restrictions: 'parsetable: 'on the member 'nam4wpan'
Parser. h: 98: Error: there are additional restrictions: 'parsetable: 'on the member 'wpan _ bradius'
Node. h: 226: Error: there are additional restrictions: 'node: 'on the member 'gettclscriptlabel'
Make: *** [netview. O] Error 1
Nam make failed! Continue...
The solution is the same as problem 2 or 3.

18. Problem log:
./Diffusion3/filter_core/filter_core.hh: 111: Error: Expected ') 'before' * 'token
Make: *** [diffusion3/ns/diffagent. O] failed!
Solution:
Edit ns-2.27/diffusion3/filter_core/filter_core.hh, the application patches are as follows:
Class diffusioncoreagent;
Class hashentry;
Class neighborentry;
+ Class diffroutingagent;
Typedef list neighborlist;
Typedef list hashlist;

19. Problem log:
For the NAM problem, a patch has been provided for some time (you can search in NS-list archive of SEP. or Oct .), which simply replaces the 'null' On Line 73 of 'agent. h' with '0'
(That is, open the agent. h file, and change the null value of row 73rd to 0)

20. LastAfter the installation is complete, you must configure the environment variables. After the installation is complete, the page prompts you to configure environment variables. In the user directory root, enter gedit ~ /. Bashrc configure environment variables. Add the followingCode:
Export ns_home =/root/ns-allinone-2.28
Export Path = "$ ns_home/nam-1.11: $ ns_home/tcl8.4.5/Unix: $ ns_home/tk8.4.5/Unix: $ ns_home/bin: $ path"
Export LD_LIBRARY_PATH = $ ns_home/tcl8.4.5/Unix: $ ns_home/tk8.4.5/Unix: $ ns_home/otcl-1.9: $ ns_home/lib: $ LD_LIBRARY_PATH
Export tcl_library = $ ns_home/tcl8.4.5/Library

So far,The main problem of ns2.28 installation in the high-version GCC environment has come to an end. We recommend that you use ns2.33 or a later version. Unless you have special requirements, you have to use the earlier NS software.
For more information about how to install ns2.33, see my previous blog... which is much simpler ~~

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.