Securing the Initial MySQL Accounts
138
This means that you did not start
mysqld
with the
--bdb-no-recover
[1310]
option and Berkeley
DB found something wrong with its own log files when it tried to recover your databases. To be able
to continue, you should move the old Berkeley DB log files from the database directory to some other
place, where you can later examine them. The
BDB
log files are named in sequence beginning with
log.0000000001
, where the number increases over time.
If you are running
mysqld
with
BDB
table support and
mysqld
dumps core at startup, this could be
due to problems with the
BDB
recovery log. In this case, you can try starting
mysqld
with
--bdb-
no-recover
[1310]
. If that helps, you should remove all
BDB
log files from the data directory and try
starting
mysqld
again without the
--bdb-no-recover
[1310]
option.
If either of the following errors occur, it means that some other program (perhaps another
mysqld
server) is using the TCP/IP port or Unix socket file that
mysqld
is trying to use:
Can't start server: Bind on TCP/IP port: Address already in use
Can't start server: Bind on unix socket...
Use
ps
to determine whether you have another
mysqld
server running. If so, shut down the server
before starting
mysqld
again. (If another server is running, and you really want to run multiple servers,
you can find information about how to do so in
Section 5.3, “Running Multiple MySQL Instances on
One Machine”
.)
If no other server is running, try to execute the command
telnet your_host_name
tcp_ip_port_number
. (The default MySQL port number is 3306.) Then press Enter a couple of
times. If you do not get an error message like
telnet: Unable to connect to remote host:
Connection refused
, some other program is using the TCP/IP port that
mysqld
is trying to use.
You will need to track down what program this is and disable it, or else tell
mysqld
to listen to a
different port with the
--port
[417]
option. In this case, you will also need to specify the port number
for client programs when connecting to the server using TCP/IP.
Another reason the port might be inaccessible is that you have a firewall running that blocks
connections to it. If so, modify the firewall settings to permit access to the port.
If the server starts but you cannot connect to it, you should make sure that you have an entry in
/etc/
hosts
that looks like this:
127.0.0.1 localhost
If you cannot get
mysqld
to start, you can try to make a trace file to find the problem by using the
--
debug
[405]
option. See
MySQL Internals: Porting to Other Systems
.
2.18.2. Securing the Initial MySQL Accounts
Part of the MySQL installation process is to set up the
mysql
database that contains the grant tables:
• Windows distributions contain preinitialized grant tables.
• On Unix, the
mysql_install_db
program populates the grant tables. Some installation methods
run this program for you. Others require that you execute it manually. For details, see
Section 2.18.1,
“Unix Postinstallation Procedures”
.
The
mysql.user
grant table defines the initial MySQL user accounts and their access privileges:
• Some accounts have the user name
root
. These are superuser accounts that have all privileges
and can do anything. The initial
root
account passwords are empty, so anyone can connect to the
MySQL server as
root
without a password and be granted all privileges.
• On Windows,
root
accounts are created that permit connections from the local host only.
Connections can be made by specifying the host name
localhost
or the IP address
127.0.0.1
. If the user selects the Enable root access from remote machines option during
installation, the Windows installer creates another
root
account that permits connections from any
host.
Содержание 5.0
Страница 1: ...MySQL 5 0 Reference Manual ...
Страница 18: ...xviii ...
Страница 60: ...40 ...
Страница 396: ...376 ...
Страница 578: ...558 ...
Страница 636: ...616 ...
Страница 844: ...824 ...
Страница 1234: ...1214 ...
Страница 1426: ...MySQL Proxy Scripting 1406 The following diagram shows an overview of the classes exposed by MySQL Proxy ...
Страница 1427: ...MySQL Proxy Scripting 1407 ...
Страница 1734: ...1714 ...
Страница 1752: ...1732 ...
Страница 1783: ...Configuring Connector ODBC 1763 ...
Страница 1793: ...Connector ODBC Examples 1773 ...
Страница 1839: ...Connector Net Installation 1819 2 You must choose the type of installation to perform ...
Страница 1842: ...Connector Net Installation 1822 5 Once the installation has been completed click Finish to exit the installer ...
Страница 1864: ...Connector Net Visual Studio Integration 1844 Figure 20 24 Debug Stepping Figure 20 25 Function Stepping 1 of 2 ...
Страница 2850: ...2830 ...
Страница 2854: ...2834 ...
Страница 2928: ...2908 ...
Страница 3000: ...2980 ...
Страница 3122: ...3102 ...
Страница 3126: ...3106 ...
Страница 3174: ...3154 ...
Страница 3232: ...3212 ...