
INSTALLATION EXAMPLE
====================

  Below is an example of the whole installation of NetBEUI extension
using custom installation for Linux 2.0.35 and SAMBA 2.0.6 :

*** Note : Make sure your samba (2.0.0 and later) is configured ***
# cd /usr/local/samba-2.0.6/source 
# configure

# cd /usr/local/netbeui

*** Note : Specifying SAMBA version is essential here ***
# vi Makefile

# make install

Adding NetBEUI to the KERNEL
Modifying the files in the kernel tree
The kernel version is 2.0.35
/usr/src/linux/net/Makefile updated
/usr/src/linux/net/Config.in updated
/usr/src/linux/include/linux/proc_fs.h updated
/usr/src/linux/include/linux/socket.h updated
/usr/src/linux/net/core/Makefile updated
/usr/src/linux/net/netsyms.c updated
/usr/src/linux/net/802/p8022.c updated
/usr/src/linux/net/802/p8022tr.c updated
/usr/src/linux/net/802/tr.c updated
/usr/src/linux/include/linux/trdevice.h updated
Copying NetBEUI files ...
Copying LLC files ...
Copying include files ...

Adding NetBEUI to SAMBA
SAMBA version is 2.0.xx
Patching client.c ...
Patching includes.h ...
Patching nameserv.h ...
Patching smb.h ...
Patching interface.c ...
Patching util.c ...
Patching util_sock.c ...
Patching clientgen.c ...
Patching nmblib.c ...
Patching nmbd.c ...
Patching nmbd_become_lmb.c ...
Patching nmbd_packets.c ...
Patching nmbd_workgroupdb.c ...
Patching password.c ...
Patching reply.c ...
Patching server.c ...
Patching Makefile ...
Patching SAMBA files finished successfully.
Making and installing NetBEUI utilities
make[1]: Entering directory `/opt/src/netbeui/pkg/source/utils'
gcc -c nbadmin.c
gcc nbadmin.o -o nbadmin
gcc -c nbstatus.c
gcc nbstatus.o -o nbstatus
make[1]: Leaving directory `/opt/src/netbeui/pkg/source/utils'

# cd /usr/src/linux
# make config
*
*
NetBEUI Protocol (CONFIG_NETBEUI) [M/n/y/?]M
The IPX protocol (CONFIG_IPX) [N/y/m/?]

# make dep
# make zlilo
.
.
# make modules
.
.
# make modules_install
.
.
# reboot
(ZZZZZzzzzz)

# cd /usr/local/samba-2.0.6/source 
# make clean
# make proto
# make all



HOW TO INSTALL NETBEUI 
======================

There are two ways for installing NetBEUI on a Linux system:

	1. Express installation - Easy installation in only one step.

	2. Custom installation - More controlled installation in 5 steps.
		Useful while express installation has some errors.


1. EXPRESS INSTALLATION
-----------------------

STEP 0. Edit the Makefile and specify needed information. These are 
	needed for installation script and should be done before any
	make command issue. You may specify the following:

	- Specify your kernel directory source path. The default 
	  path is /usr/src/linux.

	- Specify your SAMBA directory source path. The default path
	  is /usr/local/samba. 

**IMPORTANT**
	- You MUST specify your current SAMBA release in one of the 
	  forms 1.9.x or 2.0.x. This is essential for the installation
	  script to work. You can simply uncomment one of the lines
	  matching with your SAMBA release.

**IMPORTANT**
	- If using SAMBA 2.0.x, make sure that SAMBA is configured
	  before adding the NetBEUI extension.

**IMPORTANT**
	- Make sure that the kernel has support for loadable modules or
	  NetBEUI can never start up on your system.


STEP 1. Just go ahead with:

		make world
	
	You perhpas need to take a cup of coffee and wait about 10
	to 15 minutes for the whole job to get finished!

	Then REBOOT YOUR SYSTEM and boot again with the new kernel, 
	then go to HOW TO USE section in this document. 

	NOTE: During the make process, the system will be reconfigured
	and you'll be asked for new configuration. Just push ENTER to
	pass through old configuration except the brand new configuration
	'NetBEUI protocol' which is introduced below 'Networking Options'.
	Make sure to enter 'M' in front of this option to configure the
	NetBEUI as a kernel loadable module.


2. CUSTOM INSTALLATION
----------------------

STEP 0. Edit the Makefile and specify needed information. These are 
	needed for installation script and should be done before any
	make command issue. You may specify the following:

	- Specify your kernel directory source path. The default 
	  path is /usr/src/linux.

	- Specify your SAMBA directory source path. The default path
	  is /usr/local/samba. 

**IMPORTANT**
	- You MUST specify your current SAMBA release in one of the 
	  forms 1.9.x or 2.0.x. This is essential for the installation
	  script to work. You can simply uncomment one of the lines
	  matching with your SAMBA release.

**IMPORTANT**
	- If using SAMBA 2.0.x, make sure that SAMBA is configured
	  before adding the NetBEUI extension.


STEP 1. To install NetBEUI code into kernel and SAMBA go ahead with
	the following:

		make install

	You can install either the kernel NetBEUI extension or just 
	the SAMBA NetBEUI extension by:

		make install_netbeui

		make install_smb

	For other tags and usage issue:

		make

STEP 2. If you didn't get any errors at the previous step, you NOW
	have got the extension on your system. Just go ahead with
	STEP 3. Otherwise, you should repeat the last two steps
	until you successfully add the extension to your system. 

STEP 3. Reconfigure your system kernel by going below the kernel 
	source path and issuing:
	
		make config
	or
		make menuconfig

	You can find 'NetBEUI Protocol' below 'Networking Options'
	menu. NetBEUI can be setup only as a kernel module for now, 
	so activate the tag by typing 'M' on it. Also note that you
	have had 'Loadable Modules support' enabled on your system
	in the main menu.

	You then should go on with making the kernel by:

		make dep

		make zImage

	and then making the NetBEUI modules by:

		make modules

	and installing the module among your other kernel modules by:

		make modules_install

STEP 4. Create a boot entry for NetBEUI kernel image in /etc/lilo.conf and
	update the LILO (You can get more information by reading the 
	manpages of lilo.conf) and then REBOOT YOUR SYSTEM by:

		lilo; reboot

	And boot up using NetBEUI kernel image. To test if the modules 
	for NetBEUI are properly installed, you can either start or stop 
	the NetBEUI by the following:

		netb start
	or
		netb stop

STEP 5. For SAMBA extension, there's only one more step to rebuild
	SAMBA by issuing:

		make clean 
		make proto
		make all

	right below SAMBA source path on your system. (Note that 'make
	proto' is ESSENTIAL after the first installation of NetBEUI and
	before the first 'make all' of SAMBA. It's also quite the same
	after the first uninstallation of NetBEUI)

