# Главная
# О библиотеке

# Выбор дистрибутива
преимущества Linux/UNIX | основные дистрибутивы | серверный Linux | BSD | LiveCDs | прочее

# Установка и удаление программ
общие вопросы | каталоги софта | специальные случаи

# Настройка и работа
установка, загрузчики | настройка Linux | консоль | файловые системы | процессы | шеллы, русификация, коммандеры | виртуальные машины, эмуляторы

# X Window и оконные менеджеры
настройка X Window | GNOME | KDE | IceWM и др.

# Работа с текстами
редакторы | офис | шрифты, кодировки и русификация | преобразования текстовых файлов | LaTeX, SGML и др. | словари

# Графика
GIMP | фото | обработка изображений | форматы графических файлов

# Сети, администрирование
общие вопросы | Dialup & PPP | брандмауэры | маршрутизация | работа в Windows-сетях | веб-серверы | Apache | прокси-серверы | сетевая печать | прочее

# Программирование
GCC & GNU make | программирование в UNIX | графические библиотеки | Tcl | Perl | PHP | Java & C# | СУБД | CVS | прочее

# Ядро
# Мультимедиа
# Интернет
# Почта
# Безопасность
# Железо
# Разное

# Linux HowTo (как сделать)
# Книги и руководства
# Материалы на английском языке


MySQL The World's Most Popular Open Source Database # Online shop | Site map |  
CompanyProductsSupport & ConsultingTraining & CertificationDownloadsDocumentation
  BooksArticlesMailing ListsPresentationsOther Sites  
Search the MySQL manual:
MySQL Manual
  • 1 Общая информация
  • 2 Установка MySQL
  • 3 Учебное пособие по MySQL
  • 4 Администрирование баз данных
  • 5 Оптимизация в MySQL
  • 6 Справочник по языку MySQL
  • 7 Типы таблиц MySQL
  • 8 Интерфейсы для MySQL
  • 9 Расширение MySQL
  • A Проблемы и распространенные ошибки
    • A.1 Как определить, чем вызваны проблемы
    • A.2 Распространенные ошибки при использовании MySQL
    • A.3 Вопросы, связанные с инсталляцией
    • A.4 Вопросы, связанные с администрированием
    • A.5 Проблемы, относящиеся к запросам
    • A.6 Вопросы, связанные с определением таблиц
  • B Привнесенные программы
  • C Благодарности
  • D История изменений и обновлений MySQL
  • E Перенос на другие системы
  • F Переменные окружения
  • G Регулярные выражения в MySQL
  • H GNU General Public License
  • I GNU Lesser General Public License
  • Команды SQL, функциональное оглавление
  • Концептуальное оглавление

Buy this Reference Manual in softcover from Barnes & Noble!

MySQL Reference Manual
Previous / Next / Up / Table of Contents

A Проблемы и распространенные ошибки

В этой главе перечислены некоторые распространенные проблемы и сообщения об ошибках, с которыми приходится сталкиваться пользователям. Вы научитесь выяснять, в чем заключается проблема и что следует сделать для ее решения. Кроме того, здесь даны правильные решения некоторых распространенных проблем.

