configurer MySQL et PHP sur Linux

configurer MySQL et PHP sur Linux - PHP - Programmation

Marsh Posté le 28-01-2004 à 11:28:54    

Bonjour,
j'ai un gros soucis pour configurer mysql et php sur un serveur linux.
quand je rajoute le fichier my.cnf dans le repertoire /etc/,
j obtient l erreur suivante dans phpMyAdmin:
 
Bienvenue à phpMyAdmin 2.5.4  
 
 
phpMyAdmin a tenté de se connecter au serveur MySQL, et le serveur a rejeté la connexion. Veuillez vérifier les valeurs de "host", "username" et "password" dans config.inc.php et vous assurer qu'elles correspondent aux informations fournies par l'administrateur du serveur MySQL.
 
Erreur
 
MySQL a répondu:
 
 
#2002 - Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2)
[Documentation]  
 
 
je ne vois pas du tout quoi modifier et quelles valeurs rajouter afin que cela fonctionne.
 
si qqun voit kkchose...

Reply

Marsh Posté le 28-01-2004 à 11:28:54   

Reply

Marsh Posté le 28-01-2004 à 11:37:23    

Tu as verifie que tout fonctionne en ligne de commande? C'est la premiere chose a faire avant de continuer.

Reply

Marsh Posté le 28-01-2004 à 16:35:19    

Mais tu as bien édité le fichier config.inc.php et mis les valeurs de ton serveur MySQL ?

Reply

Marsh Posté le 29-01-2004 à 09:42:28    

Tout fonctionne en ligne de commande et quand j efface le fichier de configuration my.cnf du repertoire /etc , phpMyAdmin demarre correctement (je ne sais du coup, pas quel fichier de configuration est utilisé par defaut pour mysql)

Reply

Marsh Posté le 29-01-2004 à 09:50:24    

le fichier utilisé sur ma machine pour php est : config.inc.php
 
<?php
/* $Id: config.inc.php,v 1.204.2.1 2003/10/10 14:24:24 nijel Exp $ */
// vim: expandtab sw=4 ts=4 sts=4:
 
/**
 * phpMyAdmin Configuration File
 *
 * All directives are explained in Documentation.html
 */
 
 
/**
 * Sets the php error reporting - Please do not change this line!
 */
if (!isset($old_error_reporting)) {
    error_reporting(E_ALL);
    @ini_set('display_errors', '1');
}
 
 
/**
 * Your phpMyAdmin url
 *
 * Complete the variable below with the full url ie
 *    http://www.your_web.net/path_to_yo [...] directory/
 *
 * It must contain characters that are valid for a URL, and the path is
 * case sensitive on some Web servers, for example Unix-based servers.
 *
 * In most cases you can leave this variable empty, as the correct value
 * will be detected automatically. However, we recommend that you do
 * test to see that the auto-detection code works in your system. A good
 * test is to browse a table, then edit a row and save it.  There will be
 * an error message if phpMyAdmin cannot auto-detect the correct value.
 *
 * If the auto-detection code does work properly, you can set to TRUE the
 * $cfg['PmaAbsoluteUri_DisableWarning'] variable below.
 */
$cfg['PmaAbsoluteUri'] = '';
 
 
/**
 * Disable the default warning about $cfg['PmaAbsoluteUri'] not being set
 * You should use this if and ONLY if the PmaAbsoluteUri auto-detection
 * works perfectly.
 */
$cfg['PmaAbsoluteUri_DisableWarning'] = FALSE;
 
/**
 * Disable the default warning that is displayed on the DB Details Structure page
 if
 * any of the required Tables for the relationfeatures could not be found
 */
$cfg['PmaNoRelation_DisableWarning']  = FALSE;
 
/**
 * The 'cookie' auth_type uses blowfish algorithm to encrypt the password. If
 * at least one server configuration uses 'cookie' auth_type, enter here a
 * passphrase that will be used by blowfish.
 */
$cfg['blowfish_secret'] = '';
/**
 * Server(s) configuration
 */
$i = 0;
// The $cfg['Servers'] array starts with $cfg['Servers'][1].  Do not use $cfg['Se
rvers'][0].
// You can disable a server config entry by setting host to ''.
$i++;
$cfg['Servers'][$i]['host']          = 'localhost'; // MySQL hostname or IP addre
ss
$cfg['Servers'][$i]['port']          = '';          // MySQL port - leave blank f
or default port
$cfg['Servers'][$i]['socket']        = '';          // Path to the socket - leave
 blank for default socket
$cfg['Servers'][$i]['connect_type']  = 'tcp';       // How to connect to MySQL se
rver ('tcp' or 'socket')
$cfg['Servers'][$i]['compress']      = FALSE;       // Use compressed protocol fo
r the MySQL connection
                                                    // (requires PHP >= 4.3.0)
$cfg['Servers'][$i]['controluser']   = '';          // MySQL control user setting
s
                                                    // (this user must have read-
only
$cfg['Servers'][$i]['controlpass']   = '';          // access to the "mysql/user"
                                                    // and "mysql/db" tables)
