Joomla install on Centos 7 directory permission is unwritabl

Need help installing Joomla! 3.x? For all Joomla! 3.x installation issues please use this forum.

Moderator: General Support Moderators

Forum rules
Forum Rules
Absolute Beginner's Guide to Joomla! <-- please read before posting, this means YOU.
Forum Post Assistant - If you are serious about wanting help, you will use this tool to help you post.
Windows Defender SmartScreen Issues <-- please read this if using Windows 10
Locked
sgugloth
Joomla! Apprentice
Joomla! Apprentice
Posts: 6
Joined: Wed Oct 01, 2014 1:57 am

Joomla install on Centos 7 directory permission is unwritabl

Post by sgugloth » Wed Oct 01, 2014 2:08 am

Hello,

I recently bought virtual server and have centos 7 install. I install LAMP and Joomla 3.3.4 stable version.

The installation was done and i can access the site and admin page. But trying to upload templates i am getting following error:
Warning
Warning: Failed to move file!

JFolder: :files: Path is not a folder. Path: /var/www/html/joomla/tmp/install_542b61271f5d0

JFolder: :folder: Path is not a folder. Path: /var/www/html/joomla/tmp/install_542b61271f5d0

JFolder: :files: Path is not a folder. Path: /var/www/html/joomla/tmp/install_542b61271f5d0

JInstaller: :Install: Cannot find Joomla XML setup file

From Joomla administrator console under system->system Information --> directory permission everything it show is unwritable.

I tried googling and non of the resolution is working. Can some one help me on this.

Is is problem with apache user not providing folder access permission?

My installation location is /var/www/html/joomla
and the folder and its content are assigned to apache:apache

Regards,
Sandeep

sovainfo
Joomla! Exemplar
Joomla! Exemplar
Posts: 8808
Joined: Sat Oct 01, 2011 7:06 pm

Re: Joomla install on Centos 7 directory permission is unwri

Post by sovainfo » Wed Oct 01, 2014 2:48 am

Use FPA
Issue with migrating? Include logs/joomla_update.php in your report!
Blank screen? Verify pagesource for HTML code (javascript error)
Installation failing on populating database? Install with set_time_limit(0)
Document your customizations!

iextensions
I've been banned!
Posts: 1498
Joined: Fri Jul 12, 2013 5:37 pm
Contact:

Re: Joomla install on Centos 7 directory permission is unwri

Post by iextensions » Wed Oct 01, 2014 3:41 am

check correct path of folder: tmp and logs with path in your server.

sgugloth
Joomla! Apprentice
Joomla! Apprentice
Posts: 6
Joined: Wed Oct 01, 2014 1:57 am

Re: Joomla install on Centos 7 directory permission is unwri

Post by sgugloth » Wed Oct 01, 2014 6:09 am

Thank you for your replies.

@ietensions : I changed the tmp path and logs path in the configuration.php. Now when installing any template i get the following error:

Warning
JFolder::create: Could not create directoryPath: /var/www/html/joomla/templates/ice_future

Template Install: Failed to create directory: /var/www/html/joomla/templates/ice_future

@sovainfo : I will install FPA and will post the server information.


Regards,
Sandeep

sgugloth
Joomla! Apprentice
Joomla! Apprentice
Posts: 6
Joined: Wed Oct 01, 2014 1:57 am

Re: Joomla install on Centos 7 directory permission is unwri

Post by sgugloth » Wed Oct 01, 2014 6:26 am

@sovainfo following are the information collected from FPA
Forum Post Assistant (v1.2.4) : 1st October 2014 wrote:
Basic Environment :: wrote:Joomla! Instance :: Joomla! 3.3.4-Stable (Ember) 23-September-2014
Joomla! Platform :: Joomla Platform 13.1.0-Stable (Curiosity) 24-Apr-2013
Joomla! Configured :: Yes | Read-Only (755) | Owner: apache (uid: 1/gid: 1) | Group: apache (gid: 1) | Valid For: 1.5
Configuration Options :: Offline: 0 | SEF: 1 | SEF Suffix: 0 | SEF ReWrite: 0 | .htaccess/web.config: No | GZip: 0 | Cache: 0 | FTP Layer: 0 | SSL: N/A | Error Reporting: default | Site Debug: 0 | Language Debug: 0 | Default Access: N/A | Unicode Slugs: N/A | Database Credentials Present: Yes

