Setting up a wireless Testbed…(Host-AP drivers)

S#1: Machine A Master Mode and Machine B Managed Mode.

Machine A:

$sudo iwconfig wlan0 mode Master
$sudo iwconfig wlan0 essid “Hello-1″

Set the Static IP Address: 10.10.5.2 Mask: 255.0.0.0

root@Ubuntu-01:/etc/network# iwconfig wlan0
Warning: Driver for device wlan0 has been compiled with version 19
of Wireless Extension, while this program supports up to version 18.
Some things may be broken…

wlan0 IEEE 802.11b ESSID:”Hello-1″
Mode:Master Access Point: 00:00:00:00:00:00 Bit Rate:11 Mb/s
Sensitivity=1/3
Retry min limit:8 RTS thr:off Fragment thr:off
Encryption key:off
Power Management:off
Link Quality:0 Signal level:0 Noise level:0
Rx invalid nwid:0 Rx invalid crypt:0 Rx invalid frag:0
Tx excessive retries:0 Invalid misc:0 Missed beacon:0

root@Ubuntu-01:/etc/network# ifconfig wlan0
wlan0 Link encap:Ethernet HWaddr 00:02:6F:34:0B:79
inet addr:10.10.5.2 Bcast:10.255.255.255 Mask:255.0.0.0
inet6 addr: fe80::202:6fff:fe34:b79/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:69 errors:0 dropped:1 overruns:0 frame:0
TX packets:63 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:4970 (4.8 KiB) TX bytes:5220 (5.0 KiB)
Interrupt:3 Base address:0×3100

Machine B:

$sudo iwconfig wlan0 mode Managed

Set the Static IP Address: 10.10.5.3 Mask: 255.0.0.0

Important : Gateway wlan0
Connect to EssID : Hello-1

fawad@nicta123:~$ iwconfig wlan0
Warning: Driver for device wlan0 has been compiled with version 19
of Wireless Extension, while this program supports up to version 18.
Some things may be broken…

wlan0 IEEE 802.11b ESSID:”Hello-1″
Mode:Managed Frequency:2.422 GHz Access Point: 00:02:6F:34:0B:79
Bit Rate:2 Mb/s Sensitivity=1/3
Retry min limit:8 RTS thr:off Fragment thr:off
Power Management:off
Link Quality=56/70 Signal level=-19 dBm Noise level=-75 dBm
Rx invalid nwid:0 Rx invalid crypt:3 Rx invalid frag:0
Tx excessive retries:30 Invalid misc:12165 Missed beacon:0

fawad@nicta123:~$ ifconfig wlan0
wlan0 Link encap:Ethernet HWaddr 00:60:B3:29:92:EE
inet addr:10.10.5.3 Bcast:10.255.255.255 Mask:255.0.0.0
BROADCAST MULTICAST MTU:1500 Metric:1
RX packets:8799 errors:0 dropped:0 overruns:0 frame:0
TX packets:12472 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:853532 (833.5 KiB) TX bytes:1505635 (1.4 MiB)
Interrupt:3 Base address:0xe100

Now try pingning from the both ends. I think they should work.

S#2: Both Machine A & B in Ad-Hoc Mode.

Now in this case we have to see that in order for the machines to work in Ad-Hoc mode they should have same essid and channel.

Now lets configure machine A:

$sudo iwconfig wlan0 mode Ad-Hoc
$sudo iwconfig wlan0 channel 3
$sudo iwconfig wlan0 essid “Home”

fawad@Ubuntu-01:~$ iwconfig wlan0
Warning: Driver for device wlan0 has been compiled with version 19
of Wireless Extension, while this program supports up to version 18.
Some things may be broken…

wlan0 IEEE 802.11b ESSID:”Home”
Mode:Ad-Hoc Frequency:2.422 GHz Cell: 02:60:1B:27:92:EE
Bit Rate:11 Mb/s Sensitivity=1/3
Retry min limit:8 RTS thr:off Fragment thr:off
Power Management:off
Link Quality=56/70 Signal level=-40 dBm Noise level=-96 dBm
Rx invalid nwid:0 Rx invalid crypt:0 Rx invalid frag:0
Tx excessive retries:22 Invalid misc:40 Missed beacon:0

fawad@Ubuntu-01:~$ ifconfig wlan0
wlan0 Link encap:Ethernet HWaddr 00:02:6F:34:0B:79
inet addr:10.10.5.2 Bcast:10.255.255.255 Mask:255.0.0.0
inet6 addr: fe80::202:6fff:fe34:b79/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:144 errors:0 dropped:2 overruns:0 frame:0
TX packets:163 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:13304 (12.9 KiB) TX bytes:17560 (17.1 KiB)
Interrupt:3 Base address:0×3100

