# Facing issue when trying to convert existing ubuntu image for mender use

**URL:** <https://hub.mender.io/t/facing-issue-when-trying-to-convert-existing-ubuntu-image-for-mender-use/6405>\
**Category:** General Discussions\
**Tags:** ubuntu, mender-convert, mender-artifact\
**Created:** [December 6, 2023, 2:52pm UTC](https://hub.mender.io/t/facing-issue-when-trying-to-convert-existing-ubuntu-image-for-mender-use/6405 "2023-12-06T14:52:31Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![vimoxshah](https://yyz2.discourse-cdn.com/flex036/user_avatar/hub.mender.io/vimoxshah/32/2406_2.png) [@vimoxshah](https://hub.mender.io/u/vimoxshah)\
**Post date:** [December 6, 2023, 2:52pm UTC](https://hub.mender.io/t/facing-issue-when-trying-to-convert-existing-ubuntu-image-for-mender-use/6405/1 "2023-12-06T14:52:32Z")

</div>

I’m currently using a Dell machine with Ubuntu 22.04 OS installed.

I’m also exploring the possibility of using mender-convert on a raw Ubuntu ISO file to create a bootable USB that can handle the partitioning. If this is a viable solution, could you provide the necessary arguments for the mender-convert command?

When I tried below command

```auto
$MENDER_CONVERT_LOCATION/scripts/bootstrap-rootfs-overlay-hosted-server.sh \
--output-dir ${PWD}/input/rootfs_overlay_demo \
--region us \
--tenant-token “<token>"

```

I received an error for region so I modified the bootstrap-rootfs-overlay-hosted-server.sh script made it static to us and code worked.

After that I encountered an error related to the “mender-convert” modules and attempted to address it by modifying the “prob.sh” code, specifically changing the `target_arch` to “x86\_64” to resolve a previous error. However, I’m now encountering a different error.

The error arises when executing the following command in the terminal, specifically at line 42 of “deb.sh.”

```auto
MENDER_ARTIFACT_NAME=release-1 ./docker-mender-convert \
 --disk-image input/golden-image-1.img \
 --config configs/generic_x86-64_hdd_config \
 --overlay input/rootfs_overlay_demo/

```

Please check attached screenshot for detailed logs.

 ![Screenshot 2023-12-06 at 8.19.07 PM](https://canada1.discourse-cdn.com/flex036/uploads/mender/original/2X/0/0697a559e1a6197625a456a8b81e2f1d9b3a1800.png)

Ideally I should not change the code it should work as expected mentioned in the docs but unfortunately it is not working.

I’m hesitant to make further changes to the code as it may complicate management. Could you please provide assistance in a more effective manner to resolve this issue?

---

<div class="post-metadata">

**Author:** ![vimoxshah](https://yyz2.discourse-cdn.com/flex036/user_avatar/hub.mender.io/vimoxshah/32/2406_2.png) [@vimoxshah](https://hub.mender.io/u/vimoxshah)\
**Post date:** [December 11, 2023, 11:08am UTC](https://hub.mender.io/t/facing-issue-when-trying-to-convert-existing-ubuntu-image-for-mender-use/6405/2 "2023-12-11T11:08:35Z")

</div>

@pierrer @lluiscampos Can anyone please help

---

<div class="post-metadata">

**Author:** ![vimoxshah](https://yyz2.discourse-cdn.com/flex036/user_avatar/hub.mender.io/vimoxshah/32/2406_2.png) [@vimoxshah](https://hub.mender.io/u/vimoxshah)\
**Post date:** [December 11, 2023, 12:32pm UTC](https://hub.mender.io/t/facing-issue-when-trying-to-convert-existing-ubuntu-image-for-mender-use/6405/3 "2023-12-11T12:32:00Z")

</div>

@MarekBelisko @AkshatVyas any help would be much appreciated!

---

<div class="post-metadata">

**Author:** ![MarekBelisko](https://yyz2.discourse-cdn.com/flex036/user_avatar/hub.mender.io/marekbelisko/32/33_2.png) [@MarekBelisko](https://hub.mender.io/u/MarekBelisko)\
**Post date:** [December 13, 2023, 6:39am UTC](https://hub.mender.io/t/facing-issue-when-trying-to-convert-existing-ubuntu-image-for-mender-use/6405/4 "2023-12-13T06:39:58Z")

</div>

@vimoxshah check if wget is not an issue as stated in log please. Maybe it was temporary hickup.

---

<div class="post-metadata">

**Author:** ![lluiscampos](https://yyz2.discourse-cdn.com/flex036/user_avatar/hub.mender.io/lluiscampos/32/112_2.png) [@lluiscampos](https://hub.mender.io/u/lluiscampos)\
**Post date:** [December 19, 2023, 10:43am UTC](https://hub.mender.io/t/facing-issue-when-trying-to-convert-existing-ubuntu-image-for-mender-use/6405/5 "2023-12-19T10:43:12Z")

</div>

Hi @vimoxshah,

This might be a bug on `mender-convert` or `/etc/os-release` missing from your golden image.

From your logs I can see “wget …dists//stable/…”, which indicates that the distribution name is empty. There is a [piece of code](https://github.com/mendersoftware/mender-convert/blob/066f5cfacb016e6d2c964f870f60361204991d3d/modules/probe.sh#L122-L134) to “probe” the OS distro name but it seems to be returning empty for you. Can you verify that the file exists? And what are the contents?

```auto
cat etc/os-release

```

Lluís
