Hi @MarufHossain-3174,
We could use this script in this article:
https://gallery.technet.microsoft.com/WSUS-cleanup-script-7e019537
And the script runs WSUS cleanup tasks using stored procedures in WSUS database directly, avoiding timeout errors and WSUS service crash that may occur when using WSUS' Cleanup Wizard.
If the response is helpful, please click "Accept Answer" and upvote it.
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.