OSError: [Errno 8] Exec format error


#1

I’m trying to install seafile server with mysql on arch linux and I get to this point, any idea what the problem is? The line 815 is the following:

if Utils.run_argv(argv, env=env_mgr.get_binary_env()) != 0:

but I’m not sure why it fails at this line and exits the setup-seafile-mysql.py script. Any thoughts?


Press ENTER to continue, or Ctrl-C to abort

Generating ccnet configuration …

Traceback (most recent call last):
File “setup-seafile-mysql.py”, line 1471, in
main()
File “setup-seafile-mysql.py”, line 1424, in main
ccnet_config.generate()
File “setup-seafile-mysql.py”, line 815, in generate
if Utils.run_argv(argv, env=env_mgr.get_binary_env()) != 0:
File “setup-seafile-mysql.py”, line 85, in run_argv
env=env)
File “/usr/lib/python2.7/subprocess.py”, line 390, in init
errread, errwrite)
File “/usr/lib/python2.7/subprocess.py”, line 1025, in _execute_child
raise child_exception
OSError: [Errno 8] Exec format error


#2

This is a common problem with Python, and usually happens when trying to directly execute a script and #!/bin/sh is not the very first line of the directly executed script or the “shebang”, as some call it, doesn’t exist at all.


#3

So, with that being said, what version of the server are you trying to install?

Are you trying to build Seafile rather than grabbing the pre-built Seafile Server from the website? If so, what is your procedure?

[EDIT]
I should have been more clear… I looked back at my last statement… What I’m trying to ask you is if you are trying to build it for Arch Linux. Pre-built Seafile from the web site is built for Debian, Centos, and Ubuntu. You will most likely have to build Seafile for Arch.

Also, keep in mind that you’ll need to make certain the mysql server you downloaded is compatible with Arch. If you got it from an Arch repository, it should be.


#4

Hi - I’m trying to install 6.2.5 on arch linux ARM. I’m not building it, but using the
setup-seafile-mysql.sh file to set up mysql with seafile. After I answer all mysql questions, it starts into the .py script and that is where it fails.

I’ve tried:

  • “#!/bin/sh” as well as
  • “#!/usr/bin/env python” and
  • “#!/usr/bin/python”

at the top (without quotes) of setup-seafile-mysql.py but it still gives the same error.


#5

This error can also be generated if you are using the wrong version of python. What version are you using?


#6

I’m using python 2.7

I believe this is tied back to my server being ARM and seafile 32-bit executable files within the files. I ran the the “setup-seafile.sh” file and I after I answer the typical questions, I get this:

./setup-seafile.sh: line 483: /mnt/wd1000/BTSync/seafile/seafile-server-6.2.5/seafile/bin/ccnet-init: cannot execute binary file: Exec format error

$ file seafile/bin/ccnet-init
seafile/bin/ccnet-init: ELF 32-bit LSB executable, Intel 80386, version 1 (SYSV), dynamically linked, interpreter /lib/ld-linux.so.2, for GNU/Linux 2.6.18, stripped

I believe this script is called from the previous script initially noted at the start of this post. I’ve tried to build seafile from the PKGBUILD file but it gives:

==> ERROR: seafile-server is not available for the ‘arm’ architecture.

Is seafile not able to be used with ARM architecture?


#7

Seafile is also available for ARM architectures under the category Raspberry Pi:

https://www.seafile.com/en/download/

Have fun


#8

That is the release I used for this and it is still giving me the error:

==> ERROR: seafile-server is not available for the ‘arm’ architecture.


#9

Coud you please post the output of uname -a ?


#10

Linux alarm 4.4.97-1-ARCH #1 PREEMPT Sat Nov 11 04:51:38 UTC 2017 armv5tel GNU/Linux


#11

Please use Raspbian Lite or Debian armhf for SeaFile. Arch isn’t for Server. There are always dependeny problems with Arch and SeaFile.