$cfg['Servers'][$i]['auth_type']     = 'config';    // Authentication method (con
fig, http or cookie based)?
$cfg['Servers'][$i]['user']          = 'root';      // MySQL user
$cfg['Servers'][$i]['password']      = '';          // MySQL password (only neede
d
                                                    // with 'config' auth_type)
$cfg['Servers'][$i]['only_db']       = '';          // If set to a db-name, only
                                                    // this db is displayed
                                                    // at left frame
                                                    // It may also be an array
                                                    // of db-names
$cfg['Servers'][$i]['verbose']       = '';          // Verbose name for this host
 - leave blank to show the hostname
 
$cfg['Servers'][$i]['pmadb']         = '';          // Database used for Relation
, Bookmark and PDF Features
                                                    // (see scripts/create_tables
.sql)
                                                    //   - leave blank for no sup
port
                                                    //     DEFAULT: 'phpmyadmin'
$cfg['Servers'][$i]['bookmarktable'] = '';          // Bookmark table
                                                    //   - leave blank for no boo
kmark support
                                                    //     DEFAULT: 'pma_bookmark
'
$cfg['Servers'][$i]['relation']      = '';          // table to describe the rela
tion between links (see doc)
                                                    //   - leave blank for no rel
ation-links support
                                                    //     DEFAULT: 'pma_relation
'
$cfg['Servers'][$i]['table_info']    = '';          // table to describe the disp
lay fields
                                                    //   - leave blank for no dis
play fields support
                                                    //     DEFAULT: 'pma_table_info'
$cfg['Servers'][$i]['table_coords']  = '';          // table to describe the tabl
es position for the PDF schema
                                                    //   - leave blank for no PDF
 schema support
                                                    //     DEFAULT: 'pma_table_co
ords'
$cfg['Servers'][$i]['pdf_pages']     = '';          // table to describe pages of
 relationpdf
                                                    //   - leave blank if you don
't want to use this
                                                    //     DEFAULT: 'pma_pdf_page
s'
$cfg['Servers'][$i]['column_info']   = '';          // table to store column info
rmation
                                                    //   - leave blank for no col
umn comments/mime types
                                                    //     DEFAULT: 'pma_column_i
nfo'
$cfg['Servers'][$i]['history']       = '';          // table to store SQL history
                                                    //   - leave blank for no SQL
 query history
                                                    //     DEFAULT: 'pma_history'
$cfg['Servers'][$i]['verbose_check'] = TRUE;        // set to FALSE if you know t
hat your pma_* tables
                                                    // are up to date. This preve
nts compatibility
                                                    // checks and thereby increas
es performance.
$cfg['Servers'][$i]['AllowDeny']['order']           // Host authentication order,
 leave blank to not use
                                     = '';
$cfg['Servers'][$i]['AllowDeny']['rules']           // Host authentication rules,
 leave blank for defaults
                                     = array();
 
 
$i++;
$cfg['Servers'][$i]['host']            = '';
$cfg['Servers'][$i]['port']            = '';
$cfg['Servers'][$i]['socket']          = '';
$cfg['Servers'][$i]['connect_type']    = 'tcp';
$cfg['Servers'][$i]['compress']        = FALSE;
$cfg['Servers'][$i]['controluser']     = '';
$cfg['Servers'][$i]['controlpass']     = '';
$cfg['Servers'][$i]['auth_type']       = 'config';
$cfg['Servers'][$i]['user']            = 'root';
$cfg['Servers'][$i]['password']        = '';
$cfg['Servers'][$i]['only_db']         = '';
$cfg['Servers'][$i]['verbose']         = '';
$cfg['Servers'][$i]['pmadb']           = ''; // 'phpmyadmin' - see scripts/create
_tables.sql
$cfg['Servers'][$i]['bookmarktable']   = ''; // 'pma_bookmark'
$cfg['Servers'][$i]['relation']        = ''; // 'pma_relation'
$cfg['Servers'][$i]['table_info']      = ''; // 'pma_table_info'
$cfg['Servers'][$i]['table_coords']    = ''; // 'pma_table_coords'
$cfg['Servers'][$i]['pdf_pages']       = ''; // 'pma_pdf_pages'
$cfg['Servers'][$i]['column_info']     = ''; // 'pma_column_info'
$cfg['Servers'][$i]['history']         = ''; // 'pma_history'
$cfg['Servers'][$i]['verbose_check']   = TRUE;
$cfg['Servers'][$i]['AllowDeny']['order']
                                       = '';
$cfg['Servers'][$i]['AllowDeny']['rules']
                                       = array();
 
// If you have more than one server configured, you can set $cfg['ServerDefault']
// to any one of them to autoconnect to that server when phpMyAdmin is started,
// or set it to 0 to be given a list of servers without logging in
// If you have only one server configured, $cfg['ServerDefault'] *MUST* be
// set to that server.
$cfg['ServerDefault'] = 1;              // Default server (0 = no default server)
$cfg['Server']        = '';
unset($cfg['Servers'][0]);
 
 
/**
 * Other core phpMyAdmin settings
 */
