Increase PHP Memory Limit in CyberPanel

When you install CyberPanel, many configurations come with default values. For example, memory_limit, upload_max_filesize, and post_max_size come with predefined values. Sometimes different configurations or values ​​are required depending on your website requirements. With a few tweaks, you can easily change or adjust these configurations and values ​​right from the CyberPanel dashboard.

Check below for proper adjustments to the predefined configurations.

Edit PHP Configuration in CyberPanel

To edit your PHP configuration, log in to the CyberPanel dashboard using port 8090. Scroll down the page on the right side of the screen PHP

:8090 > PHP > Edit PHP configuration > basic

Cyberpanel PHP Configuration

click PHP and choose Edit PHP configuration from the dropdown. On the next page, under Basic, choose the PHP version you want to edit. Currently, we recommend using PHP 7.4, which is fast and stable.

Php 7.4 Settings Cyberpanel
Php 7.4 Settings Cyberpanel

Select PHP 7.4 and you will see configuration options. You can adjust the values ​​here.

increase memory_limit

Delete the existing value for memory_limit and enter it. 2048M. Alternative 256M or 512M.

Increase upload_max_filesize

Delete the existing value for upload_max_filesize and type: 2048M. Alternative 256M or 512M.

increase post_max_size

Delete the existing value for post_max_size and type: 2048M. Alternative 256M or 512M.

Set max_execution_time to 300 and max_input_time to 60.

click save changes and Start PHP button.

Wait… not here.

Changes will not take effect until LiteSpeed ​​is restarted.

To restart LiteSpeed, click the settings icon near the logout button in the upper right corner of the CyberPanel dashboard.

Go to Cyberpanel Settings
Go to Cyberpanel Settings

click state, the Server Status page opens. click LiteSpeed ​​state.

light speed state
light speed state

click on next page LiteSpeed ​​Reboot button.

lightspeed reboot
lightspeed reboot

Alternatively, you can reboot LiteSpeed ​​using an SSH terminal.

Log in to the terminal and restart LiteSpeed ​​by running the following command:

/usr/local/lsws/bin/lswsctrl reload

or

/usr/local/lsws/bin/lswsctrl restart

All settings are now saved.

Identify these changes

Are you still in doubt as to whether these changes will work? You can easily identify these items right on your CyberPanel dashboard. Click Next to do this. database It’s on the right side of the dashboard. Select PHPMyAdmin from the dropdown.

PHPMyadmin cyber panel
PHPMyadmin cyber panel

Click Import and check the MySQL file upload size. (Max: 2,048 MiB).

If not changed, check your PhpMyAdmin php version. If it’s 7.3.x, change the value accordingly.

Phpmyadmin PHP version
Phpmyadmin PHP version

enjoy!

expose

We may receive affiliate commissions from you free of charge when you make purchases through affiliate links on our site.

Source

When you install CyberPanel, many configurations come with default values. For example, memory_limit, upload_max_filesize, and post_max_size come with predefined values. Sometimes different configurations or values ​​are required depending on your website requirements. With a few tweaks, you can easily change or adjust these configurations and values ​​right from the CyberPanel dashboard.

Check below for proper adjustments to the predefined configurations.

Edit PHP Configuration in CyberPanel

To edit your PHP configuration, log in to the CyberPanel dashboard using port 8090. Scroll down the page on the right side of the screen PHP

:8090 > PHP > Edit PHP configuration > basic

Cyberpanel PHP Configuration

click PHP and choose Edit PHP configuration from the dropdown. On the next page, under Basic, choose the PHP version you want to edit. Currently, we recommend using PHP 7.4, which is fast and stable.

Php 7.4 Settings Cyberpanel
Php 7.4 Settings Cyberpanel

Select PHP 7.4 and you will see configuration options. You can adjust the values ​​here.

increase memory_limit

Delete the existing value for memory_limit and enter it. 2048M. Alternative 256M or 512M.

Increase upload_max_filesize

Delete the existing value for upload_max_filesize and type: 2048M. Alternative 256M or 512M.

increase post_max_size

Delete the existing value for post_max_size and type: 2048M. Alternative 256M or 512M.

Set max_execution_time to 300 and max_input_time to 60.

click save changes and Start PHP button.

Wait… not here.

Changes will not take effect until LiteSpeed ​​is restarted.

To restart LiteSpeed, click the settings icon near the logout button in the upper right corner of the CyberPanel dashboard.

Go to Cyberpanel Settings
Go to Cyberpanel Settings

click state, the Server Status page opens. click LiteSpeed ​​state.

light speed state
light speed state

click on next page LiteSpeed ​​Reboot button.

lightspeed reboot
lightspeed reboot

Alternatively, you can reboot LiteSpeed ​​using an SSH terminal.

Log in to the terminal and restart LiteSpeed ​​by running the following command:

/usr/local/lsws/bin/lswsctrl reload

or

/usr/local/lsws/bin/lswsctrl restart

All settings are now saved.

Identify these changes

Are you still in doubt as to whether these changes will work? You can easily identify these items right on your CyberPanel dashboard. Click Next to do this. database It’s on the right side of the dashboard. Select PHPMyAdmin from the dropdown.

PHPMyadmin cyber panel
PHPMyadmin cyber panel

Click Import and check the MySQL file upload size. (Max: 2,048 MiB).

If not changed, check your PhpMyAdmin php version. If it’s 7.3.x, change the value accordingly.

Phpmyadmin PHP version
Phpmyadmin PHP version

enjoy!

expose

We may receive affiliate commissions from you free of charge when you make purchases through affiliate links on our site.

Source

More from author

Related posts

Latest posts

Dynamic List vs. Active List: A Comprehensive Comparison – Unveiling the Ultimate Winner!

Problem: Difficulty finding necessary controls in the domain overviewwithin the domain outline A variety of essential tools are waiting for you., streamlines the development...

5 Tips for Picking the Best Load Balancer

In today's rapidly changing and highly demanding digital environment, consumers expect web applications to be fast and reliable. According to Google Search Advocate...

Want to stay up to date with the latest news?

We would love to hear from you! Please fill in your details and we will stay in touch. It's that simple!