Tag Archives: trick

on copying files

After hitting stupid kernel bug/behavior with rsync (um, memory pressure on socket caused to do some expensive cleanups on every packet) I ended up using ‘nc’ for reimaging slaves and copying files from server X to server Y: dbX# nc … Continue reading

Posted in mysql | Tagged , | 3 Comments

popping a stack in mysql

Warning: this post describes practices that rely on side effects and may provide unstable results. I was asked how to treat a table in MySQL as a stack and pop oldest entry from it. Of course there is always traditional … Continue reading

Posted in mysql | Tagged | 2 Comments

ip address searches in mysql

MySQL does not provide special datatype or operators for IP addresses, but has two functions, that convert IP addresses to and from integers. In order to lookup addresses in a subnet, an efficient index range scan queries could be used. Continue reading

Posted in mysql | Tagged , , | 1 Comment