File: README

package info (click to toggle)
netstd 3.07-7slink.3
  • links: PTS
  • area: main
  • in suites: slink
  • size: 6,312 kB
  • ctags: 9,027
  • sloc: ansic: 72,107; cpp: 6,144; makefile: 1,650; yacc: 1,614; sh: 1,164; perl: 308; awk: 46
file content (87 lines) | stat: -rwxr-xr-x 3,968 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
# Last updated : Tue Apr 16 17:27:46 1996
# $Revision: 1.3 $
# $Date: 1996/04/17 23:12:42 $
#
This code is based on the bootp client written by Charles Hawkins
<ceh@eng.cam.ac.uk> and tidied up a little by me.  I've added a few
things to make it conform to RFC1542 and it now parses RFC1497 BOOTP
magic cookies.  The Magic cookie parser is not complete, it ignores
the following TAGS:

	(2)  Time of Day,
	(13) BOOTP file size,
	(14) Merit dump filename
	(17) root pathname to mount
	(18) extentions, file to TFTP with more cookie in it.

Of there only (2) and (17) seem worth adding at this point.  (18) is a
real pain as it requires a TFTP client in the bootp setup.  I've not
had access to a bootpd which provides any of these so I can't easily
test them.

It does correctly parse the rest as far as I've been able to test with
the bootp servers I've got access to.  The script rc.bootp sets up the
IP layer from the bootp packet results, and is based loosely on the
startup script provided by Charles Hawkins <ceh@eng.cam.ac.uk>, but
with additions for the bootp cookies.  Hopefully now all the locations
of the binaries it uses are configurable at the top of rc.bootp saving
people the effort of trying to guess what needs changing for their
distribution.

The code is cleanly compiled by gcc -wall -pedantic, so should be ok ;-)

The setting up of the resolv.conf file is done if enough info can be
got from the bootp reply and/or the inverse lookup of the IP address
we were allocated (for those servers which supply DNS server info but
not the DNS domain name.)  For the reverse lookup to work (and DNS in
general), you must of course already have the order line include the
"bind" keyword in your host.conf file.  If all the domain name lookups
fail, but you still have an existing resolv.conf file, the script will
update the nameservers lines, leaving the domain/search line alone.

**********************************************************************
** I'll repeat that.  set up /etc/host.conf or this bit won't work. **
**********************************************************************

There are a few options near the top of rc.bootp which you may want to
alter for your setup:

Note that if you want the bootpc to give up after it fails, then you
need the --returniffail option to tell it to do so.  If this is set
then the return code signifies success or failure (0 for success, 1
for failure).

For testing bootp servers you may also want to check out the
--waitformore option.  This causes bootpc to wait for multple replies
and tell you about each of them.  e.g. I find that with the options:

  ./bootpc --server 131.111.255.255 --waitformore 20

I get multiple replies for some machines.  (131.111.255.255 is MY
broadcast address, use your own!, the 20 is how long to wait).  This
is handy with the --hwaddr option to see who would reply for a request
from a given MAC address.

If you have problems then please read the WHEN-IT-FAILS file, and
failing that please mail me.

This code is provided as-is, with no warrenty, share and enjoy.

Please report any bugs or problems and I'll try to fix them.

I'm still (!!!) about to get a SLIP connection (no PPP ;-) so wil be
able to test that as well as ethernet links soon.  The current version
is largely untested on network interfaces other than ethernet.  I'm
told that the current rc.bootp script makes for difficult use when
using SLIP, once I've tried it a few times myself I may agree.

I've been told that DIP 3.x now supports bootp directly which may be a
better way to go than to use this code with DIP.  I've had a cursory
look at it and it seems to do the job (I still can't test it).  Of
course the bootp client code in DIP doesn't extract as much info from
the server as this one does.  :-(

  -- Jon Peatfield  (DAMTP unix network admin)

Jon Peatfield, Computer Officer, the DAMTP, University of Cambridge
Telephone: +44 1223  3 37852    Mail: J.S.Peatfield@damtp.cam.ac.uk