Commit graph

1931 commits

Author SHA1 Message Date
Sergei Golubchik
72c20282db 10.0-base merge 2014-02-03 15:22:39 +01:00
Sergei Golubchik
59d9d08e2b 5.5 merge 2014-02-01 00:54:03 +01:00
Sergei Golubchik
37d240ecf9 MySQL-5.5.35 merge 2014-01-22 15:29:36 +01:00
Michael Widenius
04bee0af2e Fix for MDEV-5547: Bad error message when moving very old .frm files to MariaDB 5.5.
mysql_upgrade --help now also prints out --default options and variable values.
mysql_upgrade now prints permission errors.
mysql_upgrade doesn't print some non essential info if --silent is used.
Added handler error message about incompatible versions
Fixed that mysqlbug and mysql_install_db have the executable flag set.
Removed executable flag for some non executable files.
Changed in mysql_install_db askmonty.org to mariadb.com.
Ensured that all client executables prints --default options the same way.
Allow REPAIR ... USE_FRM for old .frm files if the are still compatible.
Extended shown error for storage engine messages.


client/mysql.cc:
  print_defaults() should be first (as in all other programs)
client/mysql_upgrade.c:
  --help now also prints out --default options and variable values
  Print out error if wrong permissions
  Don't print info if --silent
client/mysqladmin.cc:
  print_defaults() should be first (as in all other programs)
client/mysqlbinlog.cc:
  Added print_defaults() to --help
client/mysqlcheck.c:
  Added empty line in --help
client/mysqlimport.c:
  Added empty line in --help
client/mysqlshow.c:
  Made --help compatible
client/mysqlslap.c:
  Made --help compatible
client/mysqltest.cc:
  Added print_defaults() to --help
include/handler_ername.h:
  Added handler error message
include/my_base.h:
  Added handler error message
mysql-test/r/mysql_upgrade.result:
  Updated results
mysql-test/r/repair.result:
  Added test case for better error messages
mysql-test/std_data/host_old.MYD:
  Added test case for better error messages
mysql-test/std_data/host_old.MYI:
  Added test case for better error messages
mysql-test/std_data/host_old.frm:
  Added test case for better error messages
mysql-test/t/repair.test:
  Added test case for better error messages
mysys/my_handler_errors.h:
  Added handler error message
scripts/CMakeLists.txt:
  Fixed that mysqlbug and mysql_install_db have the executable flag set
scripts/mysql_install_db.sh:
  askmonty.org -> mariadb.com
sql/ha_partition.cc:
  Sometimes table_type() can be called for errors even if partition didn't manage to open any files
sql/handler.cc:
  Write clear text for not handled, but defined error messages.
sql/share/errmsg-utf8.txt:
  Extended shown error for storage engine messages
sql/sql_admin.cc:
  Allow REPAIR ... USE_FRM for old .frm files if the are still compatible
storage/myisam/ha_myisam.cc:
  Use new error message
2014-01-22 15:16:57 +02:00
Sergei Golubchik
d28d3ba40d 10.0-base merge 2013-12-16 13:02:21 +01:00
Sergei Golubchik
c6d30805db 5.5 merge 2013-11-23 00:50:54 +01:00
Jan Lindström
66612e8fd3 MDEV-5010: InnoDB errors appearing in logs with upgrade from 10.0.0 to 10.0.4.
Analysis: In earlier MySQL 5.6 versions this table innodb_index_stats  used to have a foreign key referencing to innodb_table_stats. However, in newer MySQL 5.6 versions this foreign key is removed and if you upgrade, your innodb_table_stats is created by the earlier mariadb version, thus a newer version will complain that the table is incorrectly defined.

Added drop foreign key on mysql_system_tables_fix.sql to be executed on mysql_upgrade.
2013-11-20 14:28:07 +02:00
Sergei Golubchik
fa3f8a18b2 mysql-5.5.34 merge
(some patches reverted, test case added)
2013-11-19 13:16:25 +01:00
Sergei Golubchik
4157185f24 10.0-base merge 2013-11-13 23:03:48 +01:00
Sergei Golubchik
80137baf2f MDEV-5275 Problems upgrading from MySQL 5.1 to MariaDB
correct bugs in mysql_system_tables_fix.sql.
Update system_mysql_db_fix* tests
2013-11-13 22:58:10 +01:00
unknown
db453a99ce MDEV-5282: mysql_install_db fails to create mysql.gtid_slave_pos
Patch by Elena.

