kvz.io

Crontab

  • Published on
    Unfortunately the Linux DNS resolver has no direct support for detecting and doing failovers for DNS servers. It keeps feeding requests to your primary resolving nameserver, waits for a configured timeout, attempts again, and only then tries the second nameserver. This typically means nearly 30s delay for all request as long as your primary nameserver is unreachable. It doesn't learn to directly target your secondary nameserver so long as there is trouble. Even with the most optimal configuration, the delay will still be measured in seconds per request. For many requests, that's many more seconds. I wanted to solve this.
  • Published on
    I love my NAS but because I tried to save a little money it does not [run SABnzbd](/blog/2011/02/28/optimize-your-synology-for-downloading/) very well. I've tried different approaches but find myself ending up downloading on OSX as it writes to a network share on my NAS. Too bad, but I'm archiving this one under the section first world problems. The challenge I have now though, is when my Mac goes to sleep, my mounts disappear, and SABnzbd writes to the local filesystem instead. Cause as far as my downloading program could tell, it was already writing to a local filesystem, so it will just keep on doing that until my Mac's disk is at 100%. I wrote a little script to prevent that. You may not be running SABnzbd, but there are obviously many other use cases where you want a network mount to persist. Especially if you are automating something outside of the GUI. With some small adjustments this could work for Linux/NFS/SMB as well.
  • Published on
    If you use EC2 you may have heard of Tim Kay's aws commandline tool. It provides access to most of Amazon's API and is less cumbersome than Amazon's own CLI utilities in day to day use. A lesser known tool by Tim Kay is solo. It's basically one line of Perl, but it's incredibly useful to defeat a common problem with cronjobs: overlap.
  • Published on
    Synchronizing files from one server to another is quite awesome. You can use it for backups, for keeping web servers in sync, and much more. It's fast and it doesn't take up as much bandwidth as normal copying would. And the best thing is, it can be done with only 1 command. Welcome to the wonderful world of rsync.