Host Configuration :: OS: Linux | OS Version: 3.10.0-123.el7.x86_64 | Technology: x86_64 | Web Server: Apache/2.4.6 (CentOS) PHP/5.4.16 | Encoding: gzip,deflate | Doc Root: /var/www/html | System TMP Writable: Yes

PHP Configuration :: Version: 5.4.16 | PHP API: apache2handler | Session Path Writable: Yes | Display Errors: | Error Reporting: 22527 | Log Errors To: | Last Known Error: | Register Globals: | Magic Quotes: | Safe Mode: | Open Base: | Uploads: 1 | Max. Upload Size: 2M | Max. POST Size: 8M | Max. Input Time: 60 | Max. Execution Time: 30 | Memory Limit: 128M

MySQL Configuration :: Version: 5.5.37-MariaDB (Client:5.5.37-MariaDB) | Host: --protected-- (--protected--) | Collation: latin1_swedish_ci (Character Set: latin1) | Database Size: 3.91 MiB | #of Tables:  68
Detailed Environment :: wrote:PHP Extensions :: Core (5.4.16) | date (5.4.16) | ereg () | libxml () | openssl () | pcre () | zlib (2.0) | bz2 () | calendar () | ctype () | hash (1.0) | filter (0.11.0) | ftp () | gettext () | gmp () | SPL (0.2) | iconv () | Reflection ($Id: 6c4d8062369898a397e4b128348042f5c01b4427 $) | session () | standard (5.4.16) | shmop () | SimpleXML (0.1) | sockets () | mbstring () | tokenizer (0.1) | xml () | apache2handler () | curl () | dom (20031129) | fileinfo (1.0.5) | gd () | json (1.2.1) | ldap () | exif (1.4 $Id$) | mysql (1.0) | mysqli (0.1) | odbc (1.0) | PDO (1.0.4dev) | pdo_mysql (1.0.2) | PDO_ODBC (1.0.1) | pdo_sqlite (1.0.1) | Phar (2.0.1) | posix () | snmp (0.1) | soap () | sqlite3 (0.7) | sysvmsg () | sysvsem () | sysvshm () | wddx () | xmlreader (0.1) | xmlrpc (0.51) | xmlwriter (0.1) | xsl (0.1) | zip (1.11.0) | mhash () | Zend Engine (2.4.0) |
Potential Missing Extensions :: mcrypt | suhosin |

Switch User Environment (Experimental) :: PHP CGI: No | Server SU: No | PHP SU: No | Custom SU (LiteSpeed/Cloud/Grid): No
Potential Ownership Issues: Maybe

Apache Modules :: core | mod_so | http_core | mod_access_compat | mod_actions | mod_alias | mod_allowmethods | mod_auth_basic | mod_auth_digest | mod_authn_anon | mod_authn_core | mod_authn_dbd | mod_authn_dbm | mod_authn_file | mod_authn_socache | mod_authz_core | mod_authz_dbd | mod_authz_dbm | mod_authz_groupfile | mod_authz_host | mod_authz_owner | mod_authz_user | mod_autoindex | mod_cache | mod_cache_disk | mod_data | mod_dbd | mod_deflate | mod_dir | mod_dumpio | mod_echo | mod_env | mod_expires | mod_ext_filter | mod_filter | mod_headers | mod_include | mod_info | mod_log_config | mod_logio | mod_mime_magic | mod_mime | mod_negotiation | mod_remoteip | mod_reqtimeout | mod_rewrite | mod_setenvif | mod_slotmem_plain | mod_slotmem_shm | mod_socache_dbm | mod_socache_memcache | mod_socache_shmcb | mod_status | mod_substitute | mod_suexec | mod_unique_id | mod_unixd | mod_userdir | mod_version | mod_vhost_alias | mod_dav | mod_dav_fs | mod_dav_lock | mod_lua | prefork | mod_proxy | mod_lbmethod_bybusyness | mod_lbmethod_byrequests | mod_lbmethod_bytraffic | mod_lbmethod_heartbeat | mod_proxy_ajp | mod_proxy_balancer | mod_proxy_connect | mod_proxy_express | mod_proxy_fcgi | mod_proxy_fdpass | mod_proxy_ftp | mod_proxy_http | mod_proxy_scgi | mod_systemd | mod_cgi | mod_php5 | Apache/2.4.6 (CentOS) PHP/5.4.16 |
Potential Missing Modules :: mod_security | mod_evasive | mod_dosevasive | mod_ssl | mod_qos | mod_userdir |
Folder Permissions :: wrote:Core Folders :: images/ (755) | components/ (755) | modules/ (755) | plugins/ (755) | language/ (755) | templates/ (755) | cache/ (755) | logs/ (755) | tmp/ (755) | administrator/components/ (755) | administrator/modules/ (755) | administrator/language/ (755) | administrator/templates/ (755) |

