<?xml version="1.0" encoding="utf-8" ?>

<rss version="2.0" 
   xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
   xmlns:admin="http://webns.net/mvcb/"
   xmlns:dc="http://purl.org/dc/elements/1.1/"
   xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
   xmlns:wfw="http://wellformedweb.org/CommentAPI/"
   xmlns:content="http://purl.org/rss/1.0/modules/content/"
   >
<channel>
    
    <title>Raymond P. Burkholder - Things I Do - Linux</title>
    <link>https://blog.raymond.burkholder.net/</link>
    <description>In And Around Technology and The Arts</description>
    <dc:language>en</dc:language>
    <generator>Serendipity 1.7.2 - http://www.s9y.org/</generator>
    <pubDate>Thu, 23 Jul 2026 14:59:23 GMT</pubDate>

    <image>
        <url>https://blog.raymond.burkholder.net/templates/bulletproof/img/s9y_banner_small.png</url>
        <title>RSS: Raymond P. Burkholder - Things I Do - Linux - In And Around Technology and The Arts</title>
        <link>https://blog.raymond.burkholder.net/</link>
        <width>100</width>
        <height>21</height>
    </image>

<item>
    <title>NUT USB APC BeagleBone</title>
    <link>https://blog.raymond.burkholder.net/index.php?/archives/1360-NUT-USB-APC-BeagleBone.html</link>
            <category>Debian</category>
    
    <comments>https://blog.raymond.burkholder.net/index.php?/archives/1360-NUT-USB-APC-BeagleBone.html#comments</comments>
    <wfw:comment>https://blog.raymond.burkholder.net/wfwcomment.php?cid=1360</wfw:comment>

    <slash:comments>0</slash:comments>
    <wfw:commentRss>https://blog.raymond.burkholder.net/rss.php?version=2.0&amp;type=comments&amp;cid=1360</wfw:commentRss>
    

    <author>nospam@example.com (Raymond P. Burkholder)</author>
    <content:encoded>
    &lt;p&gt;I have an APC Smart UPS 1500 connected via USB cable to a BeagleBone Green running NUT 2.8.1-5 on Linux 6.18.36-bone40.  Even on earlier Linux kernels and versions of NUT, during some sort of UPS transition, I would start to get a log full of the these error messages:

&lt;blockquote&gt;&lt;pre&gt;
usbhid-ups: nut_libusb_get_report: No such device (it may have been disconnected)
&lt;/pre&gt;&lt;/blockquote&gt;

&lt;p&gt;In detail:

&lt;blockquote&gt;&lt;pre&gt;
kernel: musb-hdrc musb-hdrc.1: Babble
kernel: usb 1-1: USB disconnect, device number 15
kernel: usb 1-1.4: USB disconnect, device number 16
kernel: usb 1-1: new high-speed USB device number 17 using musb-hdrc
kernel: usb 1-1: New USB device found, idVendor=1a40, idProduct=0201, bcdDevice= 1.00
kernel: usb 1-1: New USB device strings: Mfr=0, Product=1, SerialNumber=0
kernel: usb 1-1: Product: USB 2.0 Hub [MTT]
kernel: hub 1-1:1.0: USB hub found
kernel: hub 1-1:1.0: 7 ports detected
kernel: usb 1-1.4: new full-speed USB device number 18 using musb-hdrc
kernel: usb 1-1.4: New USB device found, idVendor=051d, idProduct=0003, bcdDevice= 0.01
kernel: usb 1-1.4: New USB device strings: Mfr=1, Product=2, SerialNumber=3
kernel: usb 1-1.4: Product: Smart-UPS_1500 FW:UPS 06.0 / ID=1028
kernel: usb 1-1.4: Manufacturer: American Power Conversion
kernel: usb 1-1.4: SerialNumber: unique_number
kernel: hid-generic 0003:051D:0003.0008: hiddev0,hidraw0: USB HID v1.11 Device [American Power Conversion  Smart-UPS_1500 FW:UPS 06.0 / ID=1028] on usb-musb-hdrc.1-1.4/input0
usbhid-ups[31894]: nut_libusb_get_report: No such device (it may have been disconnected)
usbhid-ups[31894]: nut_libusb_get_report: No such device (it may have been disconnected)
&lt;/pre&gt;&lt;/blockquote&gt;

&lt;p&gt;For some reason, USB devices &#039;disconnect&#039; and reconnect.  When the device reconnects, a new DeviceID is assigned to the USB device.  This breaks the usbhid-ups drivers supplied by NUT the packages.  That is, usbhid-ups no longer sees the APC USB device.

