简体   繁体   中英

open_basedir restriction in effect, but the directory *is specified* in php.ini

I'm running php 5.5.12 on Windows Server 2008 with IIS7 and FastCGI.

Here's one of the log errors I'm getting:

file_put_contents(): open_basedir restriction in effect. File(C:\Program Files (x86)\Wowza Media Systems\Wowza Streaming Engine 4.0.3\content\vod\test.smil) is not within the allowed path(s): (C:\Program Files (x86)\Wowza Media Systems\Wowza Streaming Engine 4.0.3\content\vod;C:\Windows\TEMP\;E:\webpage;C:\php) in E:\webpage\dev\vod\createsettings.php on line 41

Here's my open_basedir line in php.ini :

open_basedir = "C:\Program Files (x86)\Wowza Media Systems\Wowza Streaming Engine 4.0.3\content\vod;C:\Windows\TEMP\;E:\webpage;C:\php"

As you can see, the destination directory is in fact specified in open_basedir , but it's acting as if it's restricted.

Commenting out open_basedir and restarting IIS results in no error and everything works as expected.

Changing the destination directory to one of the other open directories ( C:\\Windows\\TEMP , for example) also works fine with no errors.

I've read eight pages worth of issues here but haven't seen a match. Thanks in advance for any help you can offer!

You're going to run into a lot of permission issues trying to use PHP and C:\\Program Files (x86). Both the 32-bit and 64-bit Program Files directories in Windows are very picky when it comes to write permissions. If you move the directory outside of Program Files and right into the C:\\ drive it should alleviate some problems. (ie, C:\\temp is usually easily accessible with PHP when doing file uploads, session storage, etc...).

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM