Learning Mysql


Installing Under Mac OS X | 65



Download 4.24 Mb.
View original pdf
Page63/366
Date04.08.2023
Size4.24 Mb.
#61806
1   ...   59   60   61   62   63   64   65   66   ...   366
Learning MySQL
Installing Under Mac OS X | 65

to start the MySQL server, and sudo /usr/local/mysql/support-files/mysql.server stop
to stop it.
Third, if you installed the MySQLStartupItem.pkg file during the installation process,
you can start the server from the command line by calling sudo /Library/StartupItems/MySQLCOM/MySQLCOM start
and stop it by calling sudo /Library/StartupItems/MySQLCOM/MySQLCOM start
Finally, you can use the generic mysqld_safe and mysqladmin programs from the command prompt. To start the server to run under the system mysql user account, type sudo /usr/local/mysql/bin/mysqld_safe --user=mysql
Then, press the Ctrl-Z key combination, and type
bg
to leave the server running in the background.
You can then stop the server by running the command /usr/local/mysql/bin/mysqladmin --user=root \
--password=the_mysql_root_password shutdown
This approach is the most robust, and also the most flexible if you need to add custom options to your server.
The first thing you should do once you’ve started the server is to set a password for the database root account sudo /usr/local/mysql/bin/mysqladmin --user=root password \
the_new_mysql_root_password
Once you’ve set the MySQL root password, you’ll need to use this in all further accesses to the server. For example, to shutdown the server using mysqladmin
, you would type /usr/local/mysql/bin/mysqladmin --user=root \
--password=the_mysql_root_password shutdown
Installing Only MySQL Using the no-installer Package from MySQL AB
Following the instructions in Downloading MySQL from the MySQL AB Web Site,”
earlier in this chapter, visit the MySQL AB downloads page and download the Without installer package corresponding to the version of your operating system and processor type.
This will download a compressed package with a name like mysql-standard-5.0.22-
osx10.4-i686.tar.gz. This is normally automatically decompressed and unpacked by the web browser to leave the directory mysql-standard-5.0.22-osx10.4-i686 in the download directory. You may instead find that your browser decompresses the file but does not unpack it. If this is the case, you’ll find the file mysql-standard-5.0.22-osx10.4-

Download 4.24 Mb.

Share with your friends:
1   ...   59   60   61   62   63   64   65   66   ...   366




The database is protected by copyright ©ininet.org 2024
send message

    Main page