$cfg['OBGzip']                  = 'auto'; // use GZIP output buffering if possibl
e (TRUE|FALSE|'auto')
$cfg['PersistentConnections']   = FALSE;  // use persistent connections to MySQL
database
$cfg['ExecTimeLimit']           = 300;    // maximum execution time in seconds (0
 for no limit)
$cfg['SkipLockedTables']        = FALSE;  // mark used tables, make possible to s
how
                                          // locked tables (since MySQL 3.23.30)
$cfg['ShowSQL']                 = TRUE;   // show SQL queries as run
$cfg['AllowUserDropDatabase']   = FALSE;  // show a 'Drop database' link to norma
l users
$cfg['Confirm']                 = TRUE;   // confirm 'DROP TABLE' & 'DROP DATABAS
E'
$cfg['LoginCookieRecall']       = TRUE;   // recall previous login in cookie auth
. mode or not
$cfg['UseDbSearch']             = TRUE;   // whether to enable the "database sear
ch" feature
                                          // or not
$cfg['IgnoreMultiSubmitErrors'] = FALSE;  // if set to true, PMA continues comput
ing multiple-statement queries
                                          // even if one of the queries failed
$cfg['VerboseMultiSubmit']      = TRUE;   // if set to true, PMA will show the af
fected rows of EACH statement on
                                          // multiple-statement queries. See the
read_dump.php file for hardcoded
                                          // defaults on how many queries a state
ment may contain!
$cfg['AllowArbitraryServer']    = FALSE;  // allow login to any user entered serv
er in cookie based auth
 
// Left frame setup
$cfg['LeftFrameLight']        = TRUE;   // use a select-based menu and display on
ly the
                                        // current tables in the left frame.
$cfg['LeftFrameTableSeparator']= '__';  // Which string will be used to generate
table prefixes
                                        // to split tables into multiple categori
es
$cfg['LeftFrameTableLevel']   = '1';    // How many sublevels should be displayed
 when splitting
                                        // up tables by the above Separator
$cfg['ShowTooltip']           = TRUE;   // display table comment as tooltip in le
ft frame
$cfg['ShowTooltipAliasDB']    = FALSE;  // if ShowToolTip is enabled, this define
s that table/db comments
$cfg['ShowTooltipAliasTB']    = FALSE;  // are shown (in the left menu and db_det
ails_structure) instead of
                                        // table/db names
 
$cfg['LeftDisplayLogo']       = TRUE;   // display logo at top of left frame
$cfg['LeftDisplayServers']    = FALSE;  // display server choice at top of left f
rame
 
// In the main frame, at startup...
$cfg['ShowStats']             = TRUE;   // allow to display statistics and space
usage in
                                        // the pages about database details and t
able
                                        // properties
$cfg['ShowMysqlInfo']         = FALSE;  // whether to display the "MySQL runtime
$cfg['ShowMysqlVars']         = FALSE;  // information", "MySQL system variables"
, "PHP
$cfg['ShowPhpInfo']           = FALSE;  // information" and "change password" lin
ks for
$cfg['ShowChgPassword']       = FALSE;  // simple users or not
$cfg['SuggestDBName']         = TRUE;   // suggest a new DB name if possible (fal
se = keep empty)
 
// In browse mode...
$cfg['ShowBlob']              = FALSE;  // display blob field contents
$cfg['NavigationBarIconic']   = TRUE;   // do not display text inside navigation
bar buttons
$cfg['ShowAll']               = FALSE;  // allows to display all the rows
$cfg['MaxRows']               = 30;     // maximum number of rows to display
$cfg['Order']                 = 'ASC';  // default for 'ORDER BY' clause (valid
                                        // values are 'ASC', 'DESC' or 'SMART' -i
e
                                        // descending order for fields of type
                                        // TIME, DATE, DATETIME & TIMESTAMP,
                                        // ascending order else-)
 
// In edit mode...
$cfg['ProtectBinary']         = 'blob'; // disallow editing of binary fields
                                        // valid values are:
                                        //   FALSE  allow editing
                                        //   'blob' allow editing except for BLOB
 fields
                                        //   'all'  disallow editing
$cfg['ShowFunctionFields']    = TRUE;   // Display the function fields in edit/in
sert mode
$cfg['CharEditing']           = 'input';
                                        // Which editor should be used for CHAR/V
ARCHAR fields:
                                        //  input - allows limiting of input leng
th
                                        //  textarea - allows newlines in fields
 
// For the export features...
$cfg['ZipDump']               = TRUE;   // Allow the use of zip/gzip/bzip
$cfg['GZipDump']              = TRUE;   // compression for
$cfg['BZipDump']              = TRUE;   // dump files
$cfg['CompressOnFly']         = TRUE;   // Will compress gzip/bzip2 exports on
                                        // fly without need for much memory.
                                        // If you encounter problems with
                                        // created gzip/bzip2 files disable
                                        // this feature.
 
// Tabs display settings
$cfg['LightTabs']             = FALSE;  // use graphically less intense menu tabs
$cfg['PropertiesIconic']      = TRUE;   // Use icons instead of text for the tabl
e display of a database (TRUE|FALSE|'both')
$cfg['PropertiesNumColumns']  = 1;      // How many columns should be used for ta
ble display of a database?
                                        // (a value larger than 1 results in some
 information being hidden)
 
