Deploying Package takes 10 minutes Thats is to long

I have a reletive small deploment of a website.
My problem is that it takes longer time to deploy to Production servers than Stage servers. And I dont know why.
It is this step "Deploying package: xxxxx.tar.gz that take so much time on production.
4 minutes on stage but 8 minutes on PROD, although the prod servers are a lot more powerful

The thing is that stage takes half the time on my stage servers.
All servers are Windows server 2012 R2 fully updated.

As I understand the process “Deploying package” that this would be the “copy file to the agent and unzip the file to the local disk” stage of the deployment.
I have done some testing doint this with powershell and time the execution an my test show that the production servers are significally faster in the unzip process.
Although the stage servers are running on hypervisor and the Production servera are on Vmware they all use the same storage and the same san.

This is a typical Octopus iis deployment the tar.gz file is 68 MB that expands to 68.393 files.
I could hide the problem by telling my developers that this unziping process and creating 68.000 files takes time, but I cant explain why this is so much faster on the stage servers that have lower specs.

I have migrated the prod servers between multiple VMware hosts but no significant difference in performance
This is nota a network problem since Stage and prod servers are on the same IP network

I need help.
TIA Svavar

Hi @svavark

Thanks for reaching out! Sorry to hear that you’re having an issue with longer deployments on your stage servers.

Usually, when this happens, it’s something environmental like an anti-virus/windows defender or similar that could be scanning the files as they’re extracted, which would slow down the process. There’s also a chance that the HDD on the server isn’t performing as well as it should be. Could you check if there’s anything like that causing the performance decrease, please?

Please let me know how you get on.

Regards,

Hi @stuart.mcilveen and thank you for your response.

I corrected my typo in the first post.
The problem is that my less powerful stage servers are quicker to deploy than my mighty production servers.
But the point regarding the defender setup is very good. and I will double check and report back.
All the servers are using the same san, so at the moment I have ruled out disk IO problems.
But let’s see what happens.
Regards Svavar.

Hi again @stuart.mcilveen

Thank you for your help. You were right. It was Defender that was slowing things down. I had not noticed that the package is unziped into different directory on stage that Prod.
On stage the deploment directory was excluded for virus scanning but on prod my developers were using different deploment directory, that was not excluded for defender. Slowed things down a lot.
I change the settings and everything is fast again.

Thanks. Svavar

Hi @svavark

Great to hear that solved it for you. Thank you for letting me know.

Have a great rest of your week!

Regards,