Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

OK, so I have been at this issue for the better part of 2 hours. I tried this original command

sudo chown www-data:www-data newlogo.png

I got this:

chown: www--data: Invalid argument

I have created a user and a group www-data, changed the file ownership to it but it still won't upload to the server, because:

newlogo.png: open for write: permission denied
Error:  File transfer failed

My issue is this. I need to upload this file to a server and change the ownership to www-data, everything seems like I have done that when I do it through "Get Info" it says a user www-data has permission to read and write, but it still won't upload. And when I change it manually through a terminal I still get the chown: www-data: Invalid argument error.

I am not the greatest at Apache and am about to give up. The only thing that I can see left is that the permission on the server I am trying to upload to are not set correctly to allow me to upload this file.

share|improve this question
Did you try including it in quotes? – AbhishekGirish Oct 23 '12 at 23:49
Need more info here: did you create the www-data user & group on the client, or the server? Are you running the chown command on the client or the server? What are the permissions on the folder the file is in on the server? And finally, how are you trying to upload the file to the server? – Gordon Davisson Oct 24 '12 at 3:59
What shell are you using? – ott-- Oct 24 '12 at 21:06

Try the following:

sudo chown www-data newlogo.png
sudo chgrp www-data newlogo.png
share|improve this answer
Hey guys thanks for all the help here. I actually figured it all out. I was trying to do a lot of it client side and not server side. My bad for not understanding it better before posting the question. Again, thanks for the time. – Dean Karasinski Oct 25 '12 at 0:37

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .