sandbox fix and added start/stop hooks