# Performance issues after enabling file restore

**URL:** <https://forum.suricata.io/t/performance-issues-after-enabling-file-restore/1221>\
**Category:** Help\
**Tags:** file-extraction\
**Created:** [March 15, 2021, 3:49pm UTC](https://forum.suricata.io/t/performance-issues-after-enabling-file-restore/1221 "2021-03-15T15:49:11Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![shell\_xu](https://yyz2.discourse-cdn.com/flex030/user_avatar/forum.suricata.io/shell_xu/32/63_2.png) [@shell\_xu](https://forum.suricata.io/u/shell_xu)\
**Post date:** [March 15, 2021, 3:49pm UTC](https://forum.suricata.io/t/performance-issues-after-enabling-file-restore/1221/1 "2021-03-15T15:49:11Z")

</div>

When I enable file restore in the configuration file, my Suricata has performance issues after running for a while. Not enough memory and too much CPU load. How can I optimize it?

Network traffic: 1.2Gbps (99% of it is http data)

ubuntu 18.04  
suricata: 6.0.1  
AWS: c5n.9xlarge   
vCPU: 36  
mem: 96G

perf top -p {pid}

 ![image-20210313225404099](https://canada1.discourse-cdn.com/flex030/uploads/suricata/original/1X/1c153413ca1e3fc72efd5d193eb31a5ca7710758.jpeg)

---

<div class="post-metadata">

**Author:** ![vjulien](https://yyz2.discourse-cdn.com/flex030/user_avatar/forum.suricata.io/vjulien/32/4_2.png) [@vjulien](https://forum.suricata.io/u/vjulien)\
**Post date:** [March 16, 2021, 6:48am UTC](https://forum.suricata.io/t/performance-issues-after-enabling-file-restore/1221/2 "2021-03-16T06:48:23Z")

</div>

There have been some important fixes to file inspection in 6.0.2. Could you try that and see if it changes anything?

---

<div class="post-metadata">

**Author:** ![shell\_xu](https://yyz2.discourse-cdn.com/flex030/user_avatar/forum.suricata.io/shell_xu/32/63_2.png) [@shell\_xu](https://forum.suricata.io/u/shell_xu)\
**Post date:** [March 16, 2021, 6:51am UTC](https://forum.suricata.io/t/performance-issues-after-enabling-file-restore/1221/3 "2021-03-16T06:51:18Z")

</div>

Ok, I will try to upgrade to 6.0.2 today. Give feedback later.

---

<div class="post-metadata">

**Author:** ![shell\_xu](https://yyz2.discourse-cdn.com/flex030/user_avatar/forum.suricata.io/shell_xu/32/63_2.png) [@shell\_xu](https://forum.suricata.io/u/shell_xu)\
**Post date:** [March 18, 2021, 9:03am UTC](https://forum.suricata.io/t/performance-issues-after-enabling-file-restore/1221/4 "2021-03-18T09:03:59Z")

</div>

Thank you for the suggestion, after 2 days of testing. After upgrading to Suricata v6.0.2, CPU utilization is 50% lower than before the upgrade and there is no memory overflow.
