2004-02-14 19:06:39 +01:00
<?xml version="1.0" encoding="UTF-8"?>
2008-07-07 22:22:09 +02:00
< !DOCTYPE article PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN"
"http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd">
2004-02-14 19:06:39 +01:00
<article id= "Install" >
<!-- $Id$ -->
<articleinfo >
<title > Shorewall Installation and Upgrade</title>
<authorgroup >
<author >
<firstname > Tom</firstname>
<surname > Eastep</surname>
</author>
</authorgroup>
2006-07-07 03:04:16 +02:00
<pubdate > <?dbtimestamp format="Y/m/d"?> </pubdate>
2004-02-14 19:06:39 +01:00
<copyright >
2005-08-24 04:05:26 +02:00
<year > 2001-</year>
2004-03-17 16:03:46 +01:00
2006-06-13 02:07:00 +02:00
<year > 2006</year>
2005-02-10 02:34:40 +01:00
2004-02-14 19:06:39 +01:00
<holder > Thomas M. Eastep</holder>
</copyright>
<legalnotice >
<para > Permission 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
2004-10-04 18:47:43 +02:00
<quote > <ulink url= "GnuCopyright.htm" > GNU Free Documentation
License</ulink> </quote> .</para>
2004-02-14 19:06:39 +01:00
</legalnotice>
</articleinfo>
2005-08-31 00:46:02 +02:00
<caution >
<para > <emphasis role= "bold" > This article applies to Shorewall 3.0 and
2008-08-15 03:26:15 +02:00
later. If you are installing or upgrading to a version of Shorewall
2005-08-31 00:46:02 +02:00
earlier than Shorewall 3.0.0 then please see the documentation for that
release.</emphasis> </para>
</caution>
2004-12-18 18:08:10 +01:00
<important >
<para > Before attempting installation, I strongly urge you to read and
print a copy of the <ulink url= "shorewall_quickstart_guide.htm" > Shorewall
QuickStart</ulink> Guide for the configuration that most closely matches
your own.</para>
</important>
2004-05-19 19:55:45 +02:00
2004-12-18 18:08:10 +01:00
<important >
<para > Before upgrading, be sure to review the <ulink
url="upgrade_issues.htm">Upgrade Issues</ulink> .</para>
</important>
2004-05-19 19:55:45 +02:00
2005-11-23 00:40:14 +01:00
<note >
<para > Shorewall RPMs are signed. To avoid warnings such as the
2006-08-03 06:16:32 +02:00
following<programlisting > warning: shorewall-3.2.1-1.noarch.rpm: V3 DSA signature: NOKEY, key ID 6c562ac4</programlisting> </para>
2005-11-23 00:40:14 +01:00
2005-11-23 00:54:13 +01:00
<para > download the <ulink
url="https://lists.shorewall.net/shorewall.gpg.key">Shorewall GPG
key</ulink> and run this command:</para>
2005-11-23 00:40:14 +01:00
<programlisting > <command > rpm --import shorewall.gpg.key</command> </programlisting>
</note>
2004-02-14 19:06:39 +01:00
<section id= "Install_RPM" >
<title > Install using RPM</title>
2004-03-17 16:03:46 +01:00
<para > To install Shorewall using the RPM:</para>
2004-02-14 19:06:39 +01:00
<orderedlist >
2005-03-01 21:20:26 +01:00
<listitem >
<para > <emphasis role= "bold" > Be sure that you have the correct RPM
package!</emphasis> </para>
<para > The standard RPM package from shorewall.net and the mirrors is
known to work with <emphasis
2005-11-24 20:22:48 +01:00
role="bold"><trademark > SUSE</trademark> </emphasis> , <emphasis
2005-03-01 21:20:26 +01:00
role="bold"><trademark > Power PPC</trademark> </emphasis> , <emphasis
role="bold"><trademark > Trustix</trademark> </emphasis> and <emphasis
role="bold"><trademark > TurboLinux</trademark> </emphasis> . There is
2006-06-15 07:32:14 +02:00
also an RPM package provided by Simon Matter that is tailored for
2005-03-01 21:20:26 +01:00
<trademark > <emphasis role= "bold" > RedHat/Fedora</emphasis> </trademark>
and another package from Jack Coates that is customized for <emphasis
2005-11-25 01:07:10 +01:00
role="bold"><trademark > Mandriva</trademark> </emphasis> . All of these
2005-03-01 21:20:26 +01:00
are available from the <ulink
url="http://www.shorewall.net/download.htm">download
page</ulink> .</para>
<para > If you try to install the wrong package, it probably won't
2007-06-26 01:37:55 +02:00
work.<note >
<para > If you are installing Shorewall 4.0.0 or later then you need
to install at least two packages.<itemizedlist >
<listitem >
<para > Either Shorewall-shell (the classic shell-based
configuration compiler) and/or Shorewall-perl (the newer and
faster compiler written in Perl).</para>
</listitem>
2007-07-01 19:02:22 +02:00
<listitem >
<para > Shorewall-common</para>
</listitem>
2007-06-26 01:37:55 +02:00
</itemizedlist> If you are installing Shorewall for the first
time, we strongly suggest that you install Shorewall-perl.</para>
</note> </para>
2005-03-01 21:20:26 +01:00
</listitem>
2004-02-14 19:06:39 +01:00
<listitem >
2007-07-01 19:02:22 +02:00
<para > Install the RPMs</para>
2004-02-14 19:06:39 +01:00
2007-07-01 19:02:22 +02:00
<programlisting > <command > rpm -ivh < compiler rpm> ... < shorewall-common rpm> </command> </programlisting>
2004-02-14 19:06:39 +01:00
2004-12-27 19:25:00 +01:00
<caution >
<para > Some users are in the habit of using the <command > rpm
-U</command> command for installing packages as well as for updating
them. If you use that command when installing the Shorewall RPM then
you will have to manually enable Shorewall startup at boot time by
running <command > chkconfig</command> , <command > insserv</command> or
whatever utility you use to manipulate you init symbolic
links.</para>
</caution>
2004-02-14 19:06:39 +01:00
<note >
2006-08-03 06:16:32 +02:00
<para > Some <trademark > SUSE</trademark> 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.</para>
2004-02-14 19:06:39 +01:00
2007-06-26 01:37:55 +02:00
<programlisting > <filename > <command > rpm -ivh --nodeps < rpms> </command> </filename> </programlisting>
2004-02-14 19:06:39 +01:00
</note>
<note >
2005-03-01 21:20:26 +01:00
<para > 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:</para>
2004-02-14 19:06:39 +01:00
2006-08-03 06:16:32 +02:00
<programlisting > error: failed dependencies:iproute is needed by shorewall-3.2.x-1</programlisting>
2004-02-14 19:06:39 +01:00
2005-03-01 21:20:26 +01:00
<para > This problem should not occur if you are using the correct RPM
package (see 1., above) but may be worked around by using the
--nodeps option of rpm.</para>
2004-02-14 19:06:39 +01:00
2007-06-26 01:37:55 +02:00
<programlisting > <command > rpm -ivh --nodeps < rpms> </command> </programlisting>
2004-02-14 19:06:39 +01:00
</note>
2007-07-01 19:02:22 +02:00
2007-11-21 00:51:31 +01:00
<para > Example:<programlisting > <command > rpm -ivh shorewall-perl-4.0.0-1.noarch.rpm shorewall-common-4.0.0-1.noarch.rpm</command> </programlisting> <important >
<para > Simon Matter names his '<emphasis > common</emphasis> ' rpm
'<emphasis > shorewall</emphasis> ' rather than
'<emphasis > shorewall-common</emphasis> '. So if you are installing
his RPMs, the command would be:<programlisting > <command > rpm -ivh shorewall-perl-4.0.0-1.noarch.rpm shorewall-4.0.0-1.noarch.rpm</command> </programlisting> </para>
</important> </para>
2004-02-14 19:06:39 +01:00
</listitem>
<listitem >
<para > Edit the <link linkend= "Config_Files" > configuration files</link>
to match your configuration.</para>
<warning >
<para > YOU CAN <emphasis role= "bold" > NOT</emphasis> SIMPLY INSTALL
THE RPM AND ISSUE A <quote > shorewall start</quote> COMMAND. SOME
CONFIGURATION IS REQUIRED BEFORE THE FIREWALL WILL START. IF YOU
ISSUE A <quote > start</quote> COMMAND AND THE FIREWALL FAILS TO
START, YOUR SYSTEM WILL NO LONGER ACCEPT ANY NETWORK TRAFFIC. IF
THIS HAPPENS, ISSUE A <quote > shorewall clear</quote> COMMAND TO
RESTORE NETWORK CONNECTIVITY.</para>
</warning>
</listitem>
2004-10-04 18:47:43 +02:00
<listitem >
2006-08-03 06:16:32 +02:00
<para > Enable startup by editing
2004-10-04 18:47:43 +02:00
/<filename > etc/shorewall/shorewall.conf</filename> and set
STARTUP_ENABLED to Yes).</para>
</listitem>
2004-02-14 19:06:39 +01:00
<listitem >
<para > Start the firewall by typing</para>
2004-03-17 16:03:46 +01:00
<programlisting > <command > shorewall start</command> </programlisting>
2004-02-14 19:06:39 +01:00
</listitem>
</orderedlist>
</section>
<section id= "Install_Tarball" >
<title > Install using tarball</title>
2007-06-26 01:37:55 +02:00
<note >
2007-07-01 19:02:22 +02:00
<para > If you are installing Shorewall 4.0.0 or later then you need to
install at least two packages.<itemizedlist >
2007-06-26 01:37:55 +02:00
<listitem >
2007-07-01 19:02:22 +02:00
<para > Either Shorewall-shell (the classic shell-based
configuration compiler) and/or Shorewall-perl (the newer and
faster compiler written in Perl).</para>
2007-06-26 01:37:55 +02:00
</listitem>
<listitem >
2007-07-01 19:02:22 +02:00
<para > Shorewall-common</para>
2007-06-26 01:37:55 +02:00
</listitem>
</itemizedlist> If you are installing Shorewall for the first time, we
strongly suggest that you install Shorewall-perl.</para>
</note>
2007-07-01 19:02:22 +02:00
<para > To install Shorewall-perl and Shorewall-common using the tarball and
install scripts:</para>
2004-02-14 19:06:39 +01:00
<orderedlist >
<listitem >
2007-07-01 19:02:22 +02:00
<para > unpack the tarballs:<programlisting > <command > tar -jxf shorewall-common-4.0.0.tar.bz2</command>
<command > tar -jxf shorewall-perl-4.0.0.tar.bz2
</command> </programlisting> </para>
</listitem>
<listitem >
<para > cd to the shorewall-perl directory (the version is encoded in
the directory name as in <quote > shorewall-perl-4.0.0</quote> ).</para>
2004-02-14 19:06:39 +01:00
</listitem>
<listitem >
2007-07-01 19:02:22 +02:00
<para > Type:</para>
<programlisting > <command > ./install.sh</command> </programlisting>
</listitem>
<listitem >
<para > cd to the shorewall-common directory (the version is encoded in
2007-12-03 16:31:54 +01:00
the directory name as in <quote > shorewall-common-4.0.0</quote> )</para>
2005-05-14 16:44:36 +02:00
</listitem>
<listitem >
2005-08-31 00:46:02 +02:00
<para > Type:</para>
2004-02-14 19:06:39 +01:00
2004-03-17 16:03:46 +01:00
<programlisting > <command > ./install.sh</command> </programlisting>
2004-02-14 19:06:39 +01:00
</listitem>
<listitem >
<para > Edit the <link linkend= "Config_Files" > configuration files</link>
to match your configuration.</para>
</listitem>
2004-03-17 16:03:46 +01:00
<listitem >
2005-08-31 00:46:02 +02:00
<para > Enable Startup by editing
<filename > /etc/shorewall/shorewall.conf</filename> and set
STARTUP_ENABLED=Yes.</para>
2004-03-17 16:03:46 +01:00
</listitem>
2004-02-14 19:06:39 +01:00
<listitem >
<para > Start the firewall by typing</para>
2004-03-17 16:03:46 +01:00
<programlisting > <command > shorewall start</command> </programlisting>
2004-02-14 19:06:39 +01:00
</listitem>
<listitem >
<para > If the install script was unable to configure Shorewall to be
started automatically at boot, see <ulink
2004-10-04 18:47:43 +02:00
url="starting_and_stopping_shorewall.htm">these
instructions</ulink> .</para>
2004-02-14 19:06:39 +01:00
</listitem>
</orderedlist>
</section>
2007-06-28 17:40:13 +02:00
<section id= "Debian" >
2004-12-18 18:08:10 +01:00
<title > Install the .deb</title>
2004-02-14 19:06:39 +01:00
2004-03-17 16:03:46 +01:00
<important >
2007-07-01 19:02:22 +02:00
<para > Once you have installed the .deb packages and before you attempt
to configure Shorewall, please heed the advice of Lorenzo Martignoni,
2009-01-17 21:06:28 +01:00
former Shorewall Debian Maintainer:</para>
2004-12-18 18:08:10 +01:00
2009-01-17 21:04:27 +01:00
<para > <quote > For more information about Shorewall usage on Debian system
please look at /usr/share/doc/shorewall-common/README.Debian provided by
[the] shorewall-common Debian package.</quote> </para>
2004-03-17 16:03:46 +01:00
</important>
2004-12-18 18:08:10 +01:00
<para > The easiest way to install Shorewall on Debian, is to use
2009-01-17 21:04:27 +01:00
apt-get<command > .</command> </para>
2004-12-18 18:08:10 +01:00
2006-08-03 23:18:48 +02:00
<para > First, to ensure that you are installing the latest version of
Shorewall, please modify your
<filename > /etc/apt/preferences:</filename> </para>
2006-08-03 06:16:32 +02:00
2009-01-17 21:04:27 +01:00
<para > <programlisting > Package: shorewall-common
Pin: release o=Debian,a=testing
Pin-Priority: 700
Package: shorewall-perl
2006-08-03 06:16:32 +02:00
Pin: release o=Debian,a=testing
Pin-Priority: 700
Package: shorewall-doc
Pin: release o=Debian,a=testing
2006-08-03 23:18:48 +02:00
Pin-Priority: 700</programlisting> <emphasis role= "bold" > <emphasis > Then
run:</emphasis> </emphasis> <programlisting > # apt-get update
2009-01-17 21:04:27 +01:00
# apt-get install shorewall-common shorewall-perl</programlisting> </para>
2004-12-18 18:08:10 +01:00
2006-08-03 23:18:48 +02:00
<para > <emphasis > <emphasis role= "bold" > Once you have completed configuring
Shorewall, you can enable startup at boot time by setting startup=1 in
<filename > /etc/default/shorewall</filename> .</emphasis> </emphasis> </para>
2004-12-18 18:08:10 +01:00
</section>
2007-06-28 17:40:13 +02:00
<section id= "Upgrade" >
2005-07-20 05:18:23 +02:00
<title > General Notes about Upgrading Shorewall</title>
<para > Most problems associated with upgrades come from two causes:</para>
<itemizedlist >
<listitem >
<para > The user didn't read and follow the migration considerations in
the release notes (these are also reproduced in the <ulink
2005-11-11 01:13:38 +01:00
url="upgrade_issues.htm">Shorewall Upgrade Issues</ulink> ).</para>
2005-07-20 05:18:23 +02:00
</listitem>
<listitem >
<para > The user mis-handled the
<filename > /etc/shorewall/shorewall.conf</filename> file during
upgrade. Shorewall is designed to allow the default behavior of the
product to evolve over time. To make this possible, the design assumes
that <emphasis role= "bold" > you will not replace your current
shorewall.conf</emphasis> <emphasis role= "bold" > file during
upgrades</emphasis> . It is recommended that after you first install
Shorewall that you modify
<filename > /etc/shorewall/shorewall.conf</filename> so as to prevent
your package manager from overwriting it during subsequent upgrades
(since the addition of STARTUP_ENABLED, such modification is assured
since you must manually change the setting of that option). If you
2009-01-17 21:04:27 +01:00
feel absolutely compelled to have the latest options in your
shorewall.conf then you must proceed carefully. You should determine
which new options have been added and you must reset their value (e.g.
OPTION=""); otherwise, you will get different behavior from what you
expect.</para>
2005-07-20 05:18:23 +02:00
</listitem>
</itemizedlist>
</section>
2004-12-18 18:08:10 +01:00
<section id= "Upgrade_RPM" >
<title > Upgrade using RPM</title>
2004-02-14 19:06:39 +01:00
<para > If you already have the Shorewall RPM installed and are upgrading to
a new version:</para>
<orderedlist >
2005-03-01 21:20:26 +01:00
<listitem >
<para > <emphasis role= "bold" > Be sure that you have the correct RPM
package!</emphasis> </para>
<para > The standard RPM package from shorewall.net and the mirrors is
2006-08-03 06:16:32 +02:00
known to work with <trademark > SUSE</trademark> , Power PPC, Trustix and
TurboLinux. There is also an RPM package provided by Simon Matter that
is tailored for RedHat/Fedora and another package from Jack Coates
that is customized for Mandriva. If you try to upgrade using the wrong
2007-11-21 00:51:31 +01:00
package, it probably won't work.<important >
<para > Simon Matter names his '<emphasis > common</emphasis> ' rpm
'<emphasis > shorewall</emphasis> ' rather than
'<emphasis > shorewall-common</emphasis> '.</para>
</important> </para>
2005-03-01 21:20:26 +01:00
</listitem>
2007-07-01 17:43:07 +02:00
<listitem >
<para > If you are upgrading from a 2.x or 3.x version to a 4.x version
or later, please see the <ulink url= "upgrade_issues.htm" > upgrade
issues</ulink> for specific instructions.</para>
</listitem>
2004-02-14 19:06:39 +01:00
<listitem >
<para > Upgrade the RPM</para>
2007-07-01 19:02:22 +02:00
<programlisting > <command > rpm -Uvh < compiler rpm file> ... < shorewall-common rpm file> </command> </programlisting>
2004-02-14 19:06:39 +01:00
<note >
2006-08-03 06:16:32 +02:00
<para > Some <trademark > SUSE</trademark> 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.</para>
2004-02-14 19:06:39 +01:00
2007-07-01 17:43:07 +02:00
<programlisting > <command > rpm -Uvh --nodeps < shorewall-common rpm> < compiler rpm> ...</command> </programlisting>
2004-02-14 19:06:39 +01:00
</note>
<note >
2006-08-03 06:16:32 +02:00
<para > 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:</para>
2004-02-14 19:06:39 +01:00
2006-08-03 06:16:32 +02:00
<programlisting > error: failed dependencies:iproute is needed by shorewall-3.2.1-1</programlisting>
2004-02-14 19:06:39 +01:00
2004-10-04 18:47:43 +02:00
<para > This may be worked around by using the --nodeps option of
rpm.</para>
2004-02-14 19:06:39 +01:00
2007-06-26 01:37:55 +02:00
<programlisting > <command > rpm -Uvh --nodeps < shorewall rpm> < compiler-rpm> ...</command> </programlisting>
2004-02-14 19:06:39 +01:00
</note>
</listitem>
<listitem >
<para > See if there are any incompatibilities between your
2004-10-04 18:47:43 +02:00
configuration and the new Shorewall version and correct as
necessary.</para>
2004-02-14 19:06:39 +01:00
2004-03-17 16:03:46 +01:00
<programlisting > <command > shorewall check</command> </programlisting>
2004-02-14 19:06:39 +01:00
</listitem>
<listitem >
<para > Restart the firewall.</para>
2004-03-17 16:03:46 +01:00
<programlisting > <command > shorewall restart</command> </programlisting>
2004-02-14 19:06:39 +01:00
</listitem>
</orderedlist>
</section>
<section id= "Upgrade_Tarball" >
<title > Upgrade using tarball</title>
2007-07-01 17:43:07 +02:00
<para > <important >
<para > If you are upgrading from a 2.x or 3.x version to a 4.x version
or later, please see the <ulink url= "upgrade_issues.htm" > upgrade
issues</ulink> for specific instructions.</para>
</important> </para>
2004-02-14 19:06:39 +01:00
<para > If you already have Shorewall installed and are upgrading to a new
version using the tarball:</para>
<orderedlist >
<listitem >
2007-07-01 19:02:22 +02:00
<para > unpack the tarballs:<programlisting > <command > tar -jxf shorewall-common-4.0.0.tar.bz2</command>
<command > tar -jxf shorewall-perl-4.0.0.tar.bz2
tar -jxf shorewall-shell-4.0.0.tar.bz2</command> (if you use this compiler)</programlisting> </para>
</listitem>
<listitem >
<para > cd to the shorewall-perl directory (the version is encoded in
the directory name as in <quote > shorewall-perl-4.0.0</quote> ).</para>
</listitem>
<listitem >
<para > Type:</para>
2004-02-14 19:06:39 +01:00
2007-07-01 19:02:22 +02:00
<programlisting > <command > ./install.sh</command> </programlisting>
</listitem>
<listitem >
<para > Perform the above two steps for the shorewall-shell directory if
you use that compiler.</para>
2004-02-14 19:06:39 +01:00
</listitem>
<listitem >
2007-07-01 19:02:22 +02:00
<para > cd to the shorewall-common directory (the version is encoded in
the directory name as in <quote > shorewall-perl-4.0.0</quote> )</para>
2004-02-14 19:06:39 +01:00
</listitem>
<listitem >
2005-08-31 00:46:02 +02:00
<para > Type:</para>
2004-02-14 19:06:39 +01:00
2004-03-17 16:03:46 +01:00
<programlisting > <command > ./install.sh</command> </programlisting>
2004-02-14 19:06:39 +01:00
</listitem>
<listitem >
<para > See if there are any incompatibilities between your
2004-10-04 18:47:43 +02:00
configuration and the new Shorewall version and correct as
necessary.</para>
2004-02-14 19:06:39 +01:00
2004-03-17 16:03:46 +01:00
<programlisting > <command > shorewall check</command> </programlisting>
2004-02-14 19:06:39 +01:00
</listitem>
<listitem >
<para > Start the firewall by typing</para>
2004-03-17 16:03:46 +01:00
<programlisting > <command > shorewall start</command> </programlisting>
2004-02-14 19:06:39 +01:00
</listitem>
<listitem >
<para > If the install script was unable to configure Shorewall to be
started automatically at boot, see <ulink
2004-10-04 18:47:43 +02:00
url="starting_and_stopping_shorewall.htm">these
instructions</ulink> .</para>
2004-02-14 19:06:39 +01:00
</listitem>
</orderedlist>
</section>
2007-11-29 17:50:28 +01:00
<section id= "Upgrade_Deb" >
<title > Upgrading the .deb</title>
<warning >
<para > When the installer asks if you want to replace
/etc/shorewall/shorewall.conf with the new version, we strongly advise
you to say No. See <link linkend= "Upgrade" > above</link> .</para>
</warning>
</section>
2004-02-14 19:06:39 +01:00
<section id= "LRP_Upgrade" >
<title > Upgrade the .lrp</title>
2004-10-30 17:23:18 +02:00
<para > The following was contributed by Charles Steinkuehler on the Leaf
mailing list:</para>
<blockquote >
2007-11-21 00:51:31 +01:00
<para > It's *VERY* simple...just put in a new CD and reboot! :-)
2004-10-30 17:23:18 +02:00
Actually, I'm only slightly kidding...that's exactly how I upgrade my
2008-08-15 03:26:15 +02:00
production firewalls. The partial backup feature I added to Dachstein
allows configuration data to be stored separately from the rest of the
2007-11-21 00:51:31 +01:00
package.</para>
2004-10-30 17:23:18 +02:00
2008-08-15 03:26:15 +02:00
<para > Once the config data is separated from the rest of the package,
it's an easy matter to upgrade the package while keeping your current
2004-10-30 17:23:18 +02:00
configuration (in my case, just inserting a new CD and
re-booting).</para>
<para > Users who aren't running with multiple package paths and using
partial backups can still upgrade a package, it just takes a bit of
2007-11-21 00:51:31 +01:00
extra work. The general idea is to use a partial backup to save your
configuration, replace the package, and restore your old configuration
files. Step-by-step instructions for one way to do this (assuming a
conventional single-floppy LEAF system) would be:</para>
2004-10-30 17:23:18 +02:00
<itemizedlist >
<listitem >
2007-11-21 00:51:31 +01:00
<para > Make a backup copy of your firewall disk ('NEW'). This is the
disk you will add the upgraded package(s) to.</para>
2004-10-30 17:23:18 +02:00
</listitem>
<listitem >
<para > Format a floppy to use as a temporary location for your
2007-11-21 00:51:31 +01:00
configuration file(s) ('XFER'). This disk should have the same
2004-10-30 17:23:18 +02:00
format as your firewall disk (and could simply be another backup
copy of your current firewall).</para>
</listitem>
<listitem >
<para > Make sure you have a working copy of your existing firewall
2008-08-15 03:26:15 +02:00
('OLD') in a safe place, that you *DO NOT* use during this process.
2004-10-30 17:23:18 +02:00
That way, if anything goes wrong you can simply reboot off the OLD
disk to get back to a working configuration.</para>
</listitem>
<listitem >
<para > Remove your current firewall configuration disk and replace it
with the XFER disk.</para>
</listitem>
<listitem >
<para > Use the lrcfg backup menu to make a partial backup of the
package(s) you want to upgrade, being sure to backup the files to
2007-11-21 00:51:31 +01:00
the XFER disk. From the backup menu:</para>
2004-10-30 17:23:18 +02:00
<programlisting > t e < enter> p < enter>
b < package1> < enter>
b < package2> < enter>
...</programlisting>
</listitem>
<listitem >
<para > Download and copy the package(s) you want to upgrade onto the
NEW disk.</para>
</listitem>
<listitem >
<para > Reboot your firewall using the NEW disk...at this point your
upgraded packages will have their default configuration.</para>
</listitem>
<listitem >
<para > Mount the XFER disk (mount -t msdos /dev/fd0u1680 /mnt)</para>
</listitem>
<listitem >
<para > CD to the root directory (cd /)</para>
</listitem>
<listitem >
<para > Manually extract configuration data for each package you
upgraded:</para>
<programlisting > tar -xzvf /mnt/package1.lrp
tar -xzvf /mnt/package2.lrp
...</programlisting>
</listitem>
<listitem >
<para > Unmount (umount /mnt) and remove the XFER disk</para>
</listitem>
<listitem >
<para > Using lrcfg, do *FULL* backups of your upgraded
packages.</para>
</listitem>
<listitem >
2007-11-21 00:51:31 +01:00
<para > Reboot, verifying the firewall works as expected. Some
2004-10-30 17:23:18 +02:00
configuration files may need to be 'tweaked' to work properly with
the upgraded package binaries.</para>
</listitem>
</itemizedlist>
<important >
<para > The new package file < package> .local can be used to
fine-tune which files are included (and excluded) from the partial
2007-11-21 00:51:31 +01:00
backup (see the Dachstein-CD README for details). If this file
2004-10-30 17:23:18 +02:00
doesn't exist, the backup scripts assume anything from the
< package> .list file that resides in /etc or /var/lib/lrpkg is
part of the configuration data and is used to create the partial
2007-11-21 00:51:31 +01:00
backup. If shorewall puts anything in /etc that isn't a user modified
2008-08-15 03:26:15 +02:00
configuration file, a proper shorewall.local file should be created
2007-11-21 00:51:31 +01:00
prior to making the partial backup [<emphasis role= "bold" > Editor's
note</emphasis> : Shorewall places only user-modifiable files in
/etc].</para>
2004-10-30 17:23:18 +02:00
</important>
<note >
<para > It's obviously possible to do the above 'in-place', without
using multiple disks, and even without making a partial backup (ie:
copy current config files to /tmp, manually extract new package on top
of current running firewall, then copy or merge config data from /tmp
and backup...or similar), but anyone capable of that level of command
line gymnastics is probably doing it already, without needing detailed
instructions! :-)</para>
</note>
</blockquote>
2004-11-08 04:14:27 +01:00
<para > For information on other LEAF/Bering upgrade tools, check out <ulink
2007-06-26 01:37:55 +02:00
url="http://leaf.cvs.sourceforge.net/*checkout*/leaf/devel/alexrh/lck/README.html">this
2004-11-08 04:14:27 +01:00
article by Alex Rhomberg</ulink> .</para>
2004-02-14 19:06:39 +01:00
</section>
<section id= "Config_Files" >
<title > Configuring Shorewall</title>
<para > You will need to edit some or all of the configuration files to
match your setup. In most cases, the <ulink
url="shorewall_quickstart_guide.htm">Shorewall QuickStart Guides</ulink>
contain all of the information you need.</para>
</section>
2007-06-28 17:40:13 +02:00
<section id= "Uninstall" >
2004-02-14 19:06:39 +01:00
<title > Uninstall/Fallback</title>
2004-10-04 18:47:43 +02:00
<para > See <quote > <ulink url= "fallback.htm" > Fallback and
Uninstall</ulink> </quote> .</para>
2004-02-14 19:06:39 +01:00
</section>
2008-07-04 17:11:51 +02:00
</article>