Elevated Permissions (First 10) ::
Extensions Discovered :: wrote:Components :: SITE :: com_mailto (3.0.0) | com_wrapper (3.0.0) |
Components :: ADMIN :: com_admin (3.0.0) | com_ajax (3.2.0) | com_banners (3.0.0) | com_cache (3.0.0) | com_categories (3.0.0) | com_checkin (3.0.0) | com_config (3.0.0) | com_content (3.0.0) | com_contenthistory (3.2.0) | com_cpanel (3.0.0) | com_finder (3.0.0) | com_installer (3.0.0) | com_joomlaupdate (3.0.0) | com_languages (3.0.0) | com_login (3.0.0) | com_media (3.0.0) | com_menus (3.0.0) | com_messages (3.0.0) | com_modules (3.0.0) | com_newsfeeds (3.0.0) | com_plugins (3.0.0) | com_postinstall (3.2.0) | com_redirect (3.0.0) | com_search (3.0.0) | com_tags (3.1.0) | com_templates (3.0.0) | com_users (3.0.0) | com_weblinks (3.0.0) |

Modules :: SITE :: mod_articles_archive (3.0.0) | mod_articles_categories (3.0.0) | mod_articles_category (3.0.0) | mod_articles_latest (3.0.0) | mod_articles_news (3.0.0) | mod_articles_popular (3.0.0) | mod_banners (3.0.0) | mod_breadcrumbs (3.0.0) | mod_custom (3.0.0) | mod_feed (3.0.0) | mod_finder (3.0.0) | mod_footer (3.0.0) | mod_languages (3.0.0) | mod_login (3.0.0) | mod_menu (3.0.0) | mod_random_image (3.0.0) | mod_related_items (3.0.0) | mod_search (3.0.0) | mod_stats (3.0.0) | mod_syndicate (3.0.0) | mod_tags_popular (3.1.0) | mod_tags_similar (3.1.0) | mod_users_latest (3.0.0) | mod_weblinks (3.0.0) | mod_whosonline (3.0.0) | mod_wrapper (3.0.0) |
Modules :: ADMIN :: mod_custom (3.0.0) | mod_feed (3.0.0) | mod_latest (3.0.0) | mod_logged (3.0.0) | mod_login (3.0.0) | mod_menu (3.0.0) | mod_multilangstatus (3.0.0) | mod_popular (3.0.0) | mod_quickicon (3.0.0) | mod_stats_admin (3.0.0) | mod_status (3.0.0) | mod_submenu (3.0.0) | mod_title (3.0.0) | mod_toolbar (3.0.0) | mod_version (3.0.0) |

Plugins :: SITE :: plg_authentication_cookie (3.0.0) | plg_authentication_gmail (3.0.0) | plg_authentication_joomla (3.0.0) | plg_authentication_ldap (3.0.0) | plg_captcha_recaptcha (3.0.0) | plg_content_emailcloak (3.0.0) | plg_content_finder (3.0.0) | plg_content_joomla (3.0.0) | plg_content_loadmodule (3.0.0) | plg_content_pagebreak (3.0.0) | plg_content_pagenavigation (3.0.0) | plg_content_vote (3.0.0) | plg_editors_codemirror (3.15) | plg_editors_tinymce (4.1.2) | plg_editors-xtd_article (3.0.0) | plg_editors-xtd_image (3.0.0) | plg_editors-xtd_pagebreak (3.0.0) | plg_editors-xtd_readmore (3.0.0) | plg_extension_joomla (3.0.0) | plg_finder_categories (3.0.0) | plg_finder_contacts (3.0.0) | plg_finder_content (3.0.0) | plg_finder_newsfeeds (3.0.0) | plg_finder_tags (3.0.0) | plg_finder_weblinks (3.0.0) | plg_quickicon_extensionupdate (3.0.0) | plg_quickicon_joomlaupdate (3.0.0) | plg_search_categories (3.0.0) | plg_search_contacts (3.0.0) | plg_search_content (3.0.0) | plg_search_newsfeeds (3.0.0) | plg_search_tags (3.0.0) | plg_search_weblinks (3.0.0) | plg_system_cache (3.0.0) | plg_system_debug (3.0.0) | plg_system_highlight (3.0.0) | plg_system_languagecode (3.0.0) | plg_system_languagefilter (3.0.0) | plg_system_log (3.0.0) | plg_system_logout (3.0.0) | plg_system_p3p (3.0.0) | plg_system_redirect (3.0.0) | plg_system_remember (3.0.0) | plg_system_sef (3.0.0) | IceShortCodes (3.0.1) | plg_twofactorauth_totp (3.2.0) | plg_twofactorauth_yubikey (3.2.0) | plg_user_contactcreator (3.0.0) | plg_user_joomla (3.0.0) | plg_user_profile (3.0.0) | IceShortCodes (3.0.1) |
Templates Discovered :: wrote:Templates :: SITE :: beez3 (3.1.0) | protostar (1.0) |
Templates :: ADMIN :: hathor (3.0.0) | isis (1.0) |

