Posts by Morphy

    EDIT: fixed this, the script wasn't in unix format!

    I'm struggling with this script, probably something simple but this is what I have:

    I get this error when running:

    Code
    autoconnectwifi.sh: line 26: syntax error: unexpected "done" (expecting "then")

    So after figuring my stupid mistake I found this other script and adapted it. This uses the wifi network instead of a ping, maybe better if for some reason the IP will change or unavailable. wifi_servicecode_managed_psk has been changed from what is listed in connmanctl services

    Bash
    #!/bin/bash
    
    while true ; do
        if ifconfig wlan0 | grep -q "inet addr:" ; then
            sleep 60
        else
            connmanctl connect wifi_servicecode_managed_psk &>/dev/null
            sleep 10
        fi
    done

    I guess this never got added to the wiki :( This line needs to be changed for other chips:

    3b. Edit /flash/config.txt and add (somewhere near the end): dtoverlay=i2c-rtc,ds3231

    with

    Code
    dtoverlay=i2c-rtc,ds1307

    or

    Code
    dtoverlay=i2c-rtc,pcf8523

    Also, I'm not sure if this step is necessary:

    4. Adjust the RTC's time:

    4a. Verify local system time with the 'date' command. If local time is off, either adjust it manually or connect your Pi to the Internet and wait for it to the the correct time from an NNTP server.

    4b. Transfer local time to RTC: hwclock -w

    4c. Verify RTC time: hwclock -r

    I've just added a used ds1307 rtc and the date from hwclock -r was UTC, I'm on GMT, so an hour behind. Doing hwclock -w and then rebooting with no network resulted in it being an hour ahead for some reason! It's now sorted itself out though and keeps the correct time after losing power and no network.

    Now I just need to figure out a script to keep trying to reconnect the wifi if it's unavailable after power loss. Then my pi might just get itself back ship shape after a rare power cut!

    I've managed to achieve this on rpi 4 by adding the above to cmdline.txt in /flash so it looks like this:

    Code
    boot=UUID=xxxx-xxxx morequiet disk=UUID=xxxxxxxx-xxxxx-xxxx-xxxxxxx quiet systemd.show_status=0

    It works fine apart from I'm still seeing "waiting for network...." even though this option is disabled in LE settings. Enabling it just results in another line with the same. Any idea how I can suppress this as well?

    I'm having a very intermittent issue with the onboard wifi adapter crashing on my RPi4 after some time (days or hours) of being connected and online. The connection will appear up in LE settings however I can't ping the device at all. Enabling and disabling the wifi does nothing, only a reboot works.

    I've had a look in the log and can't see anything related and am hesitant to turn on debug logging as this could happen hours or days after a boot and the log file would be huge. Here's a few things I've tried after getting onto it via a cable:

    dmesg

    Code
    connmanctl scan wifi
    Error /net/connman/technology/wifi: No carrier
    Code
    iwconfig wlan0
    wlan0     IEEE 802.11  ESSID:off/any
              Mode:Managed  Access Point: Not-Associated
              Retry short limit:7   RTS thr:off   Fragment thr:off
              Encryption key:off
              Power Management:off

    Is there anything else I can try looking at before I get a debug log?

    I updated to this build and it seems to work ok apart from Kodi will relaunch when I'm in ES or playing a game in Retroarch. Any idea why this is happening. RPi3 build.

    emby4.start

    Code
    ERROR: ld.so: object '/storage/.kodi/addons/service.emby4/lib/libMagickCore-7.Q16HDRI.so.6' from LD_PRELOAD cannot be preloaded (cannot open shared object file): ignored.
    ERROR: ld.so: object '/storage/.kodi/addons/service.emby4/lib/libMagickCore-7.Q16HDRI.so.6' from LD_PRELOAD cannot be preloaded (cannot open shared object file): ignored.
    ERROR: ld.so: object '/storage/.kodi/addons/service.emby4/lib/libMagickCore-7.Q16HDRI.so.6' from LD_PRELOAD cannot be preloaded (cannot open shared object file): ignored.
    ERROR: ld.so: object '/storage/.kodi/addons/service.emby4/lib/libMagickCore-7.Q16HDRI.so.6' from LD_PRELOAD cannot be preloaded (cannot open shared object file): ignored.
    cat: error while loading shared libraries: libMagickCore-7.Q16HDRI.so.7: cannot open shared object file: No such file or directory
    /storage/.kodi/addons/tools.dotnet-runtime/bin/le_dotnet: line 8: dotnet: not found

    Hi awiouy thanks for getting back to me. I have updated all addons so I'm assuming dotnet is up to date. Output of journalctl -u service.emby4 is blank. I'll try refreshing the repo's see if it's missing an update.

    systemctl status service.emby4.service reports:

    Just seen an old thread re emby and this command might help? ldd $(which dotnet):

    Code
            linux-vdso.so.1 (0x00007ffe41508000)
            libstdc++.so.6 => /usr/lib/libstdc++.so.6 (0x00007febe8c4c000)
            libgcc_s.so.1 => /usr/lib/libgcc_s.so.1 (0x00007febe8c32000)
            libc.musl-x86_64.so.1 => not found
            libm.so.6 => /usr/lib/libm.so.6 (0x00007febe8af2000)
            libc.so.6 => /usr/lib/libc.so.6 (0x00007febe893c000)
            /lib/ld-musl-x86_64.so.1 => /usr/lib64/ld-linux-x86-64.so.2 (0x00007febe8fe6000)

    I've just tried this on my LE generic system and it seems to update ok according to the script output but the service won't start:

    Code
    # /storage/.kodi/addons/service.emby4/bin/emby-update 4.5.0.6
    1. stopping Emby service
    2. download Emby version 4.5.0.6
    ######################################################################### 100.0%######################################################################### 100.0%
    3. removing old install
    4. extracting Emby
    5. restarting Emby service
    ... done

    systemctl status service.emby4.service :

    Journal-cur.log shows:

    Has anyone tried updating with this script to 4.5.0.6 or 4.4.2 (tried both)?

    Sorry to resurrect an old thread but this is the first result that comes up. I've got a m2 SSD connected via usb3 adapter (don't ask) and I've just written the latest image to it only to be confronted with the boot menu which requires a keyboard. Surely there should be an option in this to make it live for every boot? I've got to find a Usb stick and write the image again off an Ubuntu live boot usb now...

    It depends on profile settings but afaik addons get installed for all users but they're disabled in other profiles. It's just the userdata folder which is unique.

    I think what's happening is on logoff the VPN isn't being disconnected and when the other user logs on the check detects it as still connected so it doesn't reconnect. I'm not sure if it is still connected to the VPN or not but emby doesn't connect to my server. It's Https and over WAN so maybe it's something to do with that.

    I've got around it for now so it's not too much of a problem for me. I just set a different default VPN location on each user so it will force reconnect on logon with each Kodi user.

    Has this been tested with multiple Kodi user profiles? The reason I ask is I'm having a problem with this and with Emby for kodi client. When I flip from the master profile which has been connected to a VPN to another user, trying to play any emby library files result in Kodi freezing for a few minutes and not playing the file. There are a lot of "CCurlFile::Stat - Failed: Timeout was reached" in the logs. I've noticed if I disconnect the VPN in the other user and then try Emby this works again. Also using another connection makes it work again too. It's not losing connectivity as other addons like YouTube stream fine.