bastille firewall help needed

Discussion in 'Server Operation' started by daveb, Mar 27, 2007.

  1. daveb

    daveb Member

    Hello,

    I have a question to do with the bastille firewall. The system Ubuntu 6.10, ispconfig 2.2.11. I have a few custom rules that I use via /etc/Bastille/firewall.d/post-rule-setup.sh. My problem is everytime the server is rebooted I must create a directory /var/lock/subsys otherwise I get the error
    "touch: cannot touch `/var/lock/subsys/bastille-firewall': No such file or directory"
    My question is how can I keep from having the dir /var/lock/subsys removed everytime the server is rebooted?
     
  2. falko

    falko Super Moderator Howtoforge Staff Moderator HowtoForge Supporter ISPConfig Developer

    You could modify /etc/init.d/ispconfig_server. Change

    Code:
    case "$1" in
        start)
            echo "Starting ISPConfig system..."
            {INITDIR}/mysqld start &> /dev/null
            {INITDIR}/mysql start &> /dev/null
            sleep 3
            /root/ispconfig/httpd/bin/apachectl startssl
            /root/ispconfig/sv/ispconfig_wconf &> /dev/null &
            /root/ispconfig/php/php -q /root/ispconfig/scripts/shell/firewall.php
    to
    Code:
    case "$1" in
        start)
            echo "Starting ISPConfig system..."
            {INITDIR}/mysqld start &> /dev/null
            {INITDIR}/mysql start &> /dev/null
            sleep 3
            /root/ispconfig/httpd/bin/apachectl startssl
            /root/ispconfig/sv/ispconfig_wconf &> /dev/null &
            [B][COLOR="Red"]mkdir -p /var/lock/subsys[/COLOR][/B]
            /root/ispconfig/php/php -q /root/ispconfig/scripts/shell/firewall.php
     
  3. daveb

    daveb Member

    falko,
    Thank you, works like a charm.
     

Share This Page