简体   繁体   中英

XAMPP - phpMyAdmin error session_start() Permission denied (13)

I recently upgraded my Macbook's OS to El Capitan. I set up XAMPP just like i did on my old OS. I am trying to create a Database using phpMyAdmin But all i am getting is this error:

Warning in ./libraries/session.inc.php#101

session_start(): open(/var/folders/w3/w7pdy78x5r57wmgcytwvh16r0000gn/T/sess_t4t8i795i8d67a52b785rr0j86isrn8c, O_RDWR) failed: Permission denied (13)

Backtrace

./libraries/session.inc.php#101: session_start() ./libraries/common.inc.php#350: require(./libraries/session.inc.php) ./server_databases.php#12: require_once(./libraries/common.inc.php)

I thought it was a permissions issue so i changed all the XAMPP folders to read and write for all but still getting the same error. I have never been faced with this error before and my phpMyAdmin worked fine on my old OS. I have seen similar questions posted on here but none of the answers for them are working for me. Dose anyone know what it could be? Is this a problem within XAMPP/Apache or is this coming from the browser maybe? Im so lost with it and all out of ideas!

UPDATE

I don't know if this helps but i just checked my PHP info settings for session.save_path and it says "NO VALUE" is that suppose to be like that?

After spending all night trying to figure out the problem i finally found the solution. I copied the location of the TMPDIR.

Then used this in the Terminal:

sudo chmod 777 /paste/TMPDIR/location/here/...

And then restart XAMPP and should be all good from there. I hope this helps :)

I had this problem even with correct folder permissions. I solved it deleting the session files that were in the folder

  1. go to your phpinfo() then find your "session.save_path" value
  2. use your terminal locate to that path then try type "ls" to list file
  3. delete all file named start with sess_* (in my case I deleted "rm sess_c4ac83103bb5d8a77352a7cc4c9036eb") and then try refresh phpmyadmin again. it's works for me., hope it helps.

I had same issue in my MAC OX and XAMPP.

To solve issue try to remove session files from location reported in error message. MAC users: /Application/XAMPP/xampfiles/temp/ (whatever the session id is - it will be in error message and you will find file with the same name) Additionally open terminal in the location of /temp folder and change access:

 chmod -R o+w 
  • In case you added vhost it might be in conflict with settings (user daemon, group daemon in htdocs.conf in case you changed user as an vhost change in your XAMPP recommended for MAC users to avoid 403 access denied issue for MAC OX users using XAMPP).
  • in case you have relocated folders in XAMPP/htdocs/ your session will contain same id but will have wrong location and needs to be removed manually as location of your project was while session was active. Go in folder reported in error message and delete session files.

This worked for me, hopefully will save you some time.

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