Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ARM64/AARCH64 support #629

Closed
hotio opened this issue Apr 20, 2019 · 27 comments

Comments

Projects
None yet
4 participants
@hotio
Copy link

commented Apr 20, 2019

Could we get ARM64/AARCH64 support in the linux installer? I've seen you mention that you'd consider it....Any update on this?

@hugbug

This comment has been minimized.

Copy link
Member

commented Apr 20, 2019

I've tried it but the binary didn't work properly. It worked almost fine but at few places there were issues with file access functions. However I was able to perform speed tests which showed no big difference to armhf binary.

I might try with newer build tools to check if the issue has been fixed. However considering no real benefits of it I'm not much motivated to spend another couple of days on this.

@hotio

This comment has been minimized.

Copy link
Author

commented Apr 20, 2019

Yes I understand you not wanting to waste any time on this...one benefit however would be to actually be able to run it. It doesn't run on Ubuntu 18.04 for example, besides the other issue I read of the Arch user.

Does self compiling like linuxserver does not carry over the same problems as you are experiencing or has it more to do with integrating in the installer?

@hugbug

This comment has been minimized.

Copy link
Member

commented Apr 20, 2019

Do you have such ARM64 system where armhf from installer doesn't work? I could give that issue another try if you can test the new installers and if you have time for this. This can be a long running adventure.

Self compiling should produce perfect executables. The binary from installer is built once and has to work on variety of systems; sometimes that doesn't work as desired.

@hotio

This comment has been minimized.

Copy link
Author

commented Apr 20, 2019

I could test it on an arm64 scaleway instance

@hugbug

This comment has been minimized.

Copy link
Member

commented Apr 20, 2019

Please send me a note to nzbget@gmail.com and I'll send you installer to test.

It's important to test the whole download process from adding nzb to finished unpack. Not just that the binary runs. OK?

@hotio

This comment has been minimized.

Copy link
Author

commented Apr 20, 2019

ok

@hotio

This comment has been minimized.

Copy link
Author

commented Apr 20, 2019

Worked without a hitch, downloaded nzb just fine, extracted file is OK.

Installer for nzbget-21.0-testing-r2303M
Verifying package...
Checking system...
CPU-Architecture: aarch64
Unpacking...
Configuring...
  Free memory detected: 1599 MB
  Activating article cache (ArticleCache=100)
  Increasing write buffer (WriteBuffer=1024)
  Increasing par repair buffer (ParBuffer=100)
  Activating direct rename (DirectRename=yes)
  CPU speed detected: 800 BogoMIPS
  Disabling download during par check/repair (ParPauseQueue=yes)
  Disabling download during unpack (UnpackPauseQueue=yes)
  Disabling download during post-processing (ScriptPauseQueue=yes)
Installation completed

Quick help (from nzbget-directory):
   ./nzbget -s        - start nzbget in console mode
   ./nzbget -D        - start nzbget in daemon mode (in background)
   ./nzbget -C        - connect to background process
   ./nzbget -Q        - stop background process
   ./nzbget -h        - help screen with all commands

Successfully installed into /app
Web-interface is on http://localhost:6789 (login:nzbget, password:tegbzn6789)
For support please visit http://nzbget.net/forum
@hugbug

This comment has been minimized.

Copy link
Member

commented Apr 20, 2019

Thanks for the test.

@ALL: I'm now looking for real users who can run this build on their devices for several days in real life.

@hugbug hugbug added the feature label Apr 20, 2019

@fryfrog

This comment has been minimized.

Copy link

commented Apr 20, 2019

I've got a handful of Pi 3s and they're running arm7 and arm8 versions of a few Linux distros.

@hugbug

This comment has been minimized.

Copy link
Member

commented Apr 20, 2019

Everyone willing to test the ARM64 build please send me a note to nzbget@gmail.com and I'll provide the installer. Thanks!

It would be especially helpful if someone who already runs nzbget on an ARM64 Linux device could test the new build.