$cfg['DefaultTabServer']      = 'main.php';
                                   // Possible values:
                                   // 'main.php' = the welcome page
                                   // (recommended for multiuser setups)
                                   // 'server_databases.php' = list of databases
                                   // 'server_status.php' = runtime information
                                   // 'server_variables.php' = MySQL server varia
bles
                                   // 'server_privileges.php' = user management
                                   // 'server_processlist.php' = process list
$cfg['DefaultTabDatabase']    = 'db_details_structure.php';
                                   // Possible values:
                                   // 'db_details_structure.php' = tables list
                                   // 'db_details.php' = sql form
                                   // 'db_search.php' = search query
$cfg['DefaultTabTable']       = 'tbl_properties_structure.php';
                                   // Possible values:
                                   // 'tbl_properties_structure.php' = fields lis
t
                                   // 'tbl_properties.php' = sql form
                                   // 'tbl_select.php = select page
                                   // 'tbl_change.php = insert row page
 
/**
 * Export defaults
 */
 
$cfg['Export']['format']                    = 'sql';  // sql/latex/excel/csv/xml
$cfg['Export']['compression']               = 'none'; // none/zip/gzip/bzip2
 
$cfg['Export']['asfile']                    = FALSE;
$cfg['Export']['onserver']                  = FALSE;
$cfg['Export']['onserver_overwrite']        = FALSE;
$cfg['Export']['remember_file_template']    = TRUE;
 
$cfg['Export']['csv_columns']               = FALSE;
$cfg['Export']['csv_null']                  = 'NULL';
$cfg['Export']['csv_separator']             = ';';
$cfg['Export']['csv_enclosed']              = '&quot;';
$cfg['Export']['csv_escaped']               = '\\';
$cfg['Export']['csv_terminated']            = 'AUTO';
$cfg['Export']['excel_columns']             = FALSE;
$cfg['Export']['excel_null']                = 'NULL';
 
$cfg['Export']['latex_structure']           = TRUE;
$cfg['Export']['latex_data']                = TRUE;
$cfg['Export']['latex_columns']             = TRUE;
$cfg['Export']['latex_relation']            = TRUE;
$cfg['Export']['latex_comments']            = TRUE;
$cfg['Export']['latex_mime']                = TRUE;
$cfg['Export']['latex_null']                = '\textit{NULL}';
$cfg['Export']['latex_caption']             = TRUE;
$cfg['Export']['latex_data_label']          = 'tab:__TABLE__-data';
$cfg['Export']['latex_structure_label']     = 'tab:__TABLE__-structure';
 
$cfg['Export']['sql_structure']             = TRUE;
$cfg['Export']['sql_data']                  = TRUE;
$cfg['Export']['sql_drop_database']         = FALSE;
$cfg['Export']['sql_drop_table']            = FALSE;
$cfg['Export']['sql_auto_increment']        = TRUE;
$cfg['Export']['sql_backquotes']            = TRUE;
$cfg['Export']['sql_relation']              = FALSE;
$cfg['Export']['sql_columns']               = FALSE;
$cfg['Export']['sql_extended']              = FALSE;
$cfg['Export']['sql_comments']              = FALSE;
$cfg['Export']['sql_mime']                  = FALSE;
 
/**
 * Link to the official MySQL documentation.
 * Be sure to include no trailing slash on the path.
 * See http://www.mysql.com/documentation/index.html for more information
 * about MySQL manuals and their types.
 */
$cfg['MySQLManualBase'] = 'http://www.mysql.com/doc/en';
 
/**
 * Type of MySQL documentation:
 *   old        - old style used in phpMyAdmin 2.3.0 and sooner
 *   searchable - "Searchable, with user comments"
 *   chapters   - "HTML, one page per chapter"
 *   big        - "HTML, all on one page"
 *   none       - do not show documentation links
 */
$cfg['MySQLManualType'] = 'searchable';
 
 
/**
 * PDF options
 */
$cfg['PDFPageSizes']        = array('A3', 'A4', 'A5', 'letter', 'legal');
$cfg['PDFDefaultPageSize']  = 'A4';
 
 
/**
 * Language and charset conversion settings
 */
// Default language to use, if not browser-defined or user-defined
$cfg['DefaultLang'] = 'en-iso-8859-1';
 
// Force: always use this language - must be defined in
//        libraries/select_lang.lib.php
// $cfg['Lang']     = 'en-iso-8859-1';
 
// Default charset to use for recoding of MySQL queries, does not take
// any effect when charsets recoding is switched off by
// $cfg['AllowAnywhereRecoding'] or in language file
// (see $cfg['AvailableCharsets'] to possible choices, you can add your own)
$cfg['DefaultCharset'] = 'iso-8859-1';
 
// Allow charset recoding of MySQL queries, must be also enabled in language
// file to make harder using other language files than unicode.
// Default value is FALSE to avoid problems on servers without the iconv
// extension and where dl() is not supported
$cfg['AllowAnywhereRecoding'] = FALSE;
 
// You can select here which functions will be used for charset conversion.
// Possible values are:
//      auto   - automatically use available one (first is tested iconv, then
//               recode)
//      iconv  - use iconv or libiconv functions
//      recode - use recode_string function
$cfg['RecodingEngine'] = 'auto';
 
// Specify some parameters for iconv used in charset conversion. See iconv
// documentation for details:
// http://www.gnu.org/software/libico [...] pen.3.html
$cfg['IconvExtraParams'] = '';
 
// Available charsets for MySQL conversion. currently contains all which could
// be found in lang/* files and few more.
// Charsets will be shown in same order as here listed, so if you frequently
// use some of these move them to the top.
$cfg['AvailableCharsets'] = array(
    'iso-8859-1',
    'iso-8859-2',
    'iso-8859-3',
    'iso-8859-4',
    'iso-8859-5',
    'iso-8859-6',
    'iso-8859-7',
    'iso-8859-8',
    'iso-8859-9',
    'iso-8859-10',
    'iso-8859-11',
    'iso-8859-12',
    'iso-8859-13',
    'iso-8859-14',
    'iso-8859-15',
    'windows-1250',
    'windows-1251',
    'windows-1252',
    'windows-1257',
    'koi8-r',
    'big5',
    'gb2312',
    'utf-8',
    'utf-7',
    'x-user-defined',
    'euc-jp',
    'ks_c_5601-1987',
    'tis-620',
    'SHIFT_JIS'
);
 
// Loads language file
require('./libraries/select_lang.lib.php');
 
 
/**
 * Customization & design
 */
$cfg['LeftWidth']           = 150;          // left frame width
$cfg['LeftBgColor']         = '#D0DCE0';    // background color for the left fram
e
$cfg['RightBgColor']        = '#F5F5F5';    // background color for the right fra
me
$cfg['RightBgImage']        = '';           // path to a background image for the
 right frame
                                            // (leave blank for no background ima
ge)
$cfg['LeftPointerColor']    = '#CCFFCC';    // color of the pointer in left frame
                                            // (blank for no pointer)
$cfg['Border']              = 0;            // border width on tables
$cfg['ThBgcolor']           = '#D3DCE3';    // table header row colour
$cfg['BgcolorOne']          = '#CCCCCC';    // table data row colour
$cfg['BgcolorTwo']          = '#DDDDDD';    // table data row colour, alternate
$cfg['BrowsePointerColor']  = '#CCFFCC';    // color of the pointer in browse mod
e
                                            // (blank for no pointer)
$cfg['BrowseMarkerColor']   = '#FFCC99';    // color of the marker (visually mark
s row
                                            // by clicking on it) in browse mode
                                            // (blank for no marker)
$cfg['TextareaCols']        = 40;           // textarea size (columns) in edit mo
de
                                            // (this value will be emphasized (*2
) for sql
                                            // query textareas and (*1.25) for qu
ery window)
$cfg['TextareaRows']        = 7;            // textarea size (rows) in edit mode
$cfg['LongtextDoubleTextarea'] = TRUE;      // double size of textarea size for l
ongtext fields
$cfg['TextareaAutoSelect']  = TRUE;         // autoselect when clicking in the te
xtarea of the querybox
$cfg['CharTextareaCols']    = 40;           // textarea size (columns) for CHAR/V
ARCHAR
$cfg['CharTextareaRows']    = 2;            // textarea size (rows) for CHAR/VARC
HAR
$cfg['CtrlArrowsMoving']    = TRUE;         // Enable Ctrl+Arrows moving between
fields when editing?
$cfg['LimitChars']          = 50;           // Max field data length in browse mode for all non-numeric fields
$cfg['ModifyDeleteAtLeft']  = TRUE;         // show edit/delete links on left sid
e of browse
                                            // (or at the top with vertical brows
e)
$cfg['ModifyDeleteAtRight'] = FALSE;        // show edit/delete links on right si
de of browse
                                            // (or at the bottom with vertical br
owse)
$cfg['DefaultDisplay']      = 'horizontal'; // default display direction
                                            // (horizontal|vertical|horizontalfli
pped)
$cfg['DefaultPropDisplay']  = 'horizontal'; // default display direction for alte
ring/
                                            // creating columns (tbl_properties)
                                            // (horizontal|vertical)
 
$cfg['HeaderFlipType']      = 'css';        // table-header rotation via faking o
r css? (css|fake)
                                            // NOTE: CSS only works in IE browser
s!
$cfg['ShowBrowseComments']  = TRUE;         // shows stored relation-comments in
'browse' mode.
$cfg['ShowPropertyComments']= TRUE;         // shows stored relation-comments in
'table property' mode.
$cfg['RepeatCells']         = 100;          // repeat header names every X cells?
 (0 = deactivate)
 
$cfg['QueryFrame']          = TRUE;         // displays a new frame where a link
to a querybox is always displayed.
$cfg['QueryFrameJS']        = TRUE;         // whether to use JavaScript function
s for opening a new window for SQL commands.
                                            // if set to 'false', the target of t