Главы

  • A.1 Как определить, чем вызваны проблемы
  • A.2 Распространенные ошибки при использовании MySQL
    • A.2.1 Ошибка Access denied
    • A.2.2 Ошибка MySQL server has gone away
    • A.2.3 Ошибка Can't connect to [local] MySQL server
    • A.2.4 Ошибка Host '...' is blocked
    • A.2.5 Ошибка Too many connections
    • A.2.6 Ошибка Some non-transactional changed tables couldn't be rolled back
    • A.2.7 Ошибка Out of memory
    • A.2.8 Ошибка Packet too large
    • A.2.9 Коммуникационные ошибки / Оборванные соединения
    • A.2.10 Ошибка The table is full
    • A.2.11 Ошибка Can't create/write to file
    • A.2.12 Ошибка в клиенте Commands out of sync
    • A.2.13 Ошибка Ignoring user
    • A.2.14 Ошибка Table 'xxx' doesn't exist
    • A.2.15 Ошибка Can't initialize character set xxx
    • A.2.16 Не найден файл (File not found)
  • A.3 Вопросы, связанные с инсталляцией
    • A.3.1 Проблемы при линковании с клиентской библиотекой MySQL
    • A.3.2 Запуск MySQL от обычного пользователем
    • A.3.3 Проблемы с правами доступа к файлам
  • A.4 Вопросы, связанные с администрированием
    • A.4.1 Что делать, если работа MySQL сопровождается постоянными сбоями
    • A.4.2 Как переустановить забытый пароль пользователя root
    • A.4.3 Как MySQL реагирует на переполнение диска
    • A.4.4 Где MySQL хранит временные файлы
    • A.4.5 Как защитить или изменить сокет-файл MySQL `/tmp/mysql.sock'
    • A.4.6 Проблемы с часовыми поясами
  • A.5 Проблемы, относящиеся к запросам
    • A.5.1 Чувствительность к регистру при поиске
    • A.5.2 Проблемы с использованием столбцов типа DATE
    • A.5.3 Проблемы со значением NULL
    • A.5.4 Проблемы с alias
    • A.5.5 Удаление строк из взаимосвязанных таблиц
    • A.5.6 Решение проблем с отсутствием строк, удовлетворяющих условиям поиска
    • A.5.7 Проблемы со сравнением чисел с плавающей точкой
  • A.6 Вопросы, связанные с определением таблиц
    • A.6.1 Проблемы с ALTER TABLE
    • A.6.2 Как изменить порядок столбцов в таблице
    • A.6.3 Проблемы, относящиеся к временным (TEMPORARY) таблицам

User Comments

Posted by Whit Blauvelt on Wednesday December 18 2002, @5:27pm[Delete] [Edit]

To encrypt replication over an insecure (inter)net: Get <a href=http://stunnel.org>stunnel</a> and install it (after <a href=http://openssl.org>OpenSSL</a> if you don't already have it) on both machines.

On the slave's my.cnf under [mysqld] put:
master-host=localhost
master-port=3307

Start stunnel on the slave with:
stunnel -c -d 3307 -r mastername.com:3307

Start stunnel on the master with:
stunnel -p /path/to/ca.pem -d 3307 -r localhost:3306

Make any necessary adjustments to your firewalls to allow tcp port 3307 in and out. Restart mysql on both systems. With any luck you're in business.

Posted by Darrell Shandrow on Friday May 17 2002, @6:24am[Delete] [Edit]

The instructions for this select statement appear
to be incorrect, thus generating the 1052 error
just mentioned. Try the following, it seemed to
produce the correct result:
select shop.article, dealer, shop.price,
tmp.article, tmp.price from shop, tmp where
shop.article = tmp.article and shop.price =
tmp.price;

Posted by Alex Rozhik on Friday May 17 2002, @6:24am[Delete] [Edit]

Do not forget add function definition to
item_create.h ;)

Posted by [email protected] on Friday May 17 2002, @6:24am[Delete] [Edit]

I would recommend the web interface. Connecting to the server from a remote host is possible, but client app would have to use a username and password to do so. If the client app resides on a web browser machine (like a Java applet), it can be captured and decompiled, thus acquiring the username and password. Also, the username and password could be intercepted in transit. The best idea IMHO is to use a CGI program resident on the same machine as MySQL to interface with the database.

Posted by Renato Golin on Friday May 17 2002, @6:24am[Delete] [Edit]

You'll get crazy if you try to do the Master-Slave / Slave-Master... I can't see the point of doing it... but the H.A. for MySQL above is quite simple if you use Non-MySQL resources to do it. Like (slave-ping-master, master-is-down, slave-get-master's-name-and-IP, slave-send-email-to-sysadm)
then try to do'it with MySQL resorces...

Posted by Claudio Pucci on Friday May 17 2002, @6:24am[Delete] [Edit]

Please, add a comment for every server parameter;
is really difficult to tune a MySQL server in low memory conditions. An accurate description can be useful. A few parameters are described, a lot of them are simply reported.

Posted by Tom Howe on Friday May 17 2002, @6:24am[Delete] [Edit]

Hi, very cool stuff except for one little thing :)

Transactions dont work with replication :(

Maybe you were working on the 2 projects concurrently, or maybe you wanted to get the basics right first.

Or maybe someone forgot :(

Either way, the BEGIN, ROLLBACK and COMMIT statements are not Logged and therefore not replicated.

This means that if you do an insert on one database it is either automatically committed (autocommit on) to the other or never committed (autocommit=0). whether you commit or rollback has no effect.

Any likely hood of a fix quickly?

cheers and keep up the good work!

Posted by Carlos Fernando Scheidecker Antunes on Friday May 17 2002, @6:24am[Delete] [Edit]

The part of the manual that covers mysqldump is lacking an example with the syntax usage. For instance I have been trying to dump a table to a text CSV file with the command :
mysqldump -h localhost -u root -ppassword --field-terminated-by=';' db_parts
tbl_id > tbl_id.csv
and it gives an error saying that "mysqldump: You must use
option --tab with --fields-..."
Therefore, it is hard to get the correct syntax usage.
I hope that it fixed in the future, specialy for new users.
Thank you,
Carlos Fernando Scheidecker Antunes.

Posted by Charles Merriam on Friday May 17 2002, @6:24am[Delete] [Edit]

This section needs a couple good examples. A good SELECT .. INTO and slurp the resulting file would help. An example of the using various FIELD TERMINATED style options on the command line would be nice.

Posted by Jason Pyeron on Friday May 17 2002, @6:24am[Delete] [Edit]

# to get you [email protected]
gcc -DMYSQL_SERVER -DDEFAULT_MYSQL_HOME="\"/\"" -
DDATADIR="\"/var/lib/mysql\""
-DSHAREDIR="\"/usr/share/mysql\"" -
DHAVE_CONFIG_H -DDBUG_OFF -
I/usr/src/redhat/BUILD/mysql-
3.23.43/bdb/build_unix -
I/usr/src/redhat/BUILD/mysql-
3.23.43/innobase/include -
I/usr/src/redhat/BUILD/mysql-3.23.43/include -
I/usr/src/redhat/BUILD/mysql-3.23.43/regex -
I/usr/src/redhat/BUILD/mysql-3.23.43/sql -
I/usr/src/redhat/BUILD/mysql-3.23.43/include -
I/usr/src/redhat/BUILD/mysql-3.23.43 -O3 -felide-
constructors -fno-exceptions -fno-rtti -fno-
implicit-templates -fno-exceptions -fno-rtti -
shared -o myfile.so src src src obj src obj etc

Add your own comment.

Top / Previous / Next / Up / Table of Contents
# MySQL.com home | Site map | Contact us | Press | Jobs | Privacy policy | Trademark info | © 1995-2003 MySQL AB. All rights reserved.