Задать вопрос
@Delb228

Как запустить liquidsoap на нескольких ядрах?

Такая проблема при запуске конфига liquidsoap'а вся нагрузка ложится на одно ядро. Если запустить несколько экземпляров скрипта, то загрузка пойдет по нескольким ядрам, но в логах будет сыпаться ошибка - Connection failed: 403, Forbidden (HTTP/1.0). Я так понимаю он пытается запустить 2++ поток на icecast что никак не помогает при декодирование видео. Что нужно сделать чтобы liquidsoap стал декодировать видео на всех ядрах процессора?
Система linux debian 11. Метод установки liquidsoap - opam. Версия liquidsoap - 2.0.6
1 Экземпляр
62d516e18d4b8959718321.jpeg

Конфиг liquidsoap
set("frame.audio.channels",0)
set("log.file.path","/home/misha/log-liquidsoap.log")
set("init.daemon",true)
set("init.daemon.pidfile",false)
videoplaylist = playlist(reload=3600,"/home/misha/video/")
reklamaplaylist = playlist(reload=3600,"/home/misha/video/reklama/")
main = rotate(weights = [1, 1],[videoplaylist, reklamaplaylist])
output.icecast(
%ffmpeg(format="ogg",
%video(codec="libtheora",b="2500k",)
),
host="localhost",
port=8000,
password="***",
mount="/test",
mksafe(main))

Лог liquidsoap в нескольких экземплярах

