Jump to content

mgutt

Moderators
  • Posts

    11,355
  • Joined

  • Last visited

  • Days Won

    124

Everything posted by mgutt

  1. This status shows a RAID1. Your upper screenshot is more something like JBOD or RAID0?! I would move all data to the array and restart the cache pool configuration. And if course you should choose a RAID5 setup, but this will result in only 480GB total size (the smallest disk defines the size per disk). So finally you could drop the 240GB disk and build a RAID1 of the biggest two disks.
  2. Ich nutze einfach rsync inkrementell. Dh jedes Backup ist ein 1:1 Backup mit allen Dateien, aber nur die neuen belegen Platz. Hier zB das Script, was per CA User Scripts Plugin den appdata Share täglich von der SSD auf das Array sichert: #!/bin/bash # settings user_share="appdata" # obtain last backup dir last_backup=$(ls -t "/mnt/user/Backup/Shares/${user_share}/" | head -n1) echo "Most recent backup in /mnt/user/Backup/Shares/${user_share}/* is ${last_backup}" # new backup dir new_backup=$(date +%Y%m%d_%H%M%S) # create full backup if [[ ! -d "/mnt/user/Backup/Shares/${user_share}/${last_backup}" ]]; then echo "Create full backup ${new_backup}" # create directory tree as rsync is not able to do that mkdir -p "/mnt/user/Backup/Shares/${user_share}/${new_backup}" # https://askubuntu.com/a/561239/227119 # create very first backup rsync -a "/mnt/user/${user_share}" "/mnt/user/Backup/Shares/${user_share}/${new_backup}" # create incremental backup else echo "Create incremental backup ${new_backup} by using last backup ${last_backup}" rsync -a --delete --link-dest="/mnt/user/Backup/Shares/${user_share}/${last_backup}" "/mnt/user/${user_share}" "/mnt/user/Backup/Shares/${user_share}/${new_backup}" fi Irgendwann wollte ich noch eine "Aufräumfunktion" realisieren, damit neben den Backups der letzten 14 Tage immer nur ein Backup pro Monat/Jahr im Ordner ist, aber da es quasi keinen Platz frisst, ist das noch nicht passiert. ^^ Der Ordner "Backups" ist übrigens ein Share ohne SMB Zugriffsrechte. Dh die Backups sind auch sicher gegen Ransomware. Auf meinen Windows Clients ist übrigens keine Backup-Software installiert. Ich habe stattdessen den Users-Ordner mit einem passwortgeschützten Leserecht freigegeben (rechte Maustaste > erweiterte Freigabe). Per Unassigned Devices Plugin mounte ich die Rechner und sichere auch diese per rsync. Da Unraid damit nur Leserechte besitzt und der PC gar keine, ist auch das sicher gegen Ransomware. Außerdem braucht man keine Software.
  3. I have no problems except of that. Full bandwidth, no disconnects.
  4. I tried this out, too. At first I installed undervolt from here: https://slackware.pkgs.org/current/slackware-x86_64/undervolt-20200612_07d0c70-x86_64-1.txz.html In addition I installed "python3-3.8.2-x86_64-1.txz" through the NerdPack Plugin. After that I was able to execute the read command: undervolt --read temperature target: -0 (100C) core: 0.0 mV gpu: 0.0 mV cache: 0.0 mV uncore: 0.0 mV analogio: 0.0 mV powerlimit: 65.0W (short: 8.0s - enabled) / 4090.0W (long: 8.0s - enabled) Then I set -100mV and it seemed to work: undervolt --core -100 --cache -100 undervolt --read temperature target: -0 (100C) core: -99.61 mV gpu: 0.0 mV cache: -99.61 mV uncore: 0.0 mV analogio: 0.0 mV powerlimit: 65.0W (short: 8.0s - enabled) / 4090.0W (long: 8.0s - enabled) And now the result in idle: Before: 24.39W After: 23.88W Reduction: ~0.50W Its not much, but a nice addon to the good results of the powertop tweaks. And of course undervolting reduces power consumption on high loads as well. Maybe I find a method to compare high load consumption as well. As I do not know how far an i3-8100 could be undervolted I leave this setting until I find out more. P.S. I tested this command as well, but there was no difference in idle: undervolt --gpu -75 --core -100 --cache -100 --uncore -100 --analogio -100 undervolt --read temperature target: -0 (100C) core: -99.61 mV gpu: -75.2 mV cache: -99.61 mV uncore: -99.61 mV analogio: -99.61 mV powerlimit: 65.0W (short: 8.0s - enabled) / 4090.0W (long: 8.0s - enabled)
  5. I manually spun down all my disks. After some minutes the power consumption raised, so I executed "mdcmd spindown" through the terminal. As disk3 and disk6 reacted slowly to the command and the power consumption dropped after that, I could be sure that they were spinning, although the icon was grey: I really like to help to find the problem, but I do not know what to search for. As it can't be a disk access thing, it must be something related to the USB device power management I think. P.S. I don't know if they stay spinning all the time or spin down after several minutes again. I will observe that.
  6. 19% isn't full, but maybe your system was out of RAM?! Please check while transcoding your RAM usage with "free -h".
  7. Planst du denn noch HDDs zu verbauen? Wenn nein, dann sehe ich nichts Unsinniges daran. Dann ist es eben ein Array, das nur aus SSDs besteht. Ein Cache ist dann natürlich überflüssig. Ich verstehe zwar nicht sofort die Syno da ist, aber du wirst schon wissen warum
  8. It was directly playing and its bitrate is 116 Mbit/s?! This is extremely high, even for a 4K movie. Are you sure your Client is able to render such a high bitrate? And finally this stands in contradiction to the 19% fill rate of the "/tmp/PlexRamScratch" folder. If the movie was directly played, the folder must stay empty. Its only filled on transcoding operations.
  9. Nur als Ergänzung. Es ist nicht notwendig, aber da die CPU eine virtuelle Grafikkarte berechnen muss, ist die CPU-Belastung natürlich ungleich höher, als wenn man eine Grafikkarte hätte. Wenn du also planst eine VM dauerhaft als Client zu verwenden, macht eine Grafikkarte Sinn. Die macht dann auch viel mehr "Spaß", weil die gesamte Bedienung viel flüssiger von der Hand geht (selbst der Desktop eines Betriebssystems wird mittlerweile grafikbeschleunigt, wie auch viele Apps wie der Browser). In dem Fall würde eine GT 710 oder GT 1030 ausreichen. Soll sie besonders stromsparend sein, würde ich eine GTX 1050 Ti empfehlen.
  10. Vorab: Wenn es mit einem Docker Container geht, verwende keine VM. Das spart Ressourcen. Du hast eine NVMe SSD als Cache konfiguriert und dann hast du noch eine 2TB SSD, die du ausschließlich für Nextcloud einsetzen möchtest? Also zwei verschiedene SSDs, habe ich das richtig verstanden? Da käme mir zuerst die Frage, wie du die SSD gegen Ausfälle sicherst oder ist diese Teil deines HDD Arrays und per Parität geschützt? Wenn ja, du weißt, dass die Schreibgeschwindigkeit dann durch die Parität stark begrenzt ist (oder ist dein NAS SSD-only)? Wenn nein, was machst du bei einem Ausfall der 2TB SSD? Dann deine Frage zum Share. Grundsätzlich ist jedes Verzeichnis auf der obersten Ebene einer Disk, ein Share. Würdest du also von Hand den Ordner "nextcloud" auf "disk2" erstellen, wäre das ein Share, egal ob du dazu bisher etwas eingestellt hast oder nicht. Aus dem Grund macht es Sinn erstmal einen Share anzulegen und die Zugangsrechte zu definieren. Dir steht es natürlich frei diesem Ordner alle Rechte zu entziehen. Also "Export" auf "No" und "Security" auf "Private" und die SMB User alle auf "No Access". Dann hast du einen Share, der über SMB/NFS/etc nicht erreichbar ist. Nachdem du diesen Share angelegt hast, kannst du diesen, wie du schon richtig erkannt hast, im Container als direkten Pfad hinterlegen. Entweder nimmst du diesen Pfad: /mnt/disk2/nextcloud Dieser verweist direkt auf den Ordner auf dieser Disk. Ich nenne das Direct Disk Access. oder diesen: /mnt/user/nextcloud Dieser verweist auf die gesamte Disk-Gruppe. Das ist relevant, wenn du bei "Included Disk(s)" mehrere hinterlegt hast. zB wenn dir irgendwann die 2TB SSD nicht mehr reicht und du noch eine zweite Disk auswählst. Beispiel: Wenn man also die Datei "/mnt/user/nextcloud/bild.jpg" abruft, dann sorgt Unraid automatisch dafür, dass sie von "disk3" geladen wird (wenn sie da liegt). Fazit: Der eine Pfad ist performanter, weil "direkt", der andere flexibler. Und nur damit das auch klar ist. Wenn Du den Container installierst, stellst du fest, dass im Feld dieser Pfad voreingestellt ist: /mnt/user/appdata/nextcloudpi Er zielt also auf den Share "appdata". Da du gesagt hast, dass "appdata" auf der NVMe liegt, würden die Daten also durch diesen Pfad alle Daten auf der NVMe landen. Das wäre also nicht das was du willst. Mich erstaunt ein wenig, dass man scheinbar keine zwei Pfade angeben kann. Einen für den Webserver/Datenbank und den anderen für die Dateien. Oder wird der Webserver/Datenbank dann im docker.img hinterlegt? Wenn ich das installieren würde, dann so: - Webserver + MySQL Datenbank auf den (RAID1) NVMe Cache - Dateien ins gecachte und paritätsgesicherte HDD Array
  11. Ganz blöd gefragt. Welche Adresse rufst du exakt auf? Server nicht gefunden klingt so nach DNS Fehler. Wenn ich nämlich eine IP aufrufe mit einem Port, der nicht existiert, dann erhalte ich den Fehler "Verbindung fehlgeschlagen".
  12. @frodr You are in the wrong thread Post here.
  13. Open the WebTerminal and execute the following: while true; do lsof /boot/config/domain.cfg; done; Wait until you see which process is writing to domain.cfg. This is nothing which should run forever as it produces permanent load. There is no guarantee that it will work, so check the file modification date, too. If it changes and this command didn't return anything, this simply does not work.
  14. The transcoding dir is only a temporary dir. The different resolutions of a movie generated through "Optimize" are located under the movie path itself. Depending on your selected storage location under "/Movies/Plex Versions" or "/Movies/Moviename (2020)/Plex Versions" Example: ls -l "/mnt/user/Movie/CD/Casino (1995)/Plex Versions/"*/* -rw-rw-rw- 1 nobody users 24512056092 Jan 7 2020 /mnt/user/Movie/CD/Casino\ (1995)/Plex\ Versions/Original\ Quality/Casino\ (1995).mp4 The content of the "/Transcode" folder looks completely different and contains only small temporary video files as long a transcoding is running: ls -l /tmp/plextranscode/Transcode/Sessions/plex-transcode-id123/ total 435752 -rw-r--r-- 1 nobody users 2499 Oct 14 15:21 chunk-stream0-00001.m4s -rw-r--r-- 1 nobody users 1034440 Oct 14 15:21 chunk-stream0-00002.m4s -rw-r--r-- 1 nobody users 2781109 Oct 14 15:21 chunk-stream0-00003.m4s -rw-r--r-- 1 nobody users 2486741 Oct 14 15:21 chunk-stream0-00004.m4s .... -rw-r--r-- 1 nobody users 24730 Oct 14 15:22 chunk-stream1-00244.m4s -rw-r--r-- 1 nobody users 27713 Oct 14 15:22 chunk-stream1-00245.m4s -rw-r--r-- 1 nobody users 27288 Oct 14 15:22 chunk-stream1-00246.m4s -rw-r--r-- 1 nobody users 28020 Oct 14 15:22 chunk-stream1-00247.m4s -rw-r--r-- 1 nobody users 27956 Oct 14 15:22 chunk-stream1-00248.m4s -rw-r--r-- 1 nobody users 30500 Oct 14 15:22 chunk-stream1-00249.m4s -rw-r--r-- 1 nobody users 31674 Oct 14 15:22 chunk-stream1-00250.m4s -rw-r--r-- 1 nobody users 0 Oct 14 15:22 chunk-stream1-00251.m4s.tmp -rw-r--r-- 1 nobody users 806 Oct 14 15:21 init-stream0.m4s -rw-r--r-- 1 nobody users 741 Oct 14 15:21 init-stream1.m4s -rw-r--r-- 1 nobody users 65 Oct 14 15:21 sub-chunk-00000 -rw-r--r-- 1 nobody users 76 Oct 14 15:21 sub-chunk-00001 -rw-r--r-- 1 nobody users 547 Oct 14 15:21 sub-header -rw-r--r-- 1 nobody users 1826 Oct 14 15:21 temp-0.srt But they are directly deleted, when you stop the movie: ls -l /tmp/plextranscode/Transcode/Sessions/plex-transcode-id123/ /bin/ls: cannot access '/tmp/plextranscode/Transcode/Sessions/plex-transcode-id123/': No such file or directory
  15. Someone in Reddit found out that a container, which is using HEALTHCHECK, causes displaying the word "healthy" in the Unraid > Docker Dashboard (Advanced View): This makes it much easier to find those containers.
  16. I'm still working on the preload feature. In the meantime this could be a good solution:
  17. This script automatically spins up all defined Disks to remove spin up latency on playback. It should be executed through CA User Scripts on array startup. This script is inspired by @MJFOx's version. But instead checking the Plex log file, which needs to enable Debugging, this script monitors the CPU load of the Plex container (which rises if a Plex Client has been started): #!/bin/bash # make script race condition safe if [[ -d "/tmp/${0///}" ]] || ! mkdir "/tmp/${0///}"; then exit 1; fi trap 'rmdir "/tmp/${0///}"' EXIT # ######### Settings ################## spinup_disks='1,2,3,4,5,6,7' # Note: Usually parity disks aren't needed for Plex cpu_threshold=1 # Disks spin up if Plex container's CPU load exceeds this value # ##################################### # # ######### Script #################### while true; do plex_cpu_load=$(docker stats --no-stream | grep -i plex | awk '{sub(/%/, "");print $3}') if awk 'BEGIN {exit !('$plex_cpu_load' > '$cpu_threshold')}'; then echo "Container's CPU load exceeded threshold" for i in ${spinup_disks//,/ }; do disk_status=$(mdcmd status | grep "rdevLastIO.${i}=" | cut -d '=' -f 2 | tr -d '\n') if [[ $disk_status == "0" ]]; then echo "Spin up disk ${i}" mdcmd spinup "$i" fi done fi done Explanation - it requests the containers CPU load every ~2 seconds (answer time of "docker stats") - if the load is higher than "cpu_treshold" (default is 1%) it checks the disks spinning status - all sleeping "spinup_disks" will be spun up Downside - as long a Movie is running, all (unused) disks won't reach their sleep state (they spin down, but will be directly spun up again) Monitoring If you like to monitor the CPU load while (not) using Plex to find an optimal threshold value (or just for fun ), open the WebTerminal and execute this (replace "1" against a threshold of your choice): while true; do plex_cpu_load=$(docker stats --no-stream | grep -i plex | awk '{sub(/%/, "");print $3}') echo $plex_cpu_load if awk 'BEGIN {exit !('$plex_cpu_load' > 1)}'; then echo "Container's CPU load exceeded threshold" fi done On my machine Plex idles between 0.1 and 0.5% CPU load, why I choosed 1% as the default threshold.
  18. I thought about it again. What do you think if we monitor the Plex Container CPU load instead? By that it would work without enabling debugging in Plex, which is needed by the above script. I disabled debugging to avoid permanent writes on my SSD. EDIT: I created a version which monitors the load:
  19. Yes, because "tail -F" monitors file changes, it will run forever. But I don't know if it could be killed somehow. Maybe it's better to set it to hourly and execute it atomic. I use this in my scripts: # make script race condition safe if [[ -d "/tmp/${0///}" ]] || ! mkdir "/tmp/${0///}"; then exit 1 fi trap 'rmdir "/tmp/${0///}"' EXIT Explanation: This generates a dir in the temp folder, which is deleted when the script is aborted. If the dir exists it aborts the execution (which prevents executing it twice). And I don't know if it would be a problem to spin up a drive, that is already spinning. Maybe we check the spin status first. I tried to find out which command returns such a status. The only one I found was this: mdcmd status 1 | grep rdevLastIO So the complete script would look like this: # make script race condition safe if [[ -d "/tmp/${0///}" ]] || ! mkdir "/tmp/${0///}"; then exit 1 fi trap 'rmdir "/tmp/${0///}"' EXIT # spin up drives on plex user login tail -F "/mnt/cache/appdata/plex/Library/Application Support/Plex Media Server/Logs/Plex Media Server.log" | \ while read line ; do echo "$line" | tail -n 1 -F | grep "authenticated user" if [ $? = 0 ]; then disk0_status=$(mdcmd status | grep "rdevLastIO.0=" | cut -d '=' -f 2 | tr -d '\n') if [[ $disk0_status == "0" ]]; then echo "Spin up disk 0" mdcmd spinup 0 fi disk1_status=$(mdcmd status | grep "rdevLastIO.1=" | cut -d '=' -f 2 | tr -d '\n') if [[ $disk1_status == "0" ]]; then echo "Spin up disk 1" mdcmd spinup 1 fi disk2_status=$(mdcmd status | grep "rdevLastIO.2=" | cut -d '=' -f 2 | tr -d '\n') if [[ $disk2_status == "0" ]]; then echo "Spin up disk 2" mdcmd spinup 2 fi fi done I removed sleep as even if two users log in, it won't spinup twice as it checks the spinning status first. P.S. If disk0 is your parity drive, you don't need to spin it up
  20. Don't do it. If you watch two 4K movies it will probably fully utilize your RAM. And some users said it will fill it also if the "optimize" feature is used or a permanent live TV is running. No, Plex deletes the oldest transcoding parts of a movie automatically (One movie is splitted in hundreds of parts while transcoded). Having an unlimited size means the full transcoded movie is inside the transcoding dir. If it's limited in size, Plex purges the dir and removes the oldest transcoding parts of the movie. So the disadvantage of this method is, that if you jump to the beginning of the movie, the server has to re-transcode the movie which causes depending on your transcoding performance some seconds wait time. Note: Nobody says that you need to set the transcoding ramdisk to 4GB. Use 20GB if you like, but never let Plex use the total RAM. This will probably result in a server/VM/docker crash. Example (Emby killed the RAM): https://forums.unraid.net/topic/97726-memory-usage-very-high/ PS Even a 500MB ramdisk should work. 4GB is the default because many people tested this value with multiple concurrent 4K transcodings. With 5 and more 4K transcodings I would suggest to raise the size to 6 or 8GB. But everything above this size is useless. Or do you permanently jump backwards through your movie? It's only a cap. So if you transcode nothing, it does not utilize your RAM.
  21. @sonic6 You have many requests because of a postgresql database. If you need it, there would be nothing you could optimize. But I would say these writes happen to often : MODIFY /var/lib/docker/containers/ced93fa7c199b90a5414e103be9871a25cae5b8e3fdaab059b1517e34ad0150f/ ced93fa7c199b90a5414e103be9871a25cae5b8e3fdaab059b1517e34ad0150f-json.log Check in your Container Dashboard for a container ID (advanced view) starting with "ced93fa7". Which docker is it? Does it have a logging setting which you could disable?
  22. Irgendwie will ich auch nicht, dass der externe Server ständig mit meinem verbunden ist. Mal abgesehen davon, dass ich dann auch wieder einen Port öffnen müsste oder gar eine beständige VPN Verbindung. Näääh ^^ Ja gibt es auch für die Fritz!Box, aber geht dann nicht autark. Also wenn ich das jetzt hier einrichte, dann kann ich die nicht irgendwo anders mit hinnehmen. Ich überlege aktuell noch, einen Selfmade IPMI in den Remote-Server zu bauen.
  23. Häh und wie startest du den Server bei einem Absturz neu?! Oder meinst du, wenn wenigstens SSH noch geht? Hätte mir bei meinem letzten Fall nicht geholfen. Der Remote-Backup-Server ging beim Neustart einfach nicht aus. Ich musste daher trotzdem hinfahren. Ich hatte sonst auch schon über einen RPI mit Real VNC Viewer nachgedacht, um von außen an den Server zu kommen, aber wenn der gar nicht mehr reagiert, nützt das halt auch nichts mehr. Eventuell RPI + smarte Steckdose und im BIOS auto power on. Das könnte gehen ^^ Die Firewall mit pfSense ist auch ein Selbstbau? Ich habe keine, da ich aktuell noch keinen Vorteil darin sehe. Alle eingehenden Ports sind in der Fritz!Box dicht und fertig ^^ Ausgehender Traffic interessiert mich nicht bzw ist mir bei IPv6 oder DNS over SSL eh zu anspruchsvoll. Ja das ist ziemlich cool. Von der Auslastung her war meine Lubuntu VM aber im Idle auch nicht anders. Allerdings beim Zugriff entsprechend hoch. Ist ja klar, weil der den Desktop streamen muss und keine GPU dabei hilft. Da ich aber keinen Desktop für den Remote-Backup-Server brauche, ist es mit Zerotier am sparsamsten. Debian merke ich mir aber, weil beim Backup mit Rsync ist das natürlich optimal, statt immer ganze VM Images sichern zu müssen. Hoch lebe Docker ^^ Der Remote-Backup-Server steht bei einem Freund. Auf dessen Router habe ich keinen Zugriff. Also weder VPN noch Portforwarding möglich. Daher hatte ich früher die Lubuntu VM mit Real VNC Viewer und jetzt eben Zerotier. Beide Varianten kommen dank Relay Service an dem Router vorbei und sind kostenlos.
  24. Yes, but why does Emby write those files only if you change the path of the docker.img. Where did Emby wrote those .ts files before you changed the path to "PlexRamScratch"? If you don't know it, use this command to find them: find / -path '/proc/*' -prune -o -path '/sys/*' -prune -o -path '/mnt/disk*/*' -prune -o -path '/mnt/user*/*' -prune -o -iname '*.ts' -print Me too. Works flawlessly. Did you use Krusader between your first and last memory check? Because at the beginning it had a low usage: 36.5742 MB krusader And now it reached 5GB. If you used it, maybe it caches files while transfers are running or similar. But if you didn't use it all, this sounds like a bug to me. P.S. You can limit the RAM usage through this extra docker parameter (advanced view): --memory=1G Ok, now things become clearer. My original tweak is only to change the plex config path to /mnt/cache and not the general docker.img path. This means you quoted my tweak in your "warning", but you even don't use it: https://forums.unraid.net/topic/88999-unraid-tweaks-for-media-server-performance/?tab=comments#comment-901831 Changing the general docker.img path is a different tweak, but I didn't even write a guide for this. I use it, but wasn't able to test it with multiple dockers. So its more a "beta" thing. Maybe Emby has a problem with that. If I find the time, I will test that. Can you send me a screenshot of your Emby settings so I can test this with the same settings? I have no experience if Emby is able to clean up the dir as Plex does it. I would suggest to add an additional ramdisk for Emby alone. The steps are the same (could be added to your existing script): mkdir /tmp/EmbyRamScratch chmod -R 777 /tmp/EmbyRamScratch mount -t tmpfs -o size=8g tmpfs /tmp/EmbyRamScratch Now set this path in your emby container as transcoding path. By that it would be also easier to disinguish between the container's ramdisk usage. No idea. Maybe you find the answer here: https://emby.media/community/index.php?/topic/54676-how-often-is-transcoding-temp-cleaned/ Correct. If you want to delete them without rebooting the server, use this command: rm -r /tmp/transcoding-temp If it does, then you could do that. But do not forget. If your SSD becomes full, Plex is not able to write any more data (will probably crash). Because of that I wrote in my guide, that it is useful to set a "Min. free space" in the Global Share Settings > Cache Settings, so caching through usual shares will not fill up your NVMe. Of course it does not influence the Plex usage. If Plex alone fully utilizes the NVMe, then you should leave it to /mnt/user or buy a bigger NVMe. Side note: I hope you set up a backup of your NVMe
×
×
  • Create New...