Analytics stopped working

Hi,

Analytics stopped working before. So with Jess’s assistance, I have remove the dwh database and created it again.
Now, after 4 days, it has stopped working again.

That’s all I can see in the logs:
ERROR 29-12 16:59:09,286 - Run kjbVar job - Unable to open file appender for file [${LogPath}/log_${jobVar}.log] : org.pentaho.di.core.exception.KettleFileException:
ERROR 29-12 16:59:09,286 - Run kjbVar job - org.pentaho.di.core.exception.KettleFileException:
ERROR 29-12 16:59:09,288 - Abort job 1 - Aborting job.

Hello,

What does:
# grep ERROR /opt/kaltura/dwh/logs/*

return?

/opt/kaltura/dwh/logs/etl_update_dims-20141221-05.log:ERROR 21-12 05:00:06,308 - iterate_sequences - Errors detected!
/opt/kaltura/dwh/logs/etl_update_dims-20141221-05.log:ERROR 21-12 05:00:06,308 - iterate_sequences - Errors detected!
/opt/kaltura/dwh/logs/etl_update_dims-20141228-04.log:ERROR 28-12 04:00:09,749 - Get rows from result - Unexpected error
/opt/kaltura/dwh/logs/etl_update_dims-20141228-04.log:ERROR 28-12 04:00:09,749 - Get rows from result - java.lang.NullPointerException
/opt/kaltura/dwh/logs/etl_update_dims-20141228-04.log:ERROR 28-12 04:00:09,750 - iterate_sequences - Errors detected!
/opt/kaltura/dwh/logs/etl_update_dims-20141228-04.log:ERROR 28-12 04:00:09,750 - iterate_sequences - Errors detected!

/opt/kaltura/dwh/logs/etl_daily-20141230.log:ERROR 30-12 12:59:06,945 - Run kjbVar job - Unable to open file appender for file [${LogPath}/log_${jobVar}.log] : org.pentaho.di.core.exception.KettleFileException:
/opt/kaltura/dwh/logs/etl_daily-20141230.log:ERROR 30-12 12:59:06,945 - Run kjbVar job - org.pentaho.di.core.exception.KettleFileException:
/opt/kaltura/dwh/logs/etl_daily-20141230.log:ERROR 30-12 12:59:06,948 - Abort job 1 - Aborting job.

That’s all the errors that appeared after reinstalling dwh

Hi,

Not sure why you had to reinstall it but in any case, what exactly did you do?
Thanks,

I reinstalled because analytics DB got corrupted.
After reinstalling, it worked fine for 4 days.

Here’s the procedure you gave me to reinstall:
Your problem is a missing stored procedure - kalturadw.calc_partner_usage_data.
I am not sure how this happened to you since when a DB exists, it does not get deleted or updated when running kaltura-config-all.sh since it check whether or not the DB exists and skips if so.

You can, AFTER creating backups of the entire DB just in case, drop all the DWH DBs using:
PASSWD=YOURPASSWD
for i in mysql -N -p$PASSWD kalturadw_bisources -e “show tables”;do mysql -p$PASSWD kalturadw_bisources -e “drop table $i”;done
for i in mysql -N -p$PASSWD kalturadw -e “show tables”;do mysql -p$PASSWD kalturadw -e “drop table $i”;done
for i in mysql -N -p$PASSWD kalturadw_ds -e “show tables”;do mysql -p$PASSWD kalturadw_ds -e “drop table $i”;done
for i in mysql -N -p$PASSWD kalturalog -e “show tables”;do mysql -p$PASSWD kalturalog -e “drop table $i”;done
for i in mysql -p$PASSWD -e “Show procedure status” |grep kalturadw|awk -F " " ‘{print $2}’;do mysql kalturadw -p$PASSWD -e “drop procedure $i;”;done
for i in mysql -p$PASSWD -e “Show procedure status” |grep kalturadw_ds|awk -F " " ‘{print $2}’;do mysql kalturadw_ds -p$PASSWD -e “drop procedure $i;”;done

And then re-running kaltura-dwh-config.sh

You will lose your current stats though, of course.