Forum OpenACS Q&A: Moving users between OACS instances

Collapse
Posted by Helge Wilker on

One of my OACS installations seems to suffer from a somewhat brain-damaged database instance -- I probably modified one too many tables in there manually (and now have, among others, a problem creating subfolders in various circumstances). My plan now is to create a new database instance for this installation, which is still somewhat in development mode, but already has a number of live users.

To avoid having to re-register all of them, I would like to move (or copy?) them over to the new instance somehow. I have not yet looked at the data model code all that closely, so I'm hoping to get one of the following answers here:

  • "That's completely impossible, stupidhead! Can't you see all the referential integrity violations that is going to cause?"
  • "I'm not too sure what you're talking about, but good luck trying!"
  • "Sure, I wrote a SQL dump script for that once. Here it is!"

Obviously, the list is ordered in ascending preference :)

Note that there is no user-contributed content on the site, and even if there was, I would be contented (ha!) with losing that and only keeping the users, passwords etc.

Thanks in advance for all hints.

Collapse
Posted by Jade Rubick on
Helge, if you do a db_dump on Postgres, you get the SQL you need to add the users in. Just make the dump, and then look through it for parties, users, and so on. It will take a little work, but I think it could be done pretty easily.

You might want to start you new installation with the acs_object_seq (is that what it's called) set to a higher number than the acs_object_seq on your current install, so that you don't overlap.

Anybody else done this?

Collapse
Posted by Peter Alberer on

i have done a script that can export users, groups, group types, relationships and sitemap info, but you will have to use xotcl (=object oriented tcl, needs a module to run in aolserver) if you want to use it. the "cloning-package" as i call it can be found here. if you use it and have problems let me know, i did develop it for 4.5 and did not try it with the head version.