Search code examples
javascriptnode.jsverdaccio

Verdaccio crash with Error [ERR_STREAM_DESTROYED]: Cannot call write after a stream was destroyed


We are hosting a Verdaccio 3.4.0 npm private registry within docker.

It use a mounted volume to store packages.

For some reason, the container started to crash, it can now start but it can't see any packages:

image

I have checked and the mounted volumes is still: /verdaccio/storage

I noticed that the disk space was full, but even after cleaning more than half of the full disk space, it keep saying there's no packages published.

This is becoming critical since it impacts all our CI,

How can I restore the state of my server?


Solution

  • In order to spread knowledge, we have a chat (verdaccio community chat) about this issue. Your reasons were:

    • Lack of hard-drive space was not allowing Verdaccio to create or modify files.
    • Your database was corrupted (empty) due the first point, as reminder, Verdaccio open files and try to write to the, specially database when you publish new packages

    Solution was simple, clear some space in your disk, restart the server and restore from backup a previous .sinopia-db.json database.

    Keep always backups :-)