OwnCloud “You don’t have permission to upload or create files here.” – Quick Tip

You don't have permission to upload or create files here.
You don’t have permission to upload or create files here.

 

In an OwnCloud server if you change the permissions of an external drive to give r/w access (in my case chgrp www-data) and OwnCloud isn’t updating those permissions you can do this. In your MySQL database find your external storage in oc_storages and make note of the numeric id. Then run this query “Delete from oc_filecache where storage = numeric_id” replacing numeric_id with the one you found in the oc_storages table.

My Setup:
Ubuntu 14.04 Server
OwnCloud 7.0.2
MySQL 5.5.38
Apache 2.4.7

Advertisements

11 thoughts on “OwnCloud “You don’t have permission to upload or create files here.” – Quick Tip”

  1. Can someone please tell me how to do this step by step? I am not very proficient with mysql, but i can follow a walk through.

    1. mysql -u root -p #assuming root is your mysql admin user
      #enter mysql admin password
      use owncloud; #assuming your owncloud-db ist called owncloud (which is the default)
      select * from oc_storages;
      #note your user’s “numeric_id”, let’s assume it’s 2
      delete from oc_filecache where storage=2;
      #done

  2. Thanks for posting this answer. It worked for me on an install of 10.0.7. My situation was

    I had FTPed docs to the server, then ran sudo -u www-data php ./occ files:scan all. The files show as expected, but I was receiving the You don’t have permission message.

    I then ran your suggestion of
    mysql -u root -p #assuming root is your mysql admin user
    #enter mysql admin password
    use owncloud; #assuming your owncloud-db ist called owncloud (which is the default)
    select * from oc_storages;
    #note your user’s “numeric_id”, let’s assume it’s 2 (found this using phpmyadmin)
    delete from oc_filecache where storage=2;
    #done

    Again, thanks for posting and sharing knowlege.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s