Saving General Settings and Uploading Issues

20 posts by 4 authors in: Forums > CMS Builder
Last Post: November 25, 2013   (RSS)

By clowden - November 22, 2013

Dave,

Thank you for the tips and letting me know about the backing up. Damon asked me to open a ticket, which I did, and he helped me out getting the database back. The issue I are still having is being able to upload anything to the server. Below is the error I am getting.

Warning: move_uploaded_file(C:/XXXX/wwwroot/XXXX/uploads//test.png): failed to open stream: Permission denied in 
C:\XXXX\wwwroot\XXXX\adminNew\lib\upload_functions.php on line 183 Warning: move_uploaded_file(): Unable to move 
'C:\WINDOWS\Temp\phpF.tmp' to 'C:/XXXX/wwwroot/XXXX/uploads//test.png' in C:\XXXX\wwwroot\XXXX\adminNew\lib\upload_functions.php 
on line 183 Error moving uploaded file! move_uploaded_file(): Unable to move 'C:\WINDOWS\Temp\phpF.tmp' to 
'C:/XXXX/wwwroot/XXXX/uploads//test.png'

By Dave - November 22, 2013

Hi Clowden,

I would ask your server administrator what windows user IIS runs as (IIS is Microsoft's web server) and to confirm that user has full permissions (as set in Windows Explorer under the security tab)  to C:/XXXX/wwwroot/XXXX/uploads/

The username is likely IUSR or IUSR_YOURSERVERNAME and probably doesn't have permission to create files in that folder.  If the run Windows Explorer (explorer.exe) and go to the security tab they should be able to give full permissions to that folder and it will resolve the issue.

Is it a web hosting company or an internal company server (or are you managing the server yourself?) 

Hope that helps!

Dave Edis - Senior Developer
interactivetools.com

By clowden - November 22, 2013

I will ask and get back to you. Thank you.

They self-host all of their websites on this same server. I think there are about 5 or 6 other CMS installations on there running perfectly fine. I also just upgraded one about a month ago with no issues.

By Dave - November 22, 2013

Ok, let us know.  It just sounds like their file permissions are set incorrectly on that one install.

Dave Edis - Senior Developer
interactivetools.com

By clowden - November 22, 2013

Dave,

Just heard back from the client and he said the following:

I just verified permissions.  While the account didn’t have full access, it had read\write access.  It also had a deny entry for deleting files, and I removed that.  I set it to full permissions for now, but I’ll have to discuss with our internal team if it’s safe to keep it that way, I really don’t like giving a public internet facing guest account full control to folders unless it’s absolutely necessary.

I tried to upload a file and I still received the same error I posted earlier. I purchased a Rapid Response ticket this morning hoping we can get this fixed relatively soon.

Thanks,
Chris

By Damon - November 22, 2013

Hi Chris,

I uploaded a simple test script that returns the name of the owner of the current PHP script:

Current script owner: IUSR_N-PA-WEB01

Cheers,
Damon Edis - interactivetools.com

Hire me! Save time by getting our experts to help with your project.
http://www.interactivetools.com/consulting/

By clowden - November 22, 2013

Are you saying that user IUSR_N-PA-WEB01 is what needs the permissions changed?

By Damon - November 25, 2013

Hi,

Yes, that user needs to have full permissions set.

Can you ask your server admin to check and set that.

Cheers,
Damon Edis - interactivetools.com

Hire me! Save time by getting our experts to help with your project.
http://www.interactivetools.com/consulting/

By Damon - November 25, 2013

Hi,

Yes, that user needs to have full permissions set.

Can you ask your server admin to check and set that.

Cheers,
Damon Edis - interactivetools.com

Hire me! Save time by getting our experts to help with your project.
http://www.interactivetools.com/consulting/

By Dave - November 25, 2013

It's not actually "Full Permissions" that are required, PHP (running as the username identified) needs Read/Write/Erase permissions to that folder and any subfolders or files. 

It's just easier to give Full Permissions because Windows changes the names of the various permissions through the versions.  So your server admin can make the permissions as tight as they need, so long as PHP can create, update, and modify files (as well as list files in the directory, etc).  PHP basically just needs file access to that folder.

Let me know how it goes.

Dave Edis - Senior Developer
interactivetools.com