[mythtv-users] Heads up - Gentoo 0.22 Upgrade Coming Soon
Michael T. Dean
mtdean at thirdcontact.com
Tue Mar 2 01:42:03 UTC 2010
On 03/01/2010 07:31 PM, Richard Freeman wrote:
> To be honest this issue sort-of crept up. MySQL migrated their
> preferred locale settings but most distros lagged on implementing
> this, so most MythTV devs didn't get exposed to the problem.
Will you guys (meaning all the people I've seen who keep doing this--and
I'm not mentioning any distros/people by name) please quit telling the
world that MySQL changed the defaults and MythTV developers didn't notice.
From MySQL 5.1.41 (no particular reason for choosing that version other
than it's relatively recent and it's the one whose source I happen to
have lying around), for example:
$ grep DEFAULT_CHARSET configure
DEFAULT_CHARSET=latin1
default_charset="$DEFAULT_CHARSET"
#define MYSQL_DEFAULT_CHARSET_NAME "$default_charset"
read the script in full (or just run it without specifying
--with-charset or --with-collation) to find out for sure that, in fact,
latin1 *is* the default character set (and, therefore, latin1_swedish_ci
is the default collation) for MySQL--as it has been for versions 3.0,
4.0, 4.1, 5.0, 5.1, 5.5, ... (Feel free to check all the versions to
verify that I'm correct.)
And if you look at support-files/my-*.cnf.sh , you'll find that none of
the example/"recommended" MySQL configuration files (for use as
/etc/{,mysql/}my.cnf) they provide even specify
character_set_server/character-set-server nor UTF (with any capitalization).
and the example/"recommended" init script for the server
(support-files/mysql.server.sh) does not specify --character-set-server
or --collation-server.
See also
http://dev.mysql.com/doc/refman/5.1/en/internationalization-localization.html
http://dev.mysql.com/doc/refman/5.1/en/charset.html
http://dev.mysql.com/doc/refman/5.1/en/charset-syntax.html
http://dev.mysql.com/doc/refman/5.1/en/charset-server.html
where the last one says:
-----
Initially, the server character set and collation depend on the options
that you use when you start mysqld. You can use --character-set-server
for the character set. Along with it, you can add --collation-server for
the collation. If you don't specify a character set, that is the same as
saying --character-set-server=latin1. If you specify only a character
set (for example, latin1) but not a collation, that is the same as
saying --character-set-server=latin1
--collation-server=latin1_swedish_ci because latin1_swedish_ci is the
default collation for latin1. Therefore, the following three commands
all have the same effect:
shell> mysqld
shell> mysqld --character-set-server=latin1
shell> mysqld --character-set-server=latin1 \
--collation-server=latin1_swedish_ci
-----
TTBOMK, what changed was the default configuration chosen by packages
for a certain distro, which build MySQL by specifying a value for
--with-charset and, perhaps, --with-collation that override the MySQL
defaults with distro-specified defaults and/or provide a start script
that specifies --character-set-server and, perhaps, --collation-server
to start the server with a specific character set that overrides the
MySQL defaults.
Now, if you're saying that someone who does MySQL development told you
to change the default configuration your distro uses, that's a whole
other matter than "MySQL migrated their preferred locale settings" or
"MySQL changed the default character set." And, really, when someone
recommends a change of a program that's a required dependency of
another, you might want to at least try to figure out the effect that
change would have on the program that depends on it.
That said, whomever chose to change the default for the distro had no
way of knowing that it would break MythTV because no one took the time
to test the effect of changing the MySQL server character set on MythTV
until after 0.21-fixes was released, and every time someone who used one
of these misconfigured*** MySQL servers found an issue, they did /very/
bad things to their database to "fix" the problem rather than actually
exploring the issue to see what was happening.
So, please get your facts straight before you start accusing others of
breaking stuff you**** broke or being unaware of bigger changes (that
didn't occur). Thank you. And, I apologize in advance for my
attitude--but you really shouldn't be blaming us.
Mike
***Regardless of what anyone may say, from MythTV 0.21-fixes and below's
standpoint, the MySQL server was misconfigured--because it was
configured differently from the required configuration. That said, no
one had explored the issue to even realize that the required
configuration was required.
****Where "you" means whoever decided to just change the defaults in the
distro.
More information about the mythtv-users
mailing list