Posts by extremeaudio


    I thought in your first post you said docker containers were working, you just weren't deleting old containers. What exactly is the problem?

    I'm trying to get the linuxserver docker addons working but though I can see them as installed and enabled, I can't access the web interface of any of the installed dockers. The output of the commands as suggested by you are at this post

    thread-4062-post-30130.html#pid30130

    Nope, tried. It doesn't work from autostart. But the same command issued from command line works. That means the syntax of the command or the formatting in autostart.sh is somehow wrong. Maybe it needs to be preceded by an "exec" or maybe some delay. I have no idea. If you do please advise.

    Hmm. In command line can you try the following commands and check their output?

    docker ps -a

    docker images

    systemctl status docker.linuxserver.portainer

    The first 2 results were

    CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES

    and

    REPOSITORY TAG IMAGE ID CREATED SIZE


    and the last one gave the following output (couldn't grab everything). In My Addons > Services I can see both plex and portainer as enabled.


    The file created is "autostart.sh" not ".conf".
    Doing the commands below should create that file automatically.

    Code
    echo "#!/bin/sh" > /storage/.config/autostart.sh
    
    
    echo "xrandr --output HDMI2 --mode 1920x1080 --rate 50.00" >> /storage/.config/autostart.sh

    I don't see "1280x720@50p" in the output you posted, can you copy the output of "xrandr".

    Apologies, I meant autostart.sh. Wrote .conf by mistake.

    xrandr output as below:


    To get rid of useless containers:

    1. Before you run the container, delete existing containers with the "docker rm ..." command.

    2. When you run the container, use the "docker run --rm ..." command, to delete the container when it is stopped.

    These commands are documented on the Docker web site.

    In my experience, solution 2 will not delete the running container if Docker exits abnormally. Solution 1 takes care of that case.

    I am testing with docker run --rm appended to the command for now

    To see whats going on I have also switched on all notifications for the docker add on.

    I can endlessly see notifications on the screen that go:

    docker name: abc | action: create
    docker name: def | action: destroy
    docker name: ghi | action: create
    docker name: abc | action: destroy
    docker name: jkl | action: create
    docker name: ghi | action: destroy

    So it keeps creating and destroying these images.

    As of now it doesnt seem to be hogging too much space.

    Issuing docker ps -a also shows that at any point of time there arent more than 2 or 3 images in the list unlike the hundreds earlier.

    Prima facie, even the storage space occupied doesn't seem to be on the upswing.

    Does everything seem normal?

    issuing the command

    xrandr --output HDMI2 --mode 1920x1080 --rate 50.00

    does the job

    but adding the lines to autostart.conf doesnt do it at startup.

    Reading further, I created a xorg.conf file with the contents as below:


    This changes the resolution to 1920x1080@50Hz

    But if I change the mode line to some other supported resolution as seen in the output of xandr, like 1280x720@50p or even 1920x1080@30p it is not working. Only worked for 1920x1080@60p and 50p (didnt test many other than the examples cited here)

    The first 2 results were

    CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES

    and

    REPOSITORY TAG IMAGE ID CREATED SIZE


    and the last one gave the following output (couldn't grab everything). In My Addons > Services I can see both plex and portainer as enabled.

    You can also install docker addons from the linuxserver repo (plex is there). You can find the repo under libreelec addons / repositories.

    One you install, just modify the addon settings and that's it.

    There is also a docker gui manager in that repo called portainer. It lets you manage the containers and images through a web interface

    EDIT: by the way, the issue with your current method of starting plex is that it's creating a new container every time you start it, but it doesn't delete any of the old containers. So you end up with a ton of duplicates taking lots of space. You can use portainer to delete all of those and start fresh. The plex addon in the linuxserver repo manages all of that for you automatically


    Sounds very interesting. However I stumbled at the first step itself. I wish docker instructions were easier :(

    From command line, I issue:

    docker create \
    --name=plex \
    --net=host \
    -e VERSION=latest \
    -e PUID=0 -e PGID=0 \
    -e TZ=Asia/Kolkata \
    -v /storage/.kodi/userdata/.apps/plex:/config \
    -v /var/media/Data:/data \
    linuxserver/plex

    However I cannot open <my-ip-address>:32400/manage or <my-ip-address>:32400/web

    Secondly, portainer uses port 9000 which my Logitech media server also does. How do I change one of the two? I deploy portainer by using
    docker run -d -p 9000:9000 portainer/portainer

    If I change the port to 9001 or something, it doesnt work.

    I am having trouble with an av receiver and I do not get any display at all unless I reboot several times. I want to lock down the video resolution to 1080p@50Hz

    I am not sure about the exact change to be made in the xorg.conf file. I have edited as below but am not able to get it to work. Please help. I am using an Intel board.


    To get rid of useless containers:

    1. Before you run the container, delete existing containers with the "docker rm ..." command.

    2. When you run the container, use the "docker run --rm ..." command, to delete the container when it is stopped.

    These commands are documented on the Docker web site.

    In my experience, solution 2 will not delete the running container if Docker exits abnormally. Solution 1 takes care of that case.

    Do you mean I need to add the docker rm lines to the plex.service service file o created?

    Firstly, pardon my ignorance. I am unfamiliar with docker syntax.

    Following the good suggestions of fellow posters on this forum I have been able to get 2 containers up and running.

    But they are slowly and surely increasing in size, and by giant amounts without any addition of any new data. Mere reboots expand the occupied space. It is also taking its toll on my LE startup time. It runs into 5-6 minutes after 15-20 reboots.

    Someone suggested that cleaning up containers not in use might help and sure enough it does free up a lot of space.

    So why am I having so many unused containers piling up after a period of time?

    So there seem to be 2 possible solutions :

    1. seems like I have setup something wrong to begin with which causes so many redundant images to pile up or

    2. schedule the clean up command (at every reboot?)


    Can someone please help with this?
    [hr]
    Below is how I have setup docker, in case anyone can identify some flaw

    Plex, in the example below:


    1. from command I type the following lines:

    mkdir -p /storage/.kodi/userdata/.apps/plex
    chmod -R a+rwx /storage/.kodi/userdata/.apps/plex

    # docker run --net=host -d \
    -p 32400:32400 \
    -v /storage/.kodi/userdata/.apps/plex:/config \
    -v /var/media/Data:/data \
    timhaak/plex

    This starts the app. But if I reboot it does not restart.

    So I was told that ....

    2. create a service in a folder called system.d , for instance plex.service. Contents of the service file as follows:

    [Unit]
    Description=plex container
    Requires=service.system.docker.service
    After=service.system.docker.service

    [Service]
    Restart=always
    RestartSec=10s
    TimeoutStartSec=0
    ExecStartPre=-/bin/sh -c "mkdir -p /storage/.kodi/userdata/.apps/plex"
    ExecStart=/storage/.kodi/addons/service.system.docker/bin/docker run --net=host -d \
    -p 32400:32400 \
    -v /storage/.kodi/userdata/.apps/plex:/config \
    -v /var/media/Data:/data \
    timhaak/plex
    ExecStop=/storage/.kodi/addons/service.system.docker/bin/docker stop plex
    [Install]
    WantedBy=multi-user.target


    3. Thereafter, at console

    systemctl enable plex.service
    systemctl start plex.service
    journalctl -u plex.service

    It seems like every startup attempt is fetching a new container image


    docker ps - a gives a huge output. Please see below. And this is only part of the output, I could not copy all the way back to where I issued the command.

    Issuing docker rm `docker ps -aq -f status=exited` clears up a lot of space. What changes do I need to make to prevent this unnecessary space usage?

    Everytime I restart the LE box my storage partition fills up by 5MB. Below is my lms.service Anything amiss here?

    EDIT: Actually that was an incorrect observation, the storage size at shutdown is lets say 1000 MB, after restart it increases to 1030 MB or so and then reduces back to 1000 MB or so. Hope thats normal.