tomtomgooo 0 Posted April 3, 2020 Share Posted April 3, 2020 Hi, I am trying to migrate my emby 4.4.0 to docker swarm. I use media in a smb source which works good with docker in docker-compose mode. Now I try to migrate this in swarm with 1 replica. here is my docker-compose ( docker standard ) OK : version: '2' services: emby2: image: emby/embyserver:latest restart : unless-stopped container_name : emby2 volumes: - /etc/localtime:/etc/localtime:ro - /mnt/dockernfs/emby/data:/config ports: - 1900:1900 - 8097:8096 # - 8920:8920 environment: - UID=1000 - GID=100 And now my docker-compose for swarm : version: '3' services: emby: image: emby/embyserver:latest volumes: - /etc/localtime:/etc/localtime:ro - /mnt/dockernfs/emby/data:/config environment: - UID=1000 - GID=100 ports: - 1900:1900 - 8097:8096 # networks: # - traefik_net # deploy: # replicas: 1 # labels: # - "traefik.docker.network=traefik_net" # - "traefik.enable=true" #networks: # traefik_net: # external: true These 2 compose are launching in the same VM. Here is the log for swarm : 020-04-03 12:31:22.295 Info HttpServer: HTTP Response 500 to 10.0.0.2. Time: 61039ms. http://192.168.1.71:8096/emby/videos/57270/hls1/main/0.ts?DeviceId=1fd744f9-470b-4c98-8217-7ea8f707ea86&MediaSourceId=867de3765ca79d83b14b6ef8c51f3990&PlaySessionId=f55ad7d5696149dfa7a54c4054d7679d&VideoCodec=h264&AudioCodec=aac&VideoBitrate=139616000&AudioBitrate=384000&AudioStreamIndex=0&TranscodingMaxAudioChannels=2&SegmentContainer=ts&MinSegments=1&BreakOnNonKeyFrames=True&ManifestSubtitles=vtt&h264-profile=high,main,baseline,constrainedbaseline&h264-level=52&TranscodeReasons=ContainerNotSupported 2020-04-03 12:31:22.321 Debug DynamicHlsService: CodecValidation: Processing Plan 2020-04-03 12:31:22.321 Debug DynamicHlsService: CodecValidation: Name CanDoInHardware WillDoInHardware Reason 2020-04-03 12:31:22.321 Debug DynamicHlsService: CodecValidation: Copy video stream >> False False Software Codec 2020-04-03 12:31:22.321 Debug DynamicHlsService: CodecValidation: VideoInput >> False False Not a hardware decoder 2020-04-03 12:31:22.321 Debug DynamicHlsService: CodecValidation: VideoOutput >> False False Not a hardware encoder 2020-04-03 12:31:22.321 Debug DynamicHlsService: CodecValidation: Copy video stream >> False False Software Codec 2020-04-03 12:31:22.321 Debug DynamicHlsService: CodecValidation: Projected Processing Formats 2020-04-03 12:31:22.321 Debug DynamicHlsService: CodecValidation: Previous HW-Context Format SW-Format Next 2020-04-03 12:31:22.321 Debug DynamicHlsService: CodecValidation: h264 >> - yuv420p yuv420p >> 2020-04-03 12:31:22.326 Info DynamicHlsService: ProcessRun 'StreamTranscode 3e00a2' Execute: /bin/ffmpeg -loglevel +timing -y -print_graphs_file /config/logs/ffmpeg-remux-3e00a2eb-6c27-4772-a55b-5d52b9b4e4c6_1graph.txt -copyts -start_at_zero -f matroska,webm -noaccurate_seek -c:v:0 h264 -i "http://127.0.0.1:8096/Items/File?Id=smb%3A%2F%2F192.168.1.100%2FFilms%2FStar+Wars+-+L%27Ascension+de+Skywalker%2FStar.Wars.Episode.IX.The.Rise.of.Skywalker.2020.FRENCH.720p.BluRay.x264.AC3.WwW.Zone-Annuaire.COM.mkv" -map 0:3 -map 0:0 -sn -c:v:0 copy -bsf:v:0 h264_mp4toannexb -c:a:0 aac -ab:a:0 192000 -ac:a:0 2 -metadata:s:a:0 language=fre -filter:a:0 "volume=2" -disposition:a:0 default -max_delay 5000000 -avoid_negative_ts disabled -f segment -map_metadata -1 -map_chapters -1 -segment_format mpegts -segment_list /config/transcoding-temp/transcoding-temp/C14DC2.m3u8 -segment_list_type m3u8 -segment_time 6 -segment_start_number 0 -break_non_keyframes 1 -individual_header_trailer 0 -write_header_trailer 0 -segment_write_temp 1 "/config/transcoding-temp/transcoding-temp/C14DC2_%d.ts" -map 0:1 -map 0:3 -an -c:v:0 copy -c:s:0 webvtt -max_delay 5000000 -avoid_negative_ts disabled -f segment -map_metadata -1 -map_chapters -1 -segment_format webvtt -segment_list /config/transcoding-temp/transcoding-temp/C14DC2_s1.m3u8 -segment_list_type m3u8 -segment_time 6 -segment_start_number 0 -break_non_keyframes 1 -individual_header_trailer 1 -write_header_trailer 0 -write_empty_segments 1 -segment_write_temp 1 -min_frame_time 00:00:00.000 "/config/transcoding-temp/transcoding-temp/C14DC2_s1_%d.vtt" -map 0:2 -map 0:3 -an -c:v:0 copy -c:s:0 webvtt -max_delay 5000000 -avoid_negative_ts disabled -f segment -map_metadata -1 -map_chapters -1 -segment_format webvtt -segment_list /config/transcoding-temp/transcoding-temp/C14DC2_s2.m3u8 -segment_list_type m3u8 -segment_time 6 -segment_start_number 0 -break_non_keyframes 1 -individual_header_trailer 1 -write_header_trailer 0 -write_empty_segments 1 -segment_write_temp 1 -min_frame_time 00:00:00.000 "/config/transcoding-temp/transcoding-temp/C14DC2_s2_%d.vtt" 2020-04-03 12:31:22.328 Debug DynamicHlsService: ProcessRun 'StreamTranscode 3e00a2' Started. 2020-04-03 12:31:22.362 Info DynamicHlsService: ProcessRun 'StreamTranscode e59fb8' Process exited with code 1 2020-04-03 12:31:22.382 Info HttpServer: HTTP GET http://127.0.0.1:8096/Items/File?Id=smb%3A%2F%2F192.168.1.100%2FFilms%2FStar+Wars+-+L%27Ascension+de+Skywalker%2FStar.Wars. UserAgent: Lavf/58.35.100 2020-04-03 12:32:22.993 Error HttpServer: Error processing request *** Error Report *** Version: 4.4.0.40 Command line: /system/EmbyServer.dll -programdata /config -ffdetect /bin/ffdetect -ffmpeg /bin/ffmpeg -ffprobe /bin/ffprobe -restartexitcode 3 Operating system: Unix 4.15.0.55 64-Bit OS: True 64-Bit Process: True User Interactive: True Runtime: file:///system/System.Private.CoreLib.dll System.Environment.Version: 3.1.2 Processor count: 4 Program data path: /config Application directory: /system SharpCifs.Smb.SmbException: SharpCifs.Smb.SmbException: Failed to connect: 0.0.0.0<00>/192.168.1.100 at SharpCifs.Smb.SmbTransport.Connect() at SharpCifs.Smb.SmbTree.TreeConnect(ServerMessageBlock andx, ServerMessageBlock andxResponse) at SharpCifs.Smb.SmbFile.DoConnect() at SharpCifs.Smb.SmbFile.Connect() at SharpCifs.Smb.SmbFile.Connect0() at SharpCifs.Smb.SmbFile.QueryPath(String path, Int32 infoLevel) at SharpCifs.Smb.SmbFile.Exists() at Emby.Server.Implementations.IO.SharpCifsFileSystem.AssertFileExists(SmbFile file, String path) at Emby.Server.Implementations.IO.SharpCifsFileSystem.OpenRead(String path) at Emby.Server.Implementations.IO.SharpCifsFileSystem.GetFileStream(String path, FileOpenMode mode, FileAccessMode access, FileShareMode share) at Emby.Server.Implementations.IO.ManagedFileSystem.GetFileStream(String path, FileOpenMode mode, FileAccessMode access, FileShareMode share, FileOpenOptions fileOpenOptions) at Emby.Server.Implementations.IO.IOManager.GetResponse(HttpRequestOptions options, MediaProtocol protocol) at Emby.Server.Implementations.IO.IOManager.GetResponse(HttpRequestOptions options) at Emby.Server.Implementations.HttpServer.HttpResultFactory.GetContent(StaticFileResultOptions options, Int64 offset, Int64 length, CancellationToken cancellationToken) at Emby.Server.Implementations.HttpServer.FileWriter.SetContentResponseHeaders(Nullable`1 reportedTotalContentLength, CancellationToken cancellationToken) at Emby.Server.Implementations.HttpServer.HttpResultFactory.GetStaticResult(IRequest requestContext, StaticResultOptions options) at Emby.Server.Implementations.Services.ServiceController.GetTaskResult(Task task) at Emby.Server.Implementations.Services.ServiceHandler.ProcessRequestAsync(HttpListenerHost appHost, IRequest httpReq, IResponse httpRes, RestPath restPath, String responseContentType, CancellationToken cancellationToken) at Emby.Server.Implementations.HttpServer.HttpListenerHost.RequestHandler(IRequest httpReq, ReadOnlyMemory`1 urlString, ReadOnlyMemory`1 localPath, CancellationToken cancellationToken) SharpCifs.Util.Transport.TransportException: I/O error occurred. at SharpCifs.Util.Transport.Transport.Connect(Int64 timeout) at SharpCifs.Smb.SmbTransport.Connect() SharpCifs.Util.Transport.TransportException: Connection timeout at SharpCifs.Util.Transport.Transport.Connect(Int64 timeout) Source: Emby.Server.Implementations TargetSite: Void Connect() 2020-04-03 12:32:22.993 Info HttpServer: HTTP Response 500 to 127.0.0.1. Time: 60611ms. http://127.0.0.1:8096/Items/File?Id=smb%3A%2F%2F192.168.1.100%2FFilms%2FStar+Wars 2020-04-03 12:32:22.997 Info DynamicHlsService: AppendExtraLogData - Read graph file: /config/logs/ffmpeg-remux-3e00a2eb-6c27-4772-a55b-5d52b9b4e4c6_1graph.txt 2020-04-03 12:32:23.000 Info DynamicHlsService: AppendExtraLogData - Deserialized GraphData fileStream: {0:n} bytes Graph Count: 0 2020-04-03 12:32:23.001 Info DynamicHlsService: AppendExtraLogData - File Deleted 2020-04-03 12:32:23.008 Info DynamicHlsService: ProcessRun 'StreamTranscode 3e00a2' Process exited with code 1 2020-04-03 12:32:23.030 Error HttpServer: Error processing request *** Error Report *** Version: 4.4.0.40 Command line: /system/EmbyServer.dll -programdata /config -ffdetect /bin/ffdetect -ffmpeg /bin/ffmpeg -ffprobe /bin/ffprobe -restartexitcode 3 Operating system: Unix 4.15.0.55 64-Bit OS: True 64-Bit Process: True User Interactive: True Runtime: file:///system/System.Private.CoreLib.dll System.Environment.Version: 3.1.2 Processor count: 4 Program data path: /config Application directory: /system System.Exception: System.Exception: Error starting ffmpeg at Emby.Server.MediaEncoding.Api.BaseStreamingService.StartFfMpeg(StreamState state, String outputPath, CancellationTokenSource cancellationTokenSource, Boolean acquireResources) at Emby.Server.MediaEncoding.Api.Hls.DynamicHlsService.GetDynamicSegment(StreamRequest request, String playlistId, String segmentId, Int32 subtitleStreamIndex) at Emby.Server.Implementations.Services.ServiceController.GetTaskResult(Task task) at Emby.Server.Implementations.Services.ServiceHandler.ProcessRequestAsync(HttpListenerHost appHost, IRequest httpReq, IResponse httpRes, RestPath restPath, String responseContentType, CancellationToken cancellationToken) at Emby.Server.Implementations.HttpServer.HttpListenerHost.RequestHandler(IRequest httpReq, ReadOnlyMemory`1 urlString, ReadOnlyMemory`1 localPath, CancellationToken cancellationToken) Source: Emby.Server.MediaEncoding TargetSite: Void MoveNext() Can someone can explain why in swarm mode I get this " SharpCifs.Smb.SmbException: SharpCifs.Smb.SmbException: Failed to connect: 0.0.0.0<00>/192.168.1.100 " and why in normal mode it is ok ? Thanks for your help Thomas Link to comment Share on other sites More sharing options...
mastrmind11 717 Posted April 3, 2020 Share Posted April 3, 2020 Have you tried google? https://github.com/dperson/samba/issues/25 Link to comment Share on other sites More sharing options...
tomtomgooo 0 Posted April 3, 2020 Author Share Posted April 3, 2020 (edited) thx for your answer. I don't need to share with samba but I need to connect on with emby. My shares "Films" (192.168.1.100) are not provided by docker. They are supported by an another host in ubuntu standard. With docker standard connection to samba works good, the problem is just in swarm mode. I have tried to find an answer in google yes and I have found nothing Thanks for your help Edited April 3, 2020 by tomtomgooo Link to comment Share on other sites More sharing options...
mastrmind11 717 Posted April 3, 2020 Share Posted April 3, 2020 I guess I'm confused about what you're trying to accomplish. So you have your stuff mounted on the server that you're trying to spin up the emby docker container? I don't see any volumes pointing to your media in your config. Please clarify. Link to comment Share on other sites More sharing options...
tomtomgooo 0 Posted April 3, 2020 Author Share Posted April 3, 2020 (edited) No, media are directly pointed on media library by //192.168.1.100/Films and it result in smb://192.168.1.100/Films. FFmpeg have smb module to read samba path directly. So I no need to mount it on every VM. Edited April 3, 2020 by tomtomgooo Link to comment Share on other sites More sharing options...
Luke 37116 Posted April 3, 2020 Share Posted April 3, 2020 Rather than adding the smb share to Emby, what i would suggest instead is mounting the share to a local path using the tools in Docker to do that. Then add the local path to Emby instead. Please let us know if this helps. Thanks. Link to comment Share on other sites More sharing options...
mastrmind11 717 Posted April 3, 2020 Share Posted April 3, 2020 Rather than adding the smb share to Emby, what i would suggest instead is mounting the share to a local path using the tools in Docker to do that. Then add the local path to Emby instead. Please let us know if this helps. Thanks. I think what he's saying is that becomes a real pain in the ass when you've got multiple servers set up (which is what swarm implies). Link to comment Share on other sites More sharing options...
tomtomgooo 0 Posted April 3, 2020 Author Share Posted April 3, 2020 yes it is true. I have found where is the issue. It is with the network driver in swarm. Overlay doesn't allow connection in samba I need to configure it in Bridge. The problem now is traefik which need overlay driver to communicate between containers I work on it. I'll be back Link to comment Share on other sites More sharing options...
tomtomgooo 0 Posted April 4, 2020 Author Share Posted April 4, 2020 (edited) Ok, now it is ok. It works in swarm with bridge driver. I did'nt succeed to reverse proxy it with traefik due to overlay driver needed to communicate between emby and traefik. If someone is able to operate emby+traefik in swarm with samba media, i'am interresting ! Cheers Edited April 4, 2020 by tomtomgooo Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now