@sanderjo

This comment has been minimized.

Copy link
Contributor

commented Apr 20, 2019

Joining this thread ...

@sanderjo

This comment has been minimized.

Copy link
Contributor

commented Apr 20, 2019

Yes I understand you not wanting to waste any time on this...one benefit however would be to actually be able to run it. It doesn't run on Ubuntu 18.04 for example

Really? I tried in a Ubuntu 18.04 docker on my ARM64 / Aarch64, and no problem running the installer and the resulting nzbget

root@e743570b9484:/# sh nzbget-21.0-testing-r2302-bin-linux.run
Installer for nzbget-21.0-testing-r2302
Verifying package...
Checking system...
CPU-Architecture: armhf
Unpacking...
Configuring...
  Free memory detected: 291 MB
  Increasing write buffer (WriteBuffer=256)
  CPU speed detected: 192 BogoMIPS
  Disabling download during par check/repair (ParPauseQueue=yes)
  Disabling download during unpack (UnpackPauseQueue=yes)
  Disabling download during post-processing (ScriptPauseQueue=yes)
Installation completed

Quick help (from nzbget-directory):
   ./nzbget -s        - start nzbget in console mode
   ./nzbget -D        - start nzbget in daemon mode (in background)
   ./nzbget -C        - connect to background process
   ./nzbget -Q        - stop background process
   ./nzbget -h        - help screen with all commands

Successfully installed into /nzbget
Web-interface is on http://localhost:6789 (login:nzbget, password:tegbzn6789)
For support please visit http://nzbget.net/forum
root@e743570b9484:/# cd nzbget

root@e743570b9484:/nzbget# ./nzbget 
Usage:
  nzbget [switches]

Switches:
  -h, --help                Print this help-message
  -v, --version             Print version and exit
  -c, --configfile <file>   Filename of configuration-file
<snip>

root@e743570b9484:/nzbget# ./nzbget -s

root@e743570b9484:/nzbget# 
root@e743570b9484:~# uname -a
Linux e743570b9484 4.19.25-sunxi64 #5.78 SMP Mon Apr 8 07:19:19 CEST 2019 aarch64 aarch64 aarch64 GNU/Linux
root@e743570b9484:~# cat /etc/lsb-release 
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=18.04
DISTRIB_CODENAME=bionic
DISTRIB_DESCRIPTION="Ubuntu 18.04 LTS"
root@e743570b9484:~# 
@hotio

This comment has been minimized.

Copy link
Author

commented Apr 20, 2019

Could be, how does that change the fact it didn't run for me? I'm not making this stuff up :)

HOST

Linux scw-youthful-curie 4.9.93-mainline-rev1 #1 SMP Tue Apr 10 09:54:46 UTC 2018 aarch64 aarch64 aarch64 GNU/Linux

DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=18.04
DISTRIB_CODENAME=bionic
DISTRIB_DESCRIPTION="Ubuntu 18.04.2 LTS"

CONTAINER

Linux 4c5e08cc42a5 4.9.93-mainline-rev1 #1 SMP Tue Apr 10 09:54:46 UTC 2018 aarch64 aarch64 aarch64 GNU/Linux

DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=18.04
DISTRIB_CODENAME=bionic
DISTRIB_DESCRIPTION="Ubuntu 18.04.2 LTS"
Installer for nzbget-20.0
Verifying package...
Checking system...
CPU-Architecture: armhf
Unpacking...
Configuring...
  Free memory detected: 1616 MB
  Activating article cache (ArticleCache=100)
  Increasing write buffer (WriteBuffer=1024)
  Increasing par repair buffer (ParBuffer=100)
  Activating direct rename (DirectRename=yes)
  CPU speed detected: 800 BogoMIPS
  Disabling download during par check/repair (ParPauseQueue=yes)
  Disabling download during unpack (UnpackPauseQueue=yes)
  Disabling download during post-processing (ScriptPauseQueue=yes)
