Connect. Communicate. Collaborate. Securely.

Home » Kerio User Forums » Kerio Workspace » Backup Failure (Can't run a backup of Workspace)
  •  
iHelp IT

Messages: 5
Karma: 0
Send a private message to this user
Hi,

I'm running Starter Edition for a customer (ver 2.0.1 running on an ESXi Host). I did a setup on a different system, backed up the data and then restored onto their system. The data has come across all fine but backups won't run. At first there were some ownership issues with the backup folder. It was owned by root for some reason. After that was fixed, backups still don't run but I'm getting lots of SQL and java errors in the debug log. Can anyone shed some light on what could be causing this and a fix?

[22/Jan/2013 10:52:01] {com.kerio.workspace} INFO: Backup type MIRROR started manually
[22/Jan/2013 10:52:01] {com.kerio.workspace} INFO: Backup task (MIRROR) started
[22/Jan/2013 10:52:01] {com.kerio.workspace.backup} DEBUG: Backup config started
[22/Jan/2013 10:52:01] {com.kerio.workspace.backup} DEBUG: Backup config finished
[22/Jan/2013 10:52:01] {com.kerio.workspace.backup} DEBUG: Backup database started
[22/Jan/2013 10:52:01] {com.kerio.workspace.backup} DEBUG: Creating tempdir
[22/Jan/2013 10:52:01] {com.kerio.workspace.backup} DEBUG: Calling SYSCS_UTIL.SYSCS_BACKUP_DATABASE()
[22/Jan/2013 10:52:01] {org.hibernate.engine.jdbc.spi.SqlExceptionHelper} WARN: SQL Error: 20000, SQLState: 38000
[22/Jan/2013 10:52:01] {org.hibernate.engine.jdbc.spi.SqlExceptionHelper} ERROR: The exception 'java.lang.NullPointerException' was thrown while evaluating an expression.
[22/Jan/2013 10:52:01] {org.hibernate.engine.jdbc.spi.SqlExceptionHelper} WARN: SQL Error: 0, SQLState: XJ001
[22/Jan/2013 10:52:01] {org.hibernate.engine.jdbc.spi.SqlExceptionHelper} ERROR: Java exception: ': java.lang.NullPointerException'.
[22/Jan/2013 10:52:01] {com.kerio.workspace.backup} DEBUG: Removing tempdir
[22/Jan/2013 10:52:01] {com.kerio.workspace} ERROR: Backup task (MIRROR) failed:
org.hibernate.exception.GenericJDBCException: The exception 'java.lang.NullPointerException' was thrown while evaluating an expression.
	at org.hibernate.exception.internal.StandardSQLExceptionConverter.convert(StandardSQLExceptionConverter.java:54)
	at org.hibernate.engine.jdbc.spi.SqlExceptionHelper.convert(SqlExceptionHelper.java:125)
	at org.hibernate.engine.jdbc.spi.SqlExceptionHelper.convert(SqlExceptionHelper.java:110)
	at org.hibernate.engine.jdbc.internal.proxy.AbstractStatementProxyHandler.continueInvocation(AbstractStatementProxyHandler.java:129)
	at org.hibernate.engine.jdbc.internal.proxy.CallableStatementProxyHandler.continueInvocation(CallableStatementProxyHandler.java:49)
	at org.hibernate.engine.jdbc.internal.proxy.AbstractProxyHandler.invoke(AbstractProxyHandler.java:81)
	at $Proxy22.execute(Unknown Source)
	at com.kerio.workspace.backup.BackupService$1.execute(BackupService.java:332)
	at org.hibernate.jdbc.WorkExecutor.executeWork(WorkExecutor.java:54)
	at org.hibernate.internal.SessionImpl$1.accept(SessionImpl.java:1850)
	at org.hibernate.internal.SessionImpl$1.accept(SessionImpl.java:1847)
	at org.hibernate.engine.jdbc.internal.JdbcCoordinatorImpl.coordinateWork(JdbcCoordinatorImpl.java:211)
	at org.hibernate.internal.SessionImpl.doWork(SessionImpl.java:1868)
	at org.hibernate.internal.SessionImpl.doWork(SessionImpl.java:1854)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
	at java.lang.reflect.Method.invoke(Unknown Source)
	at org.hibernate.context.internal.ThreadLocalSessionContext$TransactionProtectionWrapper.invoke(ThreadLocalSessionContext.java:352)
	at $Proxy16.doWork(Unknown Source)
	at com.kerio.workspace.backup.BackupService.backupDB(BackupService.java:346)
	at com.kerio.workspace.backup.BackupService.doBackup(BackupService.java:202)
	at com.kerio.workspace.backup.BackupService.access$000(BackupService.java:36)
	at com.kerio.workspace.backup.BackupService$BackupType$1.execute(BackupService.java:83)
	at it.sauronsoftware.cron4j.TaskExecutor$Runner.run(Unknown Source)
	at java.lang.Thread.run(Unknown Source)
Caused by: java.sql.SQLException: The exception 'java.lang.NullPointerException' was thrown while evaluating an expression.
	at org.apache.derby.impl.jdbc.SQLExceptionFactory40.getSQLException(Unknown Source)
	at org.apache.derby.impl.jdbc.Util.newEmbedSQLException(Unknown Source)
	at org.apache.derby.impl.jdbc.Util.seeNextException(Unknown Source)
	at org.apache.derby.impl.jdbc.TransactionResourceImpl.wrapInSQLException(Unknown Source)
	at org.apache.derby.impl.jdbc.TransactionResourceImpl.handleException(Unknown Source)
	at org.apache.derby.impl.jdbc.EmbedConnection.handleException(Unknown Source)
	at org.apache.derby.impl.jdbc.ConnectionChild.handleException(Unknown Source)
	at org.apache.derby.impl.jdbc.EmbedStatement.executeStatement(Unknown Source)
	at org.apache.derby.impl.jdbc.EmbedPreparedStatement.executeStatement(Unknown Source)
	at org.apache.derby.impl.jdbc.EmbedCallableStatement.executeStatement(Unknown Source)
	at org.apache.derby.impl.jdbc.EmbedPreparedStatement.execute(Unknown Source)
	at com.mchange.v2.c3p0.impl.NewProxyCallableStatement.execute(NewProxyCallableStatement.java:3044)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
	at java.lang.reflect.Method.invoke(Unknown Source)
	at org.hibernate.engine.jdbc.internal.proxy.AbstractStatementProxyHandler.continueInvocation(AbstractStatementProxyHandler.java:122)
	... 22 more
Caused by: java.sql.SQLException: The exception 'java.lang.NullPointerException' was thrown while evaluating an expression.
	at org.apache.derby.impl.jdbc.SQLExceptionFactory.getSQLException(Unknown Source)
	at org.apache.derby.impl.jdbc.SQLExceptionFactory40.wrapArgsForTransportAcrossDRDA(Unknown Source)
	... 39 more
Caused by: java.sql.SQLException: Java exception: ': java.lang.NullPointerException'.
	at org.apache.derby.impl.jdbc.SQLExceptionFactory.getSQLException(Unknown Source)
	at org.apache.derby.impl.jdbc.SQLExceptionFactory40.wrapArgsForTransportAcrossDRDA(Unknown Source)
	at org.apache.derby.impl.jdbc.SQLExceptionFactory40.getSQLException(Unknown Source)
	at org.apache.derby.impl.jdbc.Util.newEmbedSQLException(Unknown Source)
	at org.apache.derby.impl.jdbc.Util.javaException(Unknown Source)
	at org.apache.derby.impl.jdbc.TransactionResourceImpl.wrapInSQLException(Unknown Source)
	... 36 more
Caused by: java.lang.NullPointerException
	at org.apache.derby.impl.store.raw.RawStore.logHistory(Unknown Source)
	at org.apache.derby.impl.store.raw.RawStore.backup(Unknown Source)
	at org.apache.derby.impl.store.raw.RawStore.backup(Unknown Source)
	at org.apache.derby.impl.store.access.RAMAccessManager.backup(Unknown Source)
	at org.apache.derby.impl.db.BasicDatabase.backup(Unknown Source)
	at org.apache.derby.catalog.SystemProcedures.SYSCS_BACKUP_DATABASE(Unknown Source)
	at org.apache.derby.exe.ac9b8ed821x0139xd1c2x08dexffffedaf78ab1.g0(Unknown Source)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
	at java.lang.reflect.Method.invoke(Unknown Source)
	at org.apache.derby.impl.services.reflect.ReflectMethod.invoke(Unknown Source)
	at org.apache.derby.impl.sql.execute.CallStatementResultSet.open(Unknown Source)
	at org.apache.derby.impl.sql.GenericPreparedStatement.executeStmt(Unknown Source)
	at org.apache.derby.impl.sql.GenericPreparedStatement.execute(Unknown Source)
	... 32 more
  •  
Lucian Maly (Kerio)

Messages: 136
Karma: 8
Send a private message to this user
It seems like the backup file has been corrupted. Did you get some errors while creating these backups? Are you able to successfully unzip all the backup files?

Kerio Technologies AU Pty Ltd.
  •  
iHelp IT

Messages: 5
Karma: 0
Send a private message to this user
Hi Lucian.

The backup file that I used to restore the data I migrated works just fine. No errors at all. The system works as advertised but I can't run a backup on the new system. Every time I do I get those same messages with no files created in the backup directory.
  •  
Lucian Maly (Kerio)

Messages: 136
Karma: 8
Send a private message to this user
What is the new OS that you migrated to? It could be permission issue either to the Temp directory or Backup directory. Temporary directory must be created for DB backup and that can eventually fail on MAC/Linux. Tomcat temporary directory (instead of system temp) is used for backup operation and it may have wrong permission, so you need to check that.

Kerio Technologies AU Pty Ltd.
  •  
iHelp IT

Messages: 5
Karma: 0
Send a private message to this user
Both were Starter Edition ver 2.0.1. The system I migrated from was the VMX VM and the system I migrated to was the OVF VM for ESXi. I haven't checked which versions of Debian were running in each.

Can you tell me the path/s I need to check and what the permissions/ownership should be for these temp directories in these VMs? The backup directory already had root as the owner so I wouldn't be surprised if this was a problem elsewhere.
  •  
iHelp IT

Messages: 5
Karma: 0
Send a private message to this user
Confirmed /opt/kerio/workspace/tomcat/temp has ownership of kworkspace:kworkspace and perms of 755. Looks like it's not a problem with permissions or ownership.

Do you know what those sql and null pointer exception messages near the top refer to?
  •  
Tomas Laubr (Kerio)

Messages: 34
Karma: 2
Send a private message to this user
Hello.
What about permissions to store/db directory? It seems to be a problem with writing a history.

Caused by: java.lang.NullPointerException
at org.apache.derby.impl.store.raw.RawStore.logHistory(Unknown Source)

When you perform a backup, a BACKUP.HISTORY file will be created in store/db directory.
  •  
iHelp IT

Messages: 5
Karma: 0
Send a private message to this user
Thanks for that. The store/db directory itself was ok but the BACKUP.HISTORY and service.properties files inside it were owned by root. I changed them kworkspace:kworkspace and I can now backup. Thanks for your help.
Previous Topic: Problem after install workspace version 2.0
Next Topic: Doesn't shut down properly on CentOS 5.8
Goto Forum:
  


Disclaimer:
Kerio discussion forums are intended for open communication between forum members and may contain information and material posted by members which may be useful in learning about Kerio products. The discussion forums are not intended to provide technical support for any specific product. Any information implied or expressed in the discussion forums is that of the posting member. Kerio is in no way responsible for the information posted in the forums, or its accuracy. Kerio employees may participate in the discussions, but their postings do not represent an offical position of the company on any issues raised or discussed. Kerio reserves the right to monitor and maintain the forums to promote free and accurate exchange of information.

Current Time: Sat Aug 19 14:59:29 CEST 2017

Total time taken to generate the page: 0.00446 seconds
.:: Contact :: Home ::.
Powered by: FUDforum 3.0.4.