he querybox is always the right frame.
$cfg['QueryFrameDebug']     = FALSE;        // display JS debugging link (DEVELOP
ERS only)
$cfg['QueryWindowWidth']    = 550;          // Width of Query window
$cfg['QueryWindowHeight']   = 310;          // Height of Query window
$cfg['QueryHistoryDB']      = FALSE;         // Set to TRUE if you want DB-based
query history.
                                            // If FALSE, this utilizes JS-routine
s to display
                                            // query history (lost by window clos
e)
$cfg['QueryWindowDefTab']   = 'sql';        // which tab to display in the queryw
indow on startup
                                            // (sql|files|history|full)
$cfg['QueryHistoryMax']     = 25;           // When using DB-based query history,
 how many entries
                                            // should be kept?
$cfg['BrowseMIME']          = TRUE;         // Use MIME-Types (stored in column c
omments table) for
$cfg['MaxExactCount']       = 20000;        // When approximate count < this, PMA
 will get exact count for
                                            // table rows.
$cfg['WYSIWYG-PDF']         = TRUE;         // Utilize DHTML/JS capabilities to a
llow WYSIWYG editing of
                                            // the PDF page editor. Requires an I
E6/Mozilla based browser.
 
/**
 * SQL Query box settings
 * These are the links display in all of the SQL Query boxes
 */
$cfg['SQLQuery']['Edit']      = TRUE;       // Edit link to change a query
$cfg['SQLQuery']['Explain']   = TRUE;       // EXPLAIN on SELECT queries
$cfg['SQLQuery']['ShowAsPHP'] = TRUE;       // Wrap a query in PHP
$cfg['SQLQuery']['Validate']  = FALSE;      // Validate a query (see $cfg['SQLVal
idator'] as well)
 
 
/**
 * Webserver upload/save/import directories
 */
$cfg['UploadDir']             = '';         // Directory for uploaded files that
can be executed by
                                            // phpMyAdmin. For example './upload'
. Leave empty for
                                            // no upload directory support
$cfg['SaveDir']               = '';         // Directory where phpMyAdmin can sav
e exported data on
                                            // server. For example './save'. Leav
e empty for no save
                                            // directory support.
$cfg['docSQLDir']             = '';         // Directory for docSQL imports, phpM
yAdmin can import
                                            // docSQL files from that directory.
For example
                                            // './docSQL'. Leave empty for no doc
SQL import support.
 
 
/**
 * Misc. settings
 */
$cfg['GD2Available']          = 'auto';     // Is GD >= 2 available? Set to yes/n
o/auto. 'auto'
                                            // does autodetection, which is a bit
 expensive for
                                            // php < 4.3.0, but it is the only sa
fe vay how to
                                            // determine GD version.
/**
 * SQL Parser Settings
 */
$cfg['SQP']['fmtType']      = 'html';       // Pretty-printing style to use on qu
eries (html, text, none)
$cfg['SQP']['fmtInd']       = '1';          // Amount to indent each level (float
s ok)
$cfg['SQP']['fmtIndUnit']   = 'em';         // Units for indenting each level (CS
S Types - {em,px,pt})
$cfg['SQP']['fmtColor']     = array(        // Syntax colouring data
    'comment'            => '#808000',
    'comment_mysql'      => '',
    'comment_ansi'       => '',
    'comment_c'          => '',
    'digit'              => '',
    'digit_hex'          => 'teal',
    'digit_integer'      => 'teal',
    'digit_float'        => 'aqua',
    'punct'              => 'fuchsia',
    'alpha'              => '',
    'alpha_columnType'   => '#FF9900',
    'alpha_columnAttrib' => '#0000FF',
    'alpha_reservedWord' => '#990099',
    'alpha_functionName' => '#FF0000',
    'alpha_identifier'   => 'black',
    'alpha_variable'     => '#800000',
    'quote'              => '#008000',
    'quote_double'       => '',
    'quote_single'       => '',
    'quote_backtick'     => ''
);
 
 
/**
 * If you wish to use the SQL Validator service, you should be
 * aware of the following:
 * All SQL statements are stored anonymously for statistical purposes.
 * Mimer SQL Validator, Copyright 2002 Upright Database Technology.
 * All rights reserved.
 */
$cfg['SQLValidator']['use']      = FALSE;   // Make the SQL Validator available
$cfg['SQLValidator']['username'] = '';      // If you have a custom username, spe
cify it here (defaults to anonymous)
$cfg['SQLValidator']['password'] = '';      // Password for username
 
/**
 * Developers ONLY!
 * To use the following, please install the DBG extension from http://dd.cron.ru/
dbg/
 */
$cfg['DBG']['enable'] = FALSE;              // Make the DBG stuff available
$cfg['DBG']['profile']['enable'] = FALSE;   // Produce profiling results of PHP
$cfg['DBG']['profile']['threshold'] = 0.5;  // Threshold of long running code todisplay
                                            // Anything below the threshold is no
t displayed
 
 
/**
 * MySQL settings
 */
