+ إنشاء موضوع جديد
النتائج 1 إلى 2 من 2
  1. #1
    Status
    Offline
    الصورة الرمزية Rise Company
    Engineering and Technology
    تاريخ التسجيل
    Apr 2014
    الدولة
    Egypt
    المشاركات
    4,628
    معدل تقييم المستوى
    10

    افتراضي كلاود لينكس Cloud Linux جعل اصدار alt-php 7.4 الافتراضى لجميع العملاء


    كلاود لينكس Cloud Linux جعل اصدار alt-php 7.4 الافتراضى لجميع العملاء
    Cpanel CloudLinux set all users to use alt-php



    if your cpanel server have cloudlinux + PHP Selector installed
    you need to set all site to use inherit PHP before you can use PHP Selector.

    فى الكلاود لينكس هتجد دائما لديك نوعين من php ويجب ان يكون كلاهما موجود
    ea-php
    alt-php
    من داخل Multiphp يجب ان تختار الافتراضى للسيرفر و العملاء ea-php 7.4
    او اجعل العملاء inherit للاصدار الاساسى للسيرفر ea-php 7.4

    اذا اخترت alt هذا خطا ! يلغى php selector
    لذلك اعتبر ea-php هو الاب اما alt-php هو الابن selector الى بيورث من الاب القدر المطلوب

    من داخل php selector اذا اخترت الافتراضى هيفعل على الجديد اما القديم لا



    ولجعل جميع المواقع تعمل على selector على اصدار alt-php7.4
    لجميع العملاء ادخل هذا الامر

    فقط ادخل هذا الامر
    كود PHP:
    cd /var/cpanel/users
    ls 
    -awk '{ print "selectorctl --set-user-current=7.4 --user="$1 }' sh 
    ----------------------------

    وحتى لا يحدث ارتباك للعميل لوجود كلا ea-php و alt-php
    قم باخفاء ea-php

    Home » Packages » Feature Manager » Feature Lists » Manage feature list » select Default and uncheck the box for MultiPHP INI Editor and MultiPHP Manager. This will stop your customers from seeing MultiPHP Manager/Editor which can be very confusing.

    شاهد ايضا
    كلاود لينكس CLOUD LINUX حل مشكلة CANNOT MANAGE PHP VERSIONS WHEN CAGEFS IS DISABLED

    المرجع:
    https://serverok.in/cpanel-cloudlinu...to-use-alt-php
    https://cloudlinux.zendesk.com/hc/en...on-with-cPanel
    ------------------------------------------------------------------------
    شركة رايز للهندسة و التكنولوجيا Rise Company for Engineering & Technology
    ------------------------------------------------------------------------
    Web Hosting | Web Designing | E-Marketing

    رقم # 1 فى خدمات الشركات Business Services

    استضافة مواقع Web Hosting - عمل ايميل شركة Business Emails

    تصميم موقع شركة Web Design - تسويق الكترونى على جوجل Google Adwords

    www.rise.company | www.rise.company/emails

    ملحوظة : جميع خدماتنا مخصصة للشركات فقط وغير متاحة للافراد
    وليس لنا اى منتجات او صيانة نهائيا! يرجى الانتباه الى ذلك.



  2. #2
    Status
    Offline
    الصورة الرمزية Rise Company
    Engineering and Technology
    تاريخ التسجيل
    Apr 2014
    الدولة
    Egypt
    المشاركات
    4,628
    معدل تقييم المستوى
    10

    افتراضي رد: كلاود لينكس Cloud Linux جعل اصدار alt-php 7.4 الافتراضى لجميع العملاء

    Earlier, when EasyApache 3 was in trend, CloudLinux with PHP Selector would work seamlessly; you would set up the EasyApache profile which is compatible with PHP Selector, and you are ready to go. However, with EasyApache 4 cPanel introduced the built-in MultiPHP Manager which changed everything.

    The main advantage of the MultiPHP Manager is allowing users to select different PHP versions for each domain.
    With CloudLinux, you can also make use of a similar feature: PHP Selector. PHP Selector has an important advantage over MultiPHP Manager: it allows a single cPanel user to manage PHP extensions without the need to contact his/her hoster. The user can enable/disable PHP extensions as he pleases. PHP Selector also leaves the choice of PHP version to the end-user, but the switch is made for the whole user, not for a separate website (as with MultiPHP Manager).
    The main question a hoster should answer is which of the above features he will provide for his clients: MultiPHP Manager or PHP Selector. Using both can be confusing for the end-users. You can manage which features to show to your cPanel end-users in WHM Home » Packages » Feature Manager » Feature Lists.
    If you'd like to use PHP Selector on a cPanel server, continue reading this document to understand how to integrate MultiPHP Manager and PHP Selector.
    Prerequisites

    Before integrating PHP Selector with cPanel, make sure that you have the following components installed:


    Configuration

    Once you’re done with PHP Selector’s installation, there are a few things that you need to check on cPanel servers. You need to make sure that MultiPHP Manager settings are correct and that CageFS is enabled for the users. Let us cover the steps in detail.
    Go to WHM -> MultiPHP Manager -> PHP Versions tab.


    1. Make sure that the System PHP Version is set to one of the ea-phpXX ones.
      Attention: Selecting the alt-phpXX (as a “System PHP Version”) will break the PHP Selector.
    2. Switch the PHP-FPM to Off; the PHP Selector is not compatible with it.
      Note: If you have PHP-FPM enabled for existing websites, you need to disable it for them.
    3. Last but not least, make sure that the domains/accounts (where you'd like to use the PHP Selector) use the Inherited version. You need to do that because MultiPHP Manager has a higher priority than PHP Selector. So, if any other PHP version is set in this menu, it will overwrite the PHP version selected in PHP Selector for that domain.

    That’s it! You are all set. The only thing that’s left is to make sure that you use the “Enable for all users” mode for CageFS if you’d like to keep PHP Selector for all users. You can enable it via:
    # /usr/sbin/cagefsctl --enable-all
    Frequently Asked Questions (FAQ)

    Q. How could I set the Inherited option for all new accounts/websites by default?

    A. You won’t have to; cPanel already sets the Inherited by default for all newly created accounts. You can find more information about the way PHP Inheritance works on this page.
    Q. How could I set the Inherited option for all new accounts/websites when I transfer them from one server to another?

    A. If after transferring users, they do not have Inherited version set in MultiPHP Manager, you can run this script to switch ALL domains on the server to Inherited version:
    # for i in $(cut -d: -f1 /etc/userdatadomains );do whmapi1 php_set_vhost_versions version=inherit vhost-0=$i;done Attention! Be very careful with that script because it will change PHP versions for ALL domains on your server to inherited. If you are not sure that you want exactly this, use the WHM interface and manually select the domains you wish to switch PHP version for.
    Q. What setup do you recommend for CL PHP Selector?

    A. The recommended setup is the one described in the "Configuration" part of this guide. Additionally, if you are using the Apache web server, we recommend using mod_lsapi as PHP Handler. Install it using this guide. Enable it in WHM » MultiPHP Manager » Handlers.
    Also, if you configured PHP Selector, we recommend disabling MultiPHP Manager for users. You can do that in Home » Packages » Feature Manager » Feature Lists » Manage feature list » select Default and uncheck the box for MultiPHP INI Editor and MultiPHP Manager. This will stop your customers from seeing MultiPHP Manager/Editor which can be very confusing.
    Q. Can I disable alt-phpXX versions from MultiPHP Manager’s dropdown list?

    A. You can do so by editing the /opt/alt/alt-php-config/alt-php.cfg file. Once you edit it, run the following script:
    /opt/alt/alt-php-config/multiphp_reconfigure.pyIt manages SCL prefixes for the Alt-PHP in /etc/scl/prefixes.
    In this example, we keep the alt-php72 visible in the list only:
    [MultiPHP Manager]
    alt-php44 = no
    alt-php51 = no
    alt-php52 = no
    alt-php53 = no
    alt-php54 = no
    alt-php55 = no
    alt-php56 = no
    alt-php70 = no
    alt-php71 = no
    alt-php72 = yes
    Q. I don’t want to use the PHP Selector, but I’d like to select the alt-phpXX version for one account/website. Can I do that?

    A. Sure. You’ll need to choose the alt-phpXX in the MultiPHP Manager ➔ PHP Version here:

    Please note that the PHP extensions set in the CloudLinux PHP Selector or CloudLinux Manager settings will not work in this case. You will only get the basic extensions that are built-in into a particular PHP version.
    Q. I followed this guide, but the PHP version is still not fetched for my website from PHP Selector. What did I miss?

    A. Make sure to check our Compatibility Matrix. It contains additional information on components that are incompatible with PHP Selector. E.g., you may need to remove mod_ruid2 to use our PHP Selector.
    More about PHP Selector’s configuration

    Setting up the PHP version on customer’s end (in cPanel)

    It is possible to change the current PHP Version for MultiPHP Manager on the user’s end. Here’s how the settings would look like by default:

    The end-user can change that and select any version, other than Inherited one. Just like with WHM’s MultiPHP Manager, the PHP Selector won’t work correctly in this case. We recommend leaving either PHP Selector or MultiPHP Manager enabled for the end-user. That way, your end-users will have only one place where to configure PHP which will make things easier.
    PHP directives and their priorities

    Given the way cPanel handles the PHP versions, it could be quite confusing to understand which PHP.ini directive will get higher priority over another. Let's discuss it here.
    Directives priority - If PHP Selector is enabled

    If you use the PHP Selector (and it is configured according to this guide), its options would have the highest priority. You can find them in cPanel ➔ Select PHP Version ➔ Switch to PHP Options.

    You can add custom php.ini options here too! Check this article to find out how to do that.
    The lower priority would have the php.ini (or .user.ini for some of the PHP handlers) configuration file, but you could also type in the PHP values there.
    Directives priority - If PHP Selector isn’t used

    If you haven’t configured the PHP Selector, and you’d like to simply change PHP.ini parameters for particular alt-phpXX or ea-phpXX versions, you could manage them in WHM ➔ MultiPHP INI Editor. cPanel end-user can also customize php.ini directives in cPanel ➔ MultiPHP INI Editor. For more information, read the official documentation here and here.
    PHP Version in the command-line interface (CLI)

    Shell commands, starting with /usr/bin/php and /usr/local/bin/php would use the same version that you select in the PHP Selector (if it’s already set up). That PHP will also load PHP directives selected in PHP Selector. For example, if we have a setup like this:

    We should get the 7.2 version in the php -v output if nothing was changed in the PHP Selector. This is exactly what we get:
    /usr/local/bin/php -v
    PHP 7.2.14 (cli) (built: Feb 10 2019 18:20:08) ( NTS )
    Copyright (c) 1997-2018 The PHP Group
    Zend Engine v3.2.0, Copyright (c) 1998-2018 Zend Technologies
    with Zend OPcache v7.2.14, Copyright (c) 1999-2018, by Zend Technologies
    But if we change the PHP version in the PHP Selector, the php -v output will change as well.

    /usr/local/bin/php -v
    PHP 7.3.2 (cli) (built: Feb 7 2019 13:36:44) ( NTS )
    Copyright (c) 1997-2018 The PHP Group
    Zend Engine v3.3.2, Copyright (c) 1998-2018 Zend Technologies
    However, PHP version chosen in MultiPHP Manager can also be applied to console commands /usr/bin/php and /usr/local/bin/php . Whether it will be applied or not depends on the current working directory. .htaccess file search is performed in the current directory and in parent directories. If the file is found, then the PHP version specified in it is applied, if not found, then System default PHP version is applied. System default PHP version for a specific user can be changed via PHP Selector.
    ------------------------------------------------------------------------
    شركة رايز للهندسة و التكنولوجيا Rise Company for Engineering & Technology
    ------------------------------------------------------------------------
    Web Hosting | Web Designing | E-Marketing

    رقم # 1 فى خدمات الشركات Business Services

    استضافة مواقع Web Hosting - عمل ايميل شركة Business Emails

    تصميم موقع شركة Web Design - تسويق الكترونى على جوجل Google Adwords

    www.rise.company | www.rise.company/emails

    ملحوظة : جميع خدماتنا مخصصة للشركات فقط وغير متاحة للافراد
    وليس لنا اى منتجات او صيانة نهائيا! يرجى الانتباه الى ذلك.



المواضيع المتشابهه

  1. كلاود لينكس Cloud Linux حل مشكلة خطا CloudLinux Manager | HTTP error 404
    بواسطة Rise Company في المنتدى قسم الكلاود لينكس CloudLinux
    مشاركات: 0
    آخر مشاركة: 21-07-2022, 15:54
  2. ماي كلاود My Cloud الترقية من اصدار 3 الى 5 جديد upgrade my cloud os3 to os 5
    بواسطة Rise Company في المنتدى قسم التخزين الشبكي NAS
    مشاركات: 0
    آخر مشاركة: 10-04-2021, 01:06
  3. ماي كلاود My Cloud تقرير عن جهاز WD My Cloud EX4100
    بواسطة Rise Company في المنتدى قسم التخزين الشبكي NAS
    مشاركات: 0
    آخر مشاركة: 23-04-2020, 14:12
  4. تجميع كل شىء عن الماى كلاود my cloud و my cloud home
    بواسطة Rise Company في المنتدى قسم التخزين الشبكي NAS
    مشاركات: 0
    آخر مشاركة: 21-02-2019, 20:52
  5. ماي كلاود My Cloud خطا You might not have permissions to use this network
    بواسطة Rise Company في المنتدى قسم التخزين الشبكي NAS
    مشاركات: 0
    آخر مشاركة: 31-12-2018, 13:07

المفضلات

المفضلات

ضوابط المشاركة

  • لا تستطيع إضافة مواضيع جديدة
  • لا تستطيع الرد على المواضيع
  • لا تستطيع إرفاق ملفات
  • لا تستطيع تعديل مشاركاتك
  •