Step by step guide to install Castalia in fedora 10:

Step 1:
Untar and unzip the Castalia package:
# tar –xvzf Castalia-1.3.tar.gz

Step 2:
A new directory will be created ‘Castalia-1.3’
Direct to the ‘config’ folder reside in ‘Castalia-1.3’ folder and edit the ‘Castalia.config’ file:
# cd Castalia-1.3/config
# vi Castalia.config
Change the following line:
ROOT=$(HOME)/YOUR_PATH_TO_CASTALIA
into
ROOT=$(HOME)/username/Castalia-1.3

Remark: Make sure that the path that you set is correctly pointed to the Castalia folder or else you have problem make it.
Remark: Press “i” key to insert line to Castalia.config after finish editing press “Esc” key follow by “:” key and type “wq” to write and quit from vi.

Step 3:
Change back to the Castalia home directory and run the command mkmk:
# cd ..
# ./mkmk

Step 4:
The Makefile should be generated by now, proceed with the usual built command:
# make

After finish make, check the directory Castalia/bin for the generated binary/executable file CastaliaBin.

*success* ^_^

Download the User manual and start coding!!!

All download, documentation and installation steps can be gain from http://castalia.npc.nicta.com.au/index.php

Advertisements

The instructions below describe the step-by-step guide on installing omnet++ in fedora 10:

The following packages need to be install before the omnet++ installation:
1. TCL/TK
2. BLT

Step 1: Installing TCL/TK
From the terminal extract tcl package in home directory:
# tar -xzf tcl8.4.18-src.tar.gz
Proceed by entering to the unix directory:
# cd tcl8.4.18/unix
# ./configure
# make
# make test
# make install

As above, from the terminal extract tk package in the same directory:
# tar -xzf tk8.4.18-src.tar.gz
Proceed by entering to the unix directory:
# cd tk8.4.18/unix
# ./configure–with-tcl=/usr/local/lib
# make
# make install

Remark: if error occur regarding during the installation please refer to the post "NS-2 in Fedora 10" and follow the solution at Step 5.

Step 2: Installing BLT
Extract the BLT package:
# tar -xzf BLT2.4z.tar.gz
Enter into the blt directory:
# cd blt2.4z
# ./configure --with-tcl=/usr/local/lib
# make
Enter into the demos directory and test the demo, a graphical window appear with 2 large fishes:
# cd demos
#./graph1.tcl
Entering back to blt directory and finish with the installation:
# cd ..
# make install

Step 3: Installing Omnet++
Download Omnet++ from http://www.omnetpp.org/filemgmt/index.php

Again, extract the Omnet++ to the home directory:
# tar zxvf omnetpp-3.3p1-src.gz

Before the installation took place we need to set the appropriate path at ./bashrc
At the terminal edit .bashrc:
# vi /root/.bashrc
Enter the following line to .bashrc:
------------------------------------------------------------------------------------
export PATH=$PATH:/home/omnetpp-3.3p1/bin
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/home/omnetpp-3.3p1/lib:/usr/local/lib
export TCL_LIBRARY=/usr/local/lib/tcl8.4
------------------------------------------------------------------------------------
Remark: Press "i" key to insert line to ./bashrc after finish editing press "Esc" key follow by ":" key and type "wq" to write and quit from vi.

Next, we need to edit the 'configure.user' file reside in omnetpp3.3p1 directory by comment out the line:
TK_CFLAGS=" -I/usr/local/include"
TK_LIBS=" -L/usr/local/lib -ltcl8.4 -ltk8.4"

Now we can proceed with the installation:
# ./configure
Make sure you see this before proceed to make:
Your PATH contains /home/omnetpp-3.3p1/bin. Good!
Your LD_LIBRARY_PATH is set. Good!
TCL_LIBRARY is set. Good!

# make
After make, test the samples at omnetpp/samples/dyna:
# cd dyna
# ./dyna

A network consist of server,switch and computer will appear.

*success* ^_^

Reference from the instruction above: http://blog.163.com/mchen_6431/blog/static/3228631220086210366137/#

To install NS-2 in FEDORA 10 i have followed the instructions from this url: http://www.edaboard.com/ftopic297674.html

Step 1:
Make sure your computer is connected to the internet and Please log in as a superuser so that you have permission to do as follow.
At the terminal please type the following to install the packages dependencies:
—————————————
yum install autoconf
yum install automake
yum install gcc-c++
yum install libX11-devel
yum install xorg-x11-proto-devel
yum install libXt-devel
yum install libXmu-devel
—————————————

Step 2:
Download NS-allinone-2.33 package from sourceforge.net and do as follow at directory of your choice.
At home directory extract the ns file:
# tar -xzf ns-allinone-2.33.tar.gz
Proceed by entering to the ns directory:
# cd ns-allinone-2.33
# ./install

Step 3:
After Step 2, still at the terminal type:
# vi /root/.bashrc
To insert text please press the “i” key then add the following lines to the ./bashrc

—————————————
# LD_LIBRARY_PATH
OTCL_LIB=/home/username/ns-allinone-2.33/otcl-1.13
NS2_LIB=/home/username/ns-allinone-2.33/lib
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$OTCL_LIB:$NS2_LIB

# TCL_LIBRARY
TCL_LIB=/home/username/ns-allinone-2.33/tcl8.4.18/library
export TCL_LIBRARY=$TCL_LIB

# PATH
XGRAPH=/home/username/ns-allinone-2.33/bin:/home/username/ns-allinone-2.33/tcl8.4.18/unix:/home/username/ns-allinone-2.33/tk8.4.18/unix
NS=/home/username/ns-allinone-2.33/ns-2.33/
NAM=/home/username/ns-allinone-2.33/nam-1.13/
PATH=$PATH:$XGRAPH:$NS:$NAM
—————————————

Remark: Press the “Esc” key follow by the “:”(shift+;) key then type the letters “wq” to write and quite from the terminal.

Let the environment variable that you set take effect immediately by typing the following at the terminal:
# source ~/.bashrc
or
you can choose to restart your computer

Step 4:
The NS should be working by now by typing:
$ ns
the symbol “%” should appear, press ctrl+c to exit from it.

Step 5:
The following error occur when i type “nam” at the terminal:

—————————————

: no event type or button # or keysym
while executing
"bind Listbox {
%W yview scroll [expr {- (%D / 120) * 4}] units
}"
invoked from within
"if {[tk windowingsystem] eq "classic" [tk windowingsystem] eq "aqua"} {
bind Listbox {
%W yview scroll [expr {- (%D)}] units
}
bind Li..."
---------------------------------------

I found the solution at the following url:http://victorgau.blogspot.com/2008/12/ns2-233-nam.html

1. Download tk-8.4.18-tkBind.patch from http://bugs.gentoo.org/show_bug.cgi?id=225999
2. Put the patch file in the ns-allinone-2.33 directory and patch it:
patch -p0 < tk-8.4.18-tkBind.patch
3. after this step please type ./install again at the NS directory

After this when you type "nam" at the terminal you shall see the nam GUI.

Step 6
Validate the NS by typing:
# ./validate

Step 7
Start by looking at the example provided by NS in the ex folder:
# cd /home/username/ns-allinone-2.33/ns-2.33/tcl/ex
# ns wireless-flodding.tcl

Feel free to explore your newly install NS-2.