-
Notifications
You must be signed in to change notification settings - Fork 9
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
exec container process /wasi_example_main.wasm
: Exec format error
#27
Comments
linked to KWasm/kwasm-operator#27 Signed-off-by: Sven Pfennig <[email protected]>
linked to KWasm/kwasm-operator#27 Signed-off-by: Sven Pfennig <[email protected]>
Hi @Tej-Singh-Rana, The website has not been updated yet. I just fixed the website a minute ago to make the examples work again. Thanks for your detailed bug reports! If you find anything that does not work with the |
Hi @0xE282B0 , I tried the above steps, but still failing for me. updated the installer, Here is the
Binaries: Thanks & Regards, |
Interesting, everything looks as it should:
Which kubernetes distribution do you use? - I tested some here: KWasm/kwasm-node-installer#43 |
I deployed K8s cluster using the kubeadm tool. Yes, I did restart containerd service. |
Do you have a default |
Only this one. |
Could you generate a default config and run the installer again? |
Sure, I will try this and let you know. Regards, |
Content of the
https://kwasm.sh/quickstart/#installation
https://github.com/KWasm/kwasm-node-installer/releases/tag/v0.3.0
Content of the
https://kwasm.sh/quickstart/#wasm-runtime-configuration
|
Thats odd! You can test that with these manifests: kubectl apply -f https://github.com/KWasm/kwasm-node-installer/releases/download/v0.3.0/deployment.yaml
kubectl apply -f https://github.com/KWasm/kwasm-node-installer/releases/download/v0.3.0/runtimeclass.yaml |
I will check and let you know. |
I tried it again and deployed the above manifest files. Runtimeclasses:
Deployments:
Inspected the pods:
|
Sorry, I didn't get your point. Which containers? |
Spin is one of the test containers. I wanted to see if it is a problem of the wasmedge shim or if all shims are affected. Could you please describe how you set up your cluster, that I can reproduce the issue?
|
Machine type (arm64/amd64) Ram size - amd64 Linux distribution (
kubeadm version - v1.28 |
Hi @Tej-Singh-Rana, I tried to reproduce your setup but can't reproduce your issue. Here is what I did: Detailed stepsInstall prerequisitesapt-get update
# apt-transport-https may be a dummy package; if so, you can skip that package
apt-get install -y apt-transport-https ca-certificates curl
mkdir /etc/apt/keyrings/
curl -fsSL https://pkgs.k8s.io/core:/stable:/v1.28/deb/Release.key | gpg --dearmor -o /etc/apt/keyrings/kubernetes-apt-keyring.gpg
# This overwrites any existing configuration in /etc/apt/sources.list.d/kubernetes.list
echo 'deb [signed-by=/etc/apt/keyrings/kubernetes-apt-keyring.gpg] https://pkgs.k8s.io/core:/stable:/v1.28/deb/ /' | tee /etc/apt/sources.list.d/kubernetes.list
apt-get update
apt-get install -y kubelet kubeadm kubectl containerd
apt-mark hold kubelet kubeadm kubectl containerd
# Install helm
curl -LO https://get.helm.sh/helm-v3.13.0-rc.1-linux-amd64.tar.gz | tar xzf -
mv linux-amd64/helm /usr/local/bin/ Set up clustermodprobe br_netfilter
echo 1 > /proc/sys/net/ipv4/ip_forward
kubeadm init --pod-network-cidr 10.244.0.0/16
export KUBECONFIG=/etc/kubernetes/admin.conf
kubectl apply -f https://github.com/flannel-io/flannel/releases/latest/download/kube-flannel.yml
kubectl taint node kwasm-test-85a2-49a40b node-role.kubernetes.io/control-plane:NoSchedule-
# Prepare config.toml
mkdir -p /etc/containerd/
containerd config default > /etc/containerd/config.toml Install and test KWasm operator# install latest shims with kwasm installer
helm repo add kwasm http://kwasm.sh/kwasm-operator/ --force-update
helm repo update
helm upgrade --install -n kwasm --create-namespace kwasm-operator kwasm/kwasm-operator \
--set kwasmOperator.autoProvision="true" \
--set kwasmOperator.installerImage="ghcr.io/kwasm/kwasm-node-installer:v0.3.0"
# deploy sidecar smoke tests
kubectl apply -f https://github.com/KWasm/kwasm-node-installer/releases/download/v0.3.0/deployment.yaml
kubectl apply -f https://github.com/KWasm/kwasm-node-installer/releases/download/v0.3.0/runtimeclass.yaml Test resultskubectl get all
NAME READY STATUS RESTARTS AGE
pod/lunatic-demo-6475554875-whcvs 2/2 Running 0 15m
pod/wasm-slight-6467bcc5bc-j9thq 2/2 Running 1 (11m ago) 15m
pod/wasm-spin-74c4cf5c77-xz6mn 2/2 Running 0 15m
pod/wasm-wws-888f6bc4b-9jxqc 2/2 Running 0 15m
pod/wasmedge-demo-5ff758d79-qqlz6 2/2 Running 0 15m
pod/wasmer-demo-857f947cb7-v9df7 2/2 Running 0 15m
pod/wasmtime-demo-56c78ddd95-5mnxn 2/2 Running 0 15m
NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE
service/kubernetes ClusterIP 10.96.0.1 <none> 443/TCP 33m
NAME READY UP-TO-DATE AVAILABLE AGE
deployment.apps/lunatic-demo 1/1 1 1 15m
deployment.apps/wasm-slight 1/1 1 1 15m
deployment.apps/wasm-spin 1/1 1 1 15m
deployment.apps/wasm-wws 1/1 1 1 15m
deployment.apps/wasmedge-demo 1/1 1 1 15m
deployment.apps/wasmer-demo 1/1 1 1 15m
deployment.apps/wasmtime-demo 1/1 1 1 15m
NAME DESIRED CURRENT READY AGE
replicaset.apps/lunatic-demo-6475554875 1 1 1 15m
replicaset.apps/wasm-slight-6467bcc5bc 1 1 1 15m
replicaset.apps/wasm-spin-74c4cf5c77 1 1 1 15m
replicaset.apps/wasm-wws-888f6bc4b 1 1 1 15m
replicaset.apps/wasmedge-demo-5ff758d79 1 1 1 15m
replicaset.apps/wasmer-demo-857f947cb7 1 1 1 15m
replicaset.apps/wasmtime-demo-56c78ddd95 1 1 1 15m
KWasm.sh quickstartI also tried the example from KWasm.sh, also without issues: > kubectl apply -f https://raw.githubusercontent.com/KWasm/kwasm-node-installer/main/example/test-job.yaml
runtimeclass.node.k8s.io/wasmedge unchanged
job.batch/wasm-test created
> kubectl logs job/wasm-test
Random number: 595037507
Random bytes: [45, 107, 189, 139, 130, 108, 35, 23, 246, 32, 34, 148, 196, 243, 92, 219, 16, 22, 100, 119, 30, 119, 26, 147, 228, 206, 237, 72, 3, 146, 78, 145, 87, 168, 48, 105, 104, 42, 241, 228, 25, 3, 145, 238, 57, 2, 241, 70, 249, 5, 31, 3, 171, 46, 224, 153, 86, 14, 136, 225, 103, 225, 38, 177, 113, 177, 29, 50, 222, 210, 98, 211, 59, 39, 186, 157, 178, 32, 99, 189, 197, 133, 11, 205, 241, 73, 195, 88, 229, 0, 233, 109, 106, 250, 39, 210, 17, 112, 164, 67, 51, 213, 86, 59, 17, 227, 72, 1, 109, 126, 228, 90, 183, 159, 83, 136, 203, 30, 210, 47, 9, 244, 227, 134, 8, 128, 78, 0]
Printed from wasi: This is from a main function
This is from a main function
The env vars are as follows.
KUBERNETES_SERVICE_PORT_HTTPS: 443
PATH: /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
KUBERNETES_PORT_443_TCP_ADDR: 10.96.0.1
KUBERNETES_PORT_443_TCP: tcp://10.96.0.1:443
KUBERNETES_PORT_443_TCP_PORT: 443
KUBERNETES_SERVICE_HOST: 10.96.0.1
KUBERNETES_PORT: tcp://10.96.0.1:443
HOSTNAME: wasm-test-lgdk9
KUBERNETES_SERVICE_PORT: 443
KUBERNETES_PORT_443_TCP_PROTO: tcp
The args are as follows.
/wasi_example_main.wasm
File content is This is in a file SummaryI used a CIVO > uname -a
Linux kwasm-test-85a2-49a40b 5.4.0-132-generic #148-Ubuntu SMP Mon Oct 17 16:02:06 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux
> containerd --version
containerd github.com/containerd/containerd 1.7.2
> kubeadm version
kubeadm version: &version.Info{Major:"1", Minor:"28", GitVersion:"v1.28.2", GitCommit:"89a4ea3e1e4ddd7f7572286090359983e0387b2f", GitTreeState:"clean", BuildDate:"2023-09-13T09:34:32Z", GoVersion:"go1.20.8", Compiler:"gc", Platform:"linux/amd64"}
> helm version
version.BuildInfo{Version:"v3.13.0-rc.1", GitCommit:"825e86f6a7a38cef1112bfa606e4127a706749b1", GitTreeState:"clean", GoVersion:"go1.20.8"} I have not been able to reproduce your problem. Is there anything I did that is different from your setup? |
Thanks for your time and efforts. I will dig more into it. Regards, |
Hi Team,
I was playing with the kwasm operator. I followed the steps in the official docs but encountered an error. Can you please assist me with this?
A few days ago, it was working fine. Today, I checked again and encountered an error.
Environment Details:
Working:
Not Working:
Error Output:
Earlier,
crun
is managed by the kwasm operator; now, I have to install it manually. Did we update anything recently? Can you share any URL where I can read about this?Thanks & Regards,
The text was updated successfully, but these errors were encountered: