Difference between revisions of "Cannot save Global Configuration changes/fr"

From Joomla! Documentation

(Created page with "=== Vérifier la propriété PHP ===")
(Created page with "FAQ Administration - FAQ Version 1.5 - FAQ Category:Global Configuration Management/f...")
Line 38: Line 38:
 
*# Files installed from within Joomla! and with FTP mode inactive will generally be allocated ownership by the “phantom”  user ID that used to run the main web server processes as well as your Joomla! scripts (often named as something like “apache” or “www-data”).
 
*# Files installed from within Joomla! and with FTP mode inactive will generally be allocated ownership by the “phantom”  user ID that used to run the main web server processes as well as your Joomla! scripts (often named as something like “apache” or “www-data”).
 
<noinclude>
 
<noinclude>
[[Category:FAQ]]
+
[[Category:FAQ/fr|FAQ]]
[[Category:Administration FAQ]]
+
[[Category:Administration FAQ/fr|Administration  - FAQ]]
[[Category:Version 1.5 FAQ]]
+
[[Category:Version 1.5 FAQ/fr|Version 1.5 - FAQ]]
[[Category:Global Configuration Management]]
+
[[Category:Global Configuration Management/fr|Gestion de la configuration]]
[[Category:Needs updating]]
+
[[Category:Needs updating/fr|Nécessite une mise à jour]]
 
</noinclude>
 
</noinclude>

Revision as of 10:32, 24 April 2015

Other languages:
Deutsch • ‎English • ‎Nederlands • ‎español • ‎français • ‎русский • ‎हिन्दी • ‎中文(台灣)‎

Après être entré dans l'espace de Configuration en “back-end” et après avoir cliqué sur le bouton “Enregistrer” pour enregistrer votre choix de paramètres du site, le message d'erreur suivant s'affiche : “Une erreur est survenue ! Impossible d'ouvrir à l'écriture le fichier configuration.php !”, éventuellement accompagné du message : “JFTP::write: Mauvaise réponse”, si vous travaillez avec la couche FTP activée.

Raison de cette erreur

Le script de mise à jour de la configuration dans Joomla! n'a pas été en mesure de changer le contenu du fichier “configuration.php” afin de refléter toute modification que vous auriez faite sur la page de configuration. Joomla! n'a soit pas été en mesure d'écrire dans le fichier et/ou n'a pas pu rendre le fichier accessible en écriture (c'est à dire R/W). Since Joomla! 1.5.x attempts to make “configuration.php” writeable before saving the configuration, the latter is more usually the case. The most common reason for this is that the file “configuration.php” is owned by a different logical user to the one trying to make the change. If you are trying to change Global Configuration with FTP enabled, the latter will usually be your FTP login ID; with FTP disabled it will be a web server process identity (often named as something like “apache” or “www-data”). (You can usually check on file ownership details by logging in to your site with an FTP program. Alternatively you could use eXtplorer – see below). Unfortunately, you will be locked out of changing to the appropriate mode to update the Global Configuration as the enabling and disabling of FTP mode (and thus changing the logical identity attempting to change the configuration) is determined by the Global Configuration data held in that file.

Solutions suggérées

Do not make the “configuration.php” file writeable for all users. The result is you will be be able to update the Global Configuration only once. After the initial save, Joomla! will make that file read-only for all users and the problem will exist again.

Propriétaire

Change the ownership of the “configuration.php” file to match either your FTP login ID if using “FTP enabled” for the site, or the web server process identity if you are using “FTP disabled”.

This is not something that you can do within Joomla!. If you have total control of the server (e.g. local server or virtual server) then you should be able to do this using an appropriate utility (such as “chown” for a Linux server).

On a shared server, you should contact the technical support for your organisation or your web hosting provider, explain the problem, and ask them change the file ownership appropriately.

Utiliser une extension

Install the eXtplorer component (obtainable from the Joomla! Extensions Directory – extensions.joomla.org) – if not already in place. This will allow you to view and manipulate files in both “file” mode (using the web server process user identity) or “ftp” mode using your FTP login user identity. Although you will probably not be able to change the file ownership with this tool, you can use one of the modes to make “configuration.php” writeable for all users. This will enable you to change to the Global Configuration once – or more if you include in that a change to the FTP mode so that it matches the ownership of your “configuration.php” file (but see Note below).
NOTE: changing the FTP mode will affect the ownership applied to files uploaded to the site under the new setting (e.g. when installing extensions). File ownership advice from ianmac

Vérifier la propriété PHP

Get your web server to run PHP as CGI or FastCGI. This ensures that the PHP code is executed using the same user ID as used when uploading the Joomla code using FTP. Thus there is no conflict as the ID of the PHP process changing “configuration.php” file is the same as the file's owner. If you do not know how to set CGI or Fast CGI, contact your server administrator or hosting service provider for advice.

Background

The above is a simplified explanation, but the following may be of interest and value to all, and also help expert users formulate their own solution to this problem.

  • The file “configuration.php” is generated automatically in the site’s root folder (from “configuration.php-dist”) during site installation and incorporates in it the site-specific information given during the install process. Changes made in the Global Configuration area in the site's administrative “back-end” are written to “configuration.php” when the either the “Save” or “Apply” button is used.
  • Whenever Joomla! attempts to update “configuration.php” file it first attempts to make it writeable, and after updating the file make it unwriteable (i.e. read-only) as a security precaution.
  • Files on the web server hosting your Joomla! site will be owned by one of several entities, depending on how they were placed or created on the server. Generally files on a Joomla! site will be owned by either of two user identities:
    1. Files you upload by FTP or installed with FTP mode active will generally be allocated ownership of a user ID corresponding to your FTP login ID for that site,
    2. Files installed from within Joomla! and with FTP mode inactive will generally be allocated ownership by the “phantom” user ID that used to run the main web server processes as well as your Joomla! scripts (often named as something like “apache” or “www-data”).