On Machine B:

$sudo iwconfig wlan0 mode Ad-Hoc
$sudo iwconfig wlan0 channel 3
$sudo iwconfig wlan0 essid “Home”

fawad@nicta123:~$ iwconfig wlan0
Warning: Driver for device wlan0 has been compiled with version 19
of Wireless Extension, while this program supports up to version 18.
Some things may be broken…

wlan0 IEEE 802.11b ESSID:”Home”
Mode:Ad-Hoc Frequency:2.422 GHz Cell: 02:60:1B:27:92:EE
Bit Rate:11 Mb/s Sensitivity=1/3
Retry min limit:8 RTS thr:off Fragment thr:off
Power Management:off
Link Quality=55/70 Signal level=-18 dBm Noise level=-73 dBm
Rx invalid nwid:0 Rx invalid crypt:0 Rx invalid frag:0
Tx excessive retries:52 Invalid misc:984 Missed beacon:0

fawad@nicta123:~$ ifconfig wlan0
wlan0 Link encap:Ethernet HWaddr 00:60:B3:29:92:EE
inet addr:10.10.5.3 Bcast:10.255.255.255 Mask:255.0.0.0
inet6 addr: fe80::260:b3ff:fe29:92ee/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:144 errors:0 dropped:0 overruns:0 frame:0
TX packets:271 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:13300 (12.9 KiB) TX bytes:24228 (23.6 KiB)
Interrupt:3 Base address:0xe100

Now try pinging each of the hosts i guess they should work.

Installing and updating the kernel to Linux-2.6.16 (Ubuntu – IDE)

1. Install Ubuntu 5.10.

2. To setup the root password, reboot the machine and press ESc to go into grub mode.

To to the recovery mode of Linux and press enter.

You will get to # prompt.

Type #passwd root, enter new password and reboot #init 6.

3. Goto System -> Administrator -> Networking and enable the eth0 card for networking support.

4. Goto System ->Administrator -> Synaptic Package Manager

5. Goto Settings -> Repositories. Add Community Maintained (Universe) and press OK.

6. Press “Reload” to update the package list.

7. Goto Terminal: and run all the following commands:

$sudo apt-get update
$sudo apt-get install build-essential
$sudo apt-get install kernel-package
$sudo apt-get install gcc
$sudo apt-get install libncurses5
$sudo apt-get install libncurses5-dev
$sudo apt-get install libqt3-mt-dev

8. Now configure ftp server to transfer new linux 2.6.16 files.

9. I will go for vsftp. You can also configure ftpd, ws-ftpd or proftpd etc.

To install vsftpd:

$sudo apt-get install vsftpd, This will install vsftpd server and start it.

Now we need to make some modifications to the configuration file.

comment #anonymous_enable=YES

Uncomment local_enable=YES

Uncomment write_enable=YES

Save this file and restart vsftpd by running this command. $sudo /etc/init.d/vsftpd restart

10. Upload linux-2.6.16.tar using ftp.

11. copy linux-2.6.16.tar to /usr/src/ folder.

12. cd /usr/src

13. $sudo tar –bzip2 -xvf linux-2.6.12.tar.bz2

14. $sudo ln -s /usr/src/linux-2.6.12 /usr/src/linux

15. Run $sudo make menuconfig or $sudo make xconfig to configure your new kernel.

16. $sudo make-kpkg clean

17. $sudo make-kpkg -initrd –append-to-version=-custom kernel_image modules_image kernel_headers

18. $sudo dpkg -i kernel-image-2.6.16-custom_10.00.Custom_i386.deb
19. $sudo dpkg -i kernel-headers-2.6.16-custom_10.00.Custom_i386.deb

20. Reboot the system $sudo init 6.

C Programming

Creating a Library File .a and .so

.a

26 gcc -c bar.c foo.c
28 gcc -c program.c
33 gcc -o program program.o foo.o bar.o
36 ar crv libfoo.a bar.o foo.o

.so

39 gcc -fPIC -g -c -Wall bar.c
40 gcc -fPIC -g -c -Wall foo.c
42 gcc -shared -Wl,-soname,libfoo.so.1 -o libfoo.so.0.1 foo.o bar.o -lc

My First Makefile:
——————

