Statistics
| Branch: | Tag: | Revision:

root / README.upgrade @ d58ac891

History | View | Annotate | Download (2.5 kB)

1 4a1c29ea Antony Chazapis
UPGRADE
2 4a1c29ea Antony Chazapis
=======
3 4a1c29ea Antony Chazapis
4 4a1c29ea Antony Chazapis
0.7.9 -> 0.7.10
5 4a1c29ea Antony Chazapis
---------------
6 315f4bae Antony Chazapis
* Update settings.py (BACKEND_*, SERVICE_NAME, *_EMAIL, *_TARGET, IM_*)
7 c95d1471 Antony Chazapis
* Update 'attributes' table in mysql (backend):
8 4a1c29ea Antony Chazapis
    
9 c95d1471 Antony Chazapis
    mysql> update attributes set `key`='ETag' where `key`='hash';
10 c95d1471 Antony Chazapis
11 c95d1471 Antony Chazapis
* Upgrade 'im_user' table (im app):
12 c95d1471 Antony Chazapis
    
13 c95d1471 Antony Chazapis
    ALTER TABLE im_user ADD COLUMN 'password' VARCHAR(255);
14 4a1c29ea Antony Chazapis
15 10273d76 Antony Chazapis
0.7.10 -> 0.8.0
16 cb446fb8 Antony Chazapis
---------------
17 7f5c469e Antony Chazapis
* Upgrade 'public' table in mysql (backend):
18 7f5c469e Antony Chazapis
	* Run: mysqldump pithosdb public > public-table.sql
19 7f5c469e Antony Chazapis
	* mysql> drop table public;
20 7f5c469e Antony Chazapis
	* Update the codebase and run the server so the new public table is created
21 7f5c469e Antony Chazapis
	* From the sql dump above, take the row:
22 7f5c469e Antony Chazapis
	    
23 7f5c469e Antony Chazapis
		INSERT INTO `public` VALUES (...);
24 7f5c469e Antony Chazapis
      
25 13797bc1 Antony Chazapis
          Rewrite as:
26 7f5c469e Antony Chazapis
	    
27 7f5c469e Antony Chazapis
		INSERT INTO `public`(`path`) VALUES (...);
28 7f5c469e Antony Chazapis
	  
29 7f5c469e Antony Chazapis
	  And execute in the database
30 315f4bae Antony Chazapis
* Create settings.local with local setting overrides
31 0f8ffac4 Antony Chazapis
* Install python-django-south
32 0f8ffac4 Antony Chazapis
* Setup south:
33 0c581627 Sofia Papagiannaki
    python manage.py syncdb
34 0c581627 Sofia Papagiannaki
    python manage.py migrate im 0001 --fake
35 0c581627 Sofia Papagiannaki
    python manage.py migrate im
36 cb446fb8 Antony Chazapis
37 cb446fb8 Antony Chazapis
0.8.0 -> 0.8.1
38 cb446fb8 Antony Chazapis
--------------
39 cb446fb8 Antony Chazapis
* Reset 'policy' table in mysql (backend):
40 cb446fb8 Antony Chazapis
    
41 cb446fb8 Antony Chazapis
    mysql> update policy set `value`='auto' where `key`='versioning';
42 1e20eb36 Antony Chazapis
43 1e20eb36 Antony Chazapis
0.8.1 -> 0.8.2
44 1e20eb36 Antony Chazapis
--------------
45 1e20eb36 Antony Chazapis
* Add the 'X-Forwarded-Protocol' header directive in the apache configuration, as described in the admin guide
46 d4493d99 Antony Chazapis
* Update 'attributes' table in mysql (backend):
47 d4493d99 Antony Chazapis
    
48 d4493d99 Antony Chazapis
    mysql> CREATE TABLE `attributes_new` (
49 d4493d99 Antony Chazapis
               `serial` int(11) NOT NULL,
50 d4493d99 Antony Chazapis
               `domain` varchar(255) COLLATE utf8_bin NOT NULL,
51 d4493d99 Antony Chazapis
               `key` varchar(255) COLLATE utf8_bin NOT NULL,
52 d4493d99 Antony Chazapis
               `value` varchar(255) COLLATE utf8_bin DEFAULT NULL,
53 d4493d99 Antony Chazapis
               PRIMARY KEY (`serial`,`domain`,`key`),
54 d4493d99 Antony Chazapis
               CONSTRAINT FOREIGN KEY (`serial`) REFERENCES `versions` (`serial`) ON DELETE CASCADE ON UPDATE CASCADE
55 d4493d99 Antony Chazapis
           ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
56 d4493d99 Antony Chazapis
    mysql> insert into attributes_new select `serial`, 'pithos', `key`, `value` from attributes;
57 d4493d99 Antony Chazapis
    mysql> drop table attributes;
58 d4493d99 Antony Chazapis
    mysql> alter table attributes_new rename to attributes;
59 044f4210 Antony Chazapis
60 044f4210 Antony Chazapis
* Update 'versions' table in mysql (backend):
61 044f4210 Antony Chazapis
    
62 044f4210 Antony Chazapis
    mysql> create temporary table tmp_uuids as select distinct node, uuid() as `uuid` from versions;
63 044f4210 Antony Chazapis
    mysql> alter table versions add column `uuid` varchar(64) DEFAULT '' NOT NULL after `muser`;
64 044f4210 Antony Chazapis
    mysql> update versions v, tmp_uuids u set v.`uuid` = u.`uuid` where v.`node` = u.`node`;
65 044f4210 Antony Chazapis
    mysql> create index idx_versions_node_uuid on versions(uuid);
66 afb8520d Antony Chazapis
67 afb8520d Antony Chazapis
0.8.2 -> 0.9.0
68 afb8520d Antony Chazapis
--------------
69 afb8520d Antony Chazapis
* No upgrade path provided. Please reinstall and reconfigure.