Announcement

Collapse
No announcement yet.

PHP -v says there is one version in the shell, composer says another.

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • PHP -v says there is one version in the shell, composer says another.

    I have a strange behavior in an account.

    The php selector is assigned the PHP version 7.2 (alt-php72), and in the user shell it indicates:


    Code:
    [vipsouls@srv110 public_html]$ php -v
    PHP 7.2.34 (cli) (built: Jan 26 2023 17:57:46) (NTS)
    Copyright (c) 1997-2018 The PHP Group
    Zend Engine v3.2.0, Copyright (c) 1998-2018 Zend Technologies
    [vipsouls@srv110 public_html]$​
    However when I go to run wp-cli, I get the error

    Code:
    [vipsouls@srv110 public_html]$ wp core update && wp plugin upgrade --all && wp theme upgrade --all
    Warning: Constants may only evaluate to scalar values in /home/vipsouls/public_html/wp-content/plugins/file-manager/BootStart/Constants.php on line 29
    Notice: Use of undefined constant FM_WP_UPLOAD_DIR - assumed 'FM_WP_UPLOAD_DIR' in /home/vipsouls/public_html/wp-content/plugins/file-manager/BootStart/Constants.php on line 32
    Warning: Illegal string offset 'path' in /home/vipsouls/public_html/wp-content/plugins/file-manager/BootStart/Constants.php on line 32
    Notice: Use of undefined constant FM_WP_UPLOAD_DIR - assumed 'FM_WP_UPLOAD_DIR' in /home/vipsouls/public_html/wp-content/plugins/file-manager/BootStart/Constants.php on line 35
    Warning: Illegal string offset 'url' in /home/vipsouls/public_html/wp-content/plugins/file-manager/BootStart/Constants.php on line 35
    Notice: Use of undefined constant FM_WP_UPLOAD_DIR - assumed 'FM_WP_UPLOAD_DIR' in /home/vipsouls/public_html/wp-content/plugins/file-manager/BootStart/Constants.php on line 38
    Warning: Illegal string offset 'basedir' in /home/vipsouls/public_html/wp-content/plugins/file-manager/BootStart/Constants.php on line 38
    Notice: Use of undefined constant FM_WP_UPLOAD_DIR - assumed 'FM_WP_UPLOAD_DIR' in /home/vipsouls/public_html/wp-content/plugins/file-manager/BootStart/Constants.php on line 41
    Warning: Illegal string offset 'baseurl' in /home/vipsouls/public_html/wp-content/plugins/file-manager/BootStart/Constants.php on line 41
    Notice: Use of undefined constant FM_WP_UPLOAD_DIR - assumed 'FM_WP_UPLOAD_DIR' in /home/vipsouls/public_html/wp-content/plugins/file-manager/BootStart/Constants.php on line 44
    Warning: Illegal string offset 'basedir' in /home/vipsouls/public_html/wp-content/plugins/file-manager/BootStart/Constants.php on line 44
    Notice: Use of undefined constant FM_WP_UPLOAD_DIR - assumed 'FM_WP_UPLOAD_DIR' in /home/vipsouls/public_html/wp-content/plugins/file-manager/BootStart/Constants.php on line 47
    Warning: Illegal string offset 'baseurl' in /home/vipsouls/public_html/wp-content/plugins/file-manager/BootStart/Constants.php on line 47
    Notice: Use of undefined constant FM_WP_UPLOAD_DIR - assumed 'FM_WP_UPLOAD_DIR' in /home/vipsouls/public_html/wp-content/plugins/file-manager/BootStart/Constants.php on line 54
    Warning: Illegal string offset 'basedir' in /home/vipsouls/public_html/wp-content/plugins/file-manager/BootStart/Constants.php on line 54
    Notice: Use of undefined constant FM_WP_UPLOAD_DIR - assumed 'FM_WP_UPLOAD_DIR' in /home/vipsouls/public_html/wp-content/plugins/file-manager/BootStart/Constants.php on line 56
    Warning: Illegal string offset 'basedir' in /home/vipsouls/public_html/wp-content/plugins/file-manager/BootStart/Constants.php on line 56
    Notice: Use of undefined constant FM_WP_UPLOAD_DIR - assumed 'FM_WP_UPLOAD_DIR' in /home/vipsouls/public_html/wp-content/plugins/file-manager/BootStart/Constants.php on line 64
    Warning: Illegal string offset 'basedir' in /home/vipsouls/public_html/wp-content/plugins/file-manager/BootStart/Constants.php on line 64
    Notice: Use of undefined constant FM_WP_UPLOAD_DIR - assumed 'FM_WP_UPLOAD_DIR' in /home/vipsouls/public_html/wp-content/plugins/file-manager/BootStart/Constants.php on line 78
    Warning: Illegal string offset 'baseurl' in /home/vipsouls/public_html/wp-content/plugins/file-manager/BootStart/Constants.php on line 78
    Fatal error: Composer detected issues in your platform: Your Composer dependencies require a PHP version ">= 7.2.0". You are running 5.6. in /home/vipsouls/public_html/wp-content/plugins/backwpup/vendor/composer/platform_check.php on line 25
    Error: There has been a critical error on this website. Learn more about troubleshooting WordPress. There has been a critical error on this website.​​

  • #2
    Hi,

    Could you please show some general information of of wp-cli from under this user? Please post the output of:

    Code:
    wp --info

    Comment


    • #3
      Oh...

      Code:
      wp --info
      OS: Linux srv110.myserver.com 3.10.0-962.3.2.lve1.5.78.el7.x86_64 [NODE="1"]Home[/NODE] SMP Fri Feb 17 08:16:56 UTC 2023 x86_64
      Shell: /bin/bash
      PHP binary: /opt/alt/php56/usr/bin/php
      PHP version: 5.6.40
      php.ini used: /opt/alt/php56/etc/php.ini
      MySQL binary: /bin/mysql
      MySQL version: mysql Ver 15.1 Distrib 10.3.38-MariaDB, for Linux (x86_64) using readline 5.1
      SQL modes:
      WP-CLI root dir: phar://wp-cli.phar/vendor/wp-cli/wp-cli
      WP-CLI vendor dir: phar://wp-cli.phar/vendor
      WP_CLI phar path: /home/vipsouls
      WP-CLI packages dir:
      WP-CLI cache dir: /home/vipsouls/.wp-cli/cache
      WP-CLI global config:
      WP-CLI project config:
      WP-CLI version: 2.8.0-alpha-81dfd5d
      After si this issues I worked for correct problem with wp-cli en CageFS.

      A lot of thanks

      Comment


      • #4
        Hmm, interesting. How did you install the wp-cli at first? Seems it does not follow the symbolic links somehow.

        Comment

        Working...
        X