Installation completed

Quick help (from nzbget-directory):
   ./nzbget -s        - start nzbget in console mode
   ./nzbget -D        - start nzbget in daemon mode (in background)
   ./nzbget -C        - connect to background process
   ./nzbget -Q        - stop background process
   ./nzbget -h        - help screen with all commands

Successfully installed into /app
Web-interface is on http://localhost:6789 (login:nzbget, password:tegbzn6789)
For support please visit http://nzbget.net/forum
s6-applyuidgid: fatal: unable to exec /app/nzbget: Exec format error
@hugbug

This comment has been minimized.

Copy link
Member

commented Apr 20, 2019

@hotio, I'm confused. Do you have an aarch64-system where you need to run nzbget? If you do - why you test on scaleway? If you don't - why creating this issue?

@hugbug

This comment has been minimized.

Copy link
Member

commented Apr 20, 2019

In #480 we have found out that aarch64 Linux must be built with arm32 support to run 32 bit executables.

Try one of these commands:

zcat /proc/config.gz | grep CONFIG_COMPAT

or

grep CONFIG_COMPAT= /boot/config-$(uname -r)

What do they print on your system?

@hotio

This comment has been minimized.

Copy link
Author

commented Apr 20, 2019

I'm creating this issue, because something didn't work when testing it and I found that some people were experiencing the same problems in the past. Is that not a sound reason for creating an issue? This is only going to be more common in the future....maybe.

HOST

# CONFIG_COMPAT_BRK is not set
CONFIG_COMPAT_OLD_SIGACTION=y
CONFIG_COMPAT_BINFMT_ELF=y
CONFIG_COMPAT=y
grep: /boot/config-4.9.93-mainline-rev1: No such file or directory

CONTAINER

# CONFIG_COMPAT_BRK is not set
CONFIG_COMPAT_OLD_SIGACTION=y
CONFIG_COMPAT_BINFMT_ELF=y
CONFIG_COMPAT=y
grep: /boot/config-4.9.93-mainline-rev1: No such file or directory
@sanderjo

This comment has been minimized.

Copy link
Contributor

commented Apr 20, 2019

@hugbug That installer works for me on my ARM64 running Ubuntu 16.04 64-bit:

sander@nanopineo2:~/nzbget-installer-incl-aarch64$ sh nzbget-21.0-testing-r2303M-bin-linux---hugbug-incl-AARCH64.run
Installer for nzbget-21.0-testing-r2303M
Verifying package...
Checking system...
CPU-Architecture: aarch64
Unpacking...
Configuring...
  Free memory detected: 305 MB
  Increasing write buffer (WriteBuffer=256)
  CPU speed detected: 192 BogoMIPS
  Disabling download during par check/repair (ParPauseQueue=yes)
  Disabling download during unpack (UnpackPauseQueue=yes)
  Disabling download during post-processing (ScriptPauseQueue=yes)
Installation completed

Quick help (from nzbget-directory):
   ./nzbget -s        - start nzbget in console mode
   ./nzbget -D        - start nzbget in daemon mode (in background)
   ./nzbget -C        - connect to background process
   ./nzbget -Q        - stop background process
   ./nzbget -h        - help screen with all commands

Successfully installed into /home/sander/nzbget-installer-incl-aarch64/nzbget
Web-interface is on http://192.168.1.3:6789 (login:nzbget, password:tegbzn6789)
For support please visit http://nzbget.net/forum
sander@nanopineo2:~/nzbget-installer-incl-aarch64$ file nzbget/nzbget
nzbget/nzbget: ELF 64-bit LSB executable, ARM aarch64, version 1 (GNU/Linux), statically linked, for GNU/Linux 3.7.0, stripped
sander@nanopineo2:~/nzbget-installer-incl-aarch64$ 

sander@nanopineo2:~/nzbget-installer-incl-aarch64$ nzbget/nzbget --help
Usage:
  nzbget [switches]

