Jump to content
alsitn

[Solution For] Recursive Write Permissions On Files And Folders Error

Recommended Posts

Hi all,

 

like many, I've found myself in the impossibility to install Prestashop due to lack of permissions with a handful of folders and files. I've thought about 777 CHMOD all the red X folders recursively.

Not only it's an annoying task (/modules/ folder anyone?), but you'll have to CHMOD again any time you need to modify/upgrade something.

 

I've come across a definitive solution for this problem. It's for Pro, though.

 

1-> Connect to your hosting via SSH (any client).

2-> Log in as @root and then write

 

3->

adduser writeanynamehere

3a-> (Optional) You can also give sudo permission to the user you just created via

visudo

4-> Then write

cd /var/www/

5->

chown www-data:www-data * -R

6->

usermod -a -G www-data usernameaddedatstep2

7-> (Optional) restart your web server

 

No more write permissions error.

Have fun ;)

 

Edit: Sorry, I've forgot to mention that this solution has been tested on Ubuntu Server x64 12.10 (Quantal Quetzal) although it's safe to assume that, syntax aside, it should be similar for all Linux distros and versions.

Edited by alsitn (see edit history)
  • Like 1

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...

Important Information

Cookies ensure the smooth running of our services. Using these, you accept the use of cookies. Learn More