Cron job error with /usr/local/cpanel/scripts/update_db_cache

Adrianne

Registered
Apr 21, 2016
2
0
51
Denver, CO
cPanel Access Level
Root Administrator
I have a new dedicated server setup with root access and have still been receiving the following email alerts every 12hrs:

Subject:
Cron <root@****> /usr/bin/test -x /usr/local/cpanel/scripts/update_db_cache && /usr/local/cpanel/scripts/update_db_cache

Message:
Code:
Cpanel::Exception/(XID g4es8v) The system failed to load and to parse the file “/var/cpanel/databases/dbindex.db.json” because of an error: (XID gpzbmk) The system failed to parse the JSON stream for the caller “(eval)” because of an error: malformed JSON string, neither tag, array, object, number, string or atom, at character offset 2 (before "(end of string)") at /usr/local/cpanel/Cpanel/JSON.pm line 108.

at /usr/local/cpanel/Cpanel/Transaction/File/BaseReader.pm line 59.
    Cpanel::Transaction::File::BaseReader::__ANON__(Cpanel::Exception::JSONParseError=HASH(0x3964d38)) called at /usr/local/cpanel/3rdparty/perl/514/lib64/perl5/cpanel_lib/Try/Tiny.pm line 103
    Try::Tiny::try(CODE(0x3917878), Try::Tiny::Catch=REF(0x39289e0)) called at /usr/local/cpanel/Cpanel/Transaction/File/BaseReader.pm line 60
    Cpanel::Transaction::File::BaseReader::_init_data_with_catch(Cpanel::Transaction::File::JSONReader=HASH(0x3928398), "path", "/var/cpanel/databases/dbindex.db.json") called at /usr/local/cpanel/Cpanel/Transaction/File/BaseReader.pm line 43
    Cpanel::Transaction::File::BaseReader::new("Cpanel::Transaction::File::JSONReader", "path", "/var/cpanel/databases/dbindex.db.json") called at /usr/local/cpanel/Cpanel/DB/Map/Collection/Index.pm line 96
    Cpanel::DB::Map::Collection::Index::_load_dbindex(Cpanel::DB::Map::Collection::Index=HASH(0x3917200)) called at /usr/local/cpanel/Cpanel/DB/Map/Collection/Index.pm line 42
    Cpanel::DB::Map::Collection::Index::new("Cpanel::DB::Map::Collection::Index", HASH(0x38db6b8)) called at bin/update_db_cache.pl line 52
    Script::Update::DB::Cache::script("Script::Update::DB::Cache") called at bin/update_db_cache.pl line 35
Any insight on how I may be able to fix this error and prevent the cron from failing and stop receiving these messages would be greatly appreciated.

My Server Info:
/etc/redhat-release:CloudLinux release 7.2 (Valeri Kubasov)
/usr/local/cpanel/version:11.54.0.21
/var/cpanel/envtype:standard
CPANEL=release
Server version: Apache/2.4.18 (Unix)
Server built: Apr 20 2016 19:07:37
Cpanel::Easy::Apache v3.32.12 rev9999 +cloudlinux
PHP 5.6.20 (cli) (built: Apr 20 2016 19:10:45)
Copyright (c) 1997-2016 The PHP Group
Zend Engine v2.6.0, Copyright (c) 1998-2016 Zend Technologies
mysql Ver 14.14 Distrib 5.6.29, for Linux (x86_64) using EditLine wrapper
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,880
2,268
463
Hello :)

It's possible the "/var/cpanel/databases/dbindex.db.json" file is corrupt. Please let us know if the following commands help to address the issue:

Code:
mv /var/cpanel/databases/dbindex.db.json /root/
/usr/local/cpanel/bin/dbindex
Thank you.
 

Adrianne

Registered
Apr 21, 2016
2
0
51
Denver, CO
cPanel Access Level
Root Administrator
It has been over 24hrs now and I have received no more error alerts for this specific issue. It appears your commands above did indeed fix it. Thank you for your prompt assistance.
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,880
2,268
463
I'm happy to see the issue is now resolved. Thank you for updating us with the outcome.