PHP
Servers

PHP

  • 2023-02-17 07:00:39

Overview

FlashVPS makes it easy to switch server defaults, set maximum file upload size, maximum execution time, and disable/disable OPCache.

! Manual PHP installation
If you choose to manually install PHP versions on your server, FlashVPS won't know about those PHP settings. FlashVPS only knows about PHP settings that are managed through the FlashVPS control panel.

Multiple PHP Versions

When creating a server, you have to decide which version of PHP you want to install as the default. The PHP CLI on your server will point to the installed version selected at creation time.

Once the server has been created, FlashVPS makes it easy to install additional versions alongside the default one. In the following document, we will discuss how to manage these additional PHP versions.

Setting

You can install additional PHP versions through the Applications tab on the server's management console. Once an additional PHP version has been installed, you can select it when creating a website or when switching the PHP version of a website.

When you install a new version of PHP on your server, FlashVPS creates and configures the PHP-FPM process for that instance. This means that your server will be running multiple versions of PHP at the same time.

Uninstall

You can uninstall PHP versions through the Applications tab on the server's management console. You can choose to uninstall the PHP version as long as:

  • There are other versions installed.
  • The version you want to uninstall is not the default server version for new sites.
  • The version you want to uninstall is not the default version of the server on the CLI.
  • The version you want to uninstall is not used by any website.

Switch Default PHP

The 'default' PHP version is the PHP version that will be used by default when creating a new website on the server. Conversion steps:

  1. At the server management console > SelectPhiên bản mặc định PHP PHP 0
  2. Select the PHP version you want to transferPHP 1
  3. SelectCập nhật

When a new PHP version is selected as the 'default' version for your server, the PHP versions used by existing websites will not be updated.

Some common PHP configuration settings

! Configuration Settings
Changing the following settings will apply the changes to all PHP versions installed on the server.

Maximum file upload size

You can configure the maximum file upload size at the server management console. Values ​​are provided in megabytes. For reference, 1024MBis 1GB.PHP 2

Maximum execution time

You can configure the maximum execution time at the server management console. Values ​​are provided in units of giây.PHP 3

OPcache

Optimizing OPcache PHP for production will configure OPcache to store your compiled PHP code in memory to dramatically improve performance. If you choose to optimize OPcache for production, you should verify that your deployment script restarts the PHP-FPM service at the end of each deployment.

Enable PHPOpcache at the server management consolePHP 4

Author FlashPanel Admin
FlashPanel Admin
Joined in 3 years ago