2022/07/18 03:21:40 >>> LOG START
2022/07/18 03:21:37 [main:3] Liquidsoap 2.0.6
2022/07/18 03:21:37 [main:3] Using: bytes=[distributed with OCaml 4.02 or above] pcre=7.5.0 sedlex=3.0 menhirLib=20220210 curl=0.9.2 dtools=0.4.4 duppy=0.9.2 cry=0.6.7 mm=0.8.1 ogg=0.7.2 ogg.decoder=0.7.2 vorbis=0.8.0 vorbis.decoder=0.8.0 dynlink=[distributed with Ocaml] theora=0.4.0 theora.decoder=0.4.0 ffmpeg=1.1.4 taglib=0.3.9 camomile=1.0.2
2022/07/18 03:21:37 [dynamic.loader:3] Could not find dynamic module for lame encoder.
2022/07/18 03:21:37 [dynamic.loader:3] Could not find dynamic module for fdkaac encoder.
2022/07/18 03:21:37 [clock:3] Using builtin (low-precision) implementation for latency control
2022/07/18 03:21:40 [lang:2] WARNING: "set" is deprecated and will be removed in future version. Please use `settings.path.to.key.set(value)`
2022/07/18 03:21:40 [lang:2] WARNING: "set" is deprecated and will be removed in future version. Please use `settings.path.to.key.set(value)`
2022/07/18 03:21:40 [lang:2] WARNING: "set" is deprecated and will be removed in future version. Please use `settings.path.to.key.set(value)`
2022/07/18 03:21:40 [lang:2] WARNING: "set" is deprecated and will be removed in future version. Please use `settings.path.to.key.set(value)`
2022/07/18 03:21:40 [frame:3] Using 44100Hz audio, 25Hz video, 44100Hz main.
2022/07/18 03:21:40 [frame:3] Video frame size set to: 1280x720
2022/07/18 03:21:40 [frame:3] Frame size must be a multiple of 1764 ticks = 1764 audio samples = 1 video samples.
2022/07/18 03:21:40 [frame:3] Targeting 'frame.duration': 0.04s = 1764 audio samples = 1764 ticks.
2022/07/18 03:21:40 [frame:3] Frames last 0.04s = 1764 audio samples = 1 video samples = 1764 ticks.
2022/07/18 03:21:40 [sandbox:3] Sandboxing disabled
2022/07/18 03:21:40 [video.converter:3] Using preferred video converter: ffmpeg.
2022/07/18 03:21:40 [audio.converter:3] Using samplerate converter: ffmpeg.
2022/07/18 03:21:40 [clock.main:3] Streaming loop starts in auto-sync mode
2022/07/18 03:21:40 [clock.main:3] Delegating synchronisation to CPU clock
2022/07/18 03:21:40 [video.add_text:3] Using ffmpeg implementation
2022/07/18 03:21:40 [clock.main:2] We must catchup 1.44 seconds!
2022/07/18 03:21:40 [mksafe:3] Switch to safe_blank.
2022/07/18 03:21:40 [reklama:3] Prepared "/home/misha/video/reklama/test.mp4" (RID 0).
2022/07/18 03:21:40 [video:3] Prepared "/home/misha/video/494-GRATEFUL - Natasha Aughey - Brooke Ence Workout Motivation .mp4" (RID 1).
2022/07/18 03:21:40 [mksafe:3] Switch to switch_1 with transition.
2022/07/18 03:21:40 [/test:3] Connecting mount /test for source@localhost...
2022/07/18 03:21:40 [/test:2] Connection failed: 403, Forbidden (HTTP/1.0)
2022/07/18 03:21:40 [/test:3] Will try again in 3.00 sec.
2022/07/18 03:21:40 [switch_1:3] Switch to switch_0.
2022/07/18 03:21:40 [switch_0:3] Switch to video.
2022/07/18 03:21:41 [clock.main:2] We must catchup 1.95 seconds!
2022/07/18 03:21:42 [clock.main:2] We must catchup 2.36 seconds!
2022/07/18 03:21:43 [clock.main:2] We must catchup 2.77 seconds!
2022/07/18 03:21:43 >>> LOG START
2022/07/18 03:21:41 [main:3] Liquidsoap 2.0.6
2022/07/18 03:21:41 [main:3] Using: bytes=[distributed with OCaml 4.02 or above] pcre=7.5.0 sedlex=3.0 menhirLib=20220210 curl=0.9.2 dtools=0.4.4 duppy=0.9.2 cry=0.6.7 mm=0.8.1 ogg=0.7.2 ogg.decoder=0.7.2 vorbis=0.8.0 vorbis.decoder=0.8.0 dynlink=[distributed with Ocaml] theora=0.4.0 theora.decoder=0.4.0 ffmpeg=1.1.4 taglib=0.3.9 camomile=1.0.2
2022/07/18 03:21:41 [dynamic.loader:3] Could not find dynamic module for lame encoder.
2022/07/18 03:21:41 [dynamic.loader:3] Could not find dynamic module for fdkaac encoder.
2022/07/18 03:21:41 [clock:3] Using builtin (low-precision) implementation for latency control
2022/07/18 03:21:43 [lang:2] WARNING: "set" is deprecated and will be removed in future version. Please use `settings.path.to.key.set(value)`
2022/07/18 03:21:43 [lang:2] WARNING: "set" is deprecated and will be removed in future version. Please use `settings.path.to.key.set(value)`
2022/07/18 03:21:43 [lang:2] WARNING: "set" is deprecated and will be removed in future version. Please use `settings.path.to.key.set(value)`
2022/07/18 03:21:43 [lang:2] WARNING: "set" is deprecated and will be removed in future version. Please use `settings.path.to.key.set(value)`
2022/07/18 03:21:43 [frame:3] Using 44100Hz audio, 25Hz video, 44100Hz main.
2022/07/18 03:21:43 [frame:3] Video frame size set to: 1280x720
2022/07/18 03:21:43 [frame:3] Frame size must be a multiple of 1764 ticks = 1764 audio samples = 1 video samples.
2022/07/18 03:21:43 [frame:3] Targeting 'frame.duration': 0.04s = 1764 audio samples = 1764 ticks.
2022/07/18 03:21:43 [frame:3] Frames last 0.04s = 1764 audio samples = 1 video samples = 1764 ticks.
2022/07/18 03:21:43 [sandbox:3] Sandboxing disabled
2022/07/18 03:21:43 [video.converter:3] Using preferred video converter: ffmpeg.
2022/07/18 03:21:43 [audio.converter:3] Using samplerate converter: ffmpeg.
2022/07/18 03:21:43 [clock.main:3] Streaming loop starts in auto-sync mode
2022/07/18 03:21:43 [clock.main:3] Delegating synchronisation to CPU clock
2022/07/18 03:21:43 [video.add_text:3] Using ffmpeg implementation
2022/07/18 03:21:43 [mksafe:3] Switch to safe_blank.
2022/07/18 03:21:43 [video:3] Prepared "/home/misha/video/355-NO EXCUSES - Female Fitness Motivation .mp4" (RID 1).
2022/07/18 03:21:43 [mksafe:3] Switch to switch_1 with transition.
2022/07/18 03:21:43 [/test:3] Connecting mount /test for source@localhost...
2022/07/18 03:21:43 [/test:2] Connection failed: 403, Forbidden (HTTP/1.0)
2022/07/18 03:21:43 [/test:3] Will try again in 3.00 sec.
2022/07/18 03:21:43 [switch_1:3] Switch to switch_0.
2022/07/18 03:21:43 [switch_0:3] Switch to video.
2022/07/18 03:21:44 [/test:3] Connecting mount /test for source@localhost...
2022/07/18 03:21:44 [/test:2] Connection failed: 403, Forbidden (HTTP/1.0)
2022/07/18 03:21:44 [/test:3] Will try again in 3.00 sec.
2022/07/18 03:21:44 [clock.main:2] We must catchup 3.18 seconds!
2022/07/18 03:21:45 [clock.main:2] We must catchup 3.59 seconds!
2022/07/18 03:21:46 [clock.main:2] We must catchup 4.06 seconds!
2022/07/18 03:21:47 [/test:3] Connecting mount /test for source@localhost...
2022/07/18 03:21:47 [/test:2] Connection failed: 403, Forbidden (HTTP/1.0)
2022/07/18 03:21:47 [/test:3] Will try again in 3.00 sec.
  • Вопрос задан
  • 122 просмотра
Подписаться 1 Средний 2 комментария
Пригласить эксперта
Ваш ответ на вопрос

Войдите, чтобы написать ответ

Похожие вопросы