need fix: lose data when restart