[Bug]: Cannot finish a new library scan #960

Closed
opened 2026-02-20 01:12:56 -05:00 by deekerman · 5 comments
Owner

Originally created by @ghost on GitHub (Feb 11, 2023).

Describe the issue

Whenever I force rescan or add my book folder with 4TB of books, the server program will crash.
Not sure if this is related to #875

I cannot finish the library scan.

This is my observation:

[2023-02-11 15:53:05] INFO: [Scanner] Starting library scan lscan_gei7lwkb90vbnjr8n5 for 有声书库
[2023-02-11 15:54:02] INFO: [Server] Socket Connected 51vqk-atPMr_QLjoAAAL
[2023-02-11 15:54:02] INFO: [Server] Socket KReI19eN8Wnmfw7rAAAJ disconnected from client "xxxxxxxx" after 76366ms (Reason: transport error)
npm ERR! path /
npm ERR! command failed
npm ERR! signal SIGTERM
npm ERR! command sh -c -- node index.js

npm ERR! A complete log of this run can be found in:
npm ERR!     /root/.npm/_logs/2023-02-11T13_37_56_868Z-debug-0.log

> audiobookshelf@2.2.14 start
> node index.js

Config /config /metadata
[2023-02-11 15:54:53] INFO: === Starting Server ===
[2023-02-11 15:54:53] INFO: [Server] Init v2.2.14

Steps to reproduce the issue

  1. Try to scan a big library. Mine has 758 books, and 4TB in size.

Audiobookshelf version

2.2.14

How are you running audiobookshelf?

Docker

Originally created by @ghost on GitHub (Feb 11, 2023). ### Describe the issue Whenever I force rescan or add my book folder with 4TB of books, the server program will crash. Not sure if this is related to #875 I cannot finish the library scan. This is my observation: ``` [2023-02-11 15:53:05] INFO: [Scanner] Starting library scan lscan_gei7lwkb90vbnjr8n5 for 有声书库 [2023-02-11 15:54:02] INFO: [Server] Socket Connected 51vqk-atPMr_QLjoAAAL [2023-02-11 15:54:02] INFO: [Server] Socket KReI19eN8Wnmfw7rAAAJ disconnected from client "xxxxxxxx" after 76366ms (Reason: transport error) npm ERR! path / npm ERR! command failed npm ERR! signal SIGTERM npm ERR! command sh -c -- node index.js npm ERR! A complete log of this run can be found in: npm ERR! /root/.npm/_logs/2023-02-11T13_37_56_868Z-debug-0.log > audiobookshelf@2.2.14 start > node index.js Config /config /metadata [2023-02-11 15:54:53] INFO: === Starting Server === [2023-02-11 15:54:53] INFO: [Server] Init v2.2.14 ``` ### Steps to reproduce the issue 1. Try to scan a big library. Mine has 758 books, and 4TB in size. ### Audiobookshelf version 2.2.14 ### How are you running audiobookshelf? Docker
deekerman 2026-02-20 01:12:56 -05:00
  • closed this issue
  • added the
    bug
    label
Author
Owner

@ghost commented on GitHub (Feb 11, 2023):

This is the message from the /root/.npm/_logs/xxxxx.log file:

