Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Raspbian, avprobe "Failed to set value '-loglevel' for option 'hide_banner'" #144

Open
johna777 opened this issue Nov 9, 2018 · 4 comments

Comments

@johna777
Copy link

johna777 commented Nov 9, 2018

Piwigo 2.9.4. Running videoJS 2.9.b. avconv and avprobe installed by apt-get. Entered path for them and ran sync rebuilding thumbnails. This displays:

ffprobe error reading file. Is ffprobe install? Is ffprobe in path?
Is the video accessible & readable, Try to run the command manually.
/usr/bin/avprobe -hide_banner -loglevel fatal -show_error -show_format -show_streams -print_format json './galleries/john/family/Kathryn/Hiccups.MP4'

Running the command manually displays:
Failed to set value '-loglevel' for option 'hide_banner'

If I delete the "hide-banner" option and rerun the command it works. BTW, it did not display a banner.

@unnilennium
Copy link

same issue on a centos 6 system using ffmpeg

I had to remove also
-show_programs
-show_chapters
which are in the executed command but not on the ones displayed

ffprobe -hide_banner -show_error -show_format -show_streams -print_format json './galleries/2019/Nicolas/IMG_8948.mp4'

ffprobe version 0.10.16 Copyright (c) 2007-2015 the FFmpeg developers
built on Aug 26 2016 13:01:36 with gcc 4.4.7 20120313 (Red Hat 4.4.7-17)
configuration: --prefix=/usr --bindir=/usr/bin --datadir=/usr/share/ffmpeg --incdir=/usr/include/ffmpeg --libdir=/usr/lib64 --mandir=/usr/share/man --arch=x86_64 --extra-cflags='-O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic' --enable-bzlib --disable-crystalhd --enable-gnutls --enable-libass --enable-libcdio --enable-libcelt --enable-libdc1394 --disable-indev=jack --enable-libfreetype --enable-libgsm --enable-libmp3lame --enable-openal --enable-libopenjpeg --enable-libpulse --enable-librtmp --enable-libschroedinger --enable-libspeex --enable-libtheora --enable-libvorbis --enable-libv4l2 --enable-libx264 --enable-libxvid --enable-x11grab --enable-avfilter --enable-postproc --enable-pthreads --disable-static --enable-shared --enable-gpl --disable-debug --disable-stripping --shlibdir=/usr/lib64 --enable-runtime-cpudetect
libavutil 51. 35.100 / 51. 35.100
libavcodec 53. 61.100 / 53. 61.100
libavformat 53. 32.100 / 53. 32.100
libavdevice 53. 4.100 / 53. 4.100
libavfilter 2. 61.100 / 2. 61.100
libswscale 2. 1.100 / 2. 1.100
libswresample 0. 6.100 / 0. 6.100
libpostproc 52. 0.100 / 52. 0.100
Unrecognized option 'hide_banner'
Failed to set value '-show_error' for option 'hide_banner'

if I delete -hide_banner from the php script the error keeps displaying

@unnilennium
Copy link

here is the fix : ./plugins/piwigo-videojs/include/ffprobe.php

$json = shell_exec($sync_options['ffprobe'] ." -loglevel fatal -show_error -show_format -show_streams -show_private_data -print_format json "". $filename.""");
if (!isset($json) or empty($json))
die("ffprobe error reading file. Is ffprobe install? Is ffprobe in path?
Is the video accessible & readable, Try to run the command manually.
". $sync_options['ffprobe'] ." -loglevel fatal -show_error -show_format -show_streams -print_format json '". $filename ."'");
$output = json_decode($json, true);
//print_r($output);
} catch (Exception $e) {
die("ffprobe error reading file. Is ffprobe install? Is ffprobe in path?
Is the video accessible & readable, Try to run the command manually.
". $sync_options['ffprobe'] ." -loglevel fatal -show_error -show_format -show_streams -print_format json '". $filename ."'");
}

@johna777
Copy link
Author

johna777 commented May 2, 2019

Thanks for the suggestions, and sorry for the delay in trying it. Life happens. :) The avprobe command still fails on the shell_exec command. (I modified the die text to see if it was the shell_exec or the json_decode that was failing). Interestingly your modified error message showing the command to run manually works fine. It runs in a terminal window. No output. Wasn't expecting any. no errors.

I'm not sure what I lose with just getting a warning about no metadata.

The code above has a problem with escape characters on the double quotes near the end of the line. It should look like the original line I presume. right?

@johna777
Copy link
Author

johna777 commented May 2, 2019

I'm using raspbian Stretch by the way.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants