Search Our Database

How to Solve ‘PHP has Encountered an Access Violation at xxxxxxxx’ in Plesk

Last updated on |
by

Introduction

The error message “PHP has Encountered an Access Violation at XXXXX” can appear for both administrators and users on Plesk. This critical issue requires immediate attention, as leaving it unresolved may lead to severe system instability or corruption. In this article, we’ll guide you through several methods to resolve this error and prevent it from recurring.

Plesk Error Image

Why Does the Access Violation Error Occur?

This error can be triggered by several factors, including:

  • Conflicting DLL Files: Multiple versions of the same DLL files across different directories.
  • Memory Leaks: If your server is running on Windows, this error could be due to a memory leak in PHP or one of its extensions.
  • eAccelerator Extension Issues: Problems with the PHP eAccelerator extension.
  • Incorrect Folder Permissions: Improper permission settings in the temporary folder.
  • ZendOptimizer Compatibility: Incompatibility between ZendOptimizer and the current PHP version.
  • Application Pool Limits: Limits configured in the application pool, such as memory or process limits.

 

Prerequisites

Before you begin, ensure you have:

  • Administrator access to the Plesk control panel.
  • Remote Desktop access to the server (for Windows servers).
  • A backup of your PHP configuration files and any other critical data.

 

Fixing the Error

Follow these steps to fix the issue when you encounter this error on Plesk:

    • Copy the libmysql.dll file from the following destination
      C:\Program Files (x86)\SWsoft\Plesk\Additional\PleskPHP5 to C:\WINDOWS\system32
    • Add the PHP Path at the beginning of the environment variable “Path.” Add the following path:
      C:/PHP/php.ini 
      C:\Php;%SystemRoot%\system32;%SystemRoot%;%SystemRoot%\System32\Wbem;C:\Program Files\Intel\DMIX;C:\Php;

       

This will help if PHP is unable to access certain resources. Potential reasons might include reaching the memory limit or exceeding the maximum Inodes limit. Alternatively, incorrect code could be holding back memory.

If memory-related issues persist, remove the eAccelerator extension. While this resolves memory issues, note that it could add a burden to your system, as eAccelerator saves system resources.

    • Locate the php.ini file, which can usually be found in one of these locations:
      C:/PHP/php.ini 
      C:/winnt/php.ini 
      C:/Windows/php.ini

If the issue is related to the temp folders, make sure that the correct read, write, and execute permissions are set for these folders:

C:/Windows/temp

If the problem is with ZendOptimizer, try using another version.

 

Conclusion

By following the steps outlined above, you should be able to resolve the access violation error in Plesk. If you encounter further issues, contact Plesk support or your service provider for assistance.

Source: Fix PHP Has Encountered an Access Violation Error on Plesk

 

 

Article posted on 04 July 2020 by ips1