bugfix detect cmd should be >/dev/null 2>&1