Update daemon script for compatibility