MySQL Cluster Multi Computer Installation
Each MySQL Cluster host computer running an SQL node must have
installed on it a MySQL binary. For management nodes and data
nodes, it is not necessary to install the MySQL server binary, but
management nodes require the management server daemon
(ndb_mgmd
) and data nodes require the data node
daemon (ndbd
; in MySQL Cluster NDB 7.0 and
later, you can use ndbmtd
instead). It is also
a good idea to install the management client
(ndb_mgm
) on the management server host. This
section covers the steps necessary to install the correct binaries
for each type of Cluster node.
Sun Microsystems, Inc. provides precompiled binaries that support
Cluster. However, we also include information relating to
installing a MySQL Cluster after building MySQL from source. For
setting up a cluster using MySQL's binaries, the first step
in the installation process for each cluster host is to download
the latest MySQL Cluster NDB 6.2, MySQL Cluster NDB 6.3, or MySQL
Cluster NDB 7.0 binary archive
(mysql-cluster-gpl-6.2.19-linux-i686-glibc23.tar.gz
,
mysql-cluster-gpl-6.3.31-linux-i686-glibc23.tar.gz
,
or
mysql-cluster-gpl-7.0.11-linux-i686-glibc23.tar.gz
,
respectively) from the
MySQL Cluster downloads
area
. We assume that you have placed this file in each
machine's /var/tmp
directory. (If you do
require a custom binary, see
Installing from the Development Source Tree
.)
Data and SQL Node Installation — .tar.gz
Binary.
On each of the machines designated to host data or SQL nodes,
perform the following steps as the system
root
user:
Check your /etc/passwd
and
/etc/group
files (or use whatever
tools are provided by your operating
Ïà¹ØÎĵµ£º
#Á½ÈÕÆÚ/ʱ¼äÖ®¼äÏà²îµÄÌìÊý£º¡¡
To_Days(end_time)-To_Days(start_time)¡¡
#Á½ÈÕÆÚ/ʱ¼äÖ®¼äÏà²îµÄÃëÊý£º¡¡
SELECT¡¡UNIX_TIMESTAMP(end_time)-¡¡UNIX_TIMESTAMP(start_time);¡¡
#Á½ÈÕÆÚ/ʱ¼äÖ®¼äÏà²îµÄʱ·ÖÊý£º¡¡
SELECT¡¡SEC_TO_TIME(UNIX_TIMESTAMP(end_time)-¡¡UNIX_T ......
my.cnf »òÕßÊÇ my.ini
ÔÚ[MySQL(ºÍPHP´îÅäÖ®×î¼Ñ×éºÏ)d]ÅäÖöÎÌí¼Ó£º
max_connections = 1000
±£´æ£¬ÖØÆôMySQL(ºÍPHP´îÅäÖ®×î¼Ñ×éºÏ)·þÎñ¡£
È»ºóÓÃÃüÁ
MySQL(ºÍPHP´îÅäÖ®×î¼Ñ×éºÏ)admin -uroot -p variables
ÊäÈërootÊý¾Ý¿âÕ˺ŵÄÃÜÂëºó¿É¿´µ½
| max_connections | 1000 |
Æô¶¯mysql·þÎñ
RedHat ......
Love in coding...
Free and Susan
[Òý]MySQL INNODBÀàÐͱíµÄÍâ¼ü¹ØÁªÉèÖÃ
Here is a simple example that relates parent and child tables through a single-column foreign key:
CREATE TABLE parent (id INT NOT NULL,
......
MySQL·þÎñÆ÷²ÉÓÃÁËÄ£¿é»¯·ç¸ñ£¬¸÷²¿·ÖÖ®¼ä±£³ÖÏà¶Ô¶ÀÁ¢£¬ÓÈÆäÌåÏÖÔÚ´æ´¢¼Ü¹¹ÉÏ¡£´æ´¢ÒýÇ渺Ôð
¹ÜÀíÊý¾Ý´æ´¢£¬ÒÔ¼°MySQLµÄË÷Òý¹ÜÀí¡£Í¨¹ý¶¨ÒåµÄAPI£¬MySQL·þÎñÆ÷Äܹ»Óë´æ´¢ÒýÇæ½øÐÐͨÐÅ¡£Ä¿Ç°Ê¹ÓÃ×î¶àµÄÊÇMyISAMºÍInnoDB¡£
InnoDB±»OracleÊÕ¹ººó£¬MySQL×ÔÐпª·¢µÄд洢ÒýÇæFalcon½«ÔÚMySQL6.0°æ±¾Òý½ø¡£
MyISAMÒýÇæÊÇÒ ......