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

standard_init_linux.go:211: exec user process caused "exec format error" #1912

Closed
nextdynamic opened this issue Oct 25, 2019 · 8 comments
Closed
Assignees

Comments

@nextdynamic
Copy link

Expected Behavior

On Raspberry Pi4, I want to deploy a custom python module.

Current Behavior

The module deploys, but I receive the following error:
standard_init_linux.go:211: exec user process caused "exec format error"

Steps to Reproduce

Provide a detailed set of steps to reproduce the bug.

  1. Create an IOT Edge solution.
  2. Add a custom module with Python as the language
  3. Select arm32v7 as the platform.
  4. Build and push the Iot Solution to the repository.
  5. Create a deployment for a single device.

Context (Environment)

Visual Studio Code [ latest ]
Iot Edge extensions
Python 3.7.3
Raspberry Pi4 with Docker running and IoT Edge installed

Output of iotedge check

pi@rpi4-tibrown:~ $ sudo iotedge check
Configuration checks

√ config.yaml is well-formed - OK
√ config.yaml has well-formed connection string - OK
√ container engine is installed and functional - OK
√ config.yaml has correct hostname - OK
√ config.yaml has correct URIs for daemon mgmt endpoint - OK
√ latest security daemon - OK
√ host time is close to real time - OK
√ container time is close to host time - OK
‼ DNS server - Warning
Container engine is not configured with DNS server setting, which may impact connectivity to IoT Hub.
Please see https://aka.ms/iotedge-prod-checklist-dns for best practices.
You can ignore this warning if you are setting DNS server per module in the Edge deployment.
‼ production readiness: certificates - Warning
Device is using self-signed, automatically generated certs.
Please see https://aka.ms/iotedge-prod-checklist-certs for best practices.
√ production readiness: certificates expiry - OK
‼ production readiness: container engine - Warning
Device is not using a production-supported container engine (moby-engine).
Please see https://aka.ms/iotedge-prod-checklist-moby for details.
‼ production readiness: logs policy - Warning
Container engine is not configured to rotate module logs which may cause it run out of disk space.
Please see https://aka.ms/iotedge-prod-checklist-logs for best practices.
You can ignore this warning if you are setting log policy per module in the Edge deployment.

Connectivity checks

√ host can connect to and perform TLS handshake with IoT Hub AMQP port - OK
√ host can connect to and perform TLS handshake with IoT Hub HTTPS / WebSockets port - OK
√ host can connect to and perform TLS handshake with IoT Hub MQTT port - OK
√ container on the default network can connect to IoT Hub AMQP port - OK
√ container on the default network can connect to IoT Hub HTTPS / WebSockets port - OK
√ container on the default network can connect to IoT Hub MQTT port - OK
√ container on the IoT Edge module network can connect to IoT Hub AMQP port - OK
√ container on the IoT Edge module network can connect to IoT Hub HTTPS / WebSockets port - OK
√ container on the IoT Edge module network can connect to IoT Hub MQTT port - OK
√ Edge Hub can bind to ports on host - OK

19 check(s) succeeded.

Click here

<Paste here between the triple backticks>

Device Information

  • Host OS [ Raspian Buster ]:
  • Architecture [arm32]:
  • Container OS [ Linux containers]:

Runtime Versions

  • iotedged [run iotedge version]: iotedge 1.0.8 (208b220)
  • Edge Agent [image tag (e.g. 1.0.0)]: 1.0
  • Edge Hub [image tag (e.g. 1.0.0)]: 1.0
  • Docker/Moby [run docker version]: 19.03.4

Note: when using Windows containers on Windows, run docker -H npipe:////./pipe/iotedge_moby_engine version instead

Logs

pi@rpi4-tibrown:~ $ sudo iotedge logs samplemodule
standard_init_linux.go:211: exec user process caused "exec format error"
standard_init_linux.go:211: exec user process caused "exec format error"
standard_init_linux.go:211: exec user process caused "exec format error"
standard_init_linux.go:211: exec user process caused "exec format error"
standard_init_linux.go:211: exec user process caused "exec format error"
standard_init_linux.go:211: exec user process caused "exec format error"
standard_init_linux.go:211: exec user process caused "exec format error"

iotedged logs
</details>

<details>
<summary>edge-agent logs</summary>

</details>

<details>
<summary>edge-hub logs</summary>

</details>

## Additional Information
Please provide any additional information that may be helpful in understanding the issue.
@dmolokanov dmolokanov self-assigned this Oct 25, 2019
@dmolokanov dmolokanov added area:tooling Development tools bug Something isn't working needinfo Needs more info from issue reporter / updates from PR submitter labels Oct 25, 2019
@dmolokanov
Copy link
Contributor

Hello @nextdynamic,
What version of python SDK for IoT edge do you use? For SDK v1 is multi-stage build process is involved. The first step is to build libraries and code using cross-compile toolchain. The second one is to build an actual container image with your python code.
Could you provide a Dockerfile that was generated in VS Code?

Usually, this error message relates to situation where a user tries to run a container on the unsupported architecture of a host machine. For instance, when tries to run amd64 image on arm64 host machine.

@dmolokanov
Copy link
Contributor

I assume that you have followed some kind of guide/tutorial when faced with this issue, right? Could you provide a link for it? In addition, could you post a deployment.template.json? We need as much information as possible to address this issue.

@nextdynamic
Copy link
Author

nextdynamic commented Oct 25, 2019 via email

@vipeller vipeller self-assigned this Oct 28, 2019
@vipeller
Copy link
Contributor

vipeller commented Oct 28, 2019

@nextdynamic thank you for sharing the information how you managed to deploy a module. It is going to help us to further investigate what happened on your environment.
My question for you is that are you still blocked, or I can close this ticket?

@dmolokanov dmolokanov removed their assignment Oct 28, 2019
@nextdynamic
Copy link
Author

nextdynamic commented Oct 28, 2019 via email

@vipeller vipeller removed bug Something isn't working needinfo Needs more info from issue reporter / updates from PR submitter labels Oct 28, 2019
@kwildermuth1
Copy link

@nextdynamic Did you solve the issue running IoT Edge modules on Raspberry PI 4 with the arm32 architecture, or did you just choose a different path? I am experiencing the same issue reported here.

@nextdynamic
Copy link
Author

nextdynamic commented Nov 20, 2019 via email

@nextdynamic
Copy link
Author

nextdynamic commented Nov 20, 2019 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants