Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 116303 - dev-db/mysql-5.0.17 ebuild config fails
Summary: dev-db/mysql-5.0.17 ebuild config fails
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: x86 Linux
: High normal (vote)
Assignee: Gentoo Linux MySQL bugs team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-12-21 10:51 UTC by Jari-Matti Mäkelä
Modified: 2005-12-26 15:18 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jari-Matti Mäkelä 2005-12-21 10:51:39 UTC
MySQL requires you to configure the database if no previous database is installed. The mysql-5.0.16 - mysql-5.0.17 -ebuild script is broken (last "good" syntax was in mysql-5.0.15 ebuild):

# ebuild /usr/portage/dev-db/mysql/mysql-5.0.17 config
 * Using default DATADIR
 * MySQL DATADIR is /var/lib/mysql
 * Creating the mysql database and setting proper
 * permissions on it...
 * Insert a password for the mysql 'root' user
 * Avoid ["'\_%] characters in the password
    >
 * Check the password
    >
/var/tmp/portage/mysql-5.0.17/temp /var/tmp/portage
/var/tmp/portage
. * Loading "zoneinfo" this step may require few seconds
ERROR 1064 (42000) at line 17072: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ': Unable to load '//usr/share/zoneinfo/Asia/Riyadh87' as time zone. Skipping it.' at line 34
 * stopping the server,
 * done
Comment 1 Rodolfo Boer 2005-12-26 04:39:30 UTC
(In reply to comment #0)
> . * Loading "zoneinfo" this step may require few seconds
> ERROR 1064 (42000) at line 17072: You have an error in your SQL syntax; check
> the manual that corresponds to your MySQL server version for the right syntax
> to use near ': Unable to load '//usr/share/zoneinfo/Asia/Riyadh87' as time
> zone. Skipping it.' at line 34

The "bad" line in the ebuild is (763/764):
${ROOT}/usr/bin/mysql_tzinfo_to_sql${MY_SUFFIX} ${ROOT}/usr/share/zoneinfo \
> "${sqltmp}" 2>&1 | grep -v "Skipping it."

Should have been:
${ROOT}/usr/bin/mysql_tzinfo_to_sql${MY_SUFFIX} ${ROOT}/usr/share/zoneinfo \
2>&1 > "${sqltmp}" | grep -v "Skipping it."

If you must know why, the order of the redirection matters, previously it was
outputting error lines to sqltmp.

Do you want a patch? It's just a one liner.
Comment 2 Francesco R. (RETIRED) gentoo-dev 2005-12-26 15:18:07 UTC
Fixed now, the standard error (2>&1 | grep ...) is now redirected to a more friendly /dev/null

belive me or not it was working here 8-O .

@Jari-Matti M
Comment 3 Francesco R. (RETIRED) gentoo-dev 2005-12-26 15:18:07 UTC
Fixed now, the standard error (2>&1 | grep ...) is now redirected to a more friendly /dev/null

belive me or not it was working here 8-O .

@Jari-Matti Mäkelä
Thanks for the report

@Rodolfo Boer
Thanks for center the point