You are not logged in.

#1 2010-09-24 08:16:42

daniel.gartmann
Member
Registered: 2010-09-24
Posts: 1

How to enable routing at boot time?

Hi

How to enable routing at boot time so I don't need it to do it manually with that command: "echo 1 > /proc/sys/net/ipv4/ip_forward"?

Thank you in advance!

cheers

Daniel

Offline

#2 2010-09-24 08:18:30

graysky
Wiki Maintainer
From: :wq
Registered: 2008-12-01
Posts: 10,600
Website

Re: How to enable routing at boot time?

You can add that echo line to your /etc/rc.local which will cover it... I have mine loaded up some boot stuff:

$ cat /etc/rc.local
#!/bin/bash
#
# /etc/rc.local: Local multi-user startup script.
#

/sbin/ifconfig eth0 mtu 4000 # set jumbo frames
/root/bin/fix_lcc # fix lcc if wd20ears is connected
echo noop > /sys/block/sdb/queue/scheduler # set scheduler for SSD
echo "11" > /sys/devices/system/cpu/cpufreq/ondemand/up_threshold # adjust ondemand threshold

Last edited by graysky (2010-09-24 08:19:31)


CPU-optimized Linux-ck packages @ Repo-ck  • AUR packagesZsh and other configs

Offline

#3 2010-09-24 08:24:36

bangkok_manouel
Member
From: indicates a starting point
Registered: 2005-02-07
Posts: 1,556

Re: How to enable routing at boot time?

/etc/sysctl.conf is what you're looking for.
add net.ipv4.ip_forward=1

Offline

#4 2010-09-24 08:37:38

fukawi2
Ex-Administratorino
From: .vic.au
Registered: 2007-09-28
Posts: 6,224
Website

Re: How to enable routing at boot time?

bangkok_manouel wrote:

/etc/sysctl.conf is what you're looking for.
add net.ipv4.ip_forward=1

+1
rc.local is not the "right" way smile

Offline

#5 2010-09-24 18:50:23

graysky
Wiki Maintainer
From: :wq
Registered: 2008-12-01
Posts: 10,600
Website

Re: How to enable routing at boot time?

fukawi2 wrote:
bangkok_manouel wrote:

/etc/sysctl.conf is what you're looking for.
add net.ipv4.ip_forward=1

+1
rc.local is not the "right" way smile

Never let it be said that I do things the right way... I was ignorant to the sysctl.conf method tongue


CPU-optimized Linux-ck packages @ Repo-ck  • AUR packagesZsh and other configs

Offline

#6 2010-09-24 23:34:35

fukawi2
Ex-Administratorino
From: .vic.au
Registered: 2007-09-28
Posts: 6,224
Website

Re: How to enable routing at boot time?

graysky wrote:

Never let it be said that I do things the right way... I was ignorant to the sysctl.conf method tongue

The day you don't learn something new, is the day you die wink

Offline

Board footer

Powered by FluxBB