cancel
Showing results for 
Search instead for 
Did you mean: 

Magento 2.1.0 install error

Magento 2.1.0 install error

Hi,

I am using Plesk 12.5.30 on a VPS server with Centos 6.8 using PHP 7.0.27. When I try to install magento 2.1.0 I get the following error:

 

Error: The following error has occurred during the installation of application: Installation of magento at https://domain.com/ failed. Non-zero exit status returned by script. Output stream: 'PHP Fatal error: Uncaught Exception: Warning: SessionHandler::read(): open(/var/lib/php/session/sess_sfoeo8pulnldop8q122bti94k2, O_RDWR) failed: Permission denied (13) in /var/www/vhosts/domain.com/httpdocs/vendor/magento/framework/Session/SaveHandler/Native.php on line 22 in /var/www/vhosts/domain.com/httpdocs/vendor/magento/framework/App/ErrorHandler.php:61 Stack trace: #0 [internal function]: Magento\Framework\App\ErrorHandler->handler(2, 'SessionHandler:...', '/var/www/vhosts...', 22, Array) #1 /var/www/vhosts/domain.com/httpdocs/vendor/magento/framework/Session/SaveHandler/Native.php(22): SessionHandler->read('sfoeo8pulnldop8...') #2 /var/www/vhosts/domain.com/httpdocs/vendor/magento/framework/Session/SaveHandler.php(93): Magento\Framework\Session\SaveHandler\Native->read('sfoeo8pulnldop8...') #3 [internal function]: Magento\Framework\Session\SaveHandler->read('sfoeo8pulnldop8...') #4 /var/www/vhosts/domain.com/httpdocs/vendor/magento/framework/Session/SessionManager.php(189): session_s in /var/www/vhosts/domain.com/httpdocs/vendor/magento/framework/App/ErrorHandler.php on line 61 PHP Fatal error: Uncaught Exception: Warning: SessionHandler::write(): open(/var/lib/php/session/sess_sfoeo8pulnldop8q122bti94k2, O_RDWR) failed: Permission denied (13) in /var/www/vhosts/domain.com/httpdocs/vendor/magento/framework/Session/SaveHandler.php on line 105 in /var/www/vhosts/domain.com/httpdocs/vendor/magento/framework/App/ErrorHandler.php:61 Stack trace: #0 [internal function]: Magento\Framework\App\ErrorHandler->handler(2, 'SessionHandler:...', '/var/www/vhosts...', 105, Array) #1 /var/www/vhosts/domain.com/httpdocs/vendor/magento/framework/Session/SaveHandler.php(105): SessionHandler->write('sfoeo8pulnldop8...', '') #2 [internal function]: Magento\Framework\Session\SaveHandler->write('sfoeo8pulnldop8...', '') #3 {main} thrown in /var/www/vhosts/domain.com/httpdocs/vendor/magento/framework/App/ErrorHandler.php on line 61 '. Error stream: 'PHP Fatal error: Uncaught Exception: Warning: SessionHandler::read(): open(/var/lib/php/session/sess_sfoeo8pulnldop8q122bti94k2, O_RDWR) failed: Permission denied (13) in /var/www/vhosts/domain.com/httpdocs/vendor/magento/framework/Session/SaveHandler/Native.php on line 22 in /var/www/vhosts/domain.com/httpdocs/vendor/magento/framework/App/ErrorHandler.php:61 Stack trace: #0 [internal function]: Magento\Framework\App\ErrorHandler->handler(2, 'SessionHandler:...', '/var/www/vhosts...', 22, Array) #1 /var/www/vhosts/domain.com/httpdocs/vendor/magento/framework/Session/SaveHandler/Native.php(22): SessionHandler->read('sfoeo8pulnldop8...') #2 /var/www/vhosts/domain.com/httpdocs/vendor/magento/framework/Session/SaveHandler.php(93): Magento\Framework\Session\SaveHandler\Native->read('sfoeo8pulnldop8...') #3 [internal function]: Magento\Framework\Session\SaveHandler->read('sfoeo8pulnldop8...') #4 /var/www/vhosts/domain.com/httpdocs/vendor/magento/framework/Session/SessionManager.php(189): session_s in /var/www/vhosts/domain.com/httpdocs/vendor/magento/framework/App/ErrorHandler.php on line 61 PHP Fatal error: Uncaught Exception: Warning: SessionHandler::write(): open(/var/lib/php/session/sess_sfoeo8pulnldop8q122bti94k2, O_RDWR) failed: Permission denied (13) in /var/www/vhosts/domain.com/httpdocs/vendor/magento/framework/Session/SaveHandler.php on line 105 in /var/www/vhosts/domain.com/httpdocs/vendor/magento/framework/App/ErrorHandler.php:61 Stack trace: #0 [internal function]: Magento\Framework\App\ErrorHandler->handler(2, 'SessionHandler:...', '/var/www/vhosts...', 105, Array) #1 /var/www/vhosts/domain.com/httpdocs/vendor/magento/framework/Session/SaveHandler.php(105): SessionHandler->write('sfoeo8pulnldop8...', '') #2 [internal function]: Magento\Framework\Session\SaveHandler->write('sfoeo8pulnldop8...', '') #3 {main} thrown in /var/www/vhosts/domain.com/httpdocs/vendor/magento/framework/App/ErrorHandler.php on line 61 '.
I already tried this 'solution': http://devdocs.magento.com/guides/v2.2/install-gde/trouble/php/tshoot_session.html but it wouldn't work.

I hope someone can help me with this.

5 REPLIES

Re: Magento 2.1.0 install error

Hi @caleb_van wingerden1,

If you are storing sessions in var folder, please try to give 777 permission to it and check.

--------
Give Kudos if it helped or Accept it as solution

Re: Magento 2.1.0 install error

I gave the var folder 777 permission using: chmod -R 777 /var/

After that I tried to install magento with Plesk, but I get the same error.

Re: Magento 2.1.0 install error

The error you are facing is for Session handler of PHP configuration.

 

in your php.ini file you need to enable session.save_handler.

 

you can enable it by uncommenting line - session.save_handler.

 

So un comment session.save_handler parameter of php.ini file and give its  value like .

session.save_handler = files

 

For more details magento 2 itself given good guideline to resolve this issue , here is the link - http://devdocs.magento.com/guides/v2.2/install-gde/trouble/php/tshoot_session.html

 

if issue solved,Click Kudos & Accept as Solution

Re: Magento 2.1.0 install error

screenshot1.JPGThis is my current php.ini file. I think I don't have to change anything according that solution, but the error is still there.

Re: Magento 2.1.0 install error

Hi @caleb _vanwingerden,

Here are some useful links which can help you. As you mentioned with Plesk, I suggest following these.

1. https://talk.plesk.com/threads/magento-2-plesk-compatibility-issue.337302/
2. https://community.magento.com/t5/Installing-Magento-1-x/Magento-and-Plesk-Permissions/td-p/18589


--------
Give Kudos if it helped or Accept it as a solution