GitHub user nickaccuweb added a comment to the discussion: Usage Server - Cleanup database and start fresh new
@EduFrazao, You can clear the old usage records without cleaning or rebuilding your production cloud database. I don't recommend truncating the entire cloud_usage database because it also contains internal helper and usage-job information. Removing everything may cause CloudStack to process old usage events again. If you simply want to remove the old usage history and start collecting new records, I recommend: Step 1. Stop the Usage Server. Step 2. Take a backup of cloud_usage. Step 3. Clear only the main aggregated usage table: TRUNCATE TABLE cloud_usage.cloud_usage; Step 4. Start the Usage Server again. This keeps the existing Usage Server state/helper tables while removing the old generated usage records. I would also recommend taking the database backup first, especially if the usage data is currently being used by any billing or quota integration. Nick R Accuweb.Cloud GitHub link: https://github.com/apache/cloudstack/discussions/14252#discussioncomment-18642372 ---- This is an automatically sent email for [email protected]. To unsubscribe, please send an email to: [email protected]
