LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 05-12-2017, 06:38 PM   #1
chripy811
Member
 
Registered: Mar 2017
Posts: 31

Rep: Reputation: Disabled
Linux/Wordpress Permissions


I am having a hard time understanding how permissions are supposed to be set.

I can't seem to upgrade my wordpress and i have been reading online that it's a permissions problems.

The problem is i don't really understand who is supposed to own the folders and why

I am using CentOS, when i installed it, i remember it asked me to make a user, i made a user called "admin" i can't remember if i made him a root user,

i also have the root user, and i recently found out there is the apache user also,

can someone explain to me, what permissions and which user is supposed to have permissions for these files,


currently i have 3 users all mixed up, as you can see in the picture below,
Attached Thumbnails
Click image for larger version

Name:	permissions.png
Views:	17
Size:	16.6 KB
ID:	24996  

Last edited by chripy811; 05-12-2017 at 06:49 PM.
 
Old 05-12-2017, 07:07 PM   #2
Habitual
LQ Veteran
 
Registered: Jan 2011
Location: Yawnstown, Ohio
Distribution: Mojave
Posts: 9,374
Blog Entries: 37

Rep: Reputation: Disabled
https://codex.wordpress.org/Hardenin...le_Permissions
https://codex.wordpress.org/Installi...Minute_Install


/var/www/html/turdpress -R is gonna be the apache service/user.
files should be 644
directories should be 755
With few exceptions... None of those apply (cgi-stuff)

When you installed it, the installer "asked you" to make an admin user, it was for the Wordpress admin account
It is NOT a linux system-level user.
It's the god-mode / Power User / Admin

If you can't upgrade, it is likely a file permissions:ownership-related.
https://codex.wordpress.org/Hardenin...le_Permissions says what I've said.

Files:
Code:
find /var/www/html/turdpress/ -type f -exec chmod 644 {} \;
"Folders" or directories:
Code:
find /var/www/html/turdpress/ -type d -exec chmod 755 {} \;
Owner:
Code:
chmod -R apache:apache /var/www/html/turdpress/
Then check your dashboard for update and see what happens.
 
Old 05-12-2017, 08:09 PM   #3
chripy811
Member
 
Registered: Mar 2017
Posts: 31

Original Poster
Rep: Reputation: Disabled
hmm i followed your instructions but it didn't work, maybe it's not a permissions problem


i could update it manually but it's really bugging me to as why it's not working,


what is weird is updating plugins and installing themes work fine
Attached Thumbnails
Click image for larger version

Name:	wordpress.png
Views:	12
Size:	24.0 KB
ID:	24997  

Last edited by chripy811; 05-12-2017 at 08:10 PM.
 
Old 05-13-2017, 04:56 AM   #4
ondoho
LQ Addict
 
Registered: Dec 2013
Posts: 13,422
Blog Entries: 9

Rep: Reputation: 3668Reputation: 3668Reputation: 3668Reputation: 3668Reputation: 3668Reputation: 3668Reputation: 3668Reputation: 3668Reputation: 3668Reputation: 3668Reputation: 3668
i thinkthe most important bit from the previous post is that wordpress has a vast amount of tutorials and documentation for you to peruse.
centos is most certainly also mentioned.
one thing though: somehow i get the impression that you are using centos 6.8. good, and NOT outdated, but many of the tutorials might assume that you are using a somewhat newer operating system.
 
Old 05-13-2017, 08:15 AM   #5
Habitual
LQ Veteran
 
Registered: Jan 2011
Location: Yawnstown, Ohio
Distribution: Mojave
Posts: 9,374
Blog Entries: 37

Rep: Reputation: Disabled
How about a "Please" and "Thank You"?

Quote:
Originally Posted by chripy811 View Post
i have been reading online that it's a permissions problems.
Quote:
Originally Posted by chripy811 View Post
maybe it's not a permissions problem


I've used those 2 documents for 5 years or more on 100s of Turdpress installs and all mine work.
IDK what you've read, but I'm pretty sure it wasn't sourced from wordpress.com/codex

