Using $TRANSFER to Move User Accounts
author:
ChristianRatliff
update: 18 September 2000, 2:05pm
valid: lilyCore-2.5b
-
What is $transfer?
This tool is required because MOO offers no intrinsic database upgrade capability. You cannot point MOO at a new database and tell it to merge the two. There are many reasons, but foremost among them is that while MOO understands the structure of the database, in terms of verbs and properties, it has no understanding of the design of the contents. It does not know, for instance, that a $player object is dependent on the $event_mgr and $review_mgr objects. These semantic dependencies are beyond the ability of MOO to digest at any point other than runtime.
To work around this there are two possible paths. First, you could dump out all of the objects, verbs, and properties and attempt to load them in. This was attempted several times, and it was never able to quite work. The transition from one design to another was often difficult.
An alternate plan was developed by GordonGoldberg?. His idea was to be user and discussion-centric rather than
code-centric. He designed a pair of commands called $transfer and $xferstat which dumped out all of the objects and properties associated with a user account, as a set of lily commands (sometimes =@eval=-based and sometimes =$command=-based). These commands were then run on a new lilyCore installation, and you now had an upgraded engine
with the same user content.
This code has been maintained by JohnHarvey?. He is working on a new design which is built from single units of transfer
and object level delegation. For more information on that please speak to him.
There are often patches to the $transfer object. You can find those patches in the directory listed here:
ftp://ftp.lily.org/pub/lily/core
-
Get the verb utilities package
The package names provided do not include version numbers. It is my recommendation that you download the version-oriented files only. At the time of this writing verb-utils-1.7.tar.gz is the most current version.
indikos% ftp ftp.lily.org
Connected to freefour.acs.rpi.edu.
220 freefour.acs.rpi.edu FTP server (Version 6.00) ready.
Name (ftp.lily.org:ratlifc): anonymous
Password: ratlifc@lily.org
ftp> cd pub/lily/utils
ftp> binary
ftp> get verb-utils.tar.gz
ftp> quit
indikos% gunzip -c verb-utils.tar.gz | tar xf -
indikos% cd verb-utils
-
Download the users from your old lilyCore instance
This guide assumes you are running these commands on the same machine, and that you have have the old instance at port 7777 and the new instance at 8888. The account name is the default one for lilyCore distributions.
The parameter to $transfer is a 0 or 1, where 0 means do not transfer the review buffers and 1 means transfer the review buffers.
indikos% ./run-command localhost 7777 root avatar '$transfer 1' > transfer.out 2> transfer.err
-
Check the output for errors
Look in the .out and .err files for errors. The $transfer command itself shows errors by the word 'ERROR:' at the begining of the line. This step can be run over and over again until the output is clean of errors.
indikos% more transfer.out
...
indikos% more transfer.err
...
Now trim off the stuff at the top and bottom of the transfer.err file. You should be left with only commands and memo/info files.
indikos% vi transfer.err
-
Upload the cleaned file to the new instance
This command may be run only once. If you need to repeat it, you will have to shutdown the new instance and replace the lilyCore.db file with the one you downloaded. It is reasonable to do this several times before everything comes through cleanly.
indikos% <b>./run-file localhost 8888 root avatar transfer.err > transfer.log 2>&1</b>
indikos% <b>more transfer.log</b>
...
-
Check your transfered instance
It is our recommendation that you have some of your users sanity check the new instance. They will look for little things you may miss. It also gives them a chance to try out any new features.
-- The above copied into the Wiki on 31 Dec 2003,
coming from an earlier write-up
$TRANSFER and the upcoming 2.8.0 release
While we have various interesting ideas for LilyInCvs, it should be noted that anyone hoping to upgrade to the (upcoming) 2.8.0 release is almost certainly going to have to do something $transfer-ish. Either that, or just throw away your old user base and start with a clean slate. There have been a huge number of changes made to verbs, default property values, new properties added, changes to verb_info() and property_info() for many things, objects re-parented, and some properties (or verbs) were moved around between objects. It took me probably two months to merge the RPI and "cr7" (a development core from ChristianRatliff), and both I and CoKe have made many changes in addition to that work. And the initial RPI core already had a lot of changes compared to the last officially distributed core.
In some sense, updating the verbs would be easy. Delete every verb in your core, add every verb from the new core, and forget about any local changes that you had. That's what a DIFF will probably tell you. Conceptually the same is true of properties, but you have to be a lot more careful adding/removing/moving properties around, or you'll lose all of the important information in your core. Having done some of this by hand, I suspect it is impossible to do (by hand) on any large scale.
So, people upgrading will probably want $TRANSFER to work, at least at the minimal level of copying users and discussions from an old core to a new one. I have done almost no work on that. I expect that some work will need to be done on $TRANSFER to get back into a usable state. Possibly a lot of work. Brave volunteers and testers would be welcome (unless everyone wants to take the easy way out and just start from scratch with the new release).
-- GaranceDrosehn - 01 Jan 2004
to top