myapp: program.o foo.o bar.o
gcc -o myapp program.o foo.o bar.o
program.o: program.c lib.h
gcc -c program.c
foo.o: foo.c lib.h
gcc -c foo.c
bar.o: bar.c lib.h
gcc -c bar.c

save it as Makefile and run $make to excecute

Installing Java on Ubuntu…

http://ubuntuguide.org/wiki/Ubuntu_Edgy#How_to_install_Java_Development_Kit_.28JDK.29_v5.0

How to install Java Development Kit (JDK) v5.0

Note: Program included in Automatix2. I you have already used Automatix2, this program may have been installed

* Read #General Notes
* Read #How to add extra repositories

sudo apt-get install sun-java5-jdk

* Accept the licence agreement that appears.

* Set Sun’s JVM as default Java version:

sudo update-java-alternatives -s java-1.5.0-sun

* Edit /etc/jvm and move /usr/lib/jvm/java-1.5.0-sun to the top of JVMs offered:

gksudo gedit /etc/jvm

Setting Up a Web-Service Core Engine Based on Axis2…

Main Web Page of Axis2: http://ws.apache.org/axis2/

Now we will follow the installation guide:
http://ws.apache.org/axis2/1_1/installationguide.html

Downloading and installing ANT:
Download Page : http://ant.apache.org/bindownload.cgi
Installation Page : http://ant.apache.org/manual/index.html

Downloading and installing Maven:
http://maven.apache.org/
Download Page : http://maven.apache.org/download.html
Install guide : http://maven.apache.org/maven-1.x/start/install.html

Deploy axis2.war in the tomcat servlet engine.
Login for axis2 admin console:
username: admin
password: axis2

Levo

tar -xvfj snapgear-3.3.0-avila.tar.bz2

bzip2 -d snapgear-3.3.0-avila.tar.bz2

This generate snapgear-3.3.0-avila.tar from snapgear-3.3.0-avila.tar.bz2

# cd /usr/src
# tar -xfj /cdrom/Source/snapgear-3.3.0-avila.tar.bz2
# cd snapgear
# make dep
# make

cd /usr/src
tar -xvf /home/fawad/project/Levo/GW15002_Rev_0.6/Source/snapgear-3.3.0-avila.tar

Learning XPath…

Ref: http://www.w3schools.com/xpath/xpath_nodes.asp

mount seagate USB hardrive in Ubuntu

fawad@fawad-laptop:/media/usb$ sudo mount -t vfat /dev/sdb1 /media/usb

If this does not work you can also try with /dev/sdc1 (if we have an SATA drive as /dev/sda).

Extraction and Analysis of Tripartite Relationships from Wikipedia

Abstract: Social aspects are critical in the decision making process for social actors (human beings). Social aspects can be categorized into social interaction, social communities, social groups or any kind of behavior that emerges from interlinking, overlapping or similarities between interests of a society. These social aspects are dynamic and emergent. Therefore interlinking them in a social structure using two levels of correspondence in a bipartite affiliation network may result into isolated graphs and is not robust. The major reason is that these correspondences are dynamic and emergent therefore they should be coupled with more than single affiliation in order to sustain the interconnections during interest evolutions. In this paper we propose to interlink actors using multiple tripartite graphs rather than a bipartite graph which was the focus of most of the previous social network building techniques. The utmost benefit of using tripartite graph is that we can have multiple and hierarchical links between social actors therefore if anyone of the link is eliminated due to interest change, still we have a connection between users at a level higher than that. Therefore in this paper we discuss the extraction methods, plotting methods and analysis methods of tripartite relations between Authors, articles and categories from Wikipedia. Furthermore, we also discuss the advantages of tripartite relationships over bipartite relationships. As a conclusion of this paper we argue that to build useful, robust and dynamic social networks, actors should be linked in one or more tripartite networks.

This paper is accepted for publication at : 2008 IEEE International Symposium on Technology and Society (ISTAS 2008), Frederiction, New Brunswick, Canada.

Related Conferences for year 2008

http://socialnets2008.msra.cn/ : February 22, 2008

http://www.business.otago.ac.nz/infosci/Conferences/Isn2008/ : 27 February 2008

http://www.apnoms.org/2008/ : May 9, 2008

http://www.grid2008.org/ : Apr.18, 2008

http://ekaw2008.inrialpes.fr/ : April 21st, 2008

http://www.ipmz.uzh.ch/asna : Abstract submission by June 1

http://www.p2p08.org/ : Abstract submission deadline: April 13, 2008