recognize icon indicating copy to clipboard operation
recognize copied to clipboard

ffmpeg can't be installed or set on Alpine

Open eibex opened this issue 1 year ago • 7 comments

Which version of recognize are you using?

6.0.1

Enabled Modes

Object recognition, Face recognition, Video recognition

TensorFlow mode

Normal mode

Downstream App

Memories App

Which Nextcloud version do you have installed?

28.0.2

Which Operating system do you have installed?

Unraid Linux6.1.64

Which database are you running Nextcloud on?

Postgres 15

Which Docker container are you using to run Nextcloud? (if applicable)

28.0.2 (not AIO)

How much RAM does your server have?

64GB

What processor Architecture does your CPU have?

x86_64

Describe the Bug

The app cannot install ffmpeg when installing it.

Additional info:

  • I have ffmpeg already installed for preview generation (installed via apt)
  • I used to run Recognize before moving to Docker without issues
  • /tmp is mapped to tmpfs

Expected Behavior

ffmpeg is installed and no errors are shown.

To Reproduce

Install recognize with the main docker container image.

Debug log

[recognize] Error: Failed to install ffmpeg: os.js:68
      throw new ERR_SYSTEM_ERROR(ctx);
      ^

SystemError [ERR_SYSTEM_ERROR]: A system error occurred: uv_os_homedir returned ENOENT (no such file or directory)
    at Object.<anonymous> (/var/www/html/custom_apps/recognize/node_modules/env-paths/index.js:5:20)
    at Module._compile (internal/modules/cjs/loader.js:1085:14)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:1114:10)
    at Module.load (internal/modules/cjs/loader.js:950:32)
    at Function.Module._load (internal/modules/cjs/loader.js:790:12)
    at Module.require (internal/modules/cjs/loader.js:974:19)
    at require (internal/modules/cjs/helpers.js:93:18)
    at Object.<anonymous> (/var/www/html/custom_apps/recognize/node_modules/ffmpeg-static/install.js:7:18)
    at Module._compile (internal/modules/cjs/loader.js:1085:14)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:1114:10) {
  code: 'ERR_SYSTEM_ERROR',
  info: {
    errno: -2,
    code: 'ENOENT',
    message: 'no such file or directory',
    syscall: 'uv_os_homedir'
  },
  errno: [Getter/Setter],
  syscall: [Getter/Setter]
}
	POST /settings/apps/enable
	from xxx

eibex avatar Feb 04 '24 13:02 eibex

Hello :wave:

Thank you for taking the time to open this issue with recognize. I know it's frustrating when software causes problems. You have made the right choice to come here and open an issue to make sure your problem gets looked at and if possible solved. I try to answer all issues and if possible fix all bugs here, but it sometimes takes a while until I get to it. Until then, please be patient. Note also that GitHub is a place where people meet to make software better together. Nobody here is under any obligation to help you, solve your problems or deliver on any expectations or demands you may have, but if enough people come together we can collaborate to make this software better. For everyone. Thus, if you can, you could also look at other issues to see whether you can help other people with your knowledge and experience. If you have coding experience it would also be awesome if you could step up to dive into the code and try to fix the odd bug yourself. Everyone will be thankful for extra helping hands! One last word: If you feel, at any point, like you need to vent, this is not the place for it; you can go to the forum, to twitter or somewhere else. But this is a technical issue tracker, so please make sure to focus on the tech and keep your opinions to yourself. (Also see our Code of Conduct. Really.)

I look forward to working with you on this issue Cheers :blue_heart:

github-actions[bot] avatar Feb 04 '24 13:02 github-actions[bot]

Have you tried setting the ffmpeg path in the settings?

marcelklehr avatar Feb 04 '24 14:02 marcelklehr

I can see options to set a custom Node.js path, but not a custom ffmpeg path

eibex avatar Feb 05 '24 21:02 eibex

In the config.php file I can see that the Memories app found ffmpeg without issues at under /usr/bin/ffmpeg

I also found that Recognize somewhat works despite the error (classification run gets stuck mid way with thousands of files in queue for object, video, and face recognition).

eibex avatar Feb 10 '24 13:02 eibex

Hello :wave: This issue is waiting for a response by the original poster for 2 weeks. We cannot keep track of whether individual issues have resolved themselves or still require attention without user interaction. We're thus adding the stale label to this issue to schedule it for getting closed in 5 days time. If you believe this issue is still valid and should be fixed, you can add a comment or remove the label to avoid it getting closed.

Cheers :blue_heart:

github-actions[bot] avatar Feb 25 '24 02:02 github-actions[bot]

Not stale

eibex avatar Feb 27 '24 11:02 eibex

Ah, sorry, that was a different app with the ffmpeg path setting. Duly noted and confirmed

marcelklehr avatar Feb 28 '24 11:02 marcelklehr

ffmpeg doesn't support Alpine I think. In general recognize and alpine don't work well together.

marcelklehr avatar May 08 '24 10:05 marcelklehr