Stories
Slash Boxes
Comments

Slash Open Source Project

Slashcode Log In

Log In

[ Create a new account ]

laotan (203)

laotan
  (email not shown publicly)
http://slash.openflows.org/

Journal of laotan (203)

Wednesday June 26, 02

attempt at an upgrade to the current cvs branch

07:09 AM
Bugs
so we run a number of different slash sites, the large majority of which running the 2.2.5 release. however i've setup and have been maintaining a few using the current cvs version of slash. the juxtaposition of the two has really enamored me to the cvs, and several times daily i pine to have all my sites running on the cvs (or at least the pre-2.3/4 code).

so i took it upon myself to attempt an upgrade, thanks in large part due to the existence of the sql/mysql/upgrades file. the problem however, was that there's a gap between where 2.2.5 left off, and the upgrades file began. so another purpose of my travails was to try and induce the schema that's missing.

my model for the upgrade was the file utils/slash2toslash2.2 which i had used and loved when upgrading from 2.0 to 2.2.

so i started by backing up the files, templates, and sql dump for the old site. i then proceeded to install a fresh slash install this time using the cvs version. it seemed much saner to me to start with a fresh install, and then import the data, rather than try and impose it over the old.

the tables in the old site that i figured i should in some way be interested in were: blocks, comment_text, comments, discussions, pollanswers, pollquestions, section_topics, sections, stories, story_text, story_param, templates, topics, users*, and vars. i then proceeded to run all of the sql upgrades from the sql/mysql/upgrades file to my old sql. in my mind this was a way to help the data get ready for the attempted transplant. once that was done i one by one inserted the old db table data into the new slash db.

now mind you, i was being selective about what i wanted to import. i didn't keep all blocks, and i didn't really care about things like the abusers table. however there were some problems, and some omissions from the ugprades file. the obviouis sql changes that i noticed were not in upgrades:

ALTER TABLE blocks ADD rss_template varchar(30) default NULL;
ALTER TABLE blocks ADD items smallint(6) NOT NULL default '0';

ALTER TABLE pollquestions ADD flags enum('ok','delete','dirty') NOT NULL default 'ok';

the import of the few blocks i wanted to keep was tricky, and i found i had to move the fields around a little to make them work. the real trouble however was with the users*.

the first thing i noticed was the lack of users_hits in the ugprade notes, and yet this seems to me to be a key part of why/how users* runs into trouble. i did however note this reference later in the upgrades file:

ALTER TABLE users_hits ADD COLUMN hits_bought_today SMALLINT UNSIGNED DEFAULT 0 NOT NULL AFTER hits_bought;

so i had to create users_hits, and then apply this sql statement. i also found i had to run:

ALTER TABLE users_info add people blob;

although in the end i was unable to really get the users* working, which really, was the most valued part of the upgrade for me. i sent an email to the slash-devel list and ericdano replied indicating he had the same experience during his attempted upgrade.

mind you i've still been playing with the new site, learning about the new release, playing with the templates, sections, etc. yet the users* still doesn't work. all the old users can log in, but don't stay logged in, new users can create an account, but as admin i cannot grant seclev or author access to other users. so i've still got some debugging ahead.

i made this attempt a few days ago, took some time to reflect, i've now written up this journal entry, and then perhaps from here i'll continue on to working on this users* problem.

Update:after posting this journal entry, peloy pointed out that tf23 had submitted a patch for the upgrades file to sourceforge. yipee. will have to try again :)

This discussion has been archived. No new comments can be posted.
The Fine Print: The following comments are owned by whoever posted them. We are not responsible for them in any way.
 Full
 Abbreviated
 Hidden
More | Login
Loading... please wait.