Jump to content

stefan.tomko

Members
  • Posts

    41
  • Joined

  • Last visited

Posts posted by stefan.tomko

  1. Thank you all for quick responses. I managed to find the issue - what was causing it, not the reason.

    It happened to me in the past when Unraid was not shut down cleanly, that my libvirt image would get corrupted. I tried backing it up daily in the past, but that did not help - when it got corrupted, regardless if I stopped VM, restored libvirt.img from backup, it just did not work. So instead i backed up xml for each VM (when you edit VM and switch to XML view, I copied the output). Seems something must have changed that caused device mappings to change. When I restored VM from XML, I had at least 2 USB devices listed that were "unknown". I did not attach any of them to VM in VM's settings, yet when I started VM restored from XML, it went nuts. So instead of doing that, I manually recreated all my VMs (I have some dependencies on various network cards, mac addresses, so it is bit of work). 

    Anyhow, other things got messed up too (this is outside of this topic, but maybe someone finds it useful). I was using macvlan for docker despite few changes recently that actually recommended to change back to ipvlan. I did not have issues with macvlan, and i had several reboots recently and everything just worked. Today, after this "catastrophy", I figured that docker to docker access does not work anymore either despite having all settings set to allow that. I had to change to ipvlan and it started to work. Can't explain why all of sudden today, it stopped liking it.

    Also, all of my dockers were listed as stopped, and i could not start any of them (something like "container not found" error on start). I had to force update everyone (except for those using host/bridge access) (or would need to delete docker.img and reinstall all apps from previous apps) and then it could be started.

    Maybe server got a huge "kick" today and started disliking lot of things. But I managed to get if up and running. Again, thank you all.

  2. OK this is strange, i have cleared all mappings from both patg and config.

     

    root@Tower:/tmp/usb_manager/config# ls
    remote_usbip.cfg  usb_manager.cfg  vm_mappings.cfg
    root@Tower:/tmp/usb_manager/config# more vm_mappings.cfg 
    
    ******** vm_mappings.cfg: Not a text file ********
    
    root@Tower:/tmp/usb_manager/config# 
    
    
    
    
    root@Tower:/boot/config/plugins/usb_manager# ls
    packages/  remote_usbip.cfg  usb_manager.cfg  v2  vm_mappings.cfg  vm_mappings.cfg.backup
    root@Tower:/boot/config/plugins/usb_manager# more vm_mappings.cfg
    
    ******** vm_mappings.cfg: Not a text file ********
    
    root@Tower:/boot/config/plugins/usb_manager# 

     

    As soon as i start array and VM gets started, unraid flash is passed to VM

     

    image.thumb.png.6d0c5519665c1b558da14b40c5e5a3c4.png

     

    I can't go to VM settings to check it, as it does not show up after array start.

    Any ideas how to get out of this loop?

  3. Is there a way to clear all mappings? I am having strange issue after I replaced one of array drives. When array is stopped and VM/Docker is not running, and I look at USB tab, all ports seem correct (eg. devices that are supposed to be passed to one VM are marked with that VM, and unraid flash drive is marked as unraid flash drive). But once I start VM service, unraid flash drive gets passed to the VM and I am done at that point, my only chance is to go and reboot and start over. I can't figure this out. I am getting typical "usb corrupted" message as soon as USB gets passed to the VM.

     

    edit: I tried renaming vm_mappings.cfg (or similar) under /boot/config/plugins and reinstalled USB manager plugin, then my historical mappings were gone, so I thought it would help, but as soon as I started VM service, 2 of my USB devices got mapped to VM automatically, unraid flash included.

  4. Right. But the problem I have is that all USB mappings under USB seem OK. However as soon as I start VM service, flash drive gets passed to the VM. And once that happens, I am unable to enter docker/vm settings. My only chance then is to reboot the server and start again from scratch.

  5. you are indeed right. I am using USB manager and for some reason, all devices are OK before i start they array (meaning my flash drive is marked as flash, cannot be passed on to VM). However as soon as I start the array, USB is passed to the VM. I tried removing USB manager plugin, but it keeps passing the flash drive regardless. Any ideas? I am not passing any USB to any device directly in the VM configuration.

  6. Hello. I have been using Unraid reliably until one of my array drives failed. I have replaced it today but after start of unraid and starting the array, I got a message that my USB is corrupted.

     

    image.png.6fc81dba7ab11d7c36326e92c7b918b3.png

     

    Files are readable on the USB, but when in unraid, I see nothing under /boot. So I have replaced USB drive temporarily, transferred license but I am still getting the same error. Basically when I reboot and array is stopped, all works, I can install license for new USB drive. However as soon as I start array, USB error pops up. With that, I cannot start docker (I assume it can't read proper config and if I configure it, point it to docker.img and apply, it is not saved). Similar goes for settings - VMs (it is blank after I start array).

    I am gonna try different USB too, but I feel like this is not USB issue. Any ideas? I tried switching USB port on server, but made no difference. Posting diagnostics as well.

    tower-diagnostics-20240430-1831.zip

  7. I am using "LAN to LAN access" and am routing local networks and peer networks on respective routers. Everything works between the networks. However,  when i originate connections from unraid itself to remote side, it would always use wg0 IP of unraid server and not eth0 IP. This is causing me some headaches on the remote end. Can I somehow force unraid to use eth0 IP (or br0 in this case) and just use wg0 for tunnelled communication?

  8. Seems like i found my issue - one of my cache drives in pool (Samsung 870 QVO) is having issues which results in very low and unstable read/write speeds. Initally I removed the pool and kept only Samsung as cache. Performance was ever worse. Then I changed cache drive to Apacer AS350 only, and it is flying now. It is still covered by warranty so I am going to submit it back to seller under warranty.

  9. I am starting to suspecting my cache or something around it. I downloaded diskspeed - not to test disks, just to compare how long does it take to install it. On my other server, it takes 26 seconds. On this one here, 2:30 (2 minutes, 30 seconds). While downloading is comparably fast, it is extracting that takes long. Also, while it is ongoing, I am unable to open unraid in other tab - it just loads, like it is busy.

    I would rule out pc/cpu etc. as this has been replaced. But disks are the same.

  10. I came here to seek for advice. I went through other threads on slow/sluggish performance, but I could not find anything useful. I was running Unraid on HP Proliant server with Sandisk USB flash drive, and it was slow especially when doing things such as downloading/updating dockers, where you would spend ages on the screen showing progress. Or when installing MariaDB for instance, initial run took like 5 minutes. Same with some other dockers (nextcloud). 

    I recently moved to new server (Intel® Core™ i5-14500, 64GB of RAM, disks stayed the same, but I have replaced my flash drive) hoping for improvement, but there is no difference. I maintain few other servers that are "worse" specs-wise, so I know this is not common thing. I would appreciate any suggestion.

    tower-diagnostics-20240304-1456.zip

  11. Is there anyone who is successfully using collabora code in a docker?

    I am on Nextcloud hub 6 (27.0.1) and latest Collabora Code docker. All my dockers are in br0, with IPs on the same subnet. I am using NGINX Proxy Manager.

    I have created proxy host for nextcloud.* that points to my nextcloud. I have created the same for office.* that points to https://IP_OF_COLLABORA:DOCKER port 9980 with websockets enabled, and even with some additional config I found on some sites:

     

    # static files
    location ^~ /browser {
      proxy_pass $forward_scheme://$server:$port;
      proxy_set_header Host $http_host;
    }
    # WOPI discovery URL
    location ^~ /hosting/discovery {
      proxy_pass $forward_scheme://$server:$port;
      proxy_set_header Host $http_host;
    }
    # main websocket
    location ~ ^/cool/(.*)/ws$ {
      proxy_set_header Upgrade $http_upgrade;
      proxy_set_header Connection "upgrade";
      proxy_http_version 1.1;
      proxy_pass $forward_scheme://$server:$port;
      proxy_set_header Host $http_host;
      proxy_read_timeout 36000s;
    }
    # download, presentation and image upload
    location ~ ^/cool {
      proxy_pass $forward_scheme://$server:$port;
      proxy_set_header Host $http_host;
    }
    # Admin Console websocket
    location ^~ /cool/adminws {
      proxy_set_header Upgrade $http_upgrade;
      proxy_set_header Connection "upgrade";
      proxy_http_version 1.1;
      proxy_pass $forward_scheme://$server:$port;
      proxy_set_header Host $http_host;
      proxy_read_timeout 36000s;
    }

     

    My dockers can talk to each other, and I pointed nextcloud to use https://office.* (without port, as port is handled by NPM) and nextcloud can connect to the collabora server.

    However when I create document and try to open it, it fails after maybe 10 seconds with:

     

    image.png.105ffa38463b00ced685ac4365db2ac1.png

     

    Honestly, I am not even sure which logs matter at this point. Here is latest what I see in collabora docker:

    wsd-00001-00047 2023-09-20 22:00:10.390097 +0200 [ docbroker_002 ] ERR  loading document exception: WOPI::CheckFileInfo failed: | wsd/DocumentBroker.cpp:2610
    wsd-00001-00047 2023-09-20 22:00:10.390111 +0200 [ docbroker_002 ] ERR  Failed to add session to [https%3A%2F%2Fnextcloud.*%3A443%2Findex.php%2Fapps%2Frichdocuments%2Fwopi%2Ffiles%2F871848_instanceid] with URI [https://nextcloud.*/index.php/apps/richdocuments/wopi/files/871848_instanceid?access_token=Q8BemIu9osHPNyQCq3ikA4xFXTQKncL7&access_token_ttl=0&permission=edit]: WOPI::CheckFileInfo failed: | wsd/DocumentBroker.cpp:2572
    wsd-00001-00047 2023-09-20 22:00:10.390120 +0200 [ docbroker_002 ] ERR  Storage error while starting session on https%3A%2F%2Fnextcloud.*%3A443%2Findex.php%2Fapps%2Frichdocuments%2Fwopi%2Ffiles%2F871848_instanceid for socket #18. Terminating connection. Error: WOPI::CheckFileInfo failed: | wsd/COOLWSD.cpp:5052
    wsd-00001-00047 2023-09-20 22:00:10.394410 +0200 [ docbroker_002 ] ERR  #24: Read failed, have 0 buffered bytes (ECONNRESET: Connection reset by peer)| net/Socket.hpp:1122
    wsd-00001-00047 2023-09-20 22:00:10.394428 +0200 [ docbroker_002 ] WRN  #24: Unassociated Kit (46) disconnected unexpectedly| wsd/COOLWSD.cpp:3491
    frk-00038-00038 2023-09-20 22:00:10.404696 +0200 [ forkit ] WRN  The systemplate directory [/opt/cool/systemplate] is read-only, and at least [/opt/cool/systemplate//etc/hosts] is out-of-date. Will have to copy sysTemplate to jails. To restore optimal performance, make sure the files in [/opt/cool/systemplate/etc] are up-to-date.| common/JailUtil.cpp:524
    sh: 1: /usr/bin/coolmount: Operation not permitted
    sh: 1: /usr/bin/coolmount: Operation not permitted
    sh: 1: /usr/bin/coolmount: Operation not permitted
    wsd-00001-00055 2023-09-20 22:00:10.563226 +0200 [ docbroker_003 ] WRN  #29: Failed to verify the certificate of [nextcloud.*]| net/SslSocket.hpp:252
    wsd-00001-00055 2023-09-20 22:00:10.563294 +0200 [ docbroker_003 ] ERR  WOPI::CheckFileInfo failed for URI [https://nextcloud.*/index.php/apps/richdocuments/wopi/files/871848_instanceid?access_token=Q8BemIu9osHPNyQCq3ikA4xFXTQKncL7&access_token_ttl=0&permission=edit]: 0 (Unknown) . Headers:        Body: []| wsd/Storage.cpp:708
    wsd-00001-00055 2023-09-20 22:00:10.563320 +0200 [ docbroker_003 ] ERR  loading document exception: WOPI::CheckFileInfo failed: | wsd/DocumentBroker.cpp:2610
    wsd-00001-00055 2023-09-20 22:00:10.563327 +0200 [ docbroker_003 ] ERR  Failed to add session to [https%3A%2F%2Fnextcloud.*%3A443%2Findex.php%2Fapps%2Frichdocuments%2Fwopi%2Ffiles%2F871848_instanceid] with URI [https://nextcloud.*/index.php/apps/richdocuments/wopi/files/871848_instanceid?access_token=Q8BemIu9osHPNyQCq3ikA4xFXTQKncL7&access_token_ttl=0&permission=edit]: WOPI::CheckFileInfo failed: | wsd/DocumentBroker.cpp:2572
    wsd-00001-00055 2023-09-20 22:00:10.563333 +0200 [ docbroker_003 ] ERR  Storage error while starting session on https%3A%2F%2Fnextcloud.*%3A443%2Findex.php%2Fapps%2Frichdocuments%2Fwopi%2Ffiles%2F871848_instanceid for socket #24. Terminating connection. Error: WOPI::CheckFileInfo failed: | wsd/COOLWSD.cpp:5052
    wsd-00001-00055 2023-09-20 22:00:10.567161 +0200 [ docbroker_003 ] ERR  #18: Read failed, have 0 buffered bytes (ECONNRESET: Connection reset by peer)| net/Socket.hpp:1122
    wsd-00001-00055 2023-09-20 22:00:10.567170 +0200 [ docbroker_003 ] WRN  #18: Unassociated Kit (54) disconnected unexpectedly| wsd/COOLWSD.cpp:3491
    frk-00038-00038 2023-09-20 22:00:10.576432 +0200 [ forkit ] WRN  The systemplate directory [/opt/cool/systemplate] is read-only, and at least [/opt/cool/systemplate//etc/hosts] is out-of-date. Will have to copy sysTemplate to jails. To restore optimal performance, make sure the files in [/opt/cool/systemplate/etc] are up-to-date.| common/JailUtil.cpp:524
    sh: 1: /usr/bin/coolmount: Operation not permitted
    sh: 1: /usr/bin/coolmount: Operation not permitted
    sh: 1: /usr/bin/coolmount: Operation not permitted

     

    When I open developer console in Chrome, I am getting this:

    image.png.6aa5898ed105fc868453a54bff79d9de.png

     

    Can anyone advise?

     

    // edit

    I was able to resolve my issue. Spaceinvader's video pointed me in the right direction.

    I use pihole and internally, for nextcloud.* I resolve local IP of my reverse proxy. Same for collabora (office.*). In nextcloud's docker, I use extra parameter to use pihole proxy (by default, servers on my server segment don't get pihole proxy) and that allows nextcloud to resolve locally collabora's IP. Since Spaceinvader mentioned that both collabora and nextcloud need to be able to resolve each other, I tried to add the same extra parameter to collabora's docker. Otherwise, if collabora was to resolve it, it would resolve public IP.

    And voila - it works now.

  12. On 2/12/2023 at 8:42 AM, SimonF said:

    Plugins do a re-install at each boot. But found the issue, /etc/libvirt will not be mounted at boot time so will not create qemu.d and at the hooks file. Will look to add the processing when VM manager is started.

    So this is still "an issue". From time to time (don't know why yet), when my server goes down unexpectedly, my libvirt image gets corrupted. I recreate it, but after that, I need to reinstall USB manager as devices no longer auto-attach after VM is started. Is there something that can be done about it?

  13. Well, I did not uninstall it nor installed it. It has been the same server running from the same USB drive. If it gets created only with plugin install, it would be normal to not re-create it. 

    But I was thinking - if it can't be recreated when plugin has something to auto-attach and it cannot do so, at least be notified that this is missing. I realize not many would have this issue like I did... but just in case. 

  14. Thanks @SimonF - I have uninstalled and installed plugin again. File above is created and I restarted to test it out - it works very well.

    I do remember now that few days after switching to new server, my libvirt image was corrupted and I had to delete it and create from scratch. Maybe that contributed to it. Anyway, would this be an opportunity for improvement in any way? 

    • Like 1
  15. Output here:

    Quote

    root@Tower:~# ls /etc/libvirt/hooks/

    qemu*
    root@Tower:~# ls /etc/libvirt/hooks/qemu.d/

    /bin/ls: cannot access '/etc/libvirt/hooks/qemu.d/': No such file or directory

    I have not tried uninstalling and installing USB manager. I will give that a try.

  16. I changed server equipment. However on first boot, I would understand that mappings may change, so on first boot ever after changing motherboard, RAM, etc, I adjusted mappings.

    But now, every time I reboot server (whether it is planned or unplanned) reboot, it just boots and devices do not get attached. As a result, VM starts without it and Zigbee does not start because of missing adapter, Zwave is started but reporting missing adapter. Ocasionally, bluetooth fails as well until I attach them all. I had 3 reboots since the change, and all have the same symptoms.

  17. It is home assistant OS (VM), unraid 6.11.5

     

    Quote

    Feb 11 13:24:28 Tower root: plugin: installing: usb_manager.plg
    Feb 11 13:24:28 Tower root: plugin: checking: /boot/config/plugins/usb_manager/packages/usb_manager-2022.08.20.txz - MD5
    Feb 11 13:24:28 Tower root: plugin: skipping: /boot/config/plugins/usb_manager/packages/usb_manager-2022.08.20.txz already exists
    Feb 11 13:24:28 Tower root: plugin: running: /boot/config/plugins/usb_manager/packages/usb_manager-2022.08.20.txz
    Feb 11 13:24:28 Tower root: | Installing new package /boot/config/plugins/usb_manager/packages/usb_manager-2022.08.20.txz
    Feb 11 13:24:28 Tower root: Verifying package usb_manager-2022.08.20.txz.
    Feb 11 13:24:28 Tower root: Installing package usb_manager-2022.08.20.txz:
    Feb 11 13:24:28 Tower root: Package usb_manager-2022.08.20.txz installed.
    Feb 11 13:24:28 Tower root: | Skipping package usb_manager-2022.08.20 (already installed)
    Feb 11 13:24:28 Tower root: plugin: creating: /tmp/start_usb_manager - from INLINE content
    Feb 11 13:24:28 Tower root: plugin: setting: /tmp/start_usb_manager - mode to 0770
    Feb 11 13:24:28 Tower root: plugin: skipping: /boot/config/plugins/usb_manager/usb_manager.cfg already exists
    Feb 11 13:24:28 Tower root: plugin: skipping: /boot/config/plugins/usb_manager/remote_usbip.cfg already exists
    Feb 11 13:24:28 Tower root: plugin: skipping: /boot/config/plugins/usb_manager/vm_mappings.cfg already exists
    Feb 11 13:24:29 Tower root:  usb_manager has been installed.
    Feb 11 13:24:30 Tower root: plugin: usb_manager.plg installed
    Feb 11 13:24:30 Tower root: plugin: usb_manager.plg installed
    Feb 11 13:24:33 Tower usb_manager: Info: rc.usb_manager Building Connected Status
    Feb 11 13:24:55 Tower usb_manager: Info: rc.usb_manager Reset Connected Status
    Feb 11 13:25:23 Tower usb_manager: Starting usbip config check...
    Feb 11 13:25:53 Tower usb_manager: Info: rc.usb_manager usb_remove  dresden_elektronik_ingenieurtechnik_GmbH_ConBee_II_DE2450313 /dev/bus/usb/001/006 001 006
    Feb 11 13:25:53 Tower usb_manager: Info: rc.usb_manager Device Match 001/006 vm:   001 006
    Feb 11 13:25:53 Tower usb_manager: Info: rc.usb_manager Removed 001/006 vm:  nostate 001 006
    Feb 11 13:25:54 Tower usb_manager: Info: rc.usb_manager usb_add dresden_elektronik_ingenieurtechnik_GmbH_ConBee_II_DE2450313 /dev/bus/usb/001/010 001 010
    Feb 11 13:25:54 Tower usb_manager: Info: rc.usb_manager Add device with more than one interface & connect serial yes  .
    Feb 11 13:25:54 Tower usb_manager: Info: rc.usb_manager unable to connect device as Serial device details unknown for dresden_elektronik_ingenieurtechnik_GmbH_ConBee_II_DE2450313.
    Feb 11 13:25:54 Tower usb_manager: Info: rc.usb_manager tty_add dresden_elektronik_ingenieurtechnik_GmbH_ConBee_II_DE2450313 /dev/ttyACM1
    Feb 11 13:25:54 Tower usb_manager: Info: rc.usb_manager Processing tty attach dresden_elektronik_ingenieurtechnik_GmbH_ConBee_II_DE2450313 /dev/ttyACM1 001 010
    Feb 11 13:25:54 Tower usb_manager: Info: rc.usb_manager Add device with more than one interface & connect serial yes 1 1.
    Feb 11 13:25:54 Tower usb_manager: Info: rc.usb_manager Autoconnect vm state:running dresden_elektronik_ingenieurtechnik_GmbH_ConBee_II_DE2450313 running 001 010
    Feb 11 13:25:54 Tower usb_manager: Info: connect as serial guest port is:04
    Feb 11 13:25:54 Tower usb_manager: Info: virsh called Home Assistant 001 010 Device attached successfully
    Feb 11 13:25:58 Tower usb_manager: Info: rc.usb_manager usb_remove  dresden_elektronik_ingenieurtechnik_GmbH_ConBee_II_DE2450313 /dev/bus/usb/001/010 001 010
    Feb 11 13:25:58 Tower usb_manager: Info: rc.usb_manager Device Match 001/010 vm: Home Assistant  001 010
    Feb 11 13:25:58 Tower usb_manager: Info: connect as serial guest port is:04
    Feb 11 13:25:58 Tower usb_manager: Info: virsh called Home Assistant 001 010 Device detach request sent successfully
    Feb 11 13:25:58 Tower usb_manager: Info: rc.usb_manager Disconnect  001/010 vm: Home Assistant running 001 010
    Feb 11 13:25:58 Tower usb_manager: Info: rc.usb_manager Removed 001/010 vm: Home Assistant running 001 010
    Feb 11 13:25:58 Tower usb_manager: Info: rc.usb_manager usb_add dresden_elektronik_ingenieurtechnik_GmbH_ConBee_II_DE2450313 /dev/bus/usb/001/011 001 011
    Feb 11 13:25:58 Tower usb_manager: Info: rc.usb_manager Add device with more than one interface & connect serial yes  .
    Feb 11 13:25:58 Tower usb_manager: Info: rc.usb_manager unable to connect device as Serial device details unknown for dresden_elektronik_ingenieurtechnik_GmbH_ConBee_II_DE2450313.
    Feb 11 13:25:58 Tower usb_manager: Info: rc.usb_manager tty_add dresden_elektronik_ingenieurtechnik_GmbH_ConBee_II_DE2450313 /dev/ttyACM1
    Feb 11 13:25:58 Tower usb_manager: Info: rc.usb_manager Processing tty attach dresden_elektronik_ingenieurtechnik_GmbH_ConBee_II_DE2450313 /dev/ttyACM1 001 011
    Feb 11 13:25:58 Tower usb_manager: Info: rc.usb_manager Add device with more than one interface & connect serial yes 1 1.
    Feb 11 13:25:58 Tower usb_manager: Info: rc.usb_manager Autoconnect vm state:running dresden_elektronik_ingenieurtechnik_GmbH_ConBee_II_DE2450313 running 001 011
    Feb 11 13:25:58 Tower usb_manager: Info: connect as serial guest port is:04
    Feb 11 13:25:58 Tower usb_manager: Info: virsh called Home Assistant 001 011 Device attached successfully
    Feb 11 13:26:40 Tower usb_manager: Info: virsh called Home Assistant 001 005 Device attached successfully
    Feb 11 13:26:42 Tower usb_manager: Info: virsh called Home Assistant 001 004 Device attached successfully

     

  18. I have recently changed server and started to notice issues with auto-connecting USB devices to VM.

    I pass 3 devices to one of my VMs - Zigbee controller (passed as serial device), Zwave controller (passed as device) and bluetooth. They are all configured to auto connect to my VM, but that is not happening. If I reboot, at least 2 show that they are not attached and I have to click the button to attach it. 

    How can I figure out why is this happening?

×
×
  • Create New...