Where to download kits
The kits of MySQL on OpenVMS can be download from:
http://www.pi-net.dyndns.org/anonymous/kits/axp/ for Alpha processors
http://www.pi-net.dyndns.org/anonymous/kits/ia64/ for Itanium processors
Requirement
Zlib V1.2.3 need to be installed before MySQL.
How to install MySQL 5.1.11 on OpenVMS
By default, the installation procedure installs MySQL in the SYS$COMMON:[MYSQL051] directory. To install it in another directory, dev:[dir], use the /DESTINATION parameter of the PRODUCT command. In this case, MySQL will be installed in the dev:[dir.MYSQL] directory.
New installation
- Make the directory which holds the ZIP file your default directory
- Extract the PCSI kit from the ZIP archive.
$ UNZIP "-V" MYSQL051-V1100-0-1.ZIP
- Install MySQL to your chosen destination directory.
$ PRODUCT INSTALL MYSQL051 (default)
- or ...
$ PRODUCT INSTALL MYSQL051 /DESTINATION=dev:[dir]
- Change the default directory to the VMS-specific directory and run the two DCL procedure files, LOGICALS.COM and SYMBOLS.COM, to define the necessary logicals and symbols for MySQL.
$ SET DEFAULT SYS$COMMON:[MYSQL051.VMS] (default)
- or ...
$ SET DEFAULT dev:[dir.MYSQL051.VMS]
- then ...
$ @LOGICALS "/SYSTEM/EXEC" $ @SYMBOLS
- Configure the MySQL package to suit your environment by editing the file MYSQL051_ROOT:[VMS]my.cnf and MYSQL051_ROOT:[VMS.MYSQL]run_mysqld.com
$ copy my.cnf_template my.cnf/prot=w:re $ edit my.cnf ... $ copy [.mysql]run_mysqld.com_template [.mysql]run_mysqld.com/prot=w:re $ edit [.mysql]run_mysqld.com ... - Run the special DCL procedure FIRST_START_MYSQLD.COM to start the MySQL server for the first time.
$ @[.MYSQL]FIRST_START_MYSQLD
- . .and wait here a few moments for the database to be created.
- Run the special DCL procedure MYSQL051_CREATE_SYSTEM_TABLES.COM to create the system tables.
$ @[.MYSQL]MYSQL051_CREATE_SYSTEM_TABLES
- Connect to the master system table and display the existing password for ROOT (should be "" at this point).
$ mysql Welcome to the MySQL monitor. Commands end with ; or \g. Your MySQL connection id is 1 to server version: 5.1.11-beta-log Type 'help;' or '\h' for help. Type '\c' to clear the buffer. mysql> use mysql Database changed mysql> select Host, User, Password from user; +-----------+------+----------+ | Host | User | Password | +-----------+------+----------+ | localhost | root | | +-----------+------+----------+ 1 row in set (0.00 sec)
IMPORTANT! Define a password for the ROOT MySQL account.
mysql> update user set Password=PASSWORD('myrootpassword') where User='root'; Query OK, 0 rows affected (0.00 sec) Rows matched: 1 Changed: 1 Warnings: 0 mysql> select Host, User, Password from user; +-----------+------+------------------+ | Host | User | Password | +-----------+------+------------------+ | localhost | root | 6b6403a743ef6b56 | +-----------+------+------------------+ 1 row in set (0.00 sec) mysql> flush privileges; Query OK, 0 rows affected (0.16 sec) $- (Optional): You must also change the HOST field contents if you want to access MySQL from another host using the ROOT account. For example, setting HOST to '%' allows access from anywhere.
- (Optional): Verify your password and/or host changes took effect.
$ MYSQLADMIN -u root -p STATUS Enter password: Uptime: 25 Threads: 1 Questions: 1 Slow queries: 0 Opens: 6 Flush tables: 1 Open tables: 0 Queries per second avg: 0.040 $
- Shut down the MySQL server process.
$ MYSQLADMIN -u root -p SHUTDOWN $ MYSQLADMIN -u root -p SHUTDOWN That's right, quit twice :-)
- Finally, run the DCL procedure MYSQL_STARTUP.COM.
- (You might want to add this line to your SYSTARTUP_VMS.COM file.)
$ @dev:[dir.mysql051.VMS]MYSQL_STARTUP
You should now have a running MySQL 5.1.11 server!
New SYSUAF Account
This installation procedure creates the unprivileged SYSUAF account MYSQL_SERVER to run the server. After installation is complete, you will want to review the security settings on all volumes, directories, and files this account will access during operation and adjust them according to your needs.
Test the installation
Note: 5.1.11 of MySQL has a bug in InnoDB that can cause this version of mysqld to crash. See http://bugs.mysql.com/bug.php?id=20213
