Remote Rendering Fails: Unsafe file name

A previously reported issue with Repetier-Server ( appears to still exist when using a remote server to do video rendering.  Running 0.80.3 with ffmpeg version 3.2.4.  I might be able to work around this by replacing ffmpeg with avconv on the remote server. Will test and report.

james Repetier-Server $ cat tmp/2fb4537c-9a7c-4ad4-a423-b15159ddaef2/settings.json
    "bitrate" : 1000,
    "conversionError" : "[concat @ 0x7dddc0] Unsafe file name '/var/lib/Repetier-Server/tmp/2fb4537c-9a7c-4ad4-a423-b15159ddaef2/image_00000000.jpg'/var/lib/Repetier-Server/tmp/2fb4537c-9a7c-4ad4-a423-b15159ddaef2/input.txt: Operation not permitted",
    "conversionMode" : 3,
    "createdSeconds" : 1493938730,
    "dir" : "20170504T225850_Kobayashi_Fidget_Cube",
    "firstFrameSec" : 1,
    "framerate" : 10,
    "imageCounter" : 2,
    "includeWatermark" : true,
    "lastFrameSec" : 1,
    "name" : "Kobayashi_Fidget_Cube",
    "timelapseBitrate" : 1000,
    "valid" : true,
    "videoLength" : 84891,
    "watermarkPosition" : 0,
    "webcamOrientation" : 0


  • Nope, trying to use avconv on the remote server doesn't appear to work either.  It looks like the remote server is trying to call avconv with the same parameters as ffmpeg, but on the printer's server (RPi), it uses distinct arguments for avconv.  I'm using avconv on the RPi because apparently Debian doesn't like ffmpeg, so it's not in their repository.  The remote server is Gentoo, and it has both ffmpeg and avconv available.  The videos will render just fine on the RPi, but I don't want them to render there because long rendering jobs can cause buffering problems while printing that lead to my printer pausing while waiting for additional instrucutions; I've lost a few prints due to excess filament build up and burning in these cases.

    Works on RPi: 2017-05-04 23:27:16: /usr/bin/avconv -loglevel error -r 10 -i /var/lib/Repetier-Server/printer/Anet_A2_Plus/timelapse/20170503T231410_Platform_Jack_100fill/image_%08d.jpg -i /usr/local/Repetier-Server/www/img/watermark.png -c:v libx264 -filter_complex [0:v][1:v] overlay=x=10:y=10 -threads 1 -r 10 -pix_fmt yuv420p -profile:v baseline -movflags faststart -b:v 1000k -y /var/lib/Repetier-Server/printer/Anet_A2_Plus/timelapse/20170503T231410_Platform_Jack_100fill/video.mp4

    Doesn't work on Linux PC: 2017-05-04 23:34:41: /usr/bin/avconv -loglevel error -f concat -i /var/lib/Repetier-Server/tmp/dcd1d482-1183-4bcf-ad49-99c3dede04dc/input.txt -i /var/lib/Repetier-Server/tmp/dcd1d482-1183-4bcf-ad49-99c3dede04dc/watermark.png -c:v libx264 -filter_complex [0:v][1:v] overlay=10:10 -threads 4 -r 10 -pix_fmt yuv420p -profile:v baseline -level 3.0 -movflags +faststart -b:v 1000k -y /var/lib/Repetier-Server/tmp/dcd1d482-1183-4bcf-ad49-99c3dede04dc/video.mp4

        "conversionError" : "Unknown input format: 'concat'",
        "conversionMode" : 3,

  • Next on the troubleshooting list is to see if the -safe option for ffmpeg will help.  I don't see any way to pass this argument except by creating a bash script to provide to Repetier-Server consisting of
    /usr/bin/ffmpeg -safe $*

    Will report if this helps.
  • I remember the unsafe filename problem. I started with full names and at some point new ffmpeg versions did not like them any more. The final solution was to use local filenames and convert from the directory containing images which then worked with all versions. Maybe the remote solution does not have this trick but you see this only with some newer versions. Will check.
  • Ok, here's a shell script that can stand in for ffmpeg to make this work:

    Note that the two issues being fixed are the absolute paths (necessitating -safe 0) and the arguments to -filter_complex need to omit spaces.
    Incorrect: -filter_complex [0:v][1:v] overlay=10:10
    Correct: -filter_complex [0:v][1:v]overlay=10:10
  • Did some more tests and there are also othe rthing slike rotation that do not work with newer ffmpeg due to more strict channel rules you could say. Have fixed this hopefully to be compatible across a broader range of versions now.
Sign In or Register to comment.