Obtaining and installing cnet

The most recent public release of cnet is available from:

http://www.cs.uwa.edu.au/cnet/cnet-1.6.tar.gz (23rd June 2000)

The full distribution (about 410KB) includes all source code, Makefiles, documentation, sub-directories for each of the supported operating systems, and a few representative protocol examples.

cnet is supported only on the following platforms:

Linux (kernel 2.x, ELF only), DEC-OSF/1 (v4.0), SunOS 4.1.x, Solaris 2.x, and SGI IRIX (Rel. 5 or 6).

In particular, cnet does not run on either Windows or the Apple Macintosh.

Please appreciate that there are thousands of students worldwide using cnet. I am unable to respond to individual questions about cnet, unless they are from students enrolled in a course that I'm presenting. Please ask your professor or instructor.

If you find these instructions confusing, but eventually get cnet installed, please email chris@cs.uwa.edu.au with any suggestions on how the instructions could be clearer.

line

Requirements

To install cnet you should be prepared and able to:

line

Installation

  1. To begin installation, copy the distribution file and unpack it with the command:

    gunzip -c cnet-1.6c.tar.gz | tar xvf - or
    tar zxvf cnet-1.6c.tar.gz
  2. Change to the newly created directory cnet-1.6c
  3. Make a new publically-readable directory, such as /usr/lib/cnet (chmod 755).
  4. Copy all files from ./cnetlib to this newly created public directory. Ensure that all files are world-readable (chmod 644).
  5. Change directory to ./src.
  6. Read and modify the C #defines in config.h, such as the full pathname of the C compiler and linker on your system. In particular, ensure that your new publically-readable directory is recorded in the value of CNETPATH.
  7. Read and change site-specific constants in the Makefile for the operating system you'll be using (Makefile.linux, Makefile.sunos ...) Typically, you'll need to modify (or uncomment) CC, CFLAGS, INCLUDES, XINCLUDES, LIBDIRS, LIBS, XLIBS, BINDIR and MANDIR.
  8. If running a Linux(ELF) system and your system doesn't provide the libelf package, you'll need the libelf package provided in the distribution. Change directory to linuxelf and uncompress and untar the libelf-0.6.4 package.
  9. Change directory back (up) to ..
  10. Type 'make' to build cnet for your system (it should compile and link without error).
  11. Type 'make install' (perhaps as root) to copy the cnet binary and manual to their required (global) locations.

line

Installation restrictions

You should note the following requirements and restrictions for various systems:

line

Testing

There are some introductory examples (such as may be used as student introductions to cnet) in the EXAMPLES directory. These are the sort of things an academic staff member may set as introductory exercises, or to assist students to "get up to speed" quickly. You should now be able to execute these examples from the command-line with the commands:

    cnet TICKTOCK
    cnet STOPANDWAIT
    cnet FLOODING1

Each example has its own topology file defining the network to be simulated, for example T2, CLICK, and FLOODING1.

When cnet appears to work, the example files such as {TICKTOCK + ticktock.c}, {CLICK + click.c}, {KEYBOARD + keyboard.c}, {LINKSTATE + linkstate.c}, and {STOPANDWAIT + stopandwait.c} in the EXAMPLES directory should all be placed in a system-wide examples directory for everyone to copy and run.

REMEMBER:
If you can demonstrate that you are a member of academic staff somewhere (business card, FAX on University letterhead, or official Web page), I'll email some more detailed examples to you - ones that may typically be set for student projects.

line
cnet was written and is maintained by Chris McDonald (chris@cs.uwa.edu.au)