summaryrefslogtreecommitdiffstats
path: root/chapter_17.xml
diff options
context:
space:
mode:
authorAlan Hicks <alan@lizella.net>2010-05-01 14:17:18 -0400
committerAlan Hicks <alan@lizella.net>2010-05-01 14:17:18 -0400
commitdbca998ce52d78ce5e525e0d799adc83d580f66a (patch)
treec2a5ee10d4e488f77354f12e4c76a64615b94890 /chapter_17.xml
parent8ec49bb2c5d0fd2d3ee8dd519e783002f3c8f9ec (diff)
downloadslackbook-dbca998ce52d78ce5e525e0d799adc83d580f66a.tar.xz
Making room for new chapter and a few minor modifications.
Diffstat (limited to 'chapter_17.xml')
-rw-r--r--chapter_17.xml237
1 files changed, 153 insertions, 84 deletions
diff --git a/chapter_17.xml b/chapter_17.xml
index ea3035c..4da780b 100644
--- a/chapter_17.xml
+++ b/chapter_17.xml
@@ -3,119 +3,188 @@
"/usr/share/xml/docbook/xml-dtd-4.5/docbookx.dtd">
<chapter>
-<title>Keeping Track of Updates</title>
+<title>Package Management</title>
+
+<para>
+Package management is an essential part of any Linux distribution.
+Every piece of software included by Slackware, along with many
+third-party tools are distributed as source code that can be compiled,
+but compiling all those thousands of different applications and
+libraries is tedious and time consuming. That's why many people prefer
+to install pre-compiled software packages. In fact, when you installed
+Slackware, the <application>setup</application> program primarily
+worked by running package management tools on a list of packages. Here
+we'll look at the various tools used for handling Slackware packages.
+</para>
<section>
-<title>The -stable Branch</title>
+<title><application>pkgtool</application></title>
<para>
-Whenever a new version of Slackware is released, the Slackware team will,
-as needed, release updated packages to fix serious security vulnerabilities
-and particularly nasty bugs. Therefore, it's important to keep up with all
-of the patches for your version of Slackware, which is referred to as the
-"-stable" branch. There is also a "-current" branch, which is where we do
-our development work toward the next stable release (and as such, there are
-often intrusive changes there), but unless you're willing to work with a
-possibly broken system and are able to fix things on your own, we strongly
-recommend that you stick with the "-stable" branch.
+The simplest way to perform package maintenance tasks is to invoke
+<application>pkgtool</application>(8), a menu-driven interface to some of
+the other tools. <application>pkgtool</application> allows you to
+install or remove packages as well as view the contents of those
+packages and the list of currently installed packages in a
+user-friendly ncurses interface.
</para>
<para>
-Since -stable updates aren't distributed on the disks, you'll need to obtain
-them from the Internet. Many people and organizations offer mirrors from
-which you can download the entire Slackware tree (or only the
-<filename>patches/</filename> directory) in any number of ways. While some
-mirrors offer web access, the most common ways of obtaining updates are via
-ftp and/or rsync servers. The Slackware project maintains a small list
-(organized by country) of known mirrors. If you're unsure which mirror you
-should use, simply consult
-<ulink url="http://www.slackware.com/getslack/">http://www.slackware.com/getslack/</ulink>
-for suggestions. If you have a major university near you, there's a good
-chance that they offer a mirror of numerous open source projects, and
-Slackware may be among them. The only real requirement for a mirror is that
-it be complete, but usually it's best to use a mirror near where you live in
-order to achieve the fastest transfer times and use the least amount of
-Internet resources.
+PICTURE OF PKGTOOL MAIN SCREEN.
+FILL THIS IN!!!!!!
+FILL THIS IN!!!!!!
+FILL THIS IN!!!!!!
+FILL THIS IN!!!!!!
+FILL THIS IN!!!!!!
+FILL THIS IN!!!!!!
+FILL THIS IN!!!!!!
+FILL THIS IN!!!!!!
+FILL THIS IN!!!!!!
+FILL THIS IN!!!!!!
+FILL THIS IN!!!!!!
</para>
<para>
-So how do you know when there are updates? The best way is to consult the
-<filename>ChangeLog.txt</filename> on any up-to-date mirror. You can always
-find the latest changelogs for the "-current" and most recent "-stable"
-branch on the Slackware Project's web page, but if you're running an older
-version of Slackware, you'll need to check a mirror.
+<application>pkgtool</application> is a convenient and easy way to
+perform the most basic tasks, but for more advanced work more flexible
+tools are needed.
</para>
-<screen><prompt>darkstar:~# </prompt><userinput>wget -O - \
-ftp://slackware.osuosl.org/pub/slackware/slackware-13.0/ChangeLog.txt \
-| less</userinput>
-Sun Jan 24 20:22:46 UTC 2010
-patches/packages/httpd-2.2.14-i486-1_slack12.1.tgz: Upgraded.
- This fixes a couple of security bugs when using mod_proxy_ftp.
- For more information, see:
- http://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2009-3094
- http://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2009-3095
- (* Security fix *)</screen>
-
</section>
<section>
-<title>Security Update Mailing List</title>
+<title>Installing, Removing, and Upgrading Packages</title>
+
+<para>
+While <application>pkgtool</application> scores points for convenience,
+<application>installpkg</application>(8) is much more capable of
+handling odd tasks, such as quickly installing a single package,
+installing an entire disk set of packages, or scripting an install.
+<application>installpkg</application> takes a list of packages to
+install, and simply installs them without asking any questions. Like
+all Slackware package management tools, it assumes that you know what
+you're doing and doesn't pretend to be smarter than you. In its
+simplest form, <application>installpkg</application> simply takes a
+list of packages to install, and does exactly what you would expect.
+</para>
+
+<screen><prompt>darkstar:~# </prompt><userinput>installpkg blackbox-0.70.1-i486-2.txz</userinput>
+Verifying package blackbox-0.70.1-i486-2.txz.
+Installing package blackbox-0.70.1-i486-2.txz:
+PACKAGE DESCRIPTION:
+# blackbox (Blackbox window manager)
+#
+# Blackbox is that fast, light window manager you have been looking for
+# without all those annoying library dependencies.
+#
+# Also included in this package is the bbkeys utility for controlling
+# keyboard shortcut commands from within Blackbox.
+#
+# The Blackbox home page is http://blackboxwm.sourceforge.net
+#
+Package blackbox-0.70.1-i486-2.txz installed.</screen>
+
+<para>
+You can of course install multiple packages at a time, and in fact use
+shell wild cards. The following installs all of the "N" series
+packages from a mounted CD-ROM.
+</para>
+
+<screen><prompt>darkstar:~# </prompt><userinput>installpkg /mnt/cdrom/slackware/n/*.txz</userinput></screen>
+
+<para>
+Removing a package is every bit as easy as installing one. As you might
+expect, the command to do this is
+<application>removepkg</application>(8). Simply tell it which packages
+to remove, and <application>removepkg</application> will check the
+contents of the package database and remove all the files and
+directories for that package with one caveat. If that file is included
+in multiple installed packages, it will be skipped and if a directory
+has new files in it, the directory will be left in place. Because of
+this, removing packages takes a good while longer than installing them.
+</para>
+
+<screen><prompt>darkstar:~# </prompt><userinput>removepkg blackbox-0.70.1-i486-2.txz</userinput>
+</screen>
<para>
-While the Slackware team does release updated bugfix-only packages (i.e.
-not security fixes) occasionally, you're probably most interested in
-security fixes for vulnerabilities discovered after the -stable release.
-The Slackware Project maintains a mailing list that will notify you of any
-updated packages for such serious issues. In order to subscribe to the
-mailing list, send an e-mail to <email>majordomo@slackware.com</email>
-with the words 'subscribe slackware-security' in the body of the message.
-The majordomo will be happy to add your name to the list, and when new
-packages are released, it will mail an advisory to you.
+Finally, upgrading is just as easy with (you guessed it),
+<application>upgradepkg</application>(8) which first installs a new
+package, then removes whatever files and directories are left-over from
+the old package. One important thing to remember is that
+<application>upgradepkg</application> doesn't check to see if the
+previously installed package has a higher version number than the "new"
+package, so it can also be used to downgrade to older versions.
+</para>
+
+
+
+<screen><prompt>darkstar:~# </prompt><userinput>upgradepkg blackbox-0.70.1-i486-2.txz</userinput>
+
++==============================================================================
+| Upgrading blackbox-0.65.0-x86_64-4 package using
+./blackbox-0.70.1-i486-2.txz
++==============================================================================
+
+Pre-installing package blackbox-0.70.1-i486-2...
+
+Removing package
+/var/log/packages/blackbox-0.65.0-x86_64-4-upgraded-2010-02-23,16:50:51...
+ --> Deleting symlink /usr/share/blackbox/nls/POSIX
+ --> Deleting symlink /usr/share/blackbox/nls/US_ASCII
+ --> Deleting symlink /usr/share/blackbox/nls/de
+ --> Deleting symlink /usr/share/blackbox/nls/en
+ --> Deleting symlink /usr/share/blackbox/nls/en_GB
+...
+Package blackbox-0.65.0-x86_64-4 upgraded with new package
+./blackbox-0.70.1-i486-2.txz.</screen>
+
+<para>
+All of these tools have useful arguments. For example, the
+<arg>--root</arg> to <application>installpkg</application> will install
+packages into an arbitrary directory. The <arg>--dry-run</arg> argument
+will instruct <application>upgradepkg</application> to simply tell you
+what it would attempt without actually making any changes to the
+system. For complete details, you should (as always) refer to the man
+pages.
</para>
</section>
<section>
-<title>Upgrading Slackware Versions</title>
+<title>Package Compression Formats</title>
<para>
-Now that we've gone this far, you should feel reasonably competent in your
-ability to manage your Slackware system. But what do we do with it when
-there's a new release? Updating from one release of Slackware to another
-is a lot more complicated than simply updating a few packages. Each release
-changes a lot of things, and while many of these changes are small, some of
-them can completely break your system if you haven't prepared for them and/or
-don't understand what is changing and why. While some Linux distributions
-provide highly automated tools that attempt to handle every tiny detail for
-you, Slackware takes a much more hands-on approach to things.
+We won't go in depth into the details of package formats, but a few
+words should be given here. In the past, all Slackware packages were
+compressed with the <application>gzip</application>(1) compression
+utility, which was a good compromise between compression speed and
+size. Recently, new compression schemes have been added and the
+package management tools have been upgraded to handle these. Today,
+official Slackware packages are compressed with the
+<application>xz</application> utility and end with .txz extensions.
+Older packages (and many third party packages) still use the .tgz
+extension.
</para>
+</section>
+
+<section>
+<title><application>slackpkg</application></title>
+
<para>
-The very first thing you should do before attempting an upgrade is the one
-that many people neglect: decide if it's really necessary to upgrade. If
-the old system is stable and doing everything you want it to do, there may
-be no need to do an operating system upgrade at all. Assuming you decide
-to do the upgrade, then the second thing you should do is read the
-<filename>CHANGES_AND_HINTS.TXT</filename> file on your upgrade discs or
-a mirror. This file is updated during the development period before every
-release, and it lists lots of helpful hints and tips to aid you in dealing
-with the changes. Finally, read the <filename>UPGRADE.TXT</filename> file
-before proceeding. After doing these things, you may decide that it's less
-trouble and potential for problems to backup your configuration files and
-data and do a fresh installation of the new Slackware release rather than
-attempt a possibly tricky upgrade. However, if you still wish to continue,
-make backups of your data and configuration files first. At a minimum,
-it's good practice to backup the <filename>/etc</filename> and <filename>/home</filename>
-directories. This will give you a chance to perform a reinstall if something
-goes wrong with the upgrade.
+ The <application>slackpkg</application> is an automated tool for
+management of Slackware Linux Packages. It was in /extra for
+the release of slackware-12.1, and since the release of
+slackware-12.2 it is included in the ap/ series of a base
+installation.
+</para>
+<para>
+ For more information see the <application>man</application> pages for
+slackpkg(8) and slackpkg.conf(5).
</para>
-
<para>
-Since every new version of Slackware has a few differences, giving complete
-instructions here is not only futile but potentially misleading. You should
-always consult the documentation included on your Slackware disks or your
-favorite mirror.
+Homepage: <ulink url="http://www.slackpkg.org/">http://www.slackpkg.org/</ulink>
</para>
</section>