Switches:
  -h, --help                Print this help-message
  -v, --version             Print version and exit
  -c, --configfile <file>   Filename of configuration-file
  -n, --noconfigfile        Prevent loading of configuration-file
                            (required options must be passed with --option)
  -p, --printconfig         Print configuration and exit

<snip>

@hotio

This comment has been minimized.

Copy link
Author

commented Apr 20, 2019

Running all this barebones without any sort of container in the mix gives the same result. Guess, no two machines are the same, no idea why it would run for you @sanderjo and not for me.

@hugbug

This comment has been minimized.

Copy link
Member

commented Apr 20, 2019

I'm creating this issue, because something didn't work when testing it and I found that some people were experiencing the same problems in the past. Is that not a sound reason for creating an issue? This is only going to be more common in the future....maybe.

In #480 an Arch user has reported an issue and we have found out that his Arch system was built without 32 bit support. As suggested he has asked on Arch forum why the 32 bit support is disabled. He has got no response. In the meantime no other users reported the issue. Therefore even though nzbget installer maybe didn't work on Arch ARM64 it seemed to be not a real issue as long as there were no users willing to run nzbget there. Or maybe the compatibility issue in Arch were fixed. Fair enough?

If there are users in need for aarch64 binary (if armhf binary doesn't work) and we can confirm that we have a working aarch64 binary, then I'll include it into Linux installer.

I wish someone could do more testing including download, par2-check/repair, unpack, executing of extension scripts, etc.

@hotio

This comment has been minimized.

Copy link
Author

commented Apr 20, 2019

Seems a reasonable approach, it isn't a pressing matter for me personally, just know that it doesn't work on the hardware scaleway has deployed....but I see no reason not to start testing/giving the user the option and to be ready for what the future brings. Bundling the aarch64 binary gives a bigger chance of floating bugs to the surface then no binary at all. :-)

@sanderjo

This comment has been minimized.

Copy link
Contributor

commented Apr 20, 2019

@hotio I still don't understand: do you have a AARCH64 setup that does not work with the nzbget installer (or the resulting nzbget armhf binary)? If so, can you post the output?

@hotio

This comment has been minimized.

Copy link
Author

commented Apr 20, 2019

I have an aarch64 instance from scaleway on which the armhf binary doesn't run.

fatal: unable to exec /app/nzbget: Exec format error

See my previous posts for all the other output.

This issue experiences the same issue on scaleway hardware influxdata/telegraf#3242, it has probably to do with the fact that they build their own hardware for their servers.

@sanderjo

This comment has been minimized.

Copy link
Contributor

commented Apr 20, 2019

What is the output of

file /app/nzbget

And how did it get there? In my experience, with the installer the nzbget exe is always in a directory nzbget, so /some/thing/bla/nzbget/nzbget

@hotio

This comment has been minimized.

Copy link
Author

commented Apr 20, 2019

ELF 32-bit LSB executable, ARM, EABI5 version 1 (SYSV), statically linked, for GNU/Linux 2.6.32, stripped
The installer put it there.

@hugbug

This comment has been minimized.

Copy link
Member

commented Apr 20, 2019

I guess scaleway build kernel themselves and this kernel can't run 32 bit binaries.


I'm going to publish a new testing release with aarch64 binaries. Let's see what happens ;)

@hugbug

This comment has been minimized.

Copy link
Member

commented Apr 20, 2019

And how did it get there? In my experience, with the installer the nzbget exe is always in a directory nzbget, so /some/thing/bla/nzbget/nzbget

Probably installed with parameter --destdir /app.

@hotio

This comment has been minimized.

Copy link
Author

commented Apr 20, 2019

My Guess: not an awful lot
:-)
Damn GitHub, why no smiley support...

hugbug added a commit that referenced this issue Apr 20, 2019

@hugbug hugbug closed this Apr 29, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.