upgrade database not fully upgraded

Ask your questions regarding TimeTrex installation here.
Post Reply
davej
Posts: 12
Joined: Fri Apr 15, 2022 11:28 am

upgrade database not fully upgraded

Post by davej »

I just upgraded TimeTrex from an older version to the version downloaded today, 4/11/2022, on Ubuntu 21.04.

I completed the install as specified in the how-to.

i then went to the http://<web server address>/<timetrex directory>/interface/install/install.php

I authenticated the database correctly, but the install hangs at ~96% and does not proceed afterward, thus having to interrupt it.

(in the installation (apt-get) I did as recommended in the dialog and selected 'no' if i will be connecting to an old database (not creating a new one)
shaunw
Posts: 7839
Joined: Tue Sep 19, 2006 2:22 pm

Re: upgrade database not fully upgraded

Post by shaunw »

Please upload your TimeTrex log file to our secure upload site then reply here in the forums to let us know the file name that you uploaded:
https://www.timetrex.com/r.php?id=secure_upload
davej
Posts: 12
Joined: Fri Apr 15, 2022 11:28 am

Re: upgrade database not fully upgraded

Post by davej »

uploaded. thank you. timetrex.log
shaunw
Posts: 7839
Joined: Tue Sep 19, 2006 2:22 pm

Re: upgrade database not fully upgraded

Post by shaunw »

Unfortunately it appears that PHP may be crashing as the log file doesn't contain any useful information or error messages. Do you have a Apache or PHP error log from the day you attempted the upgrade that you could send as well?
davej
Posts: 12
Joined: Fri Apr 15, 2022 11:28 am

Re: upgrade database not fully upgraded

Post by davej »

i've had recent issues with the "processing" screen circling and not progressing. thats why i thought it would be a good idea to upgrade today.

i've uploaded the file errorFa.log, accessFA.log, and php7.4-fpmFA.log

thank you
shaunw
Posts: 7839
Joined: Tue Sep 19, 2006 2:22 pm

Re: upgrade database not fully upgraded

Post by shaunw »

Other than a few errors about being unable to connect to your database from earlier in the day, I don't see anything helpful in those error logs unfortunately.

One other thing you could try is running the following command (with the proper path of course):

Code: Select all

php /var/www/timetrex/tools/unattended_upgrade.php -f --schema_only
See if that succeeds or gives you any error messages.
davej
Posts: 12
Joined: Fri Apr 15, 2022 11:28 am

Re: upgrade database not fully upgraded

Post by davej »

this is the error it gives me now. i also cannot run it as root, will not allow as root

Force Mode enabled...
PHP Warning: opendir(/tmp/timetrex/cache_4/): failed to open dir: Permission denied in /var/www/html/timetrex/vendor/pear/cache_lite/Cache/Lite.php on line 642
PHP Warning: opendir(/tmp/timetrex/cache_b/): failed to open dir: Permission denied in /var/www/html/timetrex/vendor/pear/cache_lite/Cache/Lite.php on line 642
PHP Warning: opendir(/tmp/timetrex/cache_7/): failed to open dir: Permission denied in /var/www/html/timetrex/vendor/pear/cache_lite/Cache/Lite.php on line 642
PHP Warning: opendir(/tmp/timetrex/cache_2/): failed to open dir: Permission denied in /var/www/html/timetrex/vendor/pear/cache_lite/Cache/Lite.php on line 642
PHP Warning: opendir(/tmp/timetrex/cache_1/): failed to open dir: Permission denied in /var/www/html/timetrex/vendor/pear/cache_lite/Cache/Lite.php on line 642
PHP Warning: opendir(/tmp/timetrex/cache_6/): failed to open dir: Permission denied in /var/www/html/timetrex/vendor/pear/cache_lite/Cache/Lite.php on line 642
PHP Warning: opendir(/tmp/timetrex/cache_a/): failed to open dir: Permission denied in /var/www/html/timetrex/vendor/pear/cache_lite/Cache/Lite.php on line 642
PHP Warning: opendir(/tmp/timetrex/cache_0/): failed to open dir: Permission denied in /var/www/html/timetrex/vendor/pear/cache_lite/Cache/Lite.php on line 642
PHP Warning: opendir(/tmp/timetrex/cache_9/): failed to open dir: Permission denied in /var/www/html/timetrex/vendor/pear/cache_lite/Cache/Lite.php on line 642
PHP Warning: opendir(/tmp/timetrex/cache_5/): failed to open dir: Permission denied in /var/www/html/timetrex/vendor/pear/cache_lite/Cache/Lite.php on line 642
PHP Warning: opendir(/tmp/timetrex/cache_3/): failed to open dir: Permission denied in /var/www/html/timetrex/vendor/pear/cache_lite/Cache/Lite.php on line 642
PHP Warning: opendir(/tmp/timetrex/cache_8/): failed to open dir: Permission denied in /var/www/html/timetrex/vendor/pear/cache_lite/Cache/Lite.php on line 642
PHP Warning: opendir(/tmp/timetrex/cache_f/): failed to open dir: Permission denied in /var/www/html/timetrex/vendor/pear/cache_lite/Cache/Lite.php on line 642
PHP Warning: opendir(/tmp/timetrex/cache_4/): failed to open dir: Permission denied in /var/www/html/timetrex/vendor/pear/cache_lite/Cache/Lite.php on line 642
PHP Warning: opendir(/tmp/timetrex/cache_b/): failed to open dir: Permission denied in /var/www/html/timetrex/vendor/pear/cache_lite/Cache/Lite.php on line 642
PHP Warning: opendir(/tmp/timetrex/cache_7/): failed to open dir: Permission denied in /var/www/html/timetrex/vendor/pear/cache_lite/Cache/Lite.php on line 642
PHP Warning: opendir(/tmp/timetrex/cache_2/): failed to open dir: Permission denied in /var/www/html/timetrex/vendor/pear/cache_lite/Cache/Lite.php on line 642
PHP Warning: opendir(/tmp/timetrex/cache_1/): failed to open dir: Permission denied in /var/www/html/timetrex/vendor/pear/cache_lite/Cache/Lite.php on line 642
PHP Warning: opendir(/tmp/timetrex/cache_6/): failed to open dir: Permission denied in /var/www/html/timetrex/vendor/pear/cache_lite/Cache/Lite.php on line 642
PHP Warning: opendir(/tmp/timetrex/cache_a/): failed to open dir: Permission denied in /var/www/html/timetrex/vendor/pear/cache_lite/Cache/Lite.php on line 642
PHP Warning: opendir(/tmp/timetrex/cache_0/): failed to open dir: Permission denied in /var/www/html/timetrex/vendor/pear/cache_lite/Cache/Lite.php on line 642
PHP Warning: opendir(/tmp/timetrex/cache_9/): failed to open dir: Permission denied in /var/www/html/timetrex/vendor/pear/cache_lite/Cache/Lite.php on line 642
PHP Warning: opendir(/tmp/timetrex/cache_5/): failed to open dir: Permission denied in /var/www/html/timetrex/vendor/pear/cache_lite/Cache/Lite.php on line 642
PHP Warning: opendir(/tmp/timetrex/cache_3/): failed to open dir: Permission denied in /var/www/html/timetrex/vendor/pear/cache_lite/Cache/Lite.php on line 642
PHP Warning: opendir(/tmp/timetrex/cache_8/): failed to open dir: Permission denied in /var/www/html/timetrex/vendor/pear/cache_lite/Cache/Lite.php on line 642
PHP Warning: opendir(/tmp/timetrex/cache_f/): failed to open dir: Permission denied in /var/www/html/timetrex/vendor/pear/cache_lite/Cache/Lite.php on line 642
PHP Warning: opendir(/tmp/timetrex/cache_4/): failed to open dir: Permission denied in /var/www/html/timetrex/vendor/pear/cache_lite/Cache/Lite.php on line 642
PHP Warning: opendir(/tmp/timetrex/cache_b/): failed to open dir: Permission denied in /var/www/html/timetrex/vendor/pear/cache_lite/Cache/Lite.php on line 642
PHP Warning: opendir(/tmp/timetrex/cache_7/): failed to open dir: Permission denied in /var/www/html/timetrex/vendor/pear/cache_lite/Cache/Lite.php on line 642
PHP Warning: opendir(/tmp/timetrex/cache_2/): failed to open dir: Permission denied in /var/www/html/timetrex/vendor/pear/cache_lite/Cache/Lite.php on line 642
PHP Warning: opendir(/tmp/timetrex/cache_1/): failed to open dir: Permission denied in /var/www/html/timetrex/vendor/pear/cache_lite/Cache/Lite.php on line 642
PHP Warning: opendir(/tmp/timetrex/cache_6/): failed to open dir: Permission denied in /var/www/html/timetrex/vendor/pear/cache_lite/Cache/Lite.php on line 642
PHP Warning: opendir(/tmp/timetrex/cache_a/): failed to open dir: Permission denied in /var/www/html/timetrex/vendor/pear/cache_lite/Cache/Lite.php on line 642
PHP Warning: opendir(/tmp/timetrex/cache_0/): failed to open dir: Permission denied in /var/www/html/timetrex/vendor/pear/cache_lite/Cache/Lite.php on line 642
PHP Warning: opendir(/tmp/timetrex/cache_9/): failed to open dir: Permission denied in /var/www/html/timetrex/vendor/pear/cache_lite/Cache/Lite.php on line 642
PHP Warning: opendir(/tmp/timetrex/cache_5/): failed to open dir: Permission denied in /var/www/html/timetrex/vendor/pear/cache_lite/Cache/Lite.php on line 642
PHP Warning: opendir(/tmp/timetrex/cache_3/): failed to open dir: Permission denied in /var/www/html/timetrex/vendor/pear/cache_lite/Cache/Lite.php on line 642
PHP Warning: opendir(/tmp/timetrex/cache_8/): failed to open dir: Permission denied in /var/www/html/timetrex/vendor/pear/cache_lite/Cache/Lite.php on line 642
PHP Warning: opendir(/tmp/timetrex/cache_f/): failed to open dir: Permission denied in /var/www/html/timetrex/vendor/pear/cache_lite/Cache/Lite.php on line 642
Upgrade successfull!
shaunw
Posts: 7839
Joined: Tue Sep 19, 2006 2:22 pm

Re: upgrade database not fully upgraded

Post by shaunw »

Ok, so according to that the upgrade succeeded.

The permission errors should be corrected, but if you re-run the web-based installer, it should give you more specific error messages that are actionable.
davej
Posts: 12
Joined: Fri Apr 15, 2022 11:28 am

Re: upgrade database not fully upgraded

Post by davej »

i ran thru the web based install and let it run for 30 minutes. still hangs on 95 / 99 96% 00:00

should i upload the timetrex.log, php log, and apache log again?

-dave.j
shaunw
Posts: 7839
Joined: Tue Sep 19, 2006 2:22 pm

Re: upgrade database not fully upgraded

Post by shaunw »

Sure, we can take another look.

Can you also upload your php.ini used by Apache/PHP and the one used by the CLI PHP?
davej
Posts: 12
Joined: Fri Apr 15, 2022 11:28 am

Re: upgrade database not fully upgraded

Post by davej »

log and ini files posted. thank you.

-dave.j
davej
Posts: 12
Joined: Fri Apr 15, 2022 11:28 am

Re: upgrade database not fully upgraded

Post by davej »

i missed the CLI php.ini. got it now
shaunw
Posts: 7839
Joined: Tue Sep 19, 2006 2:22 pm

Re: upgrade database not fully upgraded

Post by shaunw »

Unfortunately the logs still aren't showing any useful information.

Your Apache PHP.ini file does have extremely low memory and execution time limits. In theory this shouldn't affect things, but its worth a try to test. If you edit that file, then change the following:

Code: Select all

max_execution_time = 30
to:

Code: Select all

max_execution_time = 600
and change:

Code: Select all

memory_limit = 256M
to:

Code: Select all

memory_limit = 1024M
Re-run the web-based installer and see if that works. Just so you know the web-based installer should complete in just a few seconds as its already been completed before.
davej
Posts: 12
Joined: Fri Apr 15, 2022 11:28 am

Re: upgrade database not fully upgraded

Post by davej »

still no luck, unfortunately.

dave.j
davej
Posts: 12
Joined: Fri Apr 15, 2022 11:28 am

Re: upgrade database not fully upgraded

Post by davej »

i should mention this is run on a RasPi.

-dave.j
davej
Posts: 12
Joined: Fri Apr 15, 2022 11:28 am

Re: upgrade database not fully upgraded

Post by davej »

i wonder if an upgrade of PHP would help or make it worse?

-dave.j
shaunw
Posts: 7839
Joined: Tue Sep 19, 2006 2:22 pm

Re: upgrade database not fully upgraded

Post by shaunw »

Something is crashing and not providing any error logs. Because we don't support TimeTrex on RasPi, nor recommend using it on such a device, there isn't much more we can help with at this time.
davej
Posts: 12
Joined: Fri Apr 15, 2022 11:28 am

Re: upgrade database not fully upgraded

Post by davej »

shaunw
Posts: 7839
Joined: Tue Sep 19, 2006 2:22 pm

Re: upgrade database not fully upgraded

Post by shaunw »

Using an Intel/AMD (x64) platform is definitely going to be a better choice simply due to the fact its more widely adopted.

But in either case if you are experiencing PHP crashes without any useful error messages, there isn't much we can help with.
davej
Posts: 12
Joined: Fri Apr 15, 2022 11:28 am

Re: upgrade database not fully upgraded

Post by davej »

i have a nice yet not too expensive Intel x64 NUC on order.

I need to access the database. i've read thru the boards a little bit and see that the database name is located in:
timetrex.ini.php

i see the information:
[database]
type = postgres8

host = localhost
database_name = timetrex
user = *censored*
password = *censored*


i see in another board you recommend using the api located in the /api directory


i'm familiar with sql command line SELECT xyz FROM abc
and hoping i can select a certain date range and punches from some select employees for record

thanks

-dave.j
shaunw
Posts: 7839
Joined: Tue Sep 19, 2006 2:22 pm

Re: upgrade database not fully upgraded

Post by shaunw »

Have you tried running the Punch Summary report and exporting it to a CSV file?
Post Reply