Backtalk 1.4 Upgrade Guide

Version 1.4.6

© 1996-2003 Jan Wolter, Steve Weiss

Backtalk version 1.4 makes some changes in the formats of the user databases. For those sites that use Backtalk with Unix login accounts, these changes will have little impact and the upgrade can be done in the usual fashion. For sites using Backtalk accounts, extra work will be required to convert existing Backtalk 1.3 user accounts to work correctly with Backtalk 1.4.

Backtalk 1.4 also adds the option of keeping various conference data in the SQL database. I have not yet developed an upgrade procedure to convert non-SQL conferences into SQL conferences. I hope to do this soon. Meanwhile, there is no easy way to upgrade an existing conferencing system to use the --index=sql option.

If you had attachments enabled under Backtalk 1.3, or want to enable them under Backtalk 1.4, then some work needs to be done to transfer over the attachment database. Tools for that are now available.

The basic procedure to upgrade the user database is to use the 'dumpuser' tool under backtalk-1.3 to save a copy of your user database, and then use the 'loaduser' tool under Backtalk 1.4 to unpack it in the new format.

You should definately be using a procedure similar to what is recommended in the Install Manual, where you install the new release in a new directory, except in this case we won't be moving the user subdirectory over, but building a new one using the dumpuser/loaduser procedure.

Getting 'dumpuser' for Backtalk 1.3

We are going to use the dumpuser tool to get a dump of the Backtalk 1.3 user database, which we will later import into the new Backtalk 1.4 system. Unfortunately, dumpuser exists in a fully functional form only in the most recent releases of Backtalk 1.3. You'll need to have Backtalk version 1.3.26 or latter.

If you already have a sufficiently recent version of Backtalk, you probably still need to compile dumpuser, because it is not built by default in Backtalk 1.3. Go to the src directory of your Backtalk distribution tree and run make dumpuser to build it.

If you don't already have a new enough Backtalk, you don't have to do a full upgrade to get dumpuser. Use a configure command pretty much identical to the one you used for your current Backtalk install - with the same user database configuration and the same --prefix setting so that it points to the current active backtalk data directory. Then just do make dumpuser in the src directory. You don't need to build the rest of backtalk or edit any config.bt scripts.

If you your system is configured with owner-id (the unix account that owns the backtalk files) different than httpd-id (the unix account that CGI programs run as) then the dumpuser program needs to be owned by httpd-id and have it's set-uid bit set. This gets tricky to achieve if you use don't have root access. You often end up having to write a CGI to execute the commands to change ownership and set the set-uid bit. Easiest might be just to do the "make open-perms", "make install-binaries-httpd", and "make restore-perms" steps from part IVA of the Install Manual, and using the CGI script described there for the second command in the sequence.

Once you have a working dumpuser command, you can dump the user database just by doing

  dumpuser > users.dump
You probably don't want to do your final user database dump until shortly before you do the switch over, but you can inspect the dump to see if it looks right. The format of the dump file is documented in the Backtalk File Formats document.

Installation of Backtalk 1.4

Now we start the install of version 1.4, for the most part, following the usual procedure. In the Configuration Step I recommend setting up new install directories, so we won't be overwriting the 1.3 install with the 1.4 install. You might consider whether you want to use different user database configuration options than you previously did. As long as we are going to dump and reload the user database anyway, there is no particular reason to use the same user database configuration.

If you choose to use an SQL database for Backtalk 1.4, create a new one. I recommend not using the same one you used for Backtalk 1.3. If you use the same one, you'll have to erase it, dropping all tables, before starting the Backtalk 1.4 install. Obviously you should run dumpuser and probably mysqldump before erasing it. In any case, edit misc/backtalk.conf to point to the new database, as described in part III of the install manual.

Run the make commands listed in part IVA of the install manual including the "make install-users" commands, but not the "make install-bbs", because we do want to create a new user database, but not a new conference database. You'll be prompted for a password for a cfadm account during this stage, but don't worry about it too much - we'll be deleting this cfadm before loaded the user database from the previous incarnation.

Install the conferences using the usual procedure of moving the 1.3 bbs directory into the 1.4 directory, and replacing it with a symlink (see the Install Manual for details).

You should be able to do some basic testing of the Backtalk system at this point, using the temporary cfadm account that you created. You can do various editting of the config files at this stage, or after the user database has been imported.

Set up of Attachment Index under Backtalk 1.4

If you are going to enable attachments under Backtalk 1.4 then you'll need to copy over the attachements and the attachment index (if you had attachments enabled in the previous system) or create a new attachment database (if you didn't). If you aren't using attachments, you can skip this section.

The attachment files themselves live in the bbs/attach directory, so linking over the bbs directory should take care of copying them over. If you are not using SQL in your Backtalk system, then the index of attachments is in a DBM file named index in that subdirectory, and that should be OK too.

But if the Backtalk 1.4 system uses SQL, then you'll need to copy the attachment index into the new SQL system. First, create the database tables for the attachment index. There should be a program called 'sqlinit' in the Backtalk distribution's src directory (if there isn't do 'make sqlinit' to compile it). To create the SQL attachment database, do:

   sqlinit baai
If you weren't using attachments under Backtalk 1.3 then you are done.

If you were using attachments under Backtalk 1.3 then you need to copy the old attachment index over. First go to the source directory where you built dumpuser (Backtalk 1.3.26 or later) and do

   make dumpattach
   dumpattach > attach.dump
This compiles the dumpattach program and dumps the attachment list from Backtalk 1.3 into the attach.dump file. Move that file over to the Backtalk 1.4 distribution's src directory and do
   make loadattach
   loadattach < attach.dump
That should do it. Note that neither loadattach nor dump attach need to have any set-uid bits set.

Import of old users into Backtalk 1.4

First, let's get rid of the cfadm account that was automatically created by the install scripts. We'll use the btrmuser command that is installed in the bin directory in the Backtalk data directory:
   btrmuser cfadm
Now we have a nice empty user database.

Then we use the loaduser command installed in bin directory under the Backtalk 1.4 directory (the one in the src directory may not have correct set-uid permissions set).

   loaduser < users.dump
Here users.dump is the name of the dumpfile generated by the Backtalk 1.3 dumpuser command.

That should be all there is to it. Finish up the rest of the configuration in the usual way.