konveyor / move2kube

Move2Kube is a command-line tool for automating creation of Infrastructure as code (IaC) artifacts. It has inbuilt support for creating IaC artifacts for replatforming to Kubernetes/Openshift.
https://move2kube.konveyor.io/
Apache License 2.0
385 stars 119 forks source link

Segmentation fault (core dumped) when running any move2kube command #816

Closed PatrickGeyer closed 2 years ago

PatrickGeyer commented 2 years ago

Describe the bug Segmentation fault (core dumped) when running move2kube To Reproduce Steps to reproduce the behavior: CentOs, newest version of move2kube

Expected behavior converts kubernetes files in folder to docker-compose file. Screenshots If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

ashokponkumar commented 2 years ago

@HarikrishnanBalagopal Can you please check this out?

HarikrishnanBalagopal commented 2 years ago

@PatrickGeyer Hi, Thanks for making a bug report.

Cant get version number due to same error

Can you tell us how you installed move2kube please?

CentOs, newest version of move2kube

Do you mean v0.3.2 ? https://github.com/konveyor/move2kube/releases/tag/v0.3.2

Segmentation fault (core dumped) when running move2kube

Usually there's some panic error message when this happens in Golang. Can you post any/all of the terminal output please?

converts kubernetes files in folder to docker-compose file.

Also if you can provide a small sample input to reproduce the bug, that would be great!

Update:

# ./move2kube version -l
Segmentation fault (core dumped)

I was able to reproduce the bug with v0.3.2 linux amd64 executable https://github.com/konveyor/move2kube/releases/download/v0.3.2/move2kube-v0.3.2-linux-amd64.tar.gz on CentOS

# cat /etc/os-release
NAME="CentOS Stream"
VERSION="9"
ID="centos"
ID_LIKE="rhel fedora"
VERSION_ID="9"
PLATFORM_ID="platform:el9"
PRETTY_NAME="CentOS Stream 9"
ANSI_COLOR="0;31"
LOGO="fedora-logo-icon"
CPE_NAME="cpe:/o:centos:centos:9"
HOME_URL="https://centos.org/"
BUG_REPORT_URL="https://bugzilla.redhat.com/"
REDHAT_SUPPORT_PRODUCT="Red Hat Enterprise Linux 9"
REDHAT_SUPPORT_PRODUCT_VERSION="CentOS Stream"

However this bug doesn't occur on Ubuntu 20.04 with the same executable file.

HarikrishnanBalagopal commented 2 years ago

Ok so I recompiled move2kube on CentOS and ran it

# move2kube version -l
version: v0.3.2
gitCommit: ef9f59dcf5c90aab70450b3a092dd5cad2832018
gitTreeState: clean
goVersion: go1.17.5

So since it's not seg faulting it might be some issue of cross compiling in our release pipeline.

ashokponkumar commented 2 years ago

@PatrickGeyer Hi, Thanks for making a bug report.

Cant get version number due to same error

Can you tell us how you installed move2kube please?

CentOs, newest version of move2kube

Do you mean v0.3.2 ? https://github.com/konveyor/move2kube/releases/tag/v0.3.2

Segmentation fault (core dumped) when running move2kube

Usually there's some panic error message when this happens in Golang. Can you post any/all of the terminal output please?

converts kubernetes files in folder to docker-compose file.

Also if you can provide a small sample input to reproduce the bug, that would be great!

Update:

# ./move2kube version -l
Segmentation fault (core dumped)

I was able to reproduce the bug with v0.3.2 linux amd64 executable https://github.com/konveyor/move2kube/releases/download/v0.3.2/move2kube-v0.3.2-linux-amd64.tar.gz on CentOS

# cat /etc/os-release
NAME="CentOS Stream"
VERSION="9"
ID="centos"
ID_LIKE="rhel fedora"
VERSION_ID="9"
PLATFORM_ID="platform:el9"
PRETTY_NAME="CentOS Stream 9"
ANSI_COLOR="0;31"
LOGO="fedora-logo-icon"
CPE_NAME="cpe:/o:centos:centos:9"
HOME_URL="https://centos.org/"
BUG_REPORT_URL="https://bugzilla.redhat.com/"
REDHAT_SUPPORT_PRODUCT="Red Hat Enterprise Linux 9"
REDHAT_SUPPORT_PRODUCT_VERSION="CentOS Stream"

However this bug doesn't occur on Ubuntu 20.04 with the same executable file.

Is it reproductive with the latest rc build? If it is an issue with golang, it might have been fixed in the latest builds.

HarikrishnanBalagopal commented 2 years ago

@PatrickGeyer Hi, I have recompiled for Linux and attached the new binary to the v0.3.2 release https://github.com/konveyor/move2kube/releases/download/v0.3.2/move2kube-v0.3.2-recompiled-for-linux-amd64.tar.gz

Please download that and use it for now while we fix this bug. It is tested and working for me on:

# cat /etc/os-release
NAME="CentOS Stream"
VERSION="9"
ID="centos"
ID_LIKE="rhel fedora"
VERSION_ID="9"
PLATFORM_ID="platform:el9"
PRETTY_NAME="CentOS Stream 9"
ANSI_COLOR="0;31"
LOGO="fedora-logo-icon"
CPE_NAME="cpe:/o:centos:centos:9"
HOME_URL="https://centos.org/"
BUG_REPORT_URL="https://bugzilla.redhat.com/"
REDHAT_SUPPORT_PRODUCT="Red Hat Enterprise Linux 9"
REDHAT_SUPPORT_PRODUCT_VERSION="CentOS Stream"

# ./move2kube version -l
version: v0.3.2
gitCommit: ef9f59dcf5c90aab70450b3a092dd5cad2832018
gitTreeState: clean
goVersion: go1.18.3
HarikrishnanBalagopal commented 2 years ago

@PatrickGeyer Hi, looking at the StackOverflow thread that you were on https://stackoverflow.com/questions/58939778/convert-kubernetes-config-to-docker-compose-file-reverse-kompose/64143453 the feature that you need is only in v2 for now. It will be added to v3 later.

So I have recompiled v0.2.0 and uploaded it to the release https://github.com/konveyor/move2kube/releases/download/v0.2.0/move2kube-v0.2.0-recompiled-for-linux-amd64.tar.gz I have tested it and it works on CentOS:

# cat /etc/os-release
NAME="CentOS Stream"
VERSION="9"
ID="centos"
ID_LIKE="rhel fedora"
VERSION_ID="9"
PLATFORM_ID="platform:el9"
PRETTY_NAME="CentOS Stream 9"
ANSI_COLOR="0;31"
LOGO="fedora-logo-icon"
CPE_NAME="cpe:/o:centos:centos:9"
HOME_URL="https://centos.org/"
BUG_REPORT_URL="https://bugzilla.redhat.com/"
REDHAT_SUPPORT_PRODUCT="Red Hat Enterprise Linux 9"
REDHAT_SUPPORT_PRODUCT_VERSION="CentOS Stream"

# ./move2kube version -l
version: v0.2.0
gitCommit: 8a4e2b89f0908e08fa817467bf4cecfcb9649cc9
gitTreeState: clean
goVersion: go1.18.3
HarikrishnanBalagopal commented 2 years ago

Closing since this was fixed

HarikrishnanBalagopal commented 1 year ago

Fixed by https://github.com/konveyor/move2kube/pull/817