&lt;p&gt;One forum article suggested that there is not enough power in the BeagleBone system to propery power a USB connection.  The suggested solution is to add a powered USB hub.  I gave that a try with no success in eliminating the problem.

&lt;p&gt; To resolve this, I&#039;m not sure if recent versions of the driver fix this, but I used Debian&#039;s udev system to sense the device id change and to restart the NUT USB driver.

&lt;p&gt;In /home/debian, which is the default home directory, I created two files and ran &#039;chmod +x&#039; on each to make them executable.  When a USB &#039;ADD&#039; state is detected, nut.target is restarted to initiate the detection and connection process.  When a removal is detected, the service is stopped.  The stop does not seem to be reliable, but the restart appears to be reliable enough to get things started again.

&lt;blockquote&gt;&lt;pre&gt;
$ cat usb_add.sh
#!/usr/bin/env bash

logger &quot;USB state change detected: $1 $2 $3&quot;
echo &quot;$(date) USB state change detected: $1 $2 $3&quot; &gt;&gt; /home/debian/usb-log.txt
systemctl restart nut.target
exit 0
&lt;/pre&gt;&lt;/blockquote&gt;

&lt;blockquote&gt;&lt;pre&gt;
$ cat usb_remove.sh
#!/usr/bin/env bash

logger &quot;USB state change detected: $1 $2&quot;
echo &quot;$(date) USB state change detected: $1 $2&quot; &gt;&gt; /home/debian/usb-log.txt
#systemctl stop nut.target
exit 0
&lt;/pre&gt;&lt;/blockquote&gt;

&lt;p&gt;To determine useful attributes I used the following (the first is a shorter result than the second):

&lt;blockquote&gt;&lt;pre&gt;
udevadm info --name=/dev/bus/usb/001/017 
udevadm info --name=/dev/bus/usb/001/017 --attribute-walk
&lt;/pre&gt;&lt;/blockquote&gt;

&lt;p&gt;The rule which invokes these scripts is:

&lt;blockquote&gt;&lt;pre&gt;
# cat  /etc/udev/rules.d/89-usb-ups-change.rules
SUBSYSTEM==&quot;usb&quot;, MODE=&quot;0660&quot;, ACTION==&quot;add&quot;,    ENV{ID_VENDOR_ID}==&quot;051d&quot;, ENV{ID_MODEL_ID}==&quot;0003&quot;, RUN+=&quot;/home/debian/usb_add.sh add &#039;$env{DEVNAME}&#039; &#039;$env{ID_USB_SERIAL}&#039;&quot;
SUBSYSTEM==&quot;usb&quot;, MODE=&quot;0660&quot;, ACTION==&quot;remove&quot;, RUN+=&quot;/home/debian/usb_remove.sh remove $env{DEVNAME}&quot;
&lt;/pre&gt;&lt;/blockquote&gt;

&lt;p&gt;These command variations were suggested to simulate a cable re-connect but did not reliably work.  I resorted to physically disconnecting and reconnecting the cable to perform a proper test for tuning and production (using the major:minor usb device manufacturer code):

&lt;blockquote&gt;&lt;pre&gt;
# major:minor usb device manufacturer code
usbreset 051d:0003
# dev bus id
udevadm test /dev/bus/usb/001/007
&lt;/pre&gt;&lt;/blockquote&gt;

&lt;p&gt;Each rule change test required the following to reload the udev rules:

&lt;blockquote&gt;&lt;pre&gt;
udevadm control --reload-rules
&lt;/pre&gt;&lt;/blockquote&gt;

&lt;p&gt;To see what Nut sees:

&lt;blockquote&gt;&lt;pre&gt;
# nut-scanner -U
Scanning USB bus.
[nutdev1]
        driver = &quot;apc_modbus&quot;
        port = &quot;auto&quot;
        vendorid = &quot;051D&quot;
        productid = &quot;0003&quot;
        product = &quot;Smart-UPS_1500 FW:UPS 06.0 / ID=1028&quot;
        serial = &quot;unique id&quot;
        vendor = &quot;American Power Conversion&quot;
        bus = &quot;001&quot;
        device = &quot;017&quot;
        busport = &quot;002&quot;
        ###NOTMATCHED-YET###bcdDevice = &quot;0001&quot;
&lt;/pre&gt;&lt;/blockquote&gt;

&lt;p&gt;A linux command provides a concise device and manufacturer id:

&lt;blockquote&gt;&lt;pre&gt;
# lsusb
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 001 Device 016: ID 050d:0234 Belkin Components F5U234 USB 2.0 4-Port Hub
Bus 001 Device 017: ID 051d:0003 American Power Conversion UPS
&lt;/pre&gt;&lt;/blockquote&gt;