Move the table creation to the end of the file, so
mysql.innodb_stats_table has been created and the statement
does not fail.
2013-11-13 15:40:46 +01:00
Sergei Golubchik
bdd883ed9a 5.5. merge 2013-11-13 14:07:58 +01:00
Sergei Golubchik
41fc2493ed MDEV-5186 /usr/bin/mysqld_safe doesn't have NUMA options support
port mysqld_safe numa extensions from percona-server: --flush-caches and --numa-interleave
2013-11-11 09:31:13 +01:00
Sergei Golubchik
a30e87414c merge 10.0-base into 10.0 2013-11-04 08:43:56 +01:00
Sergei Golubchik
5c9d2c6c9f MDEV-4332 Increase username length from 16 characters
10.0 part of the task, fix system tables
2013-11-03 16:31:52 +01:00
Venkata Sidagam
186a9fc76b Bug #12917164 DROP USER CAN'T DROP USERS WITH LEGACY
UPPER CASE HOST NAME ANYMORE
Merging from mysql-5.1 to mysql-5.5
2013-10-31 23:14:33 +05:30
Venkata Sidagam
19990c9219 Bug #12917164 DROP USER CAN'T DROP USERS WITH LEGACY
UPPER CASE HOST NAME ANYMORE

Description:
It is not possible to drop users with host names with upper case
letters in them. i.e DROP USER 'root'@'Tmp_Host_Name'; is failing
with error.

Analysis: Since the fix 11748570 we came up with lower case hostnames
as standard. But in the current bug the hostname is created by
mysql_install_db script is still having upper case hostnames. 
So, if we have the hostname with upper case letters like(Tmp_Host_Name)
then we will have as it is stored in the mysql.user table. 
In this case if use "'DROP USER 'root'@'Tmp_Host_Name';" it gives 
error because we do compare with the lower case of hostname since the 
11748570 fix.

Fix: We need to convert the hostname to lower case before storing into 
the mysql.user table when we run the mysql_install_db script.
2013-10-31 23:02:44 +05:30
Sergei Golubchik
0fdb3bcfdb 10.0-base merge (roles) 2013-10-29 15:08:44 +01:00
Sergei Golubchik
d0db4f2261 add Admin_option column to mysql.roles_mapping. update tests/results 2013-10-18 12:21:10 -07:00
Sergei Golubchik
7dda698734 rename columns in mysql.roles_mapping to be consistent with other privilege tables 2013-10-18 12:19:37 -07:00
Vicențiu Ciorbaru
60f19cbc9a Added GRANT ROLE TO ... and REVOKE ROLE FROM ... functionality.
TODO:

Privilege checks are not done upon executing the command.
2013-10-18 09:25:42 -07:00
Sergei Golubchik
cdb5510204 fix mysql_upgrade to preserve the collation of mysql.user.is_role 2013-10-18 08:14:04 -07:00
Sergei Golubchik
72d8b533cc Fixes for mysql-test failures
mysql-test/r/acl_roles_show_grants.result:
  one can do SHOW GRANTS for himself
mysql-test/t/acl_roles_set_role-table-column-priv.test:
  correct error message
mysql-test/t/acl_roles_show_grants.test:
  one can SHOW GRANTS for himself
sql/sql_acl.cc:
  bugfixing:
  * don't assign with && - it can shortcut and the second assignment won't be executed
  * correct the test in check_grant_all_columns() - want_access should not be modified
  *
sql/sql_cmd.h.OTHER:
  add new commands at the end
