BSD DevCenter
oreilly.comSafari Books Online.Conferences.

advertisement


Connecting to the Internet Using PPP or a Cable Modem
Pages: 1, 2, 3, 4

If you need to reconfigure your kernel

If your modem is physically attached to COM3 or COM4, you'll have to rebuild your kernel, as these COM ports are disabled by default. If this is the case, as root, type:



cd /usr/src/sys/i386/conf

If this produces an error message, you didn't install /src when you installed FreeBSD. To fix that, type:

/stand/sysinstall

And select Configure and then Distributions. Use your spacebar to select src, then sys.

Press enter twice, and select your media. Exit out of /stand/sysinstall when it is finished copying the necessary files and let's try again. Type:

cd /usr/src/sys/i386/conf
ls

and you'll see something like this:

GENERIC	LINT	NEWCARD

GENERIC is the name of the default kernel configuration file that came with FreeBSD; notice the convention of using all caps to signify kernel configuration files. When creating a new kernel, always make a copy of a kernel configuration file, just in case you make things worse. LINT is a handy file that explains all the possibilities one can input in a kernel configuration file, and their required syntax. Let's enable COM ports 3 and 4:

cp GENERIC MYKERNEL
pico MYKERNEL

which will open the file in the pico editor. Press Ctrl-W and type com3 (to find the line to edit). You'll probably see something like this:

# Serial (COM) ports
device		sio0	at isa? port IO_COM1 flags 0x10 irq 4
device		sio1	at isa? port IO_COM2 irq 3
device		sio2	at isa? disable port IO_COM3 irq 5
device		sio3	at isa? disable port IO_COM4 irq 9

Remove the word disable from the entries for COM 3 and 4; also verify that the irqs are correct, and modify them if they are not. Once you've saved your file (to save the file and exit pico, press Ctrl-X), type:

/usr/sbin/config MYKERNEL
Don't forget to do a "make depend"
Kernel build directory is ../../compile/MYKERNEL
cd ../../compile/MYKERNEL
make depend

When you receive the prompt back, continue with:

make

This one takes a bit longer. Finally:

make install

To test the new kernel:

reboot

When you log back in, use:

dmesg

to verify that COM3 and COM4 were successfully found. You'll probably have to turn on your scroll lock key and use your page up key to scroll through the buffer. When you are finished, press scroll lock again to receive your prompt back.

Pages: 1, 2, 3, 4

Next Pagearrow





Sponsored by: