Click here to get back home

Permissions issue when uploading with FTP

 HomeNewsGroups | Search

alt.www.webmaster - All aspects of webmastering business 

get this group's latest topics as an RSS feed add this group's latest topics to your My MSN content add this group's latest topics to your My Yahoo content
Subject Author Date
Permissions issue when uploading with FTP Chaddy2222 06-16-2009
Posted by Chaddy2222 on June 16, 2009, 11:25 am
Please log in for more thread options
Hi all.
I have an odd issue with FTP. Whenever I upload a PHP file to my web
hosts server, I get the default value of 664 set on the file. This
means that the server generates a 500 internal server error.
The permissions for PHP on this particular server are meant to be set
to 644, due to the way PHP is set-up.
Also when I manually change the permissions everything works fine. But
sometimes the default value for the permissions gets set to 0.
Has anyone else experienced this and how do you fix it, Cpanel uploads
PHP files fine with the correct permissions, but CoreFTP and Filezilla
seam to be having issues.
--
Regards Chad. http://freewebdesignonline.org

Posted by Jeff on June 16, 2009, 11:50 am
Please log in for more thread options
Chaddy2222 wrote:
show/hide quoted text

As you've noticed, your server is screwy. You may wish to ask your
server admin set umask to 022, otherwise you'll have to set it manually
as you have been doing.

I have no idea why setting to 664 should generate a 500 error. 500
errors are usually from too few permissions, not too many. Perhaps
someone else can shed some light on this.

Jeff


show/hide quoted text

Posted by Chaddy2222 on June 16, 2009, 1:01 pm
Please log in for more thread options
show/hide quoted text
Thanks Jeff. I just find it interesting it broke as well. My host
moved a heap of us resellers onto new servers due to perforance
issues.
--
Regards Chad. http://freewebdesignonline.org

Posted by Chaddy2222 on June 18, 2009, 1:26 am
Please log in for more thread options
show/hide quoted text
Hi again Jeff. I spoke to the host and they siad that it was already
set correctly, to what you suggested.
--
Regards Chad. http://freewebdesignonline.org

Posted by Jeff on June 19, 2009, 12:48 am
Please log in for more thread options
Chaddy2222 wrote:
show/hide quoted text

This is an ownership issue and is not unusual for 664 to do that.


500
show/hide quoted text

That's very odd. These are .php files uploaded as ASCII?

Here is something about umask:

http://linuxzoo.net/page/sec_umask.html

If you create a folder, what permission does it have? What is the
folder permission of your scripts parent folder?

http://dotgiri.com/2009/04/16/what-is-umask-and-how-is-umask-set/

Problems will vary depending on who owns the file. You can check
ownership if you have shell access:

ls -l

http://linuxcommand.gds.tuwien.ac.at/lts0030.php

I don't want to lead you astray, I'm not a server admin, I know
enough that there are a lot of ways to set up a webserver, and set up
who owns what files and what group they are. There is no perfect setup
for every possible use.

I'd explain exactly what is going on to your server admin and see
what they say. The servers I have are on Rackspace and when I get
confused I call them. Thats worth a lot!

Maybe someone else can shed some more light on this for you.

Jeff






show/hide quoted text

Similar ThreadsPosted
Folder permissions issue July 2, 2005, 11:59 pm
downloading/uploading time June 9, 2005, 9:05 am
Uploading multiple pics October 26, 2005, 9:01 pm
Batch uploading of files May 7, 2005, 11:46 am
uploading contents on a FP2003 website December 28, 2004, 3:26 am
Uploading files with an apostrophe in the filename May 13, 2007, 11:36 am
Permissions and chmod April 29, 2005, 5:38 pm
Question about Permissions September 6, 2006, 4:26 pm
Uploading files so they retain file date - possible? November 22, 2006, 1:58 am
How to set files permissions with .htaccess March 22, 2006, 5:45 pm

Our other projects:

Art Dolls, Fairies and Mermaids - Sunnyfaces.net

Driving a better car - Fuelzilla.com

Cabling site for homeowners and pros alike - Cabling-Design.com

Friends:

Roy's Linux, Programming and Search Engines messages

1-Script XML SitemapXML Sitemap
Privacy Policy