LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   custom script in SuSE10.0 (https://www.linuxquestions.org/questions/linux-newbie-8/custom-script-in-suse10-0-a-411237/)

gerold_vandijk 02-03-2006 08:18 AM

custom script in SuSE10.0
 
I wrote my own script to customize the firewall and activate NAT masquerade to route between my 2 netwok adapters (IPTABLES stuff), in SuSE 10.0.It works fine when ran from the command prompt, but the settings are overruled by the standard SuSE10.0 config file(s) at startup.

Q: where do I place my script to have it permanently beeing activated also after a reboot?

gerold@sicon-sr.com

satinet 02-03-2006 08:26 AM

is there a file called " /etc/init.d/boot.local "

i might be imagining it though.

getting old....

pokemaster 02-03-2006 09:14 AM

there's probably a file as mentioned by satinet (might be called local instead of boot.local, the existence and name of this file varies from distro to distro)

I know with Gentoo and Debian, there's a tool to set up this script if it doesn't exist. first, create /etc/init.d/local, make it call your script, chmod it to 755, then
Code:

update-rc.d local defaults 99
Wirh Gentoo, that's a little different... but I doubt Suse uses the Gentoo-type tool.

This will load your local script (with priority 99, so it'll load toward the end of the boot process), and it'll overwrite the settings made by Suse.


Good luck, let us know if it works!


All times are GMT -5. The time now is 02:57 AM.