You had my attention, and now you don't. Good Luck. Nothing personal.
 
Old 05-13-2017, 06:47 PM   #6
chripy811
Member
 
Registered: Mar 2017
Posts: 31

Original Poster
Rep: Reputation: Disabled
i meant during the centos installation it asks you to make a user


i will just update manually, i still can't figure it out



also, i am using centos 7 , not 6, i will try to yum update
Attached Thumbnails
Click image for larger version

Name:	CentOS-7-Installation-2422.png
Views:	7
Size:	79.2 KB
ID:	25009  

Last edited by chripy811; 05-13-2017 at 06:50 PM.
 
Old 05-13-2017, 07:52 PM   #7
Habitual
LQ Veteran
 
Registered: Jan 2011
Location: Yawnstown, Ohio
Distribution: Mojave
Posts: 9,374
Blog Entries: 37

Rep: Reputation: Disabled
CentOS installation has nothing to do with Wordpress, so I'm not sure how that's relevant.
yum update won't fix a busted Turdpress, you will have to.

All this is discussed at https://codex.wordpress.org/Installing_WordPress

Step1
step2

Is the English language an issue?

Whatever is baking your banana must be
You don't have a standard install.
You aren't reading at https://codex.wordpress.org/Installing_WordPress or
You aren't comprehending https://codex.wordpress.org/Installing_WordPress

Enough, you're not asking the right questions to solve this issue, so that
says to me you are not reading https://codex.wordpress.org/Installing_WordPress at all.

It's not going to magically fix itself. You're not trying IMO.
Failure is feedback.
 
Old 05-14-2017, 02:35 AM   #8
ondoho
LQ Addict
 
Registered: Dec 2013
Posts: 13,422
Blog Entries: 9

Rep: Reputation: 3668Reputation: 3668Reputation: 3668Reputation: 3668Reputation: 3668Reputation: 3668Reputation: 3668Reputation: 3668Reputation: 3668Reputation: 3668Reputation: 3668
Quote:
Originally Posted by chripy811 View Post
i meant during the centos installation it asks you to make a user


i will just update manually, i still can't figure it out

https://www.linuxquestions.org/quest...9&d=1494715753

also, i am using centos 7 , not 6, i will try to yum update
is this shot taken during installation?


it's really busy installing loads of stuff.

i think you are totally confused.

i will break it down for you:

1) you must install the operating system, which includes standard stuff like initial updates, creating a user, choosing a password etc.

2) then you must install a web server. the obvious choice is apache, and php. this with yum.

3) then you must get your server working, i.e. your machine is serving pages to the outside world, from some other machine you can see maybe the apache test page.

4) only now (!) do you go to wordpress, download the latest wordpress, and follow THEIR instructions to install it.

you MUST follow these steps in exactly that order.
there's no other way.
 
Old 05-15-2017, 05:03 AM   #9
r3sistance
Senior Member
 
Registered: Mar 2004
Location: UK
Distribution: CentOS 6/7
Posts: 1,375

Rep: Reputation: 217Reputation: 217Reputation: 217
Personally I advise against any CMS as they generally lead to bad practices, if you must use wordpress then makesure to follow the wordpress hardening document: https://codex.wordpress.org/Hardening_WordPress

It'll avoid most of the issues that makes wordpress like Swiss cheese in regards to security.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
LXer: WordPress Plugin Tutorial ó How To Install WordPress Plugins LXer Syndicated Linux News 0 12-09-2015 10:10 AM
failure to run wordpress due to permissions error Greebstreebling Linux - Software 3 08-27-2012 04:57 PM
[SOLVED] WordPress 3.3 permissions trouble silmaril8n Debian 2 05-30-2012 01:59 PM
[SOLVED] Wordpress permissions on Linux server. peterson.julia Linux - Newbie 3 03-10-2011 10:15 PM
Permissions for Wordpress vital_101 Ubuntu 3 10-03-2006 06:53 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 04:57 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration