Syncing MySQL tables by pt-table-checksum when there is no unique key

Today I needed to checksum and sync tables in simple master-slave replication.
So I used percona-toolkit for this.

Following checksumming (command should be running on master) of tables shows that repl.t9 and repl.t1 tables have differences:

$ pt-table-checksum --replicate=percona.checksums --create-replicate-table --empty-replicate-table --ask-pass h=localhost,u=root
            TS ERRORS  DIFFS     ROWS  CHUNKS SKIPPED    TIME TABLE
05-26T01:50:30      0      1        4       1       0   0.016 repl.t1
05-26T01:50:30      0      1        6       1       0   0.016 repl.t9

Let’s run sync and check result:
Continue reading

Installation of Midnight Commander on MacOS 10.8.3

Today I needed to install MC on my Mac.
So that is step-by-step guide:

– Installed MacPorts
Downloaded last version pkg from here http://www.macports.org/install.php and installed it

Then I tried to install MC (sudo port install mc) but got error:

Warning: The Command Line Tools for Xcode don’t appear to be installed; most ports will likely fail to build.

Continue reading

yum hangs because fastestmirror cache

I got installation hanged after this:

Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile

so I checked if network is ok

nslookup ya.ru

it’s ok

then I removed fastestmirror cache and got things working

rm -f /var/cache/yum/timedhosts.txt