Welcome to the CSIR Meraka Institute's "COIN" Blog

Monday, September 19, 2005

International Wireless Summit 2005

International Wireless Summit 2005, Aalborg, Denmark

The international wireless summit has just kicked off and I have the privilege of being amongst some of the greatest think-tanks in the wireless arena.

The aim of the IWS is to offer a platform for establishing exchanges of information between universities, industry and science parks. The next summit will be in 2008 in Helsinki, Finland.

International Wireless Symposium aims to exchange research information. 450 papers to be presented on “hot topics”.



Prof. Ramjee Prasad giving introductory speech.

Prof. Ramjee Prasad predicts that the future of wireless comms will be based on single layer technology, not quite sure what is meant by this though.

“Personal Networks are going to be of major importance in future business…”

Thursday, September 15, 2005

Creating an ipk package

TOOLS

Get the script rightfully called ipkg-build at, among other places, ftp://ftp.handhelds.org/packages/ipkg-utils, or http://www.mizi.com/download/mz20/ipkg-build.

CREATING THE PACKAGE STRUCTURE

Say you wanna create a package called MyPackage; you further wanna package the project called MyProject. Then do the following:

  1. Create a directory called MyPackage.
  2. Inside directory MyPackage, create a directory called CONTROL.
  3. Copy your project (MyProject) to the MyPackage directory.
  4. Inside directory CONTORL creating a file called control.

NOTE:

When the package is installed on the target, the MyPAckage directory will be created with respect to root. So if you wanted your files to be installed in /usr/bin on the target system, then our project would in this case be “/usr/bin”. That is you create inside directory MyPackage a directory called /usr/bin.

FORMAT AND CONTENTS OF /CONTROL/control

--------------------------------------------------------------------------------

Package: MyPackage

Priority: optional // default

Version: 1.0 //package version

Architecture: mipsel

Maintainer: I_maintain@you.com

Source: ftp:ftp:122.122.122.122 //See Note below

Section: misc //See Note below

Description: This is an attempt to create ipkg.

------------------------------------------------------------------------------------

NOTE:

The fields Section and Source seem rather useless to me in this example and I initially left them out; however the ipkg-build script complained requiring them, so I just put them in as a workaround without knowing/”caring” of their need. There are other fields not included here which you might need for your purposes, check the web for more.

Further the comments are mine for this documentation purposes only and the script MIGHT NOT permit comments.



RUNNING THE ipkg-build SCRIPT

Now simply run (of course being outside of the directory MyPackage):

“./ipkg-build –c –o root –g root MyPackage” // as root or non-root, or

“./ipkg-build –c MyPackage” //as root

IF all’s well, a package on the current directory will be created.

NOTE:

Without the “-c” option, I could not get the package installed successfully, you can try with or without and see for yourself.

Friday, September 09, 2005

Network stats on Freifunk

See: http://wiki.freifunk-leipzig.public-ip.org/index.php/LinksysNetzwerkStatisik for info on how to install web interface packages for network stats.
 
p.s. hows your german?

Thursday, September 08, 2005

How to stop dhcp client over-writing resolv.conf

Finally I found out how to do it

Edit the /etc/dhcp3/dhclient.conf file
Find the line that says request

Comment out the line that requests for domain-name, domain-name-servers and host-name

request subnet-mask, broadcast-address, time-offset, routers,
# domain-name, domain-name-servers, host-name,
netbios-name-servers, netbios-scope;

Setting up different networking scenarios on a laptop

I have always wanted to write some good scripts that configure my laptop for home and work wireless/ethernet automatically in ubuntu and so I set about building up a set of scripts that I can call.

I have four scenarios:
1. use laptop at home with wireless access point
2. use laptop at home with ethernet
3. use laptop at work with wireless access point
4. use laptop at work with ethernet

I created two files in /etc/network: interfaces.work and interfaces.home with all the ethernet and wireless settings for home and work in this file

/etc/network/interfaces.home
# This file describes the network interfaces available on your system
# and how to activate them. For more information, see interfaces(5).

# The loopback network interface
auto lo
iface lo inet loopback

# The primary network interface
iface eth0 inet static
address 10.3.13.102
netmask 255.255.255.0
gateway 10.3.13.1

#The wireless network interface
iface eth1 inet dhcp
wireless-essid pta-mesh
wireless-mode Ad-Hoc
wireless-channel 1
wireless-key off

/etc/network/interfaces.work
# This file describes the network interfaces available on your system
# and how to activate them. For more information, see interfaces(5).

# The loopback network interface
auto lo
iface lo inet loopback

# The primary network interface
iface eth0 inet dhcp

# The wireless network interface
iface eth1 inet dhcp
wireless-essid icomtek
wireless_mode Managed
wireless-key off

I also created two files with my dns and domain settings for home and work in /etc/ called resolv.home and resolv.work

resolv.home
search icomtek.csir.co.za elarduspark.org.za cids.org.za
nameserver 146.64.28.1 10.3.13.1

resolv.work
search icomtek.csir.co.za cids.org.za
nameserver 146.64.28.1


Here are my scripts that configure my interfaces based on the above files

1. Setup for wireless networking at home
/usr/local/bin/homenet-wireless

#!/bin/bash
echo Setting up network for home wireless network
sudo cp /etc/network/interfaces.home /etc/network/interfaces

eth0_status=`ifconfig | grep eth0`
eth1_status=`ifconfig | grep eth1`

if [ -n "$eth0_status" ]; then
sudo ifdown eth0
fi

if [ -n "$eth1_status" ]; then
sudo ifdown eth1
fi

sudo ifup eth1

sudo cp /etc/resolv.home /etc/resolv.conf

2. Setup for ethernet networking at home
/usr/local/bin/homenet-fixed
#!/bin/bash
echo Setting up network for home ethernet
sudo cp /etc/network/interfaces.home /etc/network/interfaces
sudo cp /etc/resolv.home /etc/resolv.conf

eth0_status=`ifconfig | grep eth0`
eth1_status=`ifconfig | grep eth1`

if [ -n "$eth0_status" ]; then
sudo ifdown eth0
fi

if [ -n "$eth1_status" ]; then
sudo ifdown eth1
fi

sudo ifup eth0

3. Setup for wireless at work
/usr/local/bin/worknet-wireless
#!/bin/bash
echo Setting up network for work wireless network
sudo cp /etc/network/interfaces.work /etc/network/interfaces
sudo cp /etc/resolv.work /etc/resolv.conf

eth0_status=`ifconfig | grep eth0`
eth1_status=`ifconfig | grep eth1`

if [ -n "$eth0_status" ]; then
sudo ifdown eth0
fi

if [ -n "$eth1_status" ]; then
sudo ifdown eth1
fi

sudo ifup eth1

4. Setup for ethernet at work
/usr/local/bin/worknet-fixed
#!/bin/bash
echo Setting up network for work ethernet
sudo cp /etc/network/interfaces.work /etc/network/interfaces
sudo cp /etc/resolv.work /etc/resolv.conf

eth0_status=`ifconfig | grep eth0`
eth1_status=`ifconfig | grep eth1`

if [ -n "$eth0_status" ]; then
sudo ifdown eth0
fi

if [ -n "$eth1_status" ]; then
sudo ifdown eth1
fi

sudo ifup eth0