// Column types;
// varchar, tinyint, text and date are listed first, based on estimated popularit
y
$cfg['ColumnTypes'] = array(
   'VARCHAR',
   'TINYINT',
   'TEXT',
   'DATE',
   'SMALLINT',
   'MEDIUMINT',
   'INT',
   'BIGINT',
   'FLOAT',
   'DOUBLE',
   'DECIMAL',
   'DATETIME',
   'TIMESTAMP',
   'TIME',
   'YEAR',
   'CHAR',
   'TINYBLOB',
   'TINYTEXT',
   'BLOB',
   'MEDIUMBLOB',
   'MEDIUMTEXT',
   'LONGBLOB',
   'LONGTEXT',
   'ENUM',
   'SET'
);
 
// Atributes
$cfg['AttributeTypes'] = array(
   '',
   'BINARY',
   'UNSIGNED',
   'UNSIGNED ZEROFILL'
);
 
// Available functions
if ($cfg['ShowFunctionFields']) {
    $cfg['Functions'] = array(
       'ASCII',
       'CHAR',
       'SOUNDEX',
       'LCASE',
       'UCASE',
       'NOW',
       'PASSWORD',
       'MD5',
       'ENCRYPT',
       'RAND',
       'LAST_INSERT_ID',
       'COUNT',
       'AVG',
       'SUM',
       'CURDATE',
       'CURTIME',
       'FROM_DAYS',
       'FROM_UNIXTIME',
       'PERIOD_ADD',
       'PERIOD_DIFF',
       'TO_DAYS',
       'UNIX_TIMESTAMP',
       'USER',
       'WEEKDAY',
       'CONCAT'
    );
 
    // Which column types will be mapped to which Group?
    $cfg['RestrictColumnTypes'] = array(
       'VARCHAR'      => 'FUNC_CHAR',
       'TINYINT'      => 'FUNC_NUMBER',
       'TEXT'         => 'FUNC_CHAR',
       'DATE'         => 'FUNC_DATE',
       'SMALLINT'     => 'FUNC_NUMBER',
       'MEDIUMINT'    => 'FUNC_NUMBER',
       'INT'          => 'FUNC_NUMBER',
       'BIGINT'       => 'FUNC_NUMBER',
       'FLOAT'        => 'FUNC_NUMBER',
       'DOUBLE'       => 'FUNC_NUMBER',
       'DECIMAL'      => 'FUNC_NUMBER',
       'DATETIME'     => 'FUNC_DATE',
       'TIMESTAMP'    => 'FUNC_DATE',
       'TIME'         => 'FUNC_DATE',
       'YEAR'         => 'FUNC_DATE',
       'CHAR'         => 'FUNC_CHAR',
       'TINYBLOB'     => 'FUNC_CHAR',
       'TINYTEXT'     => 'FUNC_CHAR',
       'BLOB'         => 'FUNC_CHAR',
       'MEDIUMBLOB'   => 'FUNC_CHAR',
       'MEDIUMTEXT'   => 'FUNC_CHAR',
       'LONGBLOB'     => 'FUNC_CHAR',
       'LONGTEXT'     => 'FUNC_CHAR',
       'ENUM'         => '',
       'SET'          => ''
    );
 
    // Map above defined groups to any function
    $cfg['RestrictFunctions'] = array(
        'FUNC_CHAR'   => array(
            'ASCII',
            'CHAR',
            'SOUNDEX',
            'LCASE',
            'UCASE',
            'PASSWORD',
            'MD5',
            'ENCRYPT',
            'LAST_INSERT_ID',
            'USER',
            'CONCAT'
        ),
 
        'FUNC_DATE'   => array(
            'NOW',
            'CURDATE',
            'CURTIME',
            'FROM_DAYS',
            'FROM_UNIXTIME',
            'PERIOD_ADD',
            'PERIOD_DIFF',
            'TO_DAYS',
            'UNIX_TIMESTAMP',
            'WEEKDAY'
        ),
 
        'FUNC_NUMBER' => array(
            'ASCII',
            'CHAR',
            'MD5',
            'ENCRYPT',
            'RAND',
            'LAST_INSERT_ID',
            'COUNT',
            'AVG',
            'SUM'
        )
    );
 
} // end if
 
 
/**
 * Unset magic_quotes_runtime - do not change!
 */
set_magic_quotes_runtime(0);
 
/**
 * File Revision - do not change either!
 */
$cfg['FileRevision'] = '$Revision: 1.204.2.1 $';
?>
 

Reply

Marsh Posté le 29-01-2004 à 10:12:00    

bloodfire29 a écrit :

le fichier utilisé sur ma machine pour php est : config.inc.php
 
$cfg['Servers'][$i]['password'] = '';
 


 
Sans le password c'est normal que tu aies une erreur...

Reply

Marsh Posté le 29-01-2004 à 11:33:08    

mon fichier my.cnf dans le repertoire /etc est le suivant.
si kkun peut m aider, j ai tjs cette erreur d erreur de creation de socket mysql.sock
 
 
 