sovainfo
Joomla! Exemplar
Joomla! Exemplar
Posts: 8808
Joined: Sat Oct 01, 2011 7:06 pm

Re: Joomla install on Centos 7 directory permission is unwri

Post by sovainfo » Wed Oct 01, 2014 1:56 pm

Looks like your apache doesn't run as apache:apache.
- change usr/grp apache runs as
or
- change owner webspace to usr/grp apache runs as
or
- enable ftp layer
Issue with migrating? Include logs/joomla_update.php in your report!
Blank screen? Verify pagesource for HTML code (javascript error)
Installation failing on populating database? Install with set_time_limit(0)
Document your customizations!

sgugloth
Joomla! Apprentice
Joomla! Apprentice
Posts: 6
Joined: Wed Oct 01, 2014 1:57 am

Re: Joomla install on Centos 7 directory permission is unwri

Post by sgugloth » Wed Oct 01, 2014 3:40 pm

@sovainfo : I am new to Linux. Are their any command i can run?

How do i check if i am running as apache:apache usr/grp?
Folder Joomla and sub-folders are assigned to apache:apache.

Regards,
Sandeep

sovainfo
Joomla! Exemplar
Joomla! Exemplar
Posts: 8808
Joined: Sat Oct 01, 2011 7:06 pm

Re: Joomla install on Centos 7 directory permission is unwri

Post by sovainfo » Wed Oct 01, 2014 3:54 pm

ps -ef|grep apache
ps -ef|grep httpd

One of these commands depending on your flavor of linux. Also -ef could be different.
Issue with migrating? Include logs/joomla_update.php in your report!
Blank screen? Verify pagesource for HTML code (javascript error)
Installation failing on populating database? Install with set_time_limit(0)
Document your customizations!

sgugloth
Joomla! Apprentice
Joomla! Apprentice
Posts: 6
Joined: Wed Oct 01, 2014 1:57 am

Re: Joomla install on Centos 7 directory permission is unwri

Post by sgugloth » Wed Oct 01, 2014 4:51 pm

@sovainfo here is what the command provides:

[root@localhost ~]# ps -ef|grep apache
apache 11114 11110 0 Sep30 ? 00:00:01 /usr/sbin/httpd -DFOREGROUND
apache 11117 11110 0 Sep30 ? 00:00:00 /usr/sbin/httpd -DFOREGROUND
apache 11119 11110 0 Sep30 ? 00:00:01 /usr/sbin/httpd -DFOREGROUND
apache 11124 11110 0 Sep30 ? 00:00:02 /usr/sbin/httpd -DFOREGROUND
apache 11125 11110 0 Sep30 ? 00:00:00 /usr/sbin/httpd -DFOREGROUND
apache 11135 11110 0 Sep30 ? 00:00:01 /usr/sbin/httpd -DFOREGROUND
apache 11213 11110 0 Sep30 ? 00:00:00 /usr/sbin/httpd -DFOREGROUND
apache 11214 11110 0 Sep30 ? 00:00:00 /usr/sbin/httpd -DFOREGROUND
apache 11215 11110 0 Sep30 ? 00:00:00 /usr/sbin/httpd -DFOREGROUND
apache 11337 11110 0 01:58 ? 00:00:00 /usr/sbin/httpd -DFOREGROUND
root 14734 14715 0 12:50 pts/0 00:00:00 grep --color=auto apache
[root@localhost ~]# ps -ef|grep httpd
root 11110 1 0 Sep30 ? 00:00:03 /usr/sbin/httpd -DFOREGROUND
apache 11114 11110 0 Sep30 ? 00:00:01 /usr/sbin/httpd -DFOREGROUND
apache 11117 11110 0 Sep30 ? 00:00:00 /usr/sbin/httpd -DFOREGROUND
apache 11119 11110 0 Sep30 ? 00:00:01 /usr/sbin/httpd -DFOREGROUND
apache 11124 11110 0 Sep30 ? 00:00:02 /usr/sbin/httpd -DFOREGROUND
apache 11125 11110 0 Sep30 ? 00:00:00 /usr/sbin/httpd -DFOREGROUND
apache 11135 11110 0 Sep30 ? 00:00:01 /usr/sbin/httpd -DFOREGROUND
apache 11213 11110 0 Sep30 ? 00:00:00 /usr/sbin/httpd -DFOREGROUND
apache 11214 11110 0 Sep30 ? 00:00:00 /usr/sbin/httpd -DFOREGROUND
apache 11215 11110 0 Sep30 ? 00:00:00 /usr/sbin/httpd -DFOREGROUND
apache 11337 11110 0 01:58 ? 00:00:00 /usr/sbin/httpd -DFOREGROUND
root 14736 14715 0 12:50 pts/0 00:00:00 grep --color=auto httpd