&lt;p&gt;Other troubleshooting commands include:

&lt;blockquote&gt;&lt;pre&gt;
udevadm monitor
&lt;/pre&gt;&lt;blockquote&gt;

&lt;p&gt;This solution for those who might encounter &lt;a href=&quot;https://github.com/networkupstools/nut/issues/3385&quot; target=_blank&gt;Update 2.7.4 to 2.8.4 CP UPS driver disconnect (nut_libusb_get_report: No such device)&lt;/a&gt; 
    </content:encoded>

    <pubDate>Sun, 28 Jun 2026 01:10:00 +0000</pubDate>
    <guid isPermaLink="false">https://blog.raymond.burkholder.net/index.php?/archives/1360-guid.html</guid>
    
</item>
<item>
    <title>Linux - Copying file to clipboard</title>
    <link>https://blog.raymond.burkholder.net/index.php?/archives/1358-Linux-Copying-file-to-clipboard.html</link>
            <category>Linux</category>
    
    <comments>https://blog.raymond.burkholder.net/index.php?/archives/1358-Linux-Copying-file-to-clipboard.html#comments</comments>
    <wfw:comment>https://blog.raymond.burkholder.net/wfwcomment.php?cid=1358</wfw:comment>

    <slash:comments>0</slash:comments>
    <wfw:commentRss>https://blog.raymond.burkholder.net/rss.php?version=2.0&amp;type=comments&amp;cid=1358</wfw:commentRss>
    

    <author>nospam@example.com (Raymond P. Burkholder)</author>
    <content:encoded>
    &lt;p&gt;Install tool:
&lt;blockquote&gt;&lt;pre&gt;
sudo apt install xclip
&lt;/pre&gt;&lt;/blockquote&gt;

&lt;p&gt;Perform the copy:

&lt;blockquote&gt;&lt;pre&gt;
cat filename.base64 | xclip -rmlastnl -selection clipboard
&lt;/pre&gt;&lt;/blockquote&gt; 
    </content:encoded>

    <pubDate>Mon, 25 May 2026 02:25:44 +0000</pubDate>
    <guid isPermaLink="false">https://blog.raymond.burkholder.net/index.php?/archives/1358-guid.html</guid>
    
</item>
<item>
    <title>Installing Citrix Workspace on Debian</title>
    <link>https://blog.raymond.burkholder.net/index.php?/archives/1356-Installing-Citrix-Workspace-on-Debian.html</link>
            <category>Debian</category>
    
    <comments>https://blog.raymond.burkholder.net/index.php?/archives/1356-Installing-Citrix-Workspace-on-Debian.html#comments</comments>
    <wfw:comment>https://blog.raymond.burkholder.net/wfwcomment.php?cid=1356</wfw:comment>

    <slash:comments>0</slash:comments>
    <wfw:commentRss>https://blog.raymond.burkholder.net/rss.php?version=2.0&amp;type=comments&amp;cid=1356</wfw:commentRss>
    

    <author>nospam@example.com (Raymond P. Burkholder)</author>
    <content:encoded>
    &lt;p&gt;On installation, the Citrix Workspace installer will ask for libwebkit2gtk-4.0-37.  However, in the latest Debian, libwebkit2gtk-4.1-0 is installed.  That package brings in many other packages so there is no practical way to install an earlier version.

&lt;p&gt;The solution to this give the older &lt;b&gt;Debian Bookworm&lt;/b&gt; a try where the package is available for installation.

&lt;blockquote&gt;&lt;pre&gt;
&gt; apt-cache search libwebkit2gtk
libwebkit2gtk-4.0-37 - Web content engine library for GTK
libwebkit2gtk-4.0-dev - Web content engine library for GTK - development files
libwebkit2gtk-4.0-doc - Web content engine library for GTK - documentation
libwebkit2gtk-4.1-0 - Web content engine library for GTK
libwebkit2gtk-4.1-dev - Web content engine library for GTK - development files
&lt;/pre&gt;&lt;/blockquote&gt;

&lt;p&gt;To prep for Citrix installation, install the following:

&lt;blockquote&gt;&lt;pre&gt;
# apt install libwebkit2gtk-4.0-37 libcurl4 libspeexdsp1
&lt;/pre&gt;&lt;/blockquote&gt; 
    </content:encoded>

    <pubDate>Sun, 10 May 2026 00:36:22 +0000</pubDate>
    <guid isPermaLink="false">https://blog.raymond.burkholder.net/index.php?/archives/1356-guid.html</guid>
    
</item>

</channel>
</rss>
