Move open guard to _update_db