0 verbose cli /usr/local/bin/node /usr/local/bin/npm
1 info using npm@8.19.3
2 info using node@v16.19.0
3 timing npm:load:whichnode Completed in 0ms
4 timing config:load:defaults Completed in 1ms
5 timing config:load:file:/usr/local/lib/node_modules/npm/npmrc Completed in 1ms
6 timing config:load:builtin Completed in 1ms
7 timing config:load:cli Completed in 1ms
8 timing config:load:env Completed in 0ms
9 timing config:load:file:/.npmrc Completed in 0ms
10 timing config:load:project Completed in 2ms
11 timing config:load:file:/root/.npmrc Completed in 0ms
12 timing config:load:user Completed in 0ms
13 timing config:load:file:/usr/local/etc/npmrc Completed in 0ms
14 timing config:load:global Completed in 0ms
15 timing config:load:validate Completed in 0ms
16 timing config:load:credentials Completed in 1ms
17 timing config:load:setEnvs Completed in 0ms
18 timing config:load Completed in 6ms
19 timing npm:load:configload Completed in 6ms
20 timing npm:load:mkdirpcache Completed in 1ms
21 timing npm:load:mkdirplogs Completed in 0ms
22 verbose title npm start
23 verbose argv "start"
24 timing npm:load:setTitle Completed in 1ms
25 timing config:load:flatten Completed in 1ms
26 timing npm:load:display Completed in 1ms
27 verbose logfile logs-max:10 dir:/root/.npm/_logs
28 verbose logfile /root/.npm/_logs/2023-02-06T19_58_44_268Z-debug-0.log
29 timing npm:load:logFile Completed in 3ms
30 timing npm:load:timers Completed in 0ms
31 timing npm:load:configScope Completed in 0ms
32 timing npm:load Completed in 12ms
33 silly logfile done cleaning log files
34 timing command:run-script Completed in 409151445ms
35 timing command:start Completed in 409151451ms
36 verbose stack Error: command failed
36 verbose stack     at ChildProcess.<anonymous> (/usr/local/lib/node_modules/npm/node_modules/@npmcli/promise-spawn/lib/index.js:63:27)
36 verbose stack     at ChildProcess.emit (node:events:513:28)
36 verbose stack     at maybeClose (node:internal/child_process:1100:16)
36 verbose stack     at Process.ChildProcess._handle.onexit (node:internal/child_process:304:5)
37 verbose pkgid audiobookshelf@2.2.14
38 verbose cwd /
39 verbose Linux 6.1.9-arch1-1
40 verbose node v16.19.0
41 verbose npm  v8.19.3
42 error path /
43 error command failed
44 error signal SIGTERM
45 error command sh -c -- node index.js
46 verbose exit 1
47 timing npm Completed in 409151474ms
48 verbose code 1
@ghost commented on GitHub (Feb 11, 2023): This is the message from the /root/.npm/_logs/xxxxx.log file: ``` 0 verbose cli /usr/local/bin/node /usr/local/bin/npm 1 info using npm@8.19.3 2 info using node@v16.19.0 3 timing npm:load:whichnode Completed in 0ms 4 timing config:load:defaults Completed in 1ms 5 timing config:load:file:/usr/local/lib/node_modules/npm/npmrc Completed in 1ms 6 timing config:load:builtin Completed in 1ms 7 timing config:load:cli Completed in 1ms 8 timing config:load:env Completed in 0ms 9 timing config:load:file:/.npmrc Completed in 0ms 10 timing config:load:project Completed in 2ms 11 timing config:load:file:/root/.npmrc Completed in 0ms 12 timing config:load:user Completed in 0ms 13 timing config:load:file:/usr/local/etc/npmrc Completed in 0ms 14 timing config:load:global Completed in 0ms 15 timing config:load:validate Completed in 0ms 16 timing config:load:credentials Completed in 1ms 17 timing config:load:setEnvs Completed in 0ms 18 timing config:load Completed in 6ms 19 timing npm:load:configload Completed in 6ms 20 timing npm:load:mkdirpcache Completed in 1ms 21 timing npm:load:mkdirplogs Completed in 0ms 22 verbose title npm start 23 verbose argv "start" 24 timing npm:load:setTitle Completed in 1ms 25 timing config:load:flatten Completed in 1ms 26 timing npm:load:display Completed in 1ms 27 verbose logfile logs-max:10 dir:/root/.npm/_logs 28 verbose logfile /root/.npm/_logs/2023-02-06T19_58_44_268Z-debug-0.log 29 timing npm:load:logFile Completed in 3ms 30 timing npm:load:timers Completed in 0ms 31 timing npm:load:configScope Completed in 0ms 32 timing npm:load Completed in 12ms 33 silly logfile done cleaning log files 34 timing command:run-script Completed in 409151445ms 35 timing command:start Completed in 409151451ms 36 verbose stack Error: command failed 36 verbose stack at ChildProcess.<anonymous> (/usr/local/lib/node_modules/npm/node_modules/@npmcli/promise-spawn/lib/index.js:63:27) 36 verbose stack at ChildProcess.emit (node:events:513:28) 36 verbose stack at maybeClose (node:internal/child_process:1100:16) 36 verbose stack at Process.ChildProcess._handle.onexit (node:internal/child_process:304:5) 37 verbose pkgid audiobookshelf@2.2.14 38 verbose cwd / 39 verbose Linux 6.1.9-arch1-1 40 verbose node v16.19.0 41 verbose npm v8.19.3 42 error path / 43 error command failed 44 error signal SIGTERM 45 error command sh -c -- node index.js 46 verbose exit 1 47 timing npm Completed in 409151474ms 48 verbose code 1 ```
Author
Owner

@advplyr commented on GitHub (Feb 11, 2023):

What OS are you using?
Is your media stored on a remote file system?

From your last message I think your issue may be solved in the next release from this PR https://github.com/advplyr/audiobookshelf/pull/1484

If you have one audiobook that is thousands of audio files I could see that having an issue.

@advplyr commented on GitHub (Feb 11, 2023): What OS are you using? Is your media stored on a remote file system? From your last message I think your issue may be solved in the next release from this PR https://github.com/advplyr/audiobookshelf/pull/1484 If you have one audiobook that is thousands of audio files I could see that having an issue.
Author
Owner

@ghost commented on GitHub (Feb 11, 2023):

OS: Arch OS, rolling release
CPU i7-12700K
RAM 64 GB, SWAP 64GB on M.2 SSD
File system: ZFS, raidz2, 7200rpm CMR HDD

Yes, I have a lot of books with a few thousand chapters (audio files) in a book.

I think my server is pretty performant, well, comparing to Raspberry Pi at least. If my server cannot handle the scan, I doubt any other server can.

I will wait for the next release and try it out and report back here.

@ghost commented on GitHub (Feb 11, 2023): OS: Arch OS, rolling release CPU i7-12700K RAM 64 GB, SWAP 64GB on M.2 SSD File system: ZFS, raidz2, 7200rpm CMR HDD Yes, I have a lot of books with a few thousand chapters (audio files) in a book. I think my server is pretty performant, well, comparing to Raspberry Pi at least. If my server cannot handle the scan, I doubt any other server can. I will wait for the next release and try it out and report back here.
Author
Owner

@advplyr commented on GitHub (Feb 11, 2023):

Great, thanks! Hope to get a release out today or tomorrow.

@advplyr commented on GitHub (Feb 11, 2023): Great, thanks! Hope to get a release out today or tomorrow.
Author
Owner

@advplyr commented on GitHub (Feb 11, 2023):

Hopefully fixed in v2.2.15

.. but let me know!

@advplyr commented on GitHub (Feb 11, 2023): *Hopefully* fixed in [v2.2.15](https://github.com/advplyr/audiobookshelf/releases/tag/v2.2.15) .. but let me know!
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/audiobookshelf#960
No description provided.