<< previous page   --   table of contents   --   next page >>
| | | | | | | |
  • Return to Table of Contents
  • Table of Contents

    1. General Information
    2. MySQL Installation
    3. Tutorial Introduction
    4. Database Administration
    5. MySQL Optimisation
    6. MySQL Language Reference
    7. MySQL Table Types
    8. MySQL APIs
    9. Extending MySQL

    190 MySQL Technical Reference for Version 4.0.3 See Section 4.1.1 [Command-line options], page 181. If you are installing binary MySQL versions (.tar les) and start them with ./bin/safe_ mysqld then in most cases the only option you need to add/change is the socket and port argument to safe_mysqld. See Section 4.1.4 [Running Multiple MySQL Servers on the Same Machine], page 190. 4.1.4  Running Multiple MySQL Servers on the Same Machine There are circumstances when you might want to run multiple servers on the same machine. For  example,  you  might  want  to  test  a  new  MySQL  release  while  leaving  your  existing production setup undisturbed.  Or you might be an Internet service provider that wants to provide independent MySQL installations for di erent customers. If you want to run multiple servers, the easiest way is to compile the servers with di erent TCP/IP ports and socket les so they are not both listening to the same TCP/IP port or socket le.  See Section 4.7.3 [mysqld_multi], page 276. Assume an existing server is con gured for the default port number and socket le.  Then con gure the new server with a configure command something like this: shell> ./configure   --with-tcp-port=port_number \ --with-unix-socket-path=file_name \ --prefix=/usr/local/mysql-3.22.9 Here  port_number  and  file_name  should be di erent from the default port number and socket le pathname, and the --prefix value should specify an installation directory dif- ferent from the one under which the existing MySQL installation is located. You can check the socket used by any currently executing MySQL server with this command: shell> mysqladmin -h hostname --port=port_number variables Note that if you specify \localhost" as a hostname, mysqladmin will default to using Unix sockets instead of TCP/IP. If you have a MySQL server running on the port you used, you will get a list of some of the most important con gurable variables in MySQL, including the socket name. You don't have to recompile a new MySQL server just to start with a di erent port and socket.  You can change the port and socket to be used by specifying them at runtime as options to safe_mysqld: shell> /path/to/safe_mysqld --socket=file_name --port=port_number mysqld_multi can also take safe_mysqld (or mysqld) as an argument and pass the options from a con guration le to safe_mysqld and further to mysqld. If you run the new server on the same database directory as another server with logging enabled, you should also specify the name of the log les to safe_mysqld with --log, -- log-update, or  --log-slow-queries.  Otherwise, both servers may be trying to write to the same log le. Warning:   normally  you  should  never  have  two  servers  that  update  data  in  the  same database!  If your OS doesn't support fault-free system locking, this may lead to unpleasant surprises!
     

    Customer Support CentreMySQL Reference Manual

    Web Hosting Services
    UNIX WEB HOSTING
    SUPPORT & FAQ's
    TERMS OF USE
    Domain Services
    DOMAIN REGISTRATION
    MANAGE YOUR ACCOUNT
    SUPPORT & FAQ's
    TERMS OF USE
    SITE MAP
    Home
    Hosting Plans | Domain Registration | About Us | Contact Us | Site Map
    Terms of Use | Privacy Policy | Guarantees
    Merchant Accounts

    SpiritHost - web hosting for spiritual and education sites
    SpiritHit.com - Religious and Spiritual Portal
  • Return to Table of Contents
  • Back to top

  • Web Hosting: Manuals & FAQ's

    1. Unix-Based Web Hosting
    2. Unix Dedicated Servers
    3. Windows Dedicated Servers
    4. CuteFTP User’s Guide
    5. CuteHTML User’s Guide
    6. WS_FTP Pro User's Guide
    7. Miva Order User's Guide
    8. Miva Merchant User's Guide