Skip to content

tkl-upgrade-php not working #2074

Open
Open

Description

@JedMeister

@ash34 tried our tkl-upgrade-php script on his v18.2 WordPress server and it failed - see #2073 (comment) for more info.

Activity

  1. added this to the 19.0 milestone on Nov 19, 2025
  2. added
    common
    on Nov 19, 2025
  3. added theissue type on Nov 19, 2025
  4. marcos-mendez commented on Mar 16, 2026

    @marcos-mendez
    Member

    Hi @ash34,

    I just tested this on a fresh TurnKey WordPress 18.2 appliance and everything works perfectly. Here's what I did:

    1. Updated WordPress first (via the dashboard) — worked out of the box, no issues
    2. Then upgraded PHP from 8.2 to 8.3 using tkl-upgrade-php — also worked flawlessly

    The key takeaway: follow the natural order of things. Update the application first, then the runtime if needed.

    Some important context on the PHP version notice:

    • The message WordPress shows about PHP 8.3 is a recommendation, not a requirement
    • WordPress 6.8 is fully compatible with PHP 8.0, 8.1, and 8.2 (source)
    • WordPress still supports PHP as old as 7.2.24+ in legacy mode
    • PHP 7.2/7.3 support will only be dropped in WordPress 7.0 (April 2026), and even then the minimum becomes 7.4 — not 8.3
    • PHP 8.2 on Debian Bookworm is perfectly fine and receives security patches from Debian's security team

    A word of caution: running bleeding-edge software in production is generally a bad practice. PHP 8.2 is the version that ships with Debian 12 Bookworm — it's thoroughly tested and all TurnKey LAMP-based appliances are built against it. Upgrading PHP independently from the distribution can introduce plugin incompatibilities, broken extensions, and loss of Debian security coverage.

    That said, if you do need PHP 8.3, the tkl-upgrade-php script (which I contributed to TurnKey) handles it cleanly. Just make sure to:

    • Update WordPress and all plugins before upgrading PHP
    • Test your site after the upgrade
    • Keep in mind you're now on a third-party PHP repo (packages.sury.org) instead of Debian's

    I'd suggest closing this issue as it's working as expected.

    — Marcos Méndez (@marcos-mendez) / POPSOLUTIONS

  5. OnGle commented on Mar 17, 2026

    @OnGle
    Member

    This is still somewhat of a concern, as the version of wordpress that stopped working should of also supported this version of PHP.

    Still this shouldn't be considered a serious bug, instead we should consider adding a notice or additional confirmation to the script reminding users to backup and/or confirm that the version of their current software supports the targeted version of PHP before updating PHP.

  6. ash34 commented on Mar 31, 2026

    @ash34

    I can confirm that the tkl-update-php works but only on a fresh install of the Wordpress appliance (for me at least). This was tested successfully on a clean lab installation but my main prod site was the one that failed previously so maybe it has a plug-in which doesn’t like the script.

  7. marcos-mendez commented on Mar 31, 2026

    @marcos-mendez
    Member

    Can you please @ash34 list the php modules you have php version you are leaving and php version you ar going to?

  8. ash34 commented on Apr 1, 2026

    @ash34

    [PHP Modules]
    calendar
    Core
    ctype
    curl
    date
    dom
    exif
    FFI
    fileinfo
    filter
    ftp
    gd
    gettext
    hash
    iconv
    imagick
    intl
    json
    libxml
    mbstring
    mysqli
    mysqlnd
    openssl
    pcntl
    pcre
    PDO
    pdo_mysql
    Phar
    posix
    random
    readline
    Reflection
    session
    shmop
    SimpleXML
    sockets
    sodium
    SPL
    standard
    sysvmsg
    sysvsem
    sysvshm
    tokenizer
    xml
    xmlreader
    xmlwriter
    xsl
    Zend OPcache
    zip
    zlib

    [Zend Modules]
    Zend OPcache

    Version 8.2.30 to 8.3.30

  9. ash34 commented on Apr 2, 2026

    @ash34

    More info of the failure when the upgrade is performed on a site that is not a fresh WP install.

    After the tkl-upgrade-php and systemctl restart apache2 a refresh of the browser produces the following message:

    "It appears that the MySQL extension is missing from your PHP installation, even though WordPress requires it."

  10. JedMeister commented on Apr 9, 2026

    @JedMeister
    MemberAuthor

    Thanks for the additional info.

    TBH I don't understand!? - looking at the modules you've listed it shows both pdo_mysql & mysqli - which both come from php-mysql package!?

    What TurnKey version is your prod server? If unsure run turnkey-version.

  11. OnGle commented on Jul 24, 2026

    @OnGle
    Member

    Was able to confirm issues on both new updated leantime & mediawiki. It seemingly is failing to pickup any php packages other than libapache2-mod-php<version>, currently working on a fix

  12. added and removed
    common
    on Jul 29, 2026
  13. modified the milestones: 19.0, 19.1 on Jul 29, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions