Re: Newbie on tunnelling



On 12/13/06, Odhiambo Washington <wash@xxxxxxxxxxxx> wrote:

* On 13/12/06 15:48 +0000, Chris wrote:
| Loading a kernel module at boot time is done by editing (or creating)
| loader.conf in /boot. And adding [module_name]_load="YES" to load a
module,
| so: if_gre_load="YES".
|
| Edit rc.conf for startup configurations. Take a look at "man rc.conf".
The
| sections on network_interfaces and static_routes will be of some help.
|
| On 13/12/06, Odhiambo Washington <wash@xxxxxxxxxxxx > wrote:
| >
| >I need to create a VPN between two offices. Each has a LAN that is
| >behind a FreeBSD router/firewall.
| >
| >I have managed to do the following manually:
| >
| >hq-office:
| >kldload if_gre.ko
| >ifconfig gre0 create
| >ifconfig gre0 tunnel 62.8.68.94 62.8.82.142
| >ifconfig gre0 inet 10.0.0.1 10.0.0.2 netmask 255.255.255.252
| >route add -net 192.168.1.0/24 -interface gre0
| >
| >sub-office:
| >kldload if_gre.ko
| >ifconfig gre0 create
| >ifconfig gre0 tunnel 62.8.82.142 62.8.68.94
| >ifconfig gre0 inet 10.0.0.2 10.0.0.1 netmask 255.255.255.252
| >route add -net 192.168.0.0/24 -interface gre0
| >
| >Now my simple question is: How do I automate these commands during boot
| >time?
| >



So, if I compiled kernel with "device gre" (FreeBSD 5.5 here, sorry)
then there is no need to load the module via loader.conf, yes?

So in rc.conf. would the following suffice (for hq-office)?

cloned_interfaces="gre0"
ifconfig_gre0="inet 10.0.0.1 10.0.0.2 tunnel 62.8.68.94 62.8.82.142 up"

How about the static route portions? It's still not clear to me how to
take care of them in rc.conf.

TIA

-Wash


As I believe you were previously instructed, read the manual (it's all in
there):

http://www.freebsd.org/cgi/man.cgi?query=rc.conf&apropos=0&sektion=0&manpath=FreeBSD+6.1-RELEASE&format=html
_______________________________________________
freebsd-questions@xxxxxxxxxxx mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions-unsubscribe@xxxxxxxxxxx"



Relevant Pages

  • Re: Newbie on tunnelling
    ... | Loading a kernel module at boot time is done by editing ... |>kldload if_gre.ko ...
    (freebsd-questions)
  • Re: Newbie on tunnelling
    ... Loading a kernel module at boot time is done by editing ... kldload if_gre.ko ... ifconfig gre0 tunnel 62.8.68.94 62.8.82.142 ...
    (freebsd-questions)
  • modprobe.conf is ignored
    ... after loading the kernel module a daemon has to be started. ... At boot time the module gets loaded but the daemon does not get started. ... So I think the install command does not get executed at all. ...
    (Fedora)
  • Re: USB storage device mount problem
    ... In addition to the advice from others here, I can recommend the ... geom_label kernel module. ... Load it manually using kldload, ...
    (comp.unix.bsd.freebsd.misc)
  • Re: commercial OSS drivers
    ... > home use but they told me they can not give me support using them. ... sure you unload your kernel module, ... Follow the installer ... rather annoying since increases boot time. ...
    (freebsd-questions)