sql/sql_db.cc:
  don't call acl_get() if all privileges are already satisfied
  (crashes when run with --skip-grants, because acl data stuctures aren't initialized)
sql/sql_parse.cc:
  * test for current_user in get_current_user()
  * map explicitly specified user@host to current_user
2013-10-18 08:10:51 -07:00
Vicențiu Ciorbaru
071c4ce88b Removed no longer needed RoleHostFK as it is not used to link to a Role.
Also removed code that loads that column into memory.
2013-10-17 15:06:09 -07:00
Vicențiu Ciorbaru
69a3deb58e Modify mysql.user table to contain a is_user column. 2013-10-17 15:02:47 -07:00
Vicențiu Ciorbaru
f401de7a4a Reordered entries to keep the had_user_table variable correct. 2013-10-17 14:57:10 -07:00
Vicențiu Ciorbaru
dc5fdacfe0 Added the new roles_mapping table to mysql_system_tables.sql script. 2013-10-17 14:57:06 -07:00
Sreedhar.S
d8bcc6215e BUG 17560050 - MYSQL_INSTALL_DB SCRIPT FAILING WITH RESOLVEIP ISSUES. 2013-10-09 17:08:45 +05:30
Sreedhar.S
99146a5056 Bug #16619754 - MYSQL_INSTALL_DB.PL FAILS TO CREATE DATABASE ON WINDOWS.
As this mysql_install_db.pl file has always generated lots of confusion on Windows.  This fix will make sure to get it removed only from Windows
2013-09-30 13:01:17 +05:30
Michael Widenius
9081c4dc6b Added information about the MariaDB foundation
Updated information in SHOW AUTHORS and SHOW CONTRIBUTORS
SHOW AUTHORS and SHOW CONTRIBUTORS are not depricated anymore.

CMakeLists.txt:
  Install TODO and CREDITS files
CREDITS:
  Information about the MariaDB foundation
README:
  Updated to include the MariaDB foundation
mysql-test/r/contributors.result:
  Updated contributors
mysql-test/r/show_check.result:
  SHOW AUTHORS and SHOW CONTRIBUTORS are not depricated anymore.
scripts/make_binary_distribution.sh:
  Added TODO and CREDITS
sql/authors.h:
  Updated list of active authors
sql/contributors.h:
  Updated list of active contributors and members of the MariaDB foundation
sql/sql_show.cc:
  Extend comment lengths
sql/sql_yacc.yy:
  SHOW AUTHORS and SHOW CONTRIBUTORS are not depricated anymore
2013-09-23 20:27:37 +03:00
Sergei Golubchik
2fe0836eed 5.5.33a merge 2013-09-20 11:29:01 +02:00
Sergei Golubchik
9af177042e 10.0-base merge.
Partitioning/InnoDB changes are *not* merged (they'll come from 5.6)
TokuDB does not compile (not updated to 10.0 SE API)
2013-09-21 10:14:42 +02:00
Sergei Golubchik
6e52631065 MDEV-4979 mysqld_safe section in my.cnf doesn't have mariadb equivalent
read also [mariadb_safe] section.
modify the manpage accordingly (and remove a netware-specific option from it)
2013-09-19 22:24:39 +02:00
Sergei Golubchik
4ec2e9d7ed 5.5 merge and fixes for compiler/test errors 2013-09-18 13:07:31 +02:00
Sergey Vojtovich
6c396aaf2a MDEV-4950 - mysql_upgrade fails with disabled InnoDB
Do not attempt to create innodb_index_stats and innodb_table_stats
if InnoDB is not available.
2013-09-13 12:44:51 +04:00
Venkata Sidagam
17eaef19d5 Bug #16776528 RACE CONDITION CAN CAUSE MYSQLD TO REMOVE SOCKET FILE ERRANTLY
Merging from 5.1 to 5.5
2013-09-09 21:31:50 +05:30
Venkata Sidagam
044a7d7c2f Bug #16776528 RACE CONDITION CAN CAUSE MYSQLD TO REMOVE SOCKET FILE ERRANTLY
Reverting the patch. Because this change is not to me made for GA versions.
2013-09-09 20:32:50 +05:30
Venkata Sidagam
06bcc2a410 Bug #16776528 RACE CONDITION CAN CAUSE MYSQLD TO REMOVE SOCKET FILE ERRANTLY
Reverting the patch. Because this change is not to me made for GA versions.
2013-09-09 20:21:02 +05:30
Sergei Golubchik
6755944d08 remove PBXT 2013-08-30 11:25:49 +02:00
Sergei Golubchik
fcf87600a2 MDEV-4865 Change related to --log option/variable was merged partially
Complete the merge of magne.mahre@oracle.com-20101102115354-vxcaxminmzglzalk
(WL#5185 Remove deprecated 5.1 features)
2013-08-13 13:35:36 +02:00
Anirudh Mangipudi
793b5835fd Bug #16776528 RACE CONDITION CAN CAUSE MYSQLD TO REMOVE SOCKET FILE ERRANTLY
Problem Description:
A mysqld_safe instance is started. An InnoDB crash recovery begins which takes
few seconds to complete. During this crash recovery process happening, another
mysqld_safe instance is started with the same server startup parameters. Since
the mysqld's pid file is absent during the crash recovery process the second
instance assumes there is no other process and tries to acquire a lock on the
ibdata files in the datadir.  But this step fails and the 2nd instance keeps 
retrying 100 times each with a delay of 1 second. Now after the 100 attempts, 
the server goes down, but while going down it hits the mysqld_safe script's 
cleanup section and without any check it blindly deletes the socket and pid 
files. Since no lock is placed on the socket file, it gets deleted.

Solution:
We create a mysqld_safe.pid file in the datadir, which protects the presence 
server instance resources by storing the mysqld_safe's process id in it. We
place a check if the mysqld_safe.pid file is existing in the datadir. If yes
then we check if the pid it contains is an active pid or not. If yes again,
then the scripts logs an error saying "A mysqld_safe instance is already 
running". Otherwise it will log the present mysqld_safe's pid into the 
mysqld_safe.pid file.
2013-08-12 23:06:58 +05:30
Anirudh Mangipudi
8757f39543 Bug #16776528 RACE CONDITION CAN CAUSE MYSQLD TO REMOVE SOCKET FILE ERRANTLY
Problem Description:
A mysqld_safe instance is started. An InnoDB crash recovery begins which takes
few seconds to complete. During this crash recovery process happening, another
mysqld_safe instance is started with the same server startup parameters. Since
the mysqld's pid file is absent during the crash recovery process the second
instance assumes there is no other process and tries to acquire a lock on the
ibdata files in the datadir.  But this step fails and the 2nd instance keeps 
retrying 100 times each with a delay of 1 second. Now after the 100 attempts, 
the server goes down, but while going down it hits the mysqld_safe script's 
cleanup section and without any check it blindly deletes the socket and pid 
files. Since no lock is placed on the socket file, it gets deleted.

Solution:
We create a mysqld_safe.pid file in the datadir, which protects the presence 
server instance resources by storing the mysqld_safe's process id in it. We
place a check if the mysqld_safe.pid file is existing in the datadir. If yes
then we check if the pid it contains is an active pid or not. If yes again,
then the scripts logs an error saying "A mysqld_safe instance is already 
running". Otherwise it will log the present mysqld_safe's pid into the 
mysqld_safe.pid file.
2013-08-12 21:54:50 +05:30
Sergei Golubchik
b7b5f6f1ab 10.0-monty merge
includes:
* remove some remnants of "Bug#14521864: MYSQL 5.1 TO 5.5 BUGS PARTITIONING"
* introduce LOCK_share, now LOCK_ha_data is strictly for engines
* rea_create_table() always creates .par file (even in "frm-only" mode)
* fix a 5.6 bug, temp file leak on dummy ALTER TABLE
2013-07-21 16:39:19 +02:00
Sergei Golubchik
5f6380adde 10.0-base merge 2013-07-18 16:46:57 +02:00
Sergei Golubchik
97e640b9ae 5.5 merge 2013-07-17 21:24:29 +02:00
Sergei Golubchik
005c7e5421 mysql-5.5.32 merge 2013-07-16 19:09:54 +02:00
Sergei Golubchik
33b7d10921 MDEV-4757 Change mysql.slow_log.event_time from TIMESTAMP to TIMESTAMP(6) 2013-07-15 22:50:06 +02:00
Sergey Petrunya
34c7fe0750 Fix fix_priv_tables.test: make mysql_system_tables_fix.sql to not modify user.password_expired column. 2013-07-04 17:01:36 +04:00
Sergey Petrunya
f9a9309a77 Fix typo in scripts/mysql_system_tables_fix.sql 2013-07-04 16:36:43 +04:00
unknown
ecbf36a914 MDEV-4058
MySQL 5.6.10 performance schema: merge of host_cache table
2013-06-27 12:51:34 +03:00