cPanel ELevate from upgrade to AlmaLinux 8 Errors

Operating System & Version
CentOS v7.9.2009 STANDARD kvm
cPanel & WHM Version
cPanel Version 106.0.11

perezs

Registered
Jan 7, 2023
1
0
0
London
cPanel Access Level
Root Administrator
Hello i am trying to upgrade my cpanel to AlmaLinux 8 but on /scripts/elevate-cpanel --log i am getting these errors please see below can anyone help me with this matter please.

[INFO] E Sysup: Needed system packages were not installed: ea-cpanel-tools, ea-profiles-cpanel
* 2023-01-07 15:33:16 (3929) [INFO]
* 2023-01-07 15:33:16 (3410) [WARN] /scripts/sysup failed, please fix it and rerun it before upgrading.
* 2023-01-07 15:33:16 (2727) [WARN] *** Elevation Blocker detected: ***

[WARN] Unknown error while checking blockers: Unable to backup EA4 profile. Failure from /usr/local/bin/ea_current_to_profile --target-os=AlmaLinux_8 --output=/tmp/xP1zWdozqB/ea_profile.json at /scripts/elevate-cpanel line 1644.
* 2023-01-07 15:33:16 (709) [WARN] Please fix the detected issues before performing the elevation process.
 
I have the same problem:
* 2023-06-10 11:26:52 [INFO] Checking EasyApache profile compatibility with AlmaLinux 8.
* 2023-06-10 11:26:52 [INFO] Running: /usr/local/bin/ea_current_to_profile --target-os=AlmaLinux_8 --output=/tmp/_5EU_2wxrc/ea_profile.json
* 2023-06-10 11:26:53 [WARN] Unknown error while checking blockers: Unable to backup EA4 profile. Failure from /usr/local/bin/ea_current_to_profile --target-os=AlmaLinux_8 --output=/tmp/_5EU_2wxrc/ea_profile.json at /scripts/elevate-cpanel line 2238.
* 2023-06-10 11:26:53 [WARN] Please fix the detected issues before performing the elevation process.


When I run /scripts/sysup I got:
info [sysup] ea4: repo already installed
checkyum version 22.3 (excludes: bind-chroot)
All Needed Packages are already installed.


Any ideas? I already did a manual backup of EA profile, is there any chance to avoid this check in the elevate script?
 
Script throws an exception:

