Shorewall Installation and UpgradeTomEastep2004-06-252001200220032004Thomas M. EastepPermission is granted to copy, distribute and/or modify this
document under the terms of the GNU Free Documentation License, Version
1.2 or any later version published by the Free Software Foundation; with
no Invariant Sections, with no Front-Cover, and with no Back-Cover
Texts. A copy of the license is included in the section entitled
GNU Free Documentation License.Note to Debian UsersIf you install using the .deb, you will find that your /etc/shorewall directory is empty. This is
intentional. The released configuration file skeletons may be found on
your system in the directory /usr/share/doc/shorewall/default-config.
Simply copy the files you need from that directory to /etc/shorewall and modify the copies.Note that you must copy /usr/share/doc/shorewall/default-config/shorewall.conf
and /usr/share/doc/shorewall/default-config/modules to /etc/shorewall even if you do not modify
those files.Install using RPMBefore attempting installation, I strongly urge you to read and
print a copy of the Shorewall
QuickStart Guide for the configuration that most closely matches
your own.To install Shorewall using the RPM:Install the RPMrpm -ivh <shorewall rpm>Some SuSE users have encountered a problem whereby rpm reports
a conflict with kernel <= 2.2 even though a 2.4 kernel is
installed. If this happens, simply use the --nodeps option to rpm.rpm -ivh --nodeps <shorewall rpm>Beginning with Shorewall 1.4.0, Shorewall is dependent on the
iproute package. Unfortunately, some distributions call this package
iproute2 which will cause the installation of Shorewall to fail with
the diagnostic:error: failed dependencies:iproute is needed by shorewall-1.4.x-1This may be worked around by using the --nodeps option of rpm.rpm -ivh --nodeps <shorewall rpm>Edit the configuration files
to match your configuration.YOU CAN NOT SIMPLY INSTALL
THE RPM AND ISSUE A shorewall start COMMAND. SOME
CONFIGURATION IS REQUIRED BEFORE THE FIREWALL WILL START. IF YOU
ISSUE A start COMMAND AND THE FIREWALL FAILS TO
START, YOUR SYSTEM WILL NO LONGER ACCEPT ANY NETWORK TRAFFIC. IF
THIS HAPPENS, ISSUE A shorewall clear COMMAND TO
RESTORE NETWORK CONNECTIVITY.Start the firewall by typingshorewall startInstall using tarballBefore attempting installation, I strongly urge you to read and
print a copy of the Shorewall
QuickStart Guide for the configuration that most closely matches
your own.To install Shorewall using the tarball and install script:unpack the tarball (tar -zxf shorewall-x.y.z.tgz).cd to the shorewall directory (the version is encoded in the
directory name as in shorewall-1.1.10).If you are running Slackware,
you need Shorewall 2.0.2 RC1 or later. If you are installing a
Shorewall version earlier than 2.0.3 Beta 1 then you must also edit
the install.sh file and change the linesDEST="/etc/init.d"
INIT="shorewall"toDEST="/etc/rc.d"
INIT="rc.firewall"If you are running Slackware and are installing Shorewall 2.0.3
Beta 1 or later, then type:DEST=/etc/rc.d INIT=rc.firewall ./install.shOtherwise, type:./install.shEdit the configuration files
to match your configuration.Enable Startup by removing /etc/shorewall/startup_disabled
(Debian users will edit /etc/default/shorewall
and set startup=1).Start the firewall by typingshorewall startIf the install script was unable to configure Shorewall to be
started automatically at boot, see these instructions.Install the .lrpBefore attempting installation, I strongly urge you to read and
print a copy of the Shorewall
QuickStart Guide for the configuration that most closely matches
your own.To install my version of Shorewall on a fresh Bering disk, simply
replace the shorwall.lrp file on the image with the file
that you downloaded. See the two-interface
QuickStart Guide for information about further steps required.Upgrade using RPMBefore upgrading, be sure to review the Upgrade Issues.If you already have the Shorewall RPM installed and are upgrading to
a new version:If you are upgrading from a 1.2 version of Shorewall to a 1.4
version or and you have entries in the /etc/shorewall/hosts file then
please check your /etc/shorewall/interfaces file to be sure that it
contains an entry for each interface mentioned in the hosts file. Also,
there are certain 1.2 rule forms that are no longer supported under 1.4
(you must use the new 1.4 syntax). See the
upgrade issues for details.Upgrade the RPMrpm -Uvh <shorewall rpm file>Some SuSE users have encountered a problem whereby rpm reports
a conflict with kernel <= 2.2 even though a 2.4 kernel is
installed. If this happens, simply use the --nodeps option to rpm.rpm -Uvh --nodeps <shorewall rpm>Beginning with Shorewall 1.4.0, Shorewall is dependent on the
iproute package. Unfortunately, some distributions call this package
iproute2 which will cause the upgrade of Shorewall to fail with the
diagnostic:error: failed dependencies:iproute is needed by shorewall-1.4.0-1This may be worked around by using the --nodeps option of rpm.rpm -Uvh --nodeps <shorewall rpm>See if there are any incompatibilities between your
configuration and the new Shorewall version and correct as necessary.shorewall checkRestart the firewall.shorewall restartUpgrade using tarballBefore upgrading, be sure to review the Upgrade Issues.If you already have Shorewall installed and are upgrading to a new
version using the tarball:If you are upgrading from a 1.2 version of Shorewall to a 1.4
version and you have entries in the /etc/shorewall/hosts file then
please check your /etc/shorewall/interfaces file to be sure that it
contains an entry for each interface mentioned in the hosts file. Also,
there are certain 1.2 rule forms that are no longer supported under 1.4
(you must use the new 1.4 syntax). See the
upgrade issues for details.unpack the tarball.tar -zxf shorewall-x.y.z.tgzcd to the shorewall directory (the version is encoded in the
directory name as in shorewall-3.0.1).If you are running Slackware,
you should use Shorewall 2.0.2 RC1 or later. If you are installing a
Shorewall version earlier than 2.0.3 Beta 1 then you must also edit
the install.sh file and change the linesDEST="/etc/init.d"
INIT="shorewall"toDEST="/etc/rc.d"
INIT="rc.firewall"If you are running Slackware and are installing Shorewall 2.0.3
Beta 1 or later, then type:DEST=/etc/rc.d INIT=rc.firewall ./install.shOtherwise, type:./install.shSee if there are any incompatibilities between your
configuration and the new Shorewall version and correct as necessary.shorewall checkStart the firewall by typingshorewall startIf the install script was unable to configure Shorewall to be
started automatically at boot, see these instructions.Upgrade the .lrpBefore upgrading, be sure to review the Upgrade Issues.There appears to be no standard method for upgrading LEAF/Bering
packages — Sorry to be so unhelpful.Configuring ShorewallYou will need to edit some or all of the configuration files to
match your setup. In most cases, the Shorewall QuickStart Guides
contain all of the information you need.Uninstall/FallbackSee Fallback and Uninstall.