regel / loudml

Loud ML is the first open-source AI solution for ICT and IoT automation
Other
298 stars 93 forks source link

Installation on Ubuntu 16.04 - bad magic number in 'loudml' #12

Closed qbee-io closed 6 years ago

qbee-io commented 6 years ago

Hi I'm trying to install loudml on my server by following manual installation steps, and got some strange errors:

My server: Ubuntu 16.04.3 LTS Python 3.5.2

auto installation is failing too - file is not found. See logs below

Could someone guide me how I can solve this "bad magic" issue?

This is what I see in the journal logs:

Mar 09 12:52:54 ubuntu-2gb-lon1-01 systemd[1]: Started LoudML daemon.
Mar 09 12:52:55 ubuntu-2gb-lon1-01 loudmld[26777]: Traceback (most recent call last):
Mar 09 12:52:55 ubuntu-2gb-lon1-01 loudmld[26777]:   File "/usr/bin/loudmld", line 11, in <module>
Mar 09 12:52:55 ubuntu-2gb-lon1-01 loudmld[26777]:     load_entry_point('loudml==1.2', 'console_scripts', 'loudmld')()
Mar 09 12:52:55 ubuntu-2gb-lon1-01 loudmld[26777]:   File "/usr/local/lib/python3.5/dist-packages/pkg_resources/__init__.py", line 587, in load_entry_point
Mar 09 12:52:55 ubuntu-2gb-lon1-01 loudmld[26777]:     return get_distribution(dist).load_entry_point(group, name)
Mar 09 12:52:55 ubuntu-2gb-lon1-01 loudmld[26777]:   File "/usr/local/lib/python3.5/dist-packages/pkg_resources/__init__.py", line 2800, in load_entry_point
Mar 09 12:52:55 ubuntu-2gb-lon1-01 loudmld[26777]:     return ep.load()
Mar 09 12:52:55 ubuntu-2gb-lon1-01 loudmld[26777]:   File "/usr/local/lib/python3.5/dist-packages/pkg_resources/__init__.py", line 2431, in load
Mar 09 12:52:55 ubuntu-2gb-lon1-01 loudmld[26777]:     return self.resolve()
Mar 09 12:52:55 ubuntu-2gb-lon1-01 loudmld[26777]:   File "/usr/local/lib/python3.5/dist-packages/pkg_resources/__init__.py", line 2437, in resolve
Mar 09 12:52:55 ubuntu-2gb-lon1-01 loudmld[26777]:     module = __import__(self.module_name, fromlist=['__name__'], level=0)
Mar 09 12:52:55 ubuntu-2gb-lon1-01 loudmld[26777]: ImportError: bad magic number in 'loudml': b'\x17\r\r\n'
Mar 09 12:52:55 ubuntu-2gb-lon1-01 systemd[1]: loudmld.service: Main process exited, code=exited, status=1/FAILURE
Mar 09 12:52:55 ubuntu-2gb-lon1-01 systemd[1]: loudmld.service: Unit entered failed state.
Mar 09 12:52:55 ubuntu-2gb-lon1-01 systemd[1]: loudmld.service: Failed with result 'exit-code'.
Mar 09 12:52:55 ubuntu-2gb-lon1-01 systemd[1]: loudmld.service: Service hold-off time over, scheduling restart.
Mar 09 12:52:55 ubuntu-2gb-lon1-01 systemd[1]: Stopped LoudML daemon.
Mar 09 12:52:55 ubuntu-2gb-lon1-01 systemd[1]: loudmld.service: Start request repeated too quickly.
Mar 09 12:52:55 ubuntu-2gb-lon1-01 systemd[1]: Failed to start LoudML daemon.

p.s. "normal" installation is failing:

W: The repository 'http://loudml.s3-website-eu-west-1.amazonaws.com/repo/deb/packages/1.x/apt stable Release' does not have a Release file.
N: Data from such a repository can't be authenticated and is therefore potentially dangerous to use.
N: See apt-secure(8) manpage for repository creation and user configuration details.
E: Failed to fetch http://loudml.s3-website-eu-west-1.amazonaws.com/repo/deb/packages/1.x/apt/dists/stable/main/binary-amd64/Packages  404  Not Found
opvizordz commented 6 years ago

I made the same mistake. You need to install loudlm on Debian Stretch (9) - Ubuntu is not working

qbee-io commented 6 years ago

Thank you @opvizordz ! I'll give it a try

osunac commented 6 years ago

Sorry for this issue and thanks to @opvizordz for suggesting the best workaround for Ubuntu users. The current package will definitely work on Debian 9 and will let you move to the next step.

qbee-io commented 6 years ago

I manage to install it manually.

apt-get way did not work for me.

Thank you for the help. I'll close this one.