Cpanel::Exception::JSONParseError/(XID jsuuam) The system failed to parse the JSON stream data “{
"EA4" : {
"CentOS_6.5_standard" : [
"autotools-latest",
"autotools-latest-autoconf",
"autotools-latest-m4",
"autotools-latest-runtime",
"ea-apache24",
"ea-apache24-config",
"ea-apache24-config-runtime",
"ea-apache24-devel",
"ea-apache24-manual",
"ea-apache24-mod_allowmethods",
"ea-apache24-mod_asis",
"ea-apache24-mod_auth_digest",
"ea-apache24-mod_authn_anon",
"ea-apache24-mod_authn_dbd",
"ea-apache24-mod_authn_dbm",
"ea-apache24-mod_authn_socache",
"ea-apache24-mod_authnz_ldap",
"ea-apache24-mod_authz_dbd",
"ea-apache24-mod_authz_dbm",
"ea-apache24-mod_authz_owner",
"ea-apache24-mod_brotli",
"ea-apache24-mod_buffer",
"ea-apache24-mod_bw",
"ea-apache24-mod_bwlimited",
"ea-apache24-mod_cache",
"ea-apache24-mod_cache_disk",
"ea-apache24-mod_cache_socache",
” from the file “/etc/cpanel/ea4/profiles/pkg-manifest.json” because of an error: malformed JSON string, neither tag, array, object, number, string or atom, at character offset 244747 (before "],\n "CentOS_9"...") at /usr/local/cpanel/Cpanel/JSON.pm line 128.

at /usr/local/cpanel/Cpanel/JSON.pm line 147.
Cpanel::JSON::_throw_json_error("malformed JSON string, neither tag, array, object, number, st"..., "/etc/cpanel/ea4/profiles/pkg-manifest.json", SCALAR(0x297d368)) called at /usr/local/cpanel/Cpanel/JSON.pm line 128
Cpanel::JSON::Load("{\x{a} \"EA4\" : {\x{a} \"CentOS_6.5_standard\" : [\x{a} \"auto"..., "/etc/cpanel/ea4/profiles/pkg-manifest.json") called at /usr/local/cpanel/Cpanel/JSON.pm line 290
Cpanel::JSON::_LoadFile("/etc/cpanel/ea4/profiles/pkg-manifest.json", 0, 0, undef, 0) called at /usr/local/cpanel/Cpanel/JSON.pm line 227
Cpanel::JSON::LoadFile("/etc/cpanel/ea4/profiles/pkg-manifest.json") called at /usr/local/bin/ea_current_to_profile line 137
ea_cpanel_tools::ea_current_to_profile::script("--target-os=AlmaLinux_8") called at /usr/local/bin/ea_current_to_profile line 53


I have CentOS 7 installed on my server.
 

vanessa

Well-Known Member
PartnerNOC
Sep 26, 2006
959
76
178
Virginia Beach, VA
cPanel Access Level
DataCenter Provider
Yep, I'm able to reproduce the same error, and the json file that is generated has error:

Code:
[root@server ~]# cat /etc/cpanel/ea4/profiles/pkg-manifest.json | jq
parse error: Expected another array element at line 7617, column 7
Sounds like you might need to open a ticket with cPanel to look into this. Sure you can manually fix the json errors, but the script will just regenerate that file.

In my case, the error is an extra comma at the end of a list:

Code:
<snip>
         "ea4-legacy",
         "yum-plugin-universal-hooks",
         "ea-php82-php-sourceguardian",  <---- that comma
      ],
 
  • Like
Reactions: Salvador Vidal
Yep, I'm able to reproduce the same error, and the json file that is generated has error:

Code:
[root@server ~]# cat /etc/cpanel/ea4/profiles/pkg-manifest.json | jq
parse error: Expected another array element at line 7617, column 7
Sounds like you might need to open a ticket with cPanel to look into this. Sure you can manually fix the json errors, but the script will just regenerate that file.

In my case, the error is an extra comma at the end of a list:

Code:
<snip>
         "ea4-legacy",
         "yum-plugin-universal-hooks",
         "ea-php82-php-sourceguardian",  <---- that comma
      ],
Thanks for the help Vanessa!

I opened a ticket to cPanel support team. Hope they can help me to fix this issue.
 
In my case, the error is an extra comma at the end of a list:

Code:
<snip>
         "ea4-legacy",
         "yum-plugin-universal-hooks",
         "ea-php82-php-sourceguardian",  <---- that comma
      ],
Thanks everyone for the support!

Vanessa was right, today I review my /etc/cpanel/ea4/profiles/pkg-manifest.json file and needed to delete an extra comma in EA4-production before CentOS_9:

"ea4-experimental",
"ea4-legacy",
"yum-plugin-universal-hooks",
"ea-php82-php-sourceguardian", <---- that comma
],
"CentOS_9" : [


Once edited with vim I run again the elevate-cpanel script and EA4 profile was backed up succesfully:

* 2023-06-14 00:25:13 [INFO] Checking EasyApache profile compatibility with AlmaLinux 8.
* 2023-06-14 00:25:13 [INFO] Running: /usr/local/bin/ea_current_to_profile --target-os=AlmaLinux_8 --output=/tmp/ft_QmVOwA3/ea_profile.json
* 2023-06-14 00:25:14 [INFO] Backed up EA4 profile to /tmp/ft_QmVOwA3/ea_profile.json
 

Attachments

  • Like
Reactions: cPRex and vanessa