ddurdle 75 Posted August 5, 2018 Share Posted August 5, 2018 As a hobby, I've been helping some emby users setup their Emby to use Google Drive as a media source. There are "traditional" methods such as mounting the drive as a mount point or windows drive, but there is performance impact and affect on google drive quotas. I've written a bunch of open-source software that can setup your Google Drive as a media source for Emby, via the support for STRM files. Once deployed, the solution is self-maintaining -- new video files added to your Google Drive are automatically exported into STRMs and imported into Emby. Another big advantage with this solution is transcoding. With a tweak, transcoding requests are now handled through Google Drive transcoding, relieving critical CPU cycles on the emby server. The setup is a bit complicated. And although it works on Windows (I have a number of users who report back they are successfully using the setup in Windows), there is no "magic EXE" a user can download to run -- the code is in Python, so every other operating system comes with everything you need, but on windows, you'll need to setup Python. The preferred system configuration is a debian-based linux (including ubuntu). There will be plans to eventually push out a EXE file for Windows users, but it is not high on my priority list. For the adventurous, you can setup the install yourself. But I've been lending my time (no cost) to help deploy and setup user's Emby Google Drive host. The proper setup that runs everything with optimal performance (in particular google transcoding) can be time consuming and confusing. I have deployed complete entire new GCE spun instances in as little as 30 mins, purely because I've done it enough times. Hardware wise, there is no additional memory or cpu requirements for the code. It is designed to run on the Emby host, but it can also run on a different server. I've successfully setup working installs on as little as 256MB VPS. It'll also work fine on shared vCPU instances (free tier) on Google Compute Engine. All my test servers are hosted in GCE. The extra ram offered in the 1 vCPU package will provide great speed improvements for navigation of large libraries (by leveraging the extra ram to host the emby sqlite ibrary.db file). I'm willing to work with new users who want to get this setup for their family, by offering my time to help speed up the setup by working with you on setting up the instances. I ask, in turn, that you support Emby by purchashing premier. All the user's I have helped were very happy with the setup that they had no issue supporting Emby by purchasing Emby premier. If you want to help you with your setup or help you get hosted on GCE, reply here or direct message me. If you want to setup yourself, the github links are below. Please feel free to provide feedback and request features through "issues" on github. the service that delivers the Google Drive media: https://github.com/ddurdle/Python-GoogleDrive-VideoStream some additional optional scripts for emby for tweaking features with regards to Google Drive hosted content: https://github.com/ddurdle/GoogleDrive-VideoStream_extra Disclaimers: I'm not affiliated with Emby. I'm also not doing this as a business, but as a hobby (I already have a full time job). I don't work with any hosting providers and will not recommend any hosting service provider beside Google Compute Engine. I've always been interested in movies and tv and "the cloud". Link to comment Share on other sites More sharing options...
lepitismak 1 Posted August 13, 2018 Share Posted August 13, 2018 @@ddurdle make a video tuto please Link to comment Share on other sites More sharing options...
lepitismak 1 Posted August 14, 2018 Share Posted August 14, 2018 @@ddurdle I really have interest but I have no knowledge in linux. How could you help me? I am willing to pay your time if it is necessary. Link to comment Share on other sites More sharing options...
ddurdle 75 Posted August 15, 2018 Author Share Posted August 15, 2018 @@ddurdle I really have interest but I have no knowledge in linux. How could you help me? I am willing to pay your time if it is necessary. I pinged you but never heard back. Link to comment Share on other sites More sharing options...
numberedthought 1 Posted August 18, 2018 Share Posted August 18, 2018 ddurtle, if you're still available for help on this, I'd appreciate it. I'm familiar with linux and python. Started looking through your git and my head swum a bit. I'd like to throw this up on a GCE instance to give it a shot if I could get your help. Link to comment Share on other sites More sharing options...
numberedthought 1 Posted August 20, 2018 Share Posted August 20, 2018 So I've gotten this to work with @ddurtle's Videostream (Awesome work by the way) Setup was simple. I now only have a few issues that make it unusable for me. Primarily that google only muxes the first audio track of a file as it's audio choice. This means that for most bluray rips it grabs the commentary track as the primary output. Anyone know a way around that? Besides that, strm playback in emby using google's output is freaking insanely fast and super stable. Link to comment Share on other sites More sharing options...
ddurdle 75 Posted August 20, 2018 Author Share Posted August 20, 2018 (edited) So I've gotten this to work with @ddurtle's Videostream (Awesome work by the way) Setup was simple. I now only have a few issues that make it unusable for me. Primarily that google only muxes the first audio track of a file as it's audio choice. This means that for most bluray rips it grabs the commentary track as the primary output. Anyone know a way around that? Besides that, strm playback in emby using google's output is freaking insanely fast and super stable. The issue is actually a Google one. If the source file has a DD track, Google will default to this as primary for transcoding. Most movies that have multiple tracks will put the commentary track as the DD. Some movies that will have multiple DD tracks will be fine since the commentary track won't be the primary DD track. This is only an issue when transcoding due to audio support (such as playing back a video with a DTS audio on a device without DTS support). The solution is to use the helper script that does two things: 1) adds the settings quality selector during playback and 2) intercepts transcoding requests so it can select the proper audio track for transcoding. It's in: git clone https://github.com/ddurdle/GoogleDrive-VideoStream_extra sample commands to remap transcoders to use the wrapper: #remap transcoders cd /opt/emby-server/bin; sudo mv ffmpeg ffmpeg.oem; sudo mv ffprobe ffprobe.oem sudo ln -sf /u01/GoogleDrive-VideoStream_extra/transcoders/emby_ffmpeg.pl ffmpeg; sudo ln -sf /u01/GoogleDrive-VideoStream_extra/transcoders/emby_ffprobe.pl ffprobe There are a few custom parameters in the scripts to examine and adjust as needed. Edited August 20, 2018 by ddurdle Link to comment Share on other sites More sharing options...
numberedthought 1 Posted August 20, 2018 Share Posted August 20, 2018 Thanks for the heads up @@ddurdle. You've thought of everything I'll throw this into the mix tonight. I've got to do a dance because I'm in docker. Shouldn't be too bad. Link to comment Share on other sites More sharing options...
numberedthought 1 Posted August 25, 2018 Share Posted August 25, 2018 @@ddurdle I've followed your instructions, but unfortunately do not have any success showing multiple playback options. I've tried both in docker and in a straight install of Emby on ubuntu. I renamed the ffmprobe and ffmpeg files as specified and created the symlinks. Playback works the same as it did before. I do not see anything in the logs showing any new transcode actions, nor does /tmp have a transcode.log file as specified in the perl scripts. I'd really appreciate any help you can offer. Thanks Link to comment Share on other sites More sharing options...
ddurdle 75 Posted August 25, 2018 Author Share Posted August 25, 2018 Are you forcing the transcode by selecting the quality setting during playback and changing it, so that emby invokes transcoding? @@ddurdle I've followed your instructions, but unfortunately do not have any success showing multiple playback options. I've tried both in docker and in a straight install of Emby on ubuntu. I renamed the ffmprobe and ffmpeg files as specified and created the symlinks. Playback works the same as it did before. I do not see anything in the logs showing any new transcode actions, nor does /tmp have a transcode.log file as specified in the perl scripts. I'd really appreciate any help you can offer. Thanks Link to comment Share on other sites More sharing options...
numberedthought 1 Posted August 25, 2018 Share Posted August 25, 2018 Are you forcing the transcode by selecting the quality setting during playback and changing it, so that emby invokes transcoding? I tried to, but everything kept direct playing still. I'm wondering if there's something funky with my strm generation too. I'm deleting my libraries and regenerating my strms and will check back. Link to comment Share on other sites More sharing options...
ddurdle 75 Posted August 25, 2018 Author Share Posted August 25, 2018 What version of emby are you using? Link to comment Share on other sites More sharing options...
numberedthought 1 Posted August 25, 2018 Share Posted August 25, 2018 (edited) latest - Version 3.5.2.0 Edited August 25, 2018 by numberedthought Link to comment Share on other sites More sharing options...
ddurdle 75 Posted August 26, 2018 Author Share Posted August 26, 2018 (edited) latest - Version 3.5.2.0 Some of my testers running android have reported the inability to transcode using the quality selector -- always "direct plays". I haven't looked into it deep enough yet to raise a thread here about it. Emby never triggers ffmpeg regardless what quality setting the user selects. There are also two other issues as well being investigated on a test server I have with emby 3.5.2. Everything works as designed on emby 3.3.10., the last version thoroughly tested Edited August 26, 2018 by ddurdle Link to comment Share on other sites More sharing options...
numberedthought 1 Posted August 26, 2018 Share Posted August 26, 2018 So, I downgraded to Version 3.3.1.0 and did the ffmpeg and probe replacements again. I've forced transcoding and received no option to change the audio. Please see the playback info screenshot below https://i.imgur.com/MDtCJps.png There's nothing in the preplay screen allowing me to choose audio or playback options. https://i.imgur.com/ReBCVfz.jpg I also can't find anything in the media playback controls once playing https://i.imgur.com/ZQ3RXZL.png I'm at a loss. It's too bad too, because the strm playback is fast as heck. Link to comment Share on other sites More sharing options...
Luke 37019 Posted August 26, 2018 Share Posted August 26, 2018 Best thing to do is stay on the latest version and see how to report a media playback issue. thanks. Link to comment Share on other sites More sharing options...
ddurdle 75 Posted August 26, 2018 Author Share Posted August 26, 2018 So, I downgraded to Version 3.3.1.0 and did the ffmpeg and probe replacements again. I've forced transcoding and received no option to change the audio. Please see the playback info screenshot below https://i.imgur.com/MDtCJps.png There's nothing in the preplay screen allowing me to choose audio or playback options. https://i.imgur.com/ReBCVfz.jpg I also can't find anything in the media playback controls once playing https://i.imgur.com/ZQ3RXZL.png I'm at a loss. It's too bad too, because the strm playback is fast as heck. Got to the server dashboard, user settings, ensure the section for Media Playback is fully checked as below: Link to comment Share on other sites More sharing options...
numberedthought 1 Posted August 26, 2018 Share Posted August 26, 2018 confirmed. Link to comment Share on other sites More sharing options...
ddurdle 75 Posted August 26, 2018 Author Share Posted August 26, 2018 confirmed. What happens when you click on the quality in this shot? Do you get a popup asking to change the quality? https://i.imgur.com/ZQ3RXZL.png Link to comment Share on other sites More sharing options...
numberedthought 1 Posted August 26, 2018 Share Posted August 26, 2018 (edited) What happens when you click on the quality in this shot? Do you get a popup asking to change the quality? https://i.imgur.com/ZQ3RXZL.png Yes I do, I can change it down to different qualities. I've noticed something very weird though. So I got angry at it, and the just wiped everything out, went to the newest Emby version, then just had it scan the strm library and went to bed. Before I went to bed, when I selected playback via the web interface, I had the same result as before. Playback was uber quick, You can see it load the webm player in the background and I started playback of a google transcode. It was direct playing and I had fast scrubbing. When I woke up in the morning, I decided to play with it some more. What do you know, it now has multiple audio tracks on my test video and it chooses the 7.1 as default. I start playback and it looks like its playing back the original mkv.. I started playback via the web interface and it transcoded due to a subtitle format issue. Started playback via phone and it direct played. According to the stats it sees the container as mkv. (apparently my phone can direct play a remux) I'm wicked confused . BTW this is without the transcode helpers. I went back to the docker container. Still have scrubbing issues on mobile though. I think that may just be an Emby issue. Edited August 26, 2018 by numberedthought Link to comment Share on other sites More sharing options...
numberedthought 1 Posted August 26, 2018 Share Posted August 26, 2018 Ok, I may have stumbled into a "I'm an idiot" spot. This constant in the emby transcode helper use constant PROXY => 'http:// :8888'; Does that need to point to your strm https server that's serving the redirects? Link to comment Share on other sites More sharing options...
Shabbypenguin 0 Posted August 26, 2018 Share Posted August 26, 2018 (edited) this sounds amazing, is there a guide for going from regular emby server to strm google drive powered? the ducmentation seems geared towards people who already know what to do and how to do it. Edited August 26, 2018 by Shabbypenguin Link to comment Share on other sites More sharing options...
numberedthought 1 Posted August 26, 2018 Share Posted August 26, 2018 not quite yet. Hopefully some of this trial and error I'm going through will at least end up with a basic one. Link to comment Share on other sites More sharing options...
ddurdle 75 Posted August 26, 2018 Author Share Posted August 26, 2018 Ok, I may have stumbled into a "I'm an idiot" spot. This constant in the emby transcode helper use constant PROXY => 'http:// :8888'; Does that need to point to your strm https server that's serving the redirects? It is used in conjunction with PROXY_DETERMINATOR to http proxy IPTV as required. I have a IPTV service that can only be used through a HTTP proxy. Link to comment Share on other sites More sharing options...
ddurdle 75 Posted August 26, 2018 Author Share Posted August 26, 2018 this sounds amazing, is there a guide for going from regular emby server to strm google drive powered? the ducmentation seems geared towards people who already know what to do and how to do it. No guide, but that is also why normally I assist people through discord or slack. I've also helped people by installing and setting up, as long they are using a linux sytem. 1 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