DietPi icon indicating copy to clipboard operation
DietPi copied to clipboard

dietpi-software has incorrect download URL version for nomachine

Open tzvi208 opened this issue 1 year ago • 14 comments

Creating a bug report/issue

  • [x] I have searched the existing open and closed issues

Required Information

  • DietPi version | 9.6.1
  • Distro version | bookworm 0
  • Kernel version | Linux rpi5-01 6.6.31+rpt-rpi-2712 #1 SMP PREEMPT Debian 1:6.6.31-1+rpt1 (2024-05-29) aarch64 GNU/Linux
  • SBC model | RPi 5 Model B (aarch64)
  • Power supply used | n/a
  • SD card used | SanDisk 256GB

Additional Information (if applicable)

  • Software title | nomachine
  • Was the software title installed freshly or updated/migrated? No
  • Can this issue be replicated on a fresh installation of DietPi? Probably
  • Bug report ID | d2f560e4-1fd5-47a4-ae41-52fae7d8c10f

Steps to reproduce

  1. dietpi-software install 30

Expected behaviour

  • dietpi-software should install nomachine.

Actual behaviour

Reading package lists...
E: Invalid archive signature
E: Internal error, could not locate member control.tar{.zst,.lz4,.gz,.xz,.bz2,.lzma,}
E: Could not read meta data from /tmp/DietPi-Software/nomachine_8.11.3_3_arm64.deb
E: The package lists or status file could not be parsed or opened.
[FAILED] DietPi-Software | APT install ./nomachine_8.11.3_3_arm64.deb

Extra details

what URL Comment
URL asserted by dietpi-software https://download.nomachine.com/download/8.11/Arm/nomachine_8.11.3_3_arm64.deb downloads an HTML page pointing to v8.13
URL that succeeds https://download.nomachine.com/download/8.13/Arm/nomachine_8.13.1_1_arm64.deb from https://downloads.nomachine.com/download/?id=114&distro=ARM

tzvi208 avatar Aug 26 '24 21:08 tzvi208

Many thanks for reporting. Fixed with: https://github.com/MichaIng/DietPi/commit/40050a2

This is the first time they really removed the old downloads. Makes it more valuable to detect the latest available version automatically, but so far I could not find a good API or method to do that for their website, also since different architectures have different download pages, and sometimes different latest versions as well.

EDIT: Installation test running: https://github.com/MichaIng/DietPi/actions/runs/10567579112

MichaIng avatar Aug 26 '24 21:08 MichaIng

This is the first time they really removed the old downloads. Makes it more valuable to detect the latest available version automatically, but so far I could not find a good API or method to do that for their website, also since different architectures have different download pages, and sometimes different latest versions as well.

Would it be reasonable for dietpi-software to parse the href value from https://downloads.nomachine.com/download/?id=114&distro=ARM for the href in <a id="link_download" href="YADA">Download</a> each time it installs nomachine?

tzvi208 avatar Aug 27 '24 07:08 tzvi208

But we would need to parse a different URL for every architecture, and this id parameter does not look stable either. It would be nice to have some API or plain text download URL overview file, or https://download.nomachine.com/download/latest/Arm/nomachine_latest_arm64.deb or any such, instead of parsing multiple URLs with random page/product ID numbers 🤔.

MichaIng avatar Aug 27 '24 16:08 MichaIng

Based on a conversation I had with Nomachine support, here are static URLs for the latest versions:

dpkg --print-architecture URL md5sum for Version: 8.13.1-1
i386 https://www.nomachine.com/free/linux/32/deb/nomachine_latest_i386.deb 56e133097017dfad8f95112da7a08c56
amd64 https://www.nomachine.com/free/linux/64/deb/nomachine_latest_amd64.deb e54b47c5d2cbe977ee5f44c65bfebbb8
armv6hf https://www.nomachine.com/free/raspberry/v6/deb/nomachine_latest_armv6hf.deb e6606f7182534ab76a5646b94c5d73e8
armhf https://www.nomachine.com/free/raspberry/v7/deb/nomachine_latest_armhf.deb https://www.nomachine.com/free/arm/v7/deb/nomachine_latest_armhf.deb cb2e4bdca72ee9ae30e556e1fc74922b cb2e4bdca72ee9ae30e556e1fc74922b
arm64 https://www.nomachine.com/free/raspberry/v8/deb/nomachine_latest_arm64.deb https://www.nomachine.com/free/arm/v8/deb/nomachine_latest_arm64.deb e1b1550bbd3144a7d153b780738ac8c7 e1b1550bbd3144a7d153b780738ac8c7

Are there any other architectures you need?

tzvi208 avatar Aug 29 '24 05:08 tzvi208

