1

I tried this:

cd /opt/lampp/htdocs/
sudo usermod -a -G daemon john
sudo find . -exec chown john:daemon {} +
sudo find . -type f -exec chmod 664 {} +
sudo find . -type d -exec chmod 775 {} +cd   <-problem child

It goes fine until the last command which gives me "find: missing argument to `-exec'"

So Wordpress cannot add or delete plugins etc... thoughts?

5
  • 1
    I'm certain a webserver should not have any write privileges to htdocs, ever. If you need your PHP software (wordpress) to write to certain locations, a) these should be outside htdocs, imho, and b) these should be very selectively made writable, not blanket. Commented May 29, 2022 at 15:49
  • You have an obvious error into what you have posted. If you run find ... -exec ... + and there are more characters after + then you get the error you describe. Commented May 29, 2022 at 17:47
  • @MarcusMüller thanks for the reply. Not sure what .htdocs has to do with this. In any case, we are on localhost, so the security level is not so important (I wouldn't think). Commented May 29, 2022 at 17:48
  • the folder you're operating in is called "htdocs", and it's typically the folder that your webserver serves publicly. Commented May 29, 2022 at 17:49
  • ok @thanasisp ran that line without "cd" restarted lampp and seems to be good to go. thx Commented May 29, 2022 at 17:53

0

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.