# Example mysql config file for medium systems.
#
# This is for a system with little memory (32M - 64M) where MySQL plays
# a important part and systems up to 128M very MySQL is used together with
# other programs (like a web server)
#
# You can copy this file to
# /etc/my.cnf to set global options,
# mysql-data-dir/my.cnf to set server-specific options (in this
# installation this directory is /var/lib/mysql) or
# ~/.my.cnf to set user-specific options.
#
# One can in this file use all long options that the program supports.
# If you want to know which options a program support, run the program
# with --help option.
 
# The following options will be passed to all MySQL clients
[client]
password        = root
port            = 3306
socket          = /var/lib/mysql/mysql.sock
 
# Here follows entries for some specific programs
 
# The MySQL server
[mysqld]
port            = 3306
socket          = /var/lib/mysql/mysql.sock
skip-locking
key_buffer = 16M
max_allowed_packet = 1M
table_cache = 64
sort_buffer_size = 512K
net_buffer_length = 8K
myisam_sort_buffer_size = 8M
 
# Don't listen on a TCP/IP port at all. This can be a security enhancement,
# if all processes that need to connect to mysqld run on the same host.
# All interaction with mysqld must be made via Unix sockets or named pipes.
# Note that using this option without enabling named pipes on Windows
# (via the "enable-named-pipe" option) will render mysqld useless!
#
#skip-networking
 
# Replication Master Server (default)
# binary logging is required for replication
log-bin
 
# required unique id between 1 and 2^32 - 1
# defaults to 1 if master-host is not set
# but will not function as a master if omitted
server-id       = 1
 
# Replication Slave (comment out master section to use this)
#
# To configure this host as a replication slave, you can choose between
# two methods :
#
# 1) Use the CHANGE MASTER TO command (fully described in our manual) -
#    the syntax is:
#
#    CHANGE MASTER TO MASTER_HOST=<host>, MASTER_PORT=<port>,
#    MASTER_USER=<user>, MASTER_PASSWORD=<password> ;
#
#    where you replace <host>, <user>, <password> by quoted strings and
#    <port> by the master's port number (3306 by default).
#
#    Example:
#
#    CHANGE MASTER TO MASTER_HOST='125.564.12.1', MASTER_PORT=3306,
#    MASTER_USER='joe', MASTER_PASSWORD='secret';
#
# OR
#
# 2) Set the variables below. However, in case you choose this method, then
#    start replication for the first time (even unsuccessfully, for example
#    if you mistyped the password in master-password and the slave fails to
#    connect), the slave will create a master.info file, and any later
#    change in this file to the variables' values below will be ignored and
#    overridden by the content of the master.info file, unless you shutdown
#    the slave server, delete master.info and restart the slaver server.
#    For that reason, you may want to leave the lines below untouched
#    (commented) and instead use CHANGE MASTER TO (see above)
#
# required unique id between 2 and 2^32 - 1
# (and different from the master)
# defaults to 2 if master-host is set
# but will not function as a slave if omitted
#server-id       = 2
#
# The replication master for this slave - required
#master-host     =   <hostname>
#
# The username the slave will use for authentication when connecting
# to the master - required
#master-user     =   <username>
#
# The password the slave will authenticate with when connecting to
# the master - required
#master-password =   <password>
#
# The port the master is listening on.
# optional - defaults to 3306
#master-port     =  <port>
#
# binary logging - not required for slaves, but recommended
#log-bin
 
# Point the following paths to different dedicated disks
#tmpdir         = /tmp/
#log-update     = /path-to-dedicated-directory/hostname
 
# Uncomment the following if you are using BDB tables
#bdb_cache_size = 4M
#bdb_max_lock = 10000
 
# Uncomment the following if you are using InnoDB tables
innodb_data_home_dir = /var/lib/mysql/
innodb_data_file_path = ibdata1:10M:autoextend
wing if you are using InnoDB tables
innodb_data_home_dir = /var/lib/mysql/
innodb_data_file_path = ibdata1:10M:autoextend
innodb_log_group_home_dir = /var/lib/mysql/
innodb_log_arch_dir = /var/lib/mysql/
# You can set .._buffer_pool_size up to 50 - 80 %
# of RAM but beware of setting memory usage too high
innodb_buffer_pool_size = 16M
innodb_additional_mem_pool_size = 2M
# Set .._log_file_size to 25 % of buffer pool size
innodb_log_file_size = 5M
innodb_log_buffer_size = 8M
innodb_flush_log_at_trx_commit = 1
innodb_lock_wait_timeout = 50
 
[mysqldump]
quick
max_allowed_packet = 16M
 
[mysql]
no-auto-rehash
# Remove the next comment character if you are not familiar with SQL
#safe-updates
 
[isamchk]
key_buffer = 20M
sort_buffer_size = 20M
read_buffer = 2M
write_buffer = 2M
 
[myisamchk]
key_buffer = 20M
sort_buffer_size = 20M
read_buffer = 2M
write_buffer = 2M
 
[mysqlhotcopy]
interactive-timeout

Reply

Marsh Posté le 29-01-2004 à 11:44:40    

bloodfire29 > tu as lu mon post? :o

Reply

Sujets relatifs:

Leave a Replay

Make sure you enter the(*)required information where indicate.HTML code is not allowed