cancel
Showing results for 
Search instead for 
Did you mean: 

How can I create Veritas Cluster for mysql 2 instance?

problem 1:

I had 2 binaries

- mysql01
        binary: /usr/local/mysql01  (on local disk)
        data:    /mysql01/data  (on sharedisk)
- mysql02
        binary: /usr/local/mysql02  (on local disk)
        data:    /mysql02/data  (on sharedisk)


I can setup on system1 successful and when I switch diskgroup to system2 when I try to start both mysql on system2 have error.

root@system1.localdomain # /usr/local/mysql01/bin/mysqld_safe: my_print_defaults: not found
/usr/local/mysql01/bin/mysqld_safe: my_print_defaults: not found
090528 13:18:46 mysqld_safe Logging to '/mysql01/data/system1.localdomain.err'.
090528 13:18:46 mysqld_safe The file /usr/local/mysql/bin/mysqld
does not exist or is not executable. Please cd to the mysql installation
directory and restart this script from there as follows:
./bin/mysqld_safe&
See http://dev.mysql.com/doc/mysql/en/mysqld-safe.html for more information

How can I clear this fault? ( when I re-install mysql database; mysql_install_db, it can start process)


Problem 2:

I want to know about resources. what the resources that eassential to create mysql cluster ?

      _______mysql_service_____
     |                                                      |
MOUNT                                       LANMAN
     |                                                      |
VOLUME                                          IP
     |                                                      |
VOLUMEGROUP                         NIC

That enought? (I can't clear problem 1 to test probem 2).
3 Replies

Did you already check the

Did you already check the "Clustering MySQL Using the Agent Builder Tool" TechNote?

http://support.veritas.com/docs/301380

> I want to know about resources. what the resources that eassential to create mysql cluster ?

The above document contains a sample configuration.

I hope this helps.

Regards

Manuel

I had follow guide but it not work.

I had follow guide but it not work.

OK it use reaources as
- DiskGroup
- Mount
- mysql service (i create from agent builder; name: MySQL)

I can bring Diskgroup and Mount online but for MySQL:

I use mysql start script:
#!/bin/sh

ifconfig e1000g0:1 plumb
ifconfig e1000g0:1 192.168.30.205 netmask 255.255.255.0 broadcast + up
cd /usr/local/mysql01
./scripts/mysql_install_db --datadir=/mysql01/data
/usr/local/mysql01/bin/mysqld_safe --defaults-file=/mysql01/data/my.cnf --basedir=/usr/local/mysql01 --datadir=/mysql01/data --user=mysql


for mysql shutdown:

#!/bin/sh

ifconfig e1000g0:1 unplumb
/usr/local/mysql01/bin/mysqladmin -S /tmp/mysql01.sock -u root -pmysql01 shutdown


I follow guide except envfile I can't find this script.

It's cann't bring mysql service up.

> I follow guide except

> I follow guide except envfile I can't find this script.

This is maybe the reason for your problem. VCS and the depending Agents do not have the same environment variables compared to an interactive root shell. The reason is that the VCS daemon inherits in the startup phase the very limited environment from the init process.

You need to create the envfile on your own. It should be in accordance with the user shell that the user attribute specifies. Here is an example:

1) Login as the user specified by the user attribute.
su – mysql

2 ) Capture the environment with the following command.
env > /home/mysql/mysql.env

3) Adopt this file according to the required user shell environment. Here is a ksh shell example:
- Edit the mysql.env file to add string ‘export’ at the beginning of each line.

4) Copy the mysql.env file to shared directory or distribute it to the other nodes.
chmod 755 /home/mysql/mysql.env

I hope this helps. If not please provide your Mysql resource configuration.

Thanks

Manuel

P.S: The virtual IP could be monitored by VCS too.