Difference between revisions of "Knowledge:Migration from 6.4.0 to 6.4.1"

From OpenKM Documentation
Jump to: navigation, search
(Created page with '* See [http://issues.openkm.com/changelog_page.php?version_id=71 changelog at Mantis] * Download update from http://openkm.com/download/okm/OpenKM-6.4.1.zip (eMpg8eIjY5) * Make…')
 
Line 6: Line 6:
  
 
* Stop Tomcat
 
* Stop Tomcat
 +
 +
* Run from your preferred SQL client these queries:
 +
 +
<source lang="sql">
 +
update OKM_CONFIG set CFG_VALUE='<b>Message: </b>${notificationMessage}<br/><b>User: </b>${userId}<br/><#list documentList as doc><b>Document: </b><a href="${doc.url}">${doc.path}</a><br/></#list>' where CFG_KEY='notification.message.body';
 +
update OKM_CONFIG set CFG_VALUE='OpenKM - NOTIFICATION' where CFG_KEY='notification.message.subject';
 +
</source>
 +
 +
'''MySQL'''
 +
<source lang="sql">
 +
-- Describe table
 +
describe OKM_NODE_DOCUMENT_VERSION;
 +
 +
-- Expand column
 +
alter table OKM_NODE_DOCUMENT_VERSION modify NDV_CHECKSUM varchar(128);
 +
</source>
 +
 +
'''PostgreSQL'''
 +
<source lang="sql">
 +
-- Describe table
 +
select column_name, udt_name, character_maximum_length from INFORMATION_SCHEMA.COLUMNS where table_name = 'okm_pending_task';
 +
 +
-- Expand column
 +
alter table OKM_NODE_DOCUMENT_VERSION alter column NDV_CHECKSUM type varchar(128);
 +
</source>
 +
 +
'''Oracle'''
 +
<source lang="sql">
 +
-- Describe table
 +
select * from user_tab_columns where table_name = 'OKM_NODE_DOCUMENT_VERSION' order by column_id;
 +
 +
-- Expand column
 +
alter table OKM_NODE_DOCUMENT_VERSION modify (NDV_CHECKSUM varchar2(128));
 +
</source>
  
 
* Edit [[OpenKM.cfg]] and set '''hibernate.hbm2ddl''' to '''update'''
 
* Edit [[OpenKM.cfg]] and set '''hibernate.hbm2ddl''' to '''update'''

Revision as of 08:17, 2 April 2013

  • Make a backup!!!
  • Stop Tomcat
  • Run from your preferred SQL client these queries:
update OKM_CONFIG set CFG_VALUE='<b>Message: </b>${notificationMessage}<br/><b>User: </b>${userId}<br/><#list documentList as doc><b>Document: </b><a href="${doc.url}">${doc.path}</a><br/></#list>' where CFG_KEY='notification.message.body';
update OKM_CONFIG set CFG_VALUE='OpenKM - NOTIFICATION' where CFG_KEY='notification.message.subject';

MySQL

-- Describe table
describe OKM_NODE_DOCUMENT_VERSION;

-- Expand column
alter table OKM_NODE_DOCUMENT_VERSION modify NDV_CHECKSUM varchar(128);

PostgreSQL

-- Describe table
select column_name, udt_name, character_maximum_length from INFORMATION_SCHEMA.COLUMNS where table_name = 'okm_pending_task';

-- Expand column
alter table OKM_NODE_DOCUMENT_VERSION alter column NDV_CHECKSUM type varchar(128);

Oracle

-- Describe table
select * from user_tab_columns where table_name = 'OKM_NODE_DOCUMENT_VERSION' order by column_id;

-- Expand column
alter table OKM_NODE_DOCUMENT_VERSION modify (NDV_CHECKSUM varchar2(128));
  • Edit OpenKM.cfg and set hibernate.hbm2ddl to update
  • Replace the OpenKM.war
  • Review file descriptor limit and, eventually, increase it.
  • Start Tomcat again
  • Check for database errors:
$ grep "ERROR .*hbm2ddl" $TOMCAT_HOME/logs/catalina.log
  • Enjoy OpenKM 6.4.1!

If you have any weird problem try to stop Tomcat, delete these folders:

  • $TOMCAT_HOME/webapps/OpenKM
  • $TOMCAT_HOME/work/Catalina/localhost

And start Tomcat again.


Nota clasica.png Recommended to clear browser cache and Java Plugin cache