Quantcast
Viewing all articles
Browse latest Browse all 21

Restarting Pow when DNS stops responding

I love Pow, the Rack-based development web server from 37signals, but one thing I can’t stand is how sometimes it stops responding to DNS for no reason in particular.

Well, Mike Sutton figured out how to fix it, and I turned it into a Bash script. Just save this as pow-restart (or whatever) and run it whenever you start having issues:

#!/bin/bash
# Restarts Pow when DNS fails to resolve
lsof | grep 20560 | awk '{print $2}' | xargs kill -9
launchctl unload ~/Library/LaunchAgents/cx.pow.powd.plist
launchctl load ~/Library/LaunchAgents/cx.pow.powd.plist

Viewing all articles
Browse latest Browse all 21

Trending Articles