-
Posts
3,743 -
Joined
-
Last visited
-
Days Won
4
Content Type
Profiles
Forums
Downloads
Store
Gallery
Bug Reports
Documentation
Landing
Posts posted by kizer
-
-
Updated my script to exactly like yours up above and then just changed the one line you asked me to change. It scanned TV shows, but ignored the movies. Keep in mind my script is just like yours with Paths. You think it would of included the movies since most of my content movies are newer and in this case alot of these are really old.
Script location: /tmp/user.scripts/tmpScripts/zzzzzzz-test-zzzzzzzz/script
Note that closing this window will abort the execution of this script
Available RAM in Bytes: 2507377040
Amount of Videos that can be preloaded: 41
/mnt/user/TV/Shows/NCIS/Season 3/NCIS.-.S03E13.avi has a size of 367577088
/mnt/user/TV/Shows/NCIS/Season 3/NCIS.-.S03E14.avi has a size of 367546368
/mnt/user/TV/Shows/NCIS/Season 3/NCIS.-.S03E15.avi has a size of 367622144
/mnt/user/TV/Shows/NCIS/Season 3/NCIS.-.S03E16.avi has a size of 367663104
/mnt/user/TV/Shows/NCIS/Season 3/NCIS.-.S03E17.avi has a size of 367724544
/mnt/user/TV/Shows/NCIS/Season 3/NCIS.-.S03E18.avi has a size of 367560704
/mnt/user/TV/Shows/NCIS/Season 3/NCIS.-.S03E19.avi has a size of 367579136
/mnt/user/TV/Shows/NCIS/Season 3/NCIS.-.S03E20.avi has a size of 367570944
/mnt/user/TV/Shows/NCIS/Season 3/NCIS.-.S03E21.avi has a size of 367587328
/mnt/user/TV/Shows/NCIS/Season 3/NCIS.-.S03E22.avi has a size of 367566848
/mnt/user/TV/Shows/NCIS/Season 3/NCIS.-.S03E23.avi has a size of 367665152
/mnt/user/TV/Shows/NCIS/Season 3/NCIS.-.S03E24.avi has a size of 364546048
/mnt/user/TV/Shows/The Big Bang Theory/Season 1/The.Big.Bang.Theory.-.S01E01.avi has a size of 183793664
/mnt/user/TV/Shows/The Big Bang Theory/Season 1/The.Big.Bang.Theory.-.S01E02.avi has a size of 183742464
/mnt/user/TV/Shows/The Big Bang Theory/Season 1/The.Big.Bang.Theory.-.S01E03.avi has a size of 183769088
/mnt/user/TV/Shows/The Big Bang Theory/Season 1/The.Big.Bang.Theory.-.S01E04.avi has a size of 183756800
/mnt/user/TV/Shows/The Big Bang Theory/Season 1/The.Big.Bang.Theory.-.S01E05.avi has a size of 183732224
/mnt/user/TV/Shows/The Big Bang Theory/Season 1/The.Big.Bang.Theory.-.S01E06.avi has a size of 183709696
/mnt/user/TV/Shows/The Big Bang Theory/Season 1/The.Big.Bang.Theory.-.S01E07.avi has a size of 183732224
/mnt/user/TV/Shows/The Big Bang Theory/Season 1/The.Big.Bang.Theory.-.S01E08.avi has a size of 183703552
/mnt/user/TV/Shows/The Big Bang Theory/Season 1/The.Big.Bang.Theory.-.S01E09.avi has a size of 183711744
/mnt/user/TV/Shows/The Big Bang Theory/Season 1/The.Big.Bang.Theory.-.S01E10.avi has a size of 183672832
/mnt/user/TV/Shows/The Big Bang Theory/Season 1/The.Big.Bang.Theory.-.S01E11.avi has a size of 183674880
/mnt/user/TV/Shows/The Big Bang Theory/Season 1/The.Big.Bang.Theory.-.S01E12.avi has a size of 183674880
/mnt/user/TV/Shows/The Big Bang Theory/Season 1/The.Big.Bang.Theory.-.S01E13.avi has a size of 183746560
/mnt/user/TV/Shows/The Big Bang Theory/Season 1/The.Big.Bang.Theory.-.S01E14.avi has a size of 183701504
/mnt/user/TV/Shows/The Big Bang Theory/Season 1/The.Big.Bang.Theory.-.S01E15.avi has a size of 183732224
/mnt/user/TV/Shows/The Big Bang Theory/Season 1/The.Big.Bang.Theory.-.S01E16.avi has a size of 183719936
/mnt/user/TV/Shows/The Big Bang Theory/Season 1/The.Big.Bang.Theory.-.S01E17.avi has a size of 183703552
/mnt/user/TV/Shows/The Big Bang Theory/Season 2/The.Big.Bang.Theory.-.S02E07.avi has a size of 183415570
/mnt/user/TV/Shows/The Big Bang Theory/Season 2/The.Big.Bang.Theory.-.S02E08.avi has a size of 182377724
/mnt/user/TV/Shows/The Big Bang Theory/Season 2/The.Big.Bang.Theory.-.S02E09.avi has a size of 182779678
/mnt/user/TV/Shows/Torchwood/Season 1/Torchwood.-.S01E06.avi has a size of 367685632
/mnt/user/TV/Shows/Torchwood/Season 1/Torchwood.-.S01E07.avi has a size of 367747072
/mnt/user/TV/Shows/Torchwood/Season 1/Torchwood.-.S01E08.avi has a size of 367767552
/mnt/user/TV/Shows/Torchwood/Season 1/Torchwood.-.S01E09.avi has a size of 367720448
/mnt/user/TV/Shows/Torchwood/Season 3/Torchwood.-.S03E01.avi has a size of 577108990
/mnt/user/TV/Shows/Torchwood/Season 3/Torchwood.-.S03E02.avi has a size of 577187912
/mnt/user/TV/Shows/Torchwood/Season 3/Torchwood.-.S03E03.avi has a size of 577134280
/mnt/user/TV/Shows/Torchwood/Season 3/Torchwood.-.S03E04.avi has a size of 577226288
/mnt/user/TV/Shows/Torchwood/Season 3/Torchwood.-.S03E05.avi has a size of 576900174
Preload /mnt/user/Movies/All/Rush.Hour.3.(2007)(720p)(DTS)/Rush.Hour.3.(2007)(720p).srt
Preload /mnt/user/Movies/All/Waiting.(2005)(720p)(AC3)/Waiting.(2005)(720p).srt
Preload /mnt/user/Movies/All/Rush.Hour.2.(2001)(720p)(AC3)/Rush.Hour.2.(2001)(720p).srt
Preload /mnt/user/Movies/All/The.Librarian.The.Curse.Of.The.Judas.Chalice.(2008)(720p)(AC3)/The.Librarian.The.Curse.Of.The.Judas.Chalice.(2008)(720p).srt
Preload /mnt/user/Movies/1080-Bray-Rips/Avatar/Avatar.srt
Preload /mnt/user/TV/Shows/Adventure Time/Season 7/Adventure.Time.-.S07E35_eng.srt
Preload /mnt/user/TV/Shows/Adventure Time/Season 7/Adventure.Time.-.S07E34_eng.srt
Preload /mnt/user/TV/Shows/Adventure Time/Season 7/Adventure.Time.-.S07E33_eng.srt
Preload /mnt/user/TV/Shows/Adventure Time/Season 7/Adventure.Time.-.S07E32_eng.srt
Preload /mnt/user/TV/Shows/Adventure Time/Season 7/Adventure.Time.-.S07E31_eng.srt
Preload /mnt/user/TV/Shows/Adventure Time/Season 8/Adventure.Time.-.S08E03_eng.srt
Preload /mnt/user/TV/Shows/Adventure Time/Season 8/Adventure.Time.-.S08E01E01_eng.srt
Preload /mnt/user/TV/Shows/Top Secret Recipe/Season 1/Top.Secret.Recipe.-.S01E08.srt
Preload /mnt/user/TV/Shows/Dexter/Season 4/Dexter.-.S04E01.srtIt also gave me a popup error message saying
No video file has been proloaded (wrong path?)
-
You could simply use User.Scripts which would allow you to make a script and with a click of a button or via a specified time run a backup script of your folders to your specified destination.
-
How does this deal with Parity Sync?
-
Im running 6.9-RC30
I could fire up my other machine to test on 6.8.3 if you think there are significant changes from 6.8.3 and 6.9-RC-30
This is the output via User.Scripts:
Script location: /tmp/user.scripts/tmpScripts/zzzzzzz-test-zzzzzzzz/script
Note that closing this window will abort the execution of this script
Process substitution test
/mnt/user/Movies/All/Yours,.Mine.&.Ours.(1968)(480)/Yours,.Mine.&.Ours.(1968)(480).mkv
/mnt/user/Movies/All/Zootopia.(2016)(720p)/Zootopia.(2016)(720p).mkv
/mnt/user/Movies/All/xXx -.Return.of.Xander.Cage.(2017)(1080p)/xXx -.Return.of.Xander.Cage.(2017)(1080p).mkv
Piping test
/mnt/user/Movies/All/Yours,.Mine.&.Ours.(1968)(480)/Yours,.Mine.&.Ours.(1968)(480).mkv
/mnt/user/Movies/All/Zootopia.(2016)(720p)/Zootopia.(2016)(720p).mkv
/mnt/user/Movies/All/xXx -.Return.of.Xander.Cage.(2017)(1080p)/xXx -.Return.of.Xander.Cage.(2017)(1080p).mkv
-
6 hours ago, mgutt said:
This means it did only preload the subtitles or did you shorten the output?
Nope. I just cut and pasted your script up above and changed the paths to my Movies and TV shows. -
Just gave the new Script a try and this is the output.
Script location: /tmp/user.scripts/tmpScripts/Media-Preload-Movies/script Note that closing this window will abort the execution of this script Available RAM in Bytes: 6726713300 Amount of Videos that can be preloaded: 110 Preload /mnt/user/Movies/All/Rush.Hour.3.(2007)(720p)(DTS)/Rush.Hour.3.(2007)(720p).srt Preload /mnt/user/Movies/All/Waiting.(2005)(720p)(AC3)/Waiting.(2005)(720p).srt Preload /mnt/user/Movies/All/Rush.Hour.2.(2001)(720p)(AC3)/Rush.Hour.2.(2001)(720p).srt Preload /mnt/user/Movies/All/The.Librarian.The.Curse.Of.The.Judas.Chalice.(2008)(720p)(AC3)/The.Librarian.The.Curse.Of.The.Judas.Chalice.(2008)(720p).srt Preload /mnt/user/Movies/1080-Bray-Rips/Avatar/Avatar.srt Preload /mnt/user/TV/Shows/Adventure Time/Season 7/Adventure.Time.-.S07E35_eng.srt Preload /mnt/user/TV/Shows/Adventure Time/Season 7/Adventure.Time.-.S07E34_eng.srt Preload /mnt/user/TV/Shows/Adventure Time/Season 7/Adventure.Time.-.S07E33_eng.srt Preload /mnt/user/TV/Shows/Adventure Time/Season 7/Adventure.Time.-.S07E32_eng.srt Preload /mnt/user/TV/Shows/Adventure Time/Season 7/Adventure.Time.-.S07E31_eng.srt Preload /mnt/user/TV/Shows/Adventure Time/Season 8/Adventure.Time.-.S08E03_eng.srt Preload /mnt/user/TV/Shows/Adventure Time/Season 8/Adventure.Time.-.S08E01E01_eng.srt Preload /mnt/user/TV/Shows/Top Secret Recipe/Season 1/Top.Secret.Recipe.-.S01E08.srt Preload /mnt/user/TV/Shows/Dexter/Season 4/Dexter.-.S04E01.srt
-
On the Multiple Video Path does it split the Paths 50/50 =50% so 25%/25% of Ram?
or does it run the first path and then run to the second path until the 50% of ram is used up?
-
Yes my Given movie path is
/mnt/user/Movies/All/
OH NO....... I used
/mnt/user/Movie/All/
I just checked my Log. I see a lot more info populating since adding the s. 🤪
I'll let that run until I get off work and try again. Talk about feeling kinda dumb.
- 1
-
When I checked the log in User.Scripts it just said the following and nothing else:
Available RAM in Bytes: 16G Here don't know the exact digits so I just paraphrased it.
Amount of Videos that can be preloaded: 110
I used Plex to view the File on my AppleTV. I'm not 100% sure if any Transcoding was needed. Its a MKV with 6CH/AC3 Audio. I'll look again this Evening for a 2CH video or try it on TV shows since a lot of mine are ripped to 2CH. I have no issues with buying more Ram. I just want to see this work before I lay out the money to 32GB.
-
Just gave it a try and didn't seem to cache right. Clicked on a movie that was maybe 15movies back from the newest and spooled up a drive just like it always does. No buffering just sat there and waited for the Movie to start.
-
- I was reading about the precaching and storing on on SSD on Redditt. That's a very interesting idea which would save everybody money if they have to up their Ram or simply another option.
- Could you put in a pre-test or simply a way to say, "Scan 10 files and test" vs a scan everything you can and find out your existing settings are not a enough? Depending on some peoples Media and Ram it could scan for a long time just to find out they should either up the amount cached or lower. Could be something as simple as:
#####Uncomment below####
#Test Scan only 10 Files
#Full Scan
Also
Could there be a (Cache, Flush and Cache or maybe a Compare and update)? If Changes are made. No idea how you intended to address changes in users scans if they need to update their amounts or if files are added/removed. I'm assuming Plex simply wouldn't show the file, but not sure how removing a file would affect the Cache.
Are you planning on adding this as a Plugin in the future? Something that could be added to CA and updated or keeping it simple as a User.Script? Both work obviously, but just something for you to think about in the future.
-
It said 110 in the script output from User.Plugin. I'm only running with 16GB of ram. Depending on how this goes I wouldn't have an issue with upgrading my RAM some.
I had to run to work while it was running, but I'll try and give it a try this evening. I guess it will get beat up some by my kids while I'm at work so It'll be interesting to see what remains in Cache/Buffer while I'm gone.
-
On 10/10/2020 at 6:35 PM, mgutt said:
Test results:
Cache the first 200 MB of all movies in folder "09":
ls /mnt/user/Movie/09/*/*.mkv | xargs head -c 200000000 > /dev/null
Benchmark:
echo "$(time ( head -c 200000000 "/mnt/disk4/Movie/09/12 Monkeys (1995)/12 Monkeys (1995) FSK16 DE EN IMDB8.0.mkv" ) 2>&1 1>/dev/null )" real 0m0.063s user 0m0.015s sys 0m0.047s
While executing the benchmark disk4 still sleeps.
Starting the movie through Plex... disk spins up... Does Plex use IO_DIRECT, which bypasses any caching? Let's check that. We clean the cache:
sync; echo 1 > /proc/sys/vm/drop_caches
RAM stats before starting a movie:
free -m total used free shared buff/cache available Mem: 64358 1022 61371 761 1964 61974 Swap: 0 0 0
Started a movie in Plex. While the movie is playing the cache usage rises:
free -m total used free shared buff/cache available Mem: 64358 1050 60141 761 3165 61945 Swap: 0 0 0 free -m total used free shared buff/cache available Mem: 64358 1050 59400 761 3907 61944 Swap: 0 0 0 free -m total used free shared buff/cache available Mem: 64358 1051 57769 761 5537 61942 Swap: 0 0 0
After stopping it:
free -m total used free shared buff/cache available Mem: 64358 1043 59559 761 3755 61951 Swap: 0 0 0
Hmmm.. looks like it uses the cache. Spun down disk. Play the movie again from the beginning. Aha. Disk is still sleeping. So Plex should be cachable. But why didn't it work? Ahh.. I forget something I think. The external subtitle file. Ok, let's cache all files on the disk:
ls /mnt/user/Movie/09/*/*.* | xargs head -c 200000000 > /dev/null
Let's stop the disk and start a movie again. Nope. Still spinning up first. Ok, clean cache and cache a full movie:
sync; echo 1 > /proc/sys/vm/drop_caches cat "/mnt/disk4/Movie/09/127 Hours (2010)/127 Hours (2010) FSK12 DE EN TR IMDB7.6.mkv" > /dev/null cat "/mnt/disk4/Movie/09/127 Hours (2010)/127 Hours (2010) FSK12 DE EN TR IMDB7.6.ger.forced.srt" > /dev/null
Spin down disk, start movie in Plex and... ha.. starts directly and disk stays sleeping. Ok, maybe we need to cache more of the movie leader?1GB... 2GB... 3GB... 4GB... 5GB... nothing works. Does Plex read something from the end of the file? Let's read 5GB of the beginning and 5GB of the end of the file... aha. Movie starts directly. Puuhh... we are on the right way. Now 100MB from the beginning and 100MB from the end:
head -c 100000000 "/mnt/disk2/Movie/WX/Wall Street (1987)/Wall Street (1987) FSK12 DE EN IMDB7.4.mkv" > /dev/null head -c 100000000 "/mnt/disk2/Movie/WX/Wall Street (1987)/Wall Street (1987) FSK12 DE EN IMDB7.4.ger.forced.srt" > /dev/null tail -c 100000000 "/mnt/disk2/Movie/WX/Wall Street (1987)/Wall Street (1987) FSK12 DE EN IMDB7.4.mkv" > /dev/null
Ding Ding Ding Ding! It works. And the disk spins up while the movie plays and... no buffering. Nice! Ok. Now lets find out how much is really needed from the end of the file. 100/10... works. 100/1... works. 100/0.1... does not work. Ok, we need 1MB of the end of the file.
Let's check with a 4K movie. 100/1... works. Yeah, baby!
Ok, let's check out how much we need to read from the beginning until the buffer becomes empty. We still use the 4K movie. 50/1... works. 30/1... works... 10/1... complete fail ^^ 20/1... buffers. 25/1... works. Let's test wifi... 25/1... buffers. Wait.. my phone has only 65 mbit/s wifi and the movie has 107 mbit/s. Can't work ^^ Better position... now 866 Mbit/s connection. 25/1... buffers, 30/1... works. 25/1... buffers. This time I waited 2 minutes after each disk spun down. 30/1... buffers. Right.. I need to wait more until the disk completely stopped. 40/1... buffers. 50/1... buffers. 60/1... works.
Ok, now let's test 4K to 1080P Transcoding. 60/1.. works.
Good. So this would be the way to put our movies in the cache, but it works only if there is enough RAM for all movies:
find /mnt/user/Movies/ -iname '*.mkv' -print0 | xargs -0 head -c 60000000 > /dev/null find /mnt/user/Movies/ -iname '*.mkv' -print0 | xargs -0 tail -c 1000000 > /dev/null find /mnt/user/Movies/ -iname '*.srt' -print0 | xargs -0 cat > /dev/null
At the moment I'm stuck to create a command which sorts and uses head and tail at the same time, so it will fill the cache with the recent movies. head alone works:
find /mnt/user/Movies/ -iname '*.mkv' -printf "%T@ %p\n" | sort -n | sed -r 's/^[0-9]+.[0-9]+ //' | tr '\n' '\0' | xargs -0 head -c 60000000 > /dev/null
But adding tail does not work. Piping isn't my favorite ^^
find /mnt/user/Movies/ -iname '*.mkv' -printf "%T@ %p\n" | sort -n | sed -r 's/^[0-9]+.[0-9]+ //' | tr '\n' '\0' | tee >(xargs -0 head -c 60000000 > /dev/null) >(xargs -0 tail -c 1000000 > /dev/null)
I like your experimenting here. How about the last 10 Movies?
-
From your Example which is the complete up today with all changes directory?
I'm asking because I'm rather intrigued
-
This is a Cross Post, but there is some Discussion here about speeding up Media responsiveness.
-
I just have my Movie and TV shares setup to Cache "Yes" and use the Mover Tuning Plugin below that I have setup to check at 20% and move files that are older than 30days. Of course you can use whatever number of days you like or % of files.
Why 20% well that means unless the Share is at a minimum of %20 Full it won't even look at any files that are at least (Specified Date Old Here) on the drive. I had it set to 50% and felt that was keeping files to long on the drive and wasn't moving them.
30 days might be two long and that can easily be adjusted. I had it set to 15 and found it was just a bit two short. I'm guessing 21 days might be the magic number, but everybody is different.
I also have the mover set to Daily trigger at 3AM so it doesn't interrupt anything. I might change to around 6AM since that is when I have Plex Maintenance setup and drives are spinning
Looking for at least 20% which I'm normally at 47% because of Docker content and a smaller SSD
It'll look for files that are 30days and move them
Keep in mind the below script only works on the "Cache Pool" It will not work on other pools people create. Might work in the Future, but currently it does not.
I use the Feature of only Optimizing 10 Movies that are Transcoded onto a SSD and later moved to a Share by unraid simply so I don't add a bunch and forget to clean house. Keep in mind those files are only for a Portable drive I Dock using Unassigned Devices. I don't add a lot of movies, but when I do its pretty easy to keep track of them.
TV shows I rip are a different story. I don't Optimize them so I don't worry about them other than keeping them on the SSD for a period of time.
I totally get I could just us Rsync or find with a time in days or whatever, but some basic plugins that solve some basic needs work just great for me.
- 1
-
I use the Mover Scheduler script to keep my newest content on my SSD for 30days so I'm not spooling up my HDD's except for content that is older than 30days. So if anything that is newer "needs" to be transcoded its accessed nearly instantly coming from the SSD and Transcoded into Ram. My Kids seem to love it, because they often watch the same newest stuff over and over.
I also often copy my newest Movies I add to a portable to take on Road Trips, but I want the files to be 2Channels. I added a Sync on my account to automatically Optimize the 10 newest movies to my profile using the Filters within the Plex app on my phone so when I add something new it fires off a Transcode and stores it. Of course it'll delete files if I don't copy them fast enough since I have it set to 10, but I'm normally pretty good about catching it.
- 1
-
Almost seems like a script could be written to probe the UPS.
I found this tinkering around. Not 100% Solving your issue, but hopefully its something to get your started.
https://serverfault.com/questions/459046/configure-the-ups-apcupsd-demon-to-run-a-script
docker stop NameOfDocker
-
Also what confuses me wasn't your Bios Pointing at the USB or was it simply set to Auto?
-
I'd swap out your parity's and then run a parity check. Drink a cold one and plan your next swap outs.
-
@Squid I turned 50 on September 26. The next day I literally woke up feeling tired like I worked out the day before. Lol
All parts still intact.
- 1
- 1
-
You should post a diagnostics report.
-
I think you have an interesting idea and I would suggest running this through Limetech first just to make they have some input with this. They have had vendors doing various things here before and maybe they can give you some positive or negative feedback to help you decide. Tagging some of the guys below that you might want to reach out to if you actually do proceed in this. 😁
- 1
-
Thanks. I only have the Ender 3 Pro right now, but I did do the Kickstarter for the Ender 6SE which should be here I'm guessing in September.
Video Preloader (avoids HDD spinup latency when starting a Movie or Episode through Plex, Jellyfin or Emby)
in User Customizations
Posted
However if I remove the /mnt/user/TV/ from the line it seems to process just fine. I chose only to use 20% RAM.
However when I look at files being accessed it shows a movie playing, but unraid isn't indicating a drive being spun up even well into the movie. Its like unraid doesn't know a drive is spun up or is simply failing to indicate it.
when I get a chance I’ll fire up my other machine running 6.8.