简体   繁体   中英

How do I fix the Apache PHPSESSID err0r?

I am getting the Apache Errors from AWS PHP Library, Here is the error I am getting from Apache error log file,

[Fri Aug 09 15:47:12 2013] [error] Failed to determine HOME directory after trying "sh: 1: cd: can't cd to ~" (exit code 2)
[Fri Aug 09 15:47:12 2013] [error] PHPSESSID f97oht9qlsuvknc45t075hohn5
[Fri Aug 09 15:47:12 2013] [error] f97oht9qlsuvknc45t075hohn5
[Fri Aug 09 15:47:12 2013] [error] f97oht9qlsuvknc45t075hohn5 =

I tried to fix the error with the help of these steps , after that I got the other 3 lines errors,

[Fri Aug 09 15:47:12 2013] [error] PHPSESSID f97oht9qlsuvknc45t075hohn5
[Fri Aug 09 15:47:12 2013] [error] f97oht9qlsuvknc45t075hohn5
[Fri Aug 09 15:47:12 2013] [error] f97oht9qlsuvknc45t075hohn5 =

How do I fix these errors? Thanks for advance help.

If you are using version 1.6.x of the SDK and explicitly providing credentials to the client object (instead of relying the SDK's config discovery mechanism), then you could try using the AWS_DISABLE_CONFIG_AUTO_DISCOVERY constant to circumvent all of the self-discovery code.

You must define the constant before you include the SDK.

define('AWS_DISABLE_CONFIG_AUTO_DISCOVERY', true);
require '/path/to/sdk.class.php';

This will remove the need of the hack as described on isnoop's blog and may also resolve the issue with the other three lines showing up in your log (though I'm not sure why the SDK would cause those lines to appear).

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