Thanks a lot! Did these exist already, or did they just set it up? Sometimes it just makes sense to ask 🙂.

We need the armv6hf architecture as well, for Raspberry Pi 1 and Zero models.

MichaIng avatar Aug 29 '24 09:08 MichaIng

We need the armv6hf architecture as well, for Raspberry Pi 1 and Zero models.

I do not see armv6hf in the list of architectures supported by Debian, please see here. Searching raspbian.org for armv6hf returns only one hit.

What is the return from dpkg --print-architecture on these models running bookworm?

tzvi208 avatar Aug 29 '24 12:08 tzvi208

Did these exist already, or did they just set it up? Sometimes it just makes sense to ask 🙂.

I don't see these URL's on their web site, but I would be astonished if they set them up only on my query.

tzvi208 avatar Aug 29 '24 12:08 tzvi208

This is why "Raspbian" exists 😉. Here are the NoMachine downloads for these RPi models, respectively such which use the Raspbian package repository (instead of Debian): https://downloads.nomachine.com/linux/?id=29&distro=Raspberry

EDIT: dpkg cannot differentiate between armhf and armv6hf. So on Raspbian, the package architecture it is still armhf. But since ARMv6 does not support all ARMv7 instructions, like no NEON, it is incompatible, and Debian's armhf is hence not compatible with those RPi models. This is the reason why Raspbian was created and is maintained in the first place.

MichaIng avatar Aug 29 '24 12:08 MichaIng

This is why "Raspbian" exists 😉. Here are the NoMachine downloads for these RPi models, respectively such which use the Raspbian package repository (instead of Debian): https://downloads.nomachine.com/linux/?id=29&distro=Raspberry

  • Perhaps this was the case at one time, but today I examined all the V6 DEB links there and they all point to download.nomachine.com.
  • Likewise, I manually examined raspbian.org and failed to find any mention nomachine there.

Meanwhile, I continued my conversation with the Support Team at NoMachine support to inquire if they have a static link for ARM6 packages; I'll report their reply.

tzvi208 avatar Aug 29 '24 14:08 tzvi208

@tzvi208 Not sure what you want to say with that? What's wrong with download.nomachine.com? Of course Raspbian does not distribute NoMachine, since it's closed source commercial product, and as we know now, not allowed to be redistributed without permission. Raspbian is, like Debian, a source code repository, with binary packages compiled by the distributors. They do not distribute packages compiled elsewhere. NoMachine however provides packages compatible for the special ARMv6 hardware-floating-point architecture of the first RPi models, like Raspbian does, but Debian not.

MichaIng avatar Aug 29 '24 20:08 MichaIng

Hi @MichaIng

I misunderstood your remark:

This is why "Raspbian" exists 😉. Here are the NoMachine downloads for these RPi models, respectively such which use the Raspbian package repository (instead of Debian): https://downloads.nomachine.com/linux/?id=29&distro=Raspberry

When you mentioned Raspibian, I thought you were talking about http://archive.raspbian.org/raspbian. Now, I understand that you're referring to what NoMachine calls a distro=Raspberry. Sorry about the confusion :confused:.

With the exception of support for armv6hf in distro=Raspberry, there is no difference in content between that and distro=Arm

After further correspondence with NoMachine Support, the table in my earlier comment is now complete, including a URL to a package for armv6hf.

Please note that the package downloaded as nomachine_latest_armv6hf.deb has Architecture: armhf in its control file.

Final note: I (@tzvi208) revised this comment after I realized that my initial message NoMachine has no support for armv6hf was incorrect. I am hopeful that this concludes the research part of this issue.

tzvi208 avatar Aug 31 '24 19:08 tzvi208

Hi @MichaIng

This is just a separate comment to generate notifications that I significantly revised these two previous comments, and that you should review them before closing the implementation of any fix from this issue #7198:

tzvi208 avatar Sep 01 '24 17:09 tzvi208

Many thanks. I edited the last line where I think you wanted to show that as well the "arm" and "raspbian" ARMv8 downloads are the same. This is also what we found (and which makes just sense since RPi 2 and above are ARM fully compatible with plain Debian) and hence used the "arm" downloads for all ARMv7 and ARMv8 boards.

MichaIng avatar Sep 01 '24 17:09 MichaIng

Implemented: https://github.com/MichaIng/DietPi/commit/3942854

Hmm, now we have a bug fix and enhancement about the very same thing 😄. Well, it is both indeed. The code for installing NoMachine is now ridiculously simple/slim, not that I want to complain. It might grow again since we might need to add some EULA/licensing/personal-use-only notice, to get an official permission distributing it.

MichaIng avatar Sep 01 '24 17:09 MichaIng