sovainfo
Joomla! Exemplar
Joomla! Exemplar
Posts: 8808
Joined: Sat Oct 01, 2011 7:06 pm

Re: Joomla install on Centos 7 directory permission is unwri

Post by sovainfo » Wed Oct 01, 2014 5:43 pm

That looks ok to me. Suggest to find info on Centos 7 forum.
Issue with migrating? Include logs/joomla_update.php in your report!
Blank screen? Verify pagesource for HTML code (javascript error)
Installation failing on populating database? Install with set_time_limit(0)
Document your customizations!

sgugloth
Joomla! Apprentice
Joomla! Apprentice
Posts: 6
Joined: Wed Oct 01, 2014 1:57 am

Re: Joomla install on Centos 7 directory permission is unwri

Post by sgugloth » Wed Oct 01, 2014 5:57 pm

@sovainfo : I opened new topic in Centos 7. Are there any other directive i can look for.

I followed LAMP and Joomla installation from howtoforge.
I am missing something?

Regards,
Sandeep

webreplicator
Joomla! Intern
Joomla! Intern
Posts: 59
Joined: Tue Oct 07, 2014 6:59 pm
Contact:

Re: Joomla install on Centos 7 directory permission is unwri

Post by webreplicator » Tue Oct 07, 2014 9:56 pm

You are having permission errors.
In you Admin side go to System=>System Information=>Directory Permission

Make sure your directories has writable permission otherwise you will have to manually provide the permissions. The main reason is because your web server is not configured properly. Your web server requires a user with the appropriate rights in order to run scripts under the docroot, this will prevent from supplying permissions manually at directory or file level.

Austre
Joomla! Apprentice
Joomla! Apprentice
Posts: 32
Joined: Mon Nov 05, 2012 12:47 pm

Re: Joomla install on Centos 7 directory permission is unwri

Post by Austre » Wed Oct 15, 2014 7:39 pm

Hi!

At step 4 of Joomla Installation it shows me that configuration.php is not editable. I supose that if i finish installation, create mannualy configuration.php, i'll get same errors in this topic.

My webserver is CentOS7, httpd service installed, user and group apache set to /var/www/html recursive, no firewall on...



Any clue?

Queasy
Joomla! Enthusiast
Joomla! Enthusiast
Posts: 155
Joined: Thu Apr 17, 2014 12:50 am
Location: Portland Main
Contact:

Re: Joomla install on Centos 7 directory permission is unwri

Post by Queasy » Wed Oct 15, 2014 7:59 pm

The previous commands told will do nothing to resolve your issues.

Try the below commands before the root of your apache to correct rights and ownership:

Get ownership information from command below:
# sudo egrep -i '^user|^group' /etc/httpd/conf/httpd.conf # where ever your apache.conf or httpd.conf if located. On CentOS I believe it's apache:apache owner but double check!

# pwd
/var
# sudo chown -R www-data:www-data www
or
# sudo chown -R www-data:www-data /var/www


This will recursively change and correct apache ownership if the owner is www-data which it usually is on your distro type or apache:apache. Verify ownership from your apache configuration.

Then run this to correct all file rights:

# sudo find /var/www -type f -exec chmod 644 {} \;
# sudo find /var/www -type d -exec chmod 755 {} \;

from terminal. You should alway use sudo.

The PS command will do nothing for you. It shows processes not the information you need.


Locked

Return to “Installation Joomla! 3.x”