Question

open_basedir and safe_mode

VPS : CentOS 6.8 x64 Admin: VestaCP

I am trying to rsync my sites from another server. Rsync goes fine.

When I try to reach the site (the new one, rsynced to this server), I got an error in my cakephp logs:

2016-07-21 22:09:28 Warning: Warning (2): curl_setopt(): CURLOPT_FOLLOWLOCATION cannot be activated when an open_basedir is set in 

I tried to disable open_basedir in /etc/php.ini by : open_basedir = none I don’t find any safe_mode in this php.ini

In /usr/local/vesta/php/lib/php.ini , safe_mode = Off and open_basedir = none

I still get the errors after a service httpd restart

What can I do ?

Thanks.

Show comments

Submit an answer


This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Accepted Answer

Even if it was warning, I had to fix the issue. I hate warnings :)

So the issue was fixed:

The file to edit was:

/home/admin/conf/web/httpd.conf

And I had to comment:

php_admin_value open_basedir /home/admin/web/xxx.com/public_html:/home/admin/tmp
Ryan Quinn
DigitalOcean Employee
DigitalOcean Employee badge
July 27, 2016

This question was answered by @BrookDO:

What you’re seeing is a PHP warning message (not an error) so that message should not mean the curl request failed.

Because you’re using Vesta, ccording to docs: https://vestacp.com/docs/#config-log-location-debian-ubuntu you may need to modify /etc/php5/apache2/php.ini on Ubuntu.

View the original comment

This comment has been deleted

    Try DigitalOcean for free

    Click below to sign up and get $200 of credit to try our products over 60 days!

    Sign up

    Get our biweekly newsletter

    Sign up for Infrastructure as a Newsletter.

    Hollie's Hub for Good

    Working on improving health and education, reducing inequality, and spurring economic growth? We'd like to help.

    Become a contributor

    Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.

    Welcome to the developer cloud

    DigitalOcean makes it simple to launch in the cloud and scale up as you grow — whether you're running one virtual machine or ten thousand.

    Learn more
    DigitalOcean Cloud Control Panel