update before upgrade