need urgent help!

Posted by Jerenn, 07-17-2007, 07:54 AM
I am really sorry cause I couldnt get where to make this post! one of my clients is receving this error : Warning: move_uploaded_file(../upload/adoptive_link/mdsmds.jpg) [function.move-uploaded-file]: failed to open stream: Permission denied in /home/parsamds/public_html/c-panel/analysis.php on line 1049 what casues this error and what is the soloution!? Thanks

Posted by Jerenn, 07-17-2007, 07:57 AM
and I have to mention that all the names of files and folders are correct!

Posted by BigGorilla, 07-17-2007, 07:57 AM
You or the webserver doesn't have write permissions on the directory the uploaded file is being moved to. If you are in a phpsuexec or similar environment, you need to have 755 permissions on the directory, otherwise you may need 777.

Posted by erigid, 07-17-2007, 07:58 AM
It appears that the script /home/parsamds/public_html/c-panel/analysis.php is trying to upload a file to directory /home/parsamds/public_html/upload/adoptive_link/. Check the directory's permissions. You can either change the ownership of that directory to be owned by the webserver's user or something like chmod 777 /home/parsamds/public_html/upload/adoptive_link/. If that doesnt work check also the permissions for /home/parsamds/public_html/upload.

Posted by Jerenn, 07-17-2007, 08:19 AM
Thank you , I hope this solves the problem , I'll be back if he still had problems

Posted by Jerenn, 07-17-2007, 10:29 AM
another question .. by using permission 777 , will there be any problem about the security? thanks

Posted by erigid, 07-17-2007, 10:34 AM
777 means any user in your server can write to it. As far as security it depends on your server setup. You can also change the owner of that folder to be the webserver's user but user parsamds wont be able to write to it.

Posted by erigid, 07-17-2007, 10:36 AM
BTW, if you setup the sticky bit on the directory everyone can write to it but a user can only remove the files they created. Those are usually the permissions for /tmp. To setup the sticky bit you use 1777 instead of 777

Posted by SparkSupport, 07-17-2007, 10:43 AM
Make sure that you never have permission with 777 for folders and files, it is a major security threat.

Posted by Jerenn, 07-17-2007, 10:47 AM
sure thanks

Posted by erigid, 07-17-2007, 10:51 AM
I wouldn't call it a MAJOR security threat. It really depends on his server. I guess you can also do 733 but the web server user may need read access to that directory. Just use 777 for right now, see if it gets fixed, if it does, you know that was the problem. You can work your way up to secure it. If that wasnt the problem make sure to chmod it back to original permissions (probably 755)

Ця відповідь Вам допомогла?

 Роздрукувати цю статтю

Також прочитайте

Phpmyadmin and Webmail access problem from cpanel

Posted by Doctor_Web, 09-07-2007, 01:02 PMHello, we have a important problem with our cPanel...

utterly confused about external links?

Posted by gg2327, 09-14-2007, 11:02 PMhave a few different list of links in my link section for...

How Change Owner?

Posted by hichkas, 07-17-2007, 07:59 AMHi How i Can Change Owner to User! In VPS? Posted by...

how to cron on windows server?

Posted by waveking, 05-03-2007, 10:04 AMHi, I truly love the 'cron' feature on Linux servers....

Apache and extensions

Posted by attroll, 01-14-2008, 12:01 AMI have found a hole in one of my servers that someone else...