/etc/cron.daily/mysql-server not removed during upgrade
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
mysql-dfsg-5.0 (Ubuntu) |
Fix Released
|
Medium
|
Unassigned |
Bug Description
binlog rotation is now integrated into mysql server, configurable in /etc/mysql/my.cnf
/etc/cron.
The script fails to run, hence generates one e-mail per day.
Known workaround: delete it manually
=== Original Text ===
/etc/cron.
> echo 'SHOW MASTER LOGS;' | $M --skip-column-names >$tmp 2>&1
> filename=`tail -n $KEEP_BINARY_LOGS $tmp | head -n 1`
> echo "PURGE MASTER LOGS TO '$filename';" | $M
It aims at listing all binlog "file names" into $tmp
and then send the (e.g.) 7-th last line in the file to "PURGE MASTER".
However, "SHOW MASTER LOGS" prints 2 entries in a line, hence you also sent the file size to "PURGE MASTER", which fails it.
mysql> show master logs;
+------
| Log_name | File_size |
+------
| mysql-bin.000158 | 6333 |
| mysql-bin.000159 | 482630 |
| mysql-bin.000160 | 272 |
| mysql-bin.000161 | 538 |
| mysql-bin.000162 | 695 |
| mysql-bin.000163 | 117 |
| mysql-bin.000164 | 117 |
| mysql-bin.000165 | 141 |
| mysql-bin.000166 | 98 |
+------
# cat $tmp
mysql-bin.000160 272
Version: 5.0.19-3
Adam, I thought you were the Ubuntu mysql guy - don't get mad if I'm wrong :)