HowTo: Upgrade Slackware 12.0 to 12.1
This HowTo will show you an example of how to upgrade Slackware 12.0 to 12.1.
Note: This HowTo is just a guide and does not cover all possible scenarios. Rather it attempts to expand on the great information carefully compiled in the UPGRADE.TXT and CHANGES_AND_HINTS.TXT through a practical example. Again, this HowTo is just a guide and may not be correct for your situation. Use your brain and adjust accordingly. If you have any questions, concerns, comments, or complaints please voice them through posting. This is a forum after all :)
All of the most recent changes are in RED.
The sections of this HowTo are:
Should You Upgrade?
Things You Need to Upgrade
Getting 12.1 Sources
Create List of Non-Slackware Software
Alternative Mass Upgrade with slackpkg
Part 2 - Skip to post #19
LILO and the Fancy Bootsplash
Get Rid of Obsolete Slackware Packages from 12.0
Merge Changes for Config Files
Update Your Graphics Drivers (if needed)
Rebuild/Upgrade any Non-Slackware Packages (as Needed)
Fix Other Random Problems
** Should You Upgrade? **
This should be the first thing you ask yourself. What's in it for you? If you aren't sure, you should read the following docs:
How much work will it take? Well that depends on your system. If your system is in a state of disaster with software installed who knows where then it might be a better idea to backup and install a fresh Slackware 12.1 instead.
** Things You Need to Upgrade **
1) Slackware 12.1 sources – however you can get them: On a CD/DVD, local mirror, from a slackware mirror, network mount, etc
2) Slackware 12.0 installation – This is a HowTo on upgrading from 12.0 after all...
3) Time – This is not a one click upgrade process. It will require that you think. Take your time and do it right the first time. Please read the UPGRADE.TXT and CHANGES_AND_HINTS.TXT before attempting an upgrade! This HowTo does not cover everything included in those files.
4) (Newest Graphics Driver) – It might be a good idea, for instance, to grab the latest Nvidia driver now if you are going to need it later.
** Backup Computer **
This is without a doubt the first thing you should do before making any major system changes.
** Getting 12.1 Sources **
Most people will probably download the full iso, but if you have downloaded some sources from -current previously it might be more worth your while to simply mirror. In my case I had previously used Alien Bob's mirror-slackware-current.sh to create a local mirror of -current and install cds. I had used these to test -current. Before using mirror-slackware-current.sh I recommend you create mirror-slackware-current.conf based upon the options that you want changed from the defaults (see beginning of mirror-slackware-current.sh).
An example mirror-slackware-current.conf
After -current became Slackware 12.1 all I had to do was
change my mirror folder names from slackware-current to slackware-12.1 and slackware-current-iso to slackware-12.1-iso.
Another tip for using this script: If you have to mirror onto a non-linux partition take out the 'p' from the actual rsync commands in the script so that they don't try to preserve permissions. In my case I only had enough free space on an external NTFS drive, so that is what I used. There are two places I had to change the script, since the sync is done twice. I simply changed a line that looks like
** Create List of Non-Slackware Software **
Before you move on into the upgrade you need to properly assess where you are, and in particular, what non-slackware software you have installed.
By far the easiest way to do this is to use slackpkg, which you can find in /extra (for alternate scripts see this thread about Listing Non Stock Slackware Packages). It is recommended that you download the latest stable slackpkg release in order to have all the features used in this HowTo (such as batch and default_answer support). Do note, that the latest release is likely to be a later version than the one in the latest stable Slackware release, so you should add slackpkg to your blacklist to prevent accidentally downgrading it. You should also check the ChangeLog periodically to see if there are any crucial fixes.
Once you install it, be sure to edit blacklist, mirrors, and slackpkg.conf under /etc/slackpkg as desired (set the mirror to one for 12.0 for now). Then to get your list you can simply do
Now is a good time to get rid of any of those non-slackware packages that you no longer need. There is a chance that you will have to rebuild some of your custom packages after the upgrade.
I suggest organizing this list. You might want to, for instance, group some packages together that should be rebuilt or updated. You might also want to add any notes about software installed that is not packaged. It would be a good idea to refer to CHANGES_AND_HINTS.TXT again at this point.
** Begin Upgrade **
As root, go into runlevel 1.
If the files are on a cd then you will have to mount the other cd(s) in order to install the other packages. In my example, I was using a local mirror on my external hard drive (second partition).
The most basic way to upgrade/install all of the packages is to follow UPGRADE.TXT.
If you need any non-en_US language packs for KDE please refer to UPGRADE.TXT.
Also, if you don't want to upgrade/install certain packages (ie. blacklist them), then you will have to write a slightly more complicated script, install those package sections manually, or use something like slackpkg to help you.
** Alternative Mass Upgrade with slackpkg **
The trick to using slackpkg to do this is to specify a mount point as the mirror in /etc/slackpkg/mirrors. Since it is just a mount point, it does not matter what kind of device the partition is on as long as you can read it. In my case I had a local mirror on a NTFS partition on an external hard drive. I simply added the following to /etc/slackpkg/mirrors
It is also important to make sure /etc/slackpkg/blacklist has all the packages listed you don't want to be messed with. For instance, I do special things with my firefox packages so I list mozilla-firefox in the blacklist. Some people like to blacklist the kernel packages.
A keen observer might note that by default a/aaa_elflibs is already blacklisted, while the instructions in UPGRADE.TXT clearly have you installing them. In general, yes, aaa_elflibs should be blacklisted because it will overwrite your core libraries. During a full system upgrade, however, you can upgrade them, but you don't have to. The more important thing to realize is that this package is really only there to make sure you have the core libraries you need in case you do not do a full install of Slackware. As such, if you do a full install/upgrade of Slackware it is likely that you won't need that package anyways. If you aren't sure, simply check if all the files included are already installed (my pkg-sanity script or these other useful scripts may be of some help). In this upgrade, I found no libraries where missing from not installing it. If you do choose install it, for whatever reason, just make sure it is one of the first packages installed (which is probably why it has 'aaa' in the front). Another post on aaa_elflibs
Once your slackpkg configuration is all set, update with the new mirror
Note: By default, slackpkg will prompt you to handle new config files after installing/upgrading packages. If you need help on this skip down to the "Merge Changes for Config Files" section momentarily.
Upgrade all the packages
Since I was using fuse and ntfs-3g (both created via slackBuilds from slackBuilds.org) for my external NTFS partition, I decided not to upgrade those packages just to be safe. After all the other packages were installed I copied the packages to my hard drive, unmounted the external drive, stopped fuse (/etc/rc.d/rc.fuse stop), and then upgraded the fuse and ntfs-3g packages using upgradepkg. After that I started fuse and remounted the drive.
If you need any non-en_US language packs for KDE please refer to UPGRADE.TXT.
** Kernel Packages **
Keep in mind that the kernel image packages change the symlinks in /boot for System.map, config, and vmlinuz. This is important to note because a lot of people refer to vmlinuz in their boot manager's configuration. Which ever kernel image package is installed last (usually huge-smp) will have the symlinks pointing to its respective files. So, after upgrading your kernel packages you might have to fix these symlinks and modify your bootloader's configuration (/etc/lilo.conf for LILO) accordingly.
Also, if you ever modified your past kernel sources or built custom kernels, you should take a look in the following places to see if any clean up is necessary:
/usr/srcIn my case, I had a kernel sources folder and a module folder for a custom 22.214.171.124 kernel I had built that I needed to remove (I no longer intended to use them). I also had a rc.modules file for it that needed to be removed and the rc.modules symlink had to be fixed.
Please note that it is not recommended that you run the huge kernel for daily use (though it may not cause problems). Also, if you have one of those machines that don't work well with a SMP kernel you will need to patch your kernel sources.
Stock Kernels use UTF8 conole now
If you find you have problems with the console after this upgrade you might need to add the following append line for each of your kernel images listed in your /etc/lilo.conf. Personally, I had no such problems, so this was not needed for me.
This HowTo is continued at Post #19
Excellent post, shadowsnipes; I *really* like that you made many references to the existing documentation instead of trying to rewrite it.
Moderators, please sticky this, as it will surely be useful to people.
There are a couple of points I'd like to make:
1. No idea how I missed the two removed packages in C&H, but thanks for the note on those. I'll try to do better next time :)
2. About slackpkg leaving config files as *.orig, that is a *really* big issue in /etc/modprobe.d/ - the explanation about it is in C&H.
The slackpkg method is how I did it, but I used a normal mirror in /etc/slackpkg/mirrors. That way you don't need download the iso.
However, I'm sure I'm just being dense, I can't get slackpkg to generate a list of non-Slackware packages. When I run the second command (after the slackpkg update), I just get the slackpkg usage information output into NonSlackwarePackages.txt. I've edited the relevant files in /etc/slackpkg; is there some more obvious step I'm missing?
I apologize for the confusion. I'll edit my HowTo promptly.
Point them to slackpkg.org to get the latest stable release (2.70.4 at the moment), and then do two things:
1) add slackpkg to /etc/slackpkg/blacklist so that it doesn't try to "upgrade" itself back to the version in Slackware's /extra
2) keep an eye on slackpkg.org for future updates.
* making a mental note to see about upgrading slackpkg in /patches - 2.70.3 misses the kernel-headers package due to the weird ARCH designation in the full package name.
Or perhaps I just need to be more concise :)
By the way, I did add the Warning about extra (.orig) files under /etc/modprobe.d. Thanks for the reminder about this.
I managed to fit in the slackpkg info by taking out the new find commands I added to list and remove .orig files
I realize now that I could probably split the HowTo up into more than one post similar to how Shilo did in the "this is how I do it all" thread. I could just put a link at the end of the first post linking to the next.
This, of course, is not ideal, but doable. I'll wait to make any major changes like that until
1) I need to add/change enough information to warrant a need to split
2) I've gotten some feedback and know that splitting is the best feasible option
Thanks for the input everybody!
Upgrading to the latest version solved the problem, and revealed I have 147 packages installed that are not part of Slackware... looks like the clean install will take a while to get just how I like it! ;)
Thank <insert favourite deity here> for SlackBuilds!
Getting ready to upgrade 12.0 -> 12.1.
Reading all the posts, and the general consensus is that after the upgrade, I should recompile any custom software I built and installed.
And I should pull down the latest slackbuilds stuff and re-install that as well.
So my question is:
Why should I upgrade at all?? Why not just do a clean build if I'm going to have to reinstall/recompile everything anyway. (I realized the old stuff will work, but I'm talking recommended and best practices)
So I'm undecided...
I want to try an upgrade, but it seems like a little but of a waste of time..
I have a 10G / partition, and store all my data on another partition, so if I have to reinstall my added software anyway, I'm not sure what value an upgrade buy's me.
Thoughts and opinions?
Granted, assuming you save your packages, you could just reinstall them after a clean install. The big deciding factor on whether or not to do an upgrade versus a clean install is all in the little things. Usually there are some little things that, even if you back up all your files, you might forget. It takes a lot of work to restore all those random files, and when you upgrade only some of them might change, and then it is obvious which files you need to merge. However, you can't just restore a bunch of random files after a clean install because you are bound to clobber something. You have to know which ones to restore (unless you are just reinstalling your machine as the same version as your backup- then mass restore of course should work). Therefore, you are more likely to lost some of your settings.
So, in summary, if you are happy with how your system functions, I either recommend you don't do anything or upgrade. You are more likely to be able to keep all of your settings this way.
If you are not happy with your settings, or your system is not organized at all (unpackaged software cluttering up your system) and you want a fresh start, then a clean install is the obvious choice.
Keep in mind that even if you do a clean install, some of this guide may still apply such as getting list of non-slackware software, Miscellaneous Fixes, and the software rebuilding section.
These are just my opinions on the matter, so it might be nice to hear what others say as well.
I did a fresh install but this is a most informative thread.
Upgraded using "upgradepkg --install-new *tgz" in a ap d e f k kde n t tel x xap
I didn't check the lilo file & it failed to reboot (My fault).
The ps2 mouse didn't work rc.modules sorted this.
HP device didn't work so I reinstalled it, works fine.
This is my first upgrade as I usually reinstall, I have to say it went very well.
Do you think Windows is as easy to upgrade!
Thanks to all
As for the HP device:
Please make sure to read all of the documentation (especially UPGRADE.TXT and CHANGES_AND_HINTS.TXT) and thoroughly before (and after) upgrading or installing fresh -- it'll give you less headaches and a better system in the end.
I've just realized that by "reinstalling" HP Device Manager you may have meant reinstalling the 12.1 package (ie there was an error during the upgrade that you fixed), in which case you may have done the right thing. However, I'm not sure how you "reinstalled" the app and therefore will leave my above advice just in case it affects you.[/edit]
I have upgraded to 12.1 following your article:-)
|All times are GMT -5. The time now is 03:32 AM.|