prowler icon indicating copy to clipboard operation
prowler copied to clipboard

Scan never stops after system was rebooted by accident

Open olsonnn opened this issue 3 weeks ago • 5 comments

Issue search

  • [x] I have searched the existing issues and this bug has not been reported yet

Which component is affected?

Prowler UI

Cloud Provider (if applicable)

Azure

Steps to Reproduce

Start an Azure scan. During scan, reboot the system (here it happened by accident).

Result: scan never stops.

Expected behavior

Timeout, or option to stop.

Actual Result with Screenshots or Logs

Image

How did you install Prowler?

Docker (docker pull toniblyx/prowler)

Environment Resource

Docker

OS used

Debian12

Prowler version

5.14.0

Python version

n/a

Pip version

n/a

Context

No response

olsonnn avatar Dec 02 '25 06:12 olsonnn

I'd wait for Prowler team to actually address this, but, the feature you are referring to is already planned for implementation here: https://github.com/prowler-cloud/prowler/issues/6893

For the time being the workaround I am using is changing the scan state as cancelled via DB query (I actually don't know if that will cause collateral issues or not but YOLO):

-- Cancel a stuck scan (replace SCAN_ID with the actual scan UUID)
UPDATE scans 
SET state = 'cancelled', 
    completed_at = NOW() 
WHERE id = 'SCAN_ID'::uuid 
  AND state = 'executing';
-- Cancel all scans stuck in 'executing' for more than 4 hours
UPDATE scans 
SET state = 'cancelled', 
    completed_at = NOW() 
WHERE state = 'executing' 
  AND started_at < NOW() - INTERVAL '4 hours';

Vombato avatar Dec 02 '25 12:12 Vombato

@Vombato , i checked and the crazy thing is that this table is empty. Even during new scan. Users table does contain records for example.

olsonnn avatar Dec 02 '25 14:12 olsonnn

Hi @olsonnn,

The solution I was about to provide you is the one @Vombato gave you. Huge thanks for this.

Can you confirm that scans table is empty?

HugoPBrito avatar Dec 04 '25 09:12 HugoPBrito

Hi, I have the same situation. One of my scans is stuck since yesterday. What are the recommended steps to fix it on my end as a user?

Image

Argandov avatar Dec 07 '25 16:12 Argandov

Hi, I have the same situation. One of my scans is stuck since yesterday. What are the recommended steps to fix it on my end as a user?

Image

Hi @Argandov, The recommended solution would be the one proposed by @Vombato: https://github.com/prowler-cloud/prowler/issues/9401#issuecomment-3601742195.

HugoPBrito avatar Dec 09 '25 10:12 HugoPBrito