Install ns-2.26 on Ubuntu

June 4, 2008

Background

Ah, ns-2…the bane of many grad student’s existence. NS-2 is useful for a variety of researches related to networking. However, there might be difficult to install all the necessary packages of ns-2 in any platform. Installing the latest version of ns-2 (ns-2.33) with gcc 4.1.2 isn’t difficult at all because the source code has mapped to the current gcc configuration. Even though there is a small bug in ./configure of tk, tcl, otcl, less attempt has been done compare to the older version. This guidance based on my own experience and information from website.

The old version such as ns-2.26 won’t compile successfully with current gcc 4.1.2. So we’ve to install the gcc-2.95.

HOWTO

  1. Download the all-in-one package of ns-2 and unzip it:
    cd /usr/local/dload;
    wget http://www.isi.edu/nsnam/dist/ns-allinone-2.26.tar.gz;
    tar -xzvf ns-allinone-2.26.tar.gz;
  2. I had to install the following Debian packages:
    • apt-get install gcc-2.95
    • apt-get install g++-2.95
    • apt-get install libstdc++2.10-glibc2.2
    • apt-get install libx11-dev
    • apt-get install libxt-dev
  3. In my shell (tcsh), there were several changes needed in the configure files to compensate for stricter parsing. All lines of the form:
    system=MP-RAS-`awk ‘{print }’ /etc/.relid’`

    need changed to:

    system=MP-RAS-`awk ‘{print }’ /etc/.relid`

    That is, the second to last character (') needs to be deleted. In ns-allinone-2.26, this occurs in four places (files and line numbers):

    ./tcl8.3.2/unix/configure:4701
    ./tcl8.3.2/unix/configure:5705
    ./tk8.3.2/unix/configure:1520
    ./otcl-1.0a8/configure:4167
  4. Set your compiler environment variables in the terminal in which you will run the install script such that they point to the 2.95 version of the tools instead of the default ones. In the C shell:
    setenv CC /usr/bin/gcc-2.95;
    setenv CPP /usr/bin/cpp-2.95;
    setenv CXX /usr/bin/g++-2.95;

    Use the paths appropriate for your system. If you use the bash shell, the general form for setting an environment variable is:

    export CC=/usr/bin/gcc-2.95;

    Now, the configure scripts will use these versions of the compiler tools.

  5. When compiling the TCL/C++ interface (e.g., tclcl-1.0b13), I received a warning that stopped the compilation that line 193 of /usr/include/sys/types.h does not declare anything. Though this is not generally recommended, I used the -fpermissive option for the compiler to continue compilation.

    In the file /usr/local/dload/ns-allinone-2.26/tclcl-1.0b13/Makefile.in, I changed the CCOPT parameter on line 56 to be:

    CCOPT = -fpermissive @V_CCOPT@
  6. At this point, I just had to run the install script an everything compiled (with lots of warnings) except for nam which I didn’t need since I don’t use the visualization tools in ns-2.
    /usr/local/dload/ns-allinone-2.26/install

    (Make sure you run this in the terminal in which the CC, CPP, and CXX variables are set appropriately)

  7. Now, to get your existing ns-2 code to compile (i.e., the code in /usr/local/ns-2.26), you need to reconfigure your Makefile by specifying the new paths:
    cd /usr/local/ns-2.26; ./configure –with-tcl=/usr/local/dload/ns-allinone-2.26/tcl8.3.2 –with-tk=/usr/local/dload/ns-allinone-2.26/tk8.3.2 –with-otcl=/usr/local/dload/ns-allinone-2.26/otcl-1.0a8 –with-tclcl=/usr/local/dload/ns-allinone-2.26/tclcl-1.0b13

    Note that this will overwrite your existing Makefile, so if there was anything specific that you needed in it, you should move those commands to the Makefile.in file in /usr/local/ns-2.26.

Having fun…..


A Trip to Yokosuka Research Park

May 19, 2008

A tour has been organized by GITS to bring students to see and feel the cutting edge R&D of NTT DoCoMo. The tour brought us to Yokosuka Research Park where advanced high-tech of communications take place. Although a multi-companies plus government R&D were there, we were lucky enough to visit only NTT DoCoMo. The thing that most advanced researc institutes are kept in Yokosuka may be because Yokosuka is located in a valley where surrounded by mountains. This is better for signal propagation testing that causes less-harmful to residents. The tour has shown the mobile development that will transform the future life into ubiquitous environment.

For more detail about Yokosuka Research Park visit http://www.yrp.co.jp/en/

In front of NTT DoCoMo R&D @Yokosuka

 


Microsoft investment in Cambodia

May 4, 2008

A told that I would like to share from K7 newspaper is that Microsoft has recently started the investment for setting-up its local branch in Cambodia. It targets for Intellectual Properties of copy right and Windows in Khmer Language. A quote can be seen below:

ពីលី វង្ស (Pily Wong) មាន​សេចក្តី​ត្រូវការ​ចំនួនពីរ នោះគឺ​រថយន្ត និង​ព័ត៌មាន​ វិទ្យា។ ជនជាតិ​បារាំង​ដើម​កំណើត​ខ្មែរកាត់ចិន​រូប​នេះ​ គឺ​ជា​តំណាង​ស្រប​​ច្បាប់​ នៃ​ក្រុមហ៊ុន​ Mercedes ប្រចាំ​ប្រទេសកម្ពុជា​។ លោក​បាន​មក​រស់នៅ​ប្រទេស​ កម្ពុជា តាំងពី​៥ឆ្នាំមុន ហើយ​លោកទើប​តែ​សម្រេច​ក្តីស្រមៃ​ទីពីរ​របស់លោក​។  តាំងពី​ដើម​ខែ​មីនា​មក​ លោក​គឺជា​អគ្គ​នាយក​ក្រុមហ៊ុន Microsoft MDP  Cambodia ដែល​ជា​សាខាប្រចាំតំបន់​​ថ្មី​​មួយនៃក្រុមហ៊ុន​ដ៏​ល្បីល្បាញ​ក្នុង​ ពិភពលោក​។ អ្នក​ជំនួញ​​រូប​នេះ​មាន​អាយុ​៣២ឆ្នាំ បាន​បញ្ចប់​សញ្ញាបត្រ​ផ្នែក​ គណិតវិទ្យា ព័ត៌មានវិទ្យា និង​ពាណិជ្ជកម្មអន្តរជាតិ ហើយ​លោក​គឺ​ជា​អ្នកគ្រប់​ គ្រង​ការិយាល័យ​ដែល​មាន​សមាជិក​ប្រាំ​រូប ស្ថិត​នៅ​ភាគ​ខាង​ត្បូង​នៃ​មហាវិថី​ នរោត្តម។ លោក​បាន​​ពន្យល់​​លំអិតប្រាប់​កាសែត ពី​យុទ្ធសាស្ត្រ​នៃ​ក្រុមហ៊ុន​ដ៏​ ល្បីល្បាញ ដែល​ត្រូវ​បាន​បង្កើត​ឡើង​ដោយ​លោក ប៊ីល ហ្គេតនេះ ទាក់​ទង​ នឹងកំណើន​សេដ្ឋកិច្ច​ ការ​ការពារ​កម្មសិទ្ធិ​បញ្ញា និង​គំនិត​រៀប​ចំបង្កើត​​ Windows  ជា​ភាសា​ខ្មែរ។

Read more

To me, having Microsoft in Cambodia isn’t bad because it has been shown that IT industry getting growth. It is even better if Microsoft immediately starts implementing Windows Khmer version. However, the price of licensing the original Microsoft softwares versus our standard salary is still in debate for another decade.


Air-Powered Car First Ever Seen In The World

February 23, 2008

Air-car2009

The CityCAT, already being developed in India (bottom left), will be available for U.S. production in three different four-door styles. But it’s the radical dual-energy engine, with a possible 1000-mile range at 96 mph, that could move the Air Car beyond Auto X Prize dreams and into American garages.
 

Zero Pollution Motors (ZPM) confirmed on Thursday 21 Feb, 2008 that it expects to produce the world’s first air-powered car for the United States by late 2009 or early 2010. As the U.S. licensee for Luxembourg-based MDI, which developed the Air Car as a compression-based alternative to the internal combustion engine, ZPM has attained rights to build the first of several modular plants, which are likely to begin manufacturing in the Northeast and grow for regional production around the country, at a clip of up to 10,000 Air Cars per year.

And while ZPM is also licensed to build MDI’s two-seater OneCAT economy model (the one headed for India) and three-seat MiniCAT (like a SmartForTwo without the gas), the New Paltz, N.Y., startup is aiming bigger: Company officials want to make the first air-powered car to hit U.S. roads a $17,800, 75-hp equivalent, six-seat modified version of MDI’s CityCAT (pictured above) that, thanks to an even more radical engine, is said to travel as far as 1000 miles at up to 96 mph with each tiny fill-up.

Source: http://www.popularmechanics.com/automotive/new_cars/4251491.html?series=19


Panasonic offers big and fast SD card–for $700

February 13, 2008

Panasonic SDHC Panasonic announced a new SDHC (Secure Digital High Capacity) flash card on Tuesday that offers both high speed and lots of space for those willing to pay.

The 32-gigabyte card, called the RP-SDV32GU1K, is due to ship in April for about $700. It’s a high-speed “class 6″ card that can transfer data at speeds of 20MB per second–the world’s first at the 32GB capacity, Panasonic asserts.

SD is the dominant format for flash memory, and with the newer SDHC technology that extends capacity beyond 2GB, it’s begun spreading into space-gobbling videocameras. SanDisk, a top flash card brand, announced a 32GB SDHC card costing $350 in January, but it transfers data a notch slower, at 15MB per second.

One major flash card alternative to SD, CompactFlash, can transfer data at a maximum of 45MB per second. However, top transfer speeds are often more useful when copying files from a flash card, since cameras and videocameras often can’t write data at those top speeds.

Source: http://www.news.com/8301-13580_3-9870488-39.html?tag=nefd.top