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

Add Debian RISC-V #31

Open
benz0li opened this issue Jul 26, 2023 · 12 comments
Open

Add Debian RISC-V #31

benz0li opened this issue Jul 26, 2023 · 12 comments

Comments

@benz0li
Copy link

benz0li commented Jul 26, 2023

RISC-V is now an official Debian architecture: https://lists.debian.org/debian-riscv/2023/07/msg00053.html

The prebuilt is available at https://dl.b-data.ch/utm/debian-unstable-riscv64-utm4.zip

_virtual_machines/debian-riscv64.md:

---
title: Debian RISC-V
architecture: RISC-V64
memory: 1024 MiB
disk: 10 GiB
display: Console
spice_installed: false
username: debian
password: debian
screenshot: to be defined
download: to be defined
utm_link: true
---
## Notes
* Root account username/password is `root`/`password`. You should change this.
* This is a Debian image generated by the [Debian Quick Image Baker](https://people.debian.org/~gio/dqib/).
* Suite: unstable; APT source: `deb [arch=riscv64] http://deb.debian.org/debian/ unstable main`.
@rxhfcy
Copy link

rxhfcy commented Nov 28, 2023

@benz0li drive-by comment from a random user:

Thanks for the prebuilt image, it was very useful to me!

However, I don't think it could be added in its current form, because apt update doesn't work without first editing random text files (because RISC-V is not a "port" anymore).

I fixed things by editing /etc/apt/sources.list ("debian-ports" -> "debian"). I also removed the "unreleased" stuff.

These were the old contents of /etc/apt/sources.list:

deb [arch=riscv64] http://deb.debian.org/debian-ports unstable main
deb [arch=riscv64] http://deb.debian.org/debian-ports unreleased main

This is what I use now (seems to work):

deb http://deb.debian.org/debian/ unstable main

PS. After fixing sources.list, apt update && apt upgrade wanted to download I think hundreds of megabytes of updates, so that would be another reason to create a newer image.

@benz0li
Copy link
Author

benz0li commented Nov 28, 2023

so that would be another reason to create a newer image.

@rxhfcy Done.

debian-unstable-riscv64-utm4.zip now contains the image from the pipeline run on 26 November 2023 at 09:27:10 CET.

@benz0li
Copy link
Author

benz0li commented Feb 14, 2024

Please fix networking .

What do you mean by that?

@rxhfcy
Copy link

rxhfcy commented Feb 15, 2024

@benz0li could you try downloading a fresh copy of https://dl.b-data.ch/utm/debian-unstable-riscv64-utm4.zip and running it in UTM? After logging in, the network doesn't seem to work at all for some reason.

I have no idea where the root of the problem is. Is this something you could fix?

@benz0li
Copy link
Author

benz0li commented Feb 16, 2024

@benz0li could you try downloading a fresh copy of https://dl.b-data.ch/utm/debian-unstable-riscv64-utm4.zip and running it in UTM? After logging in, the network doesn't seem to work at all for some reason.

Done. Works as expected. (Sonoma 14.3.1 on arm64; UTM 4.4.4).

I have no idea where the root of the problem is. Is this something you could fix?

Me neither. Try changing the VMs network settings. Start with the Emulated Network Card.

@rxhfcy
Copy link

rxhfcy commented Feb 16, 2024

Thanks for the reply, but I still couldn't get things to work. Everything used to work fine before, no idea what changed. I tested different emulated network cards but none of the ones I tried worked. I was using UTM 4.4.5 (on ARM64 14.3.1) but I also tried UTM 4.4.4 and UTM 4.3.5 (didn't help either).

debian-unstable-riscv64-utm4.zip now contains the image from the pipeline run on 26 November 2023 at 09:27:10 CET.

BTW if it's not a huge hassle, could you create a newer image once again? Maybe that might help?

@benz0li
Copy link
Author

benz0li commented Feb 16, 2024

Everything used to work fine before, no idea what changed.

Sometimes I encounter network problems, too. The only thing that helps is rebooting the machine.

@rxhfcy
Copy link

rxhfcy commented Feb 16, 2024

Unfortunately rebooting doesn't help for me.

@ksbjr
Copy link

ksbjr commented Feb 16, 2024

ok found the fix. you have to download the newer img here new img rename file to .zip and then unpack it. go into utm and on the riscv vm delete the virtual driv. and then add a new vitrual drive and select the qcow2 img. Next you have to change networking in the vm to bridged, boot the img and login root/root and edit /etc/network/interface file and change the ip to match your network. seems dhcp is not in these images. once you do this reboot. then relogin and dpkg-reconfigure tzdata and set your time zone. then use date to set your time. then you can apt update. DO NOT DELETER THE KERNEL UNDER DRIVES ! this has the uboot and opensbi on it. leave it alone

@benz0li
Copy link
Author

benz0li commented Feb 17, 2024

BTW if it's not a huge hassle, could you create a newer image once again?

Done.


The network configuration remains unchanged for my images, i.e.

  • Network Mode: Emulated VLAN
  • Emulated Network Card: virtio-net-pci

@benz0li
Copy link
Author

benz0li commented Feb 17, 2024

P.S.: Use virt-customize from libguestfs to access and modify virtual machine (VM) disk images.

@TimTheBig
Copy link

TimTheBig commented May 8, 2024

At boot I get "Failed to connect to bus: No such file or directory" useing @ksbjr's method.
Then I get "Failed to start networking.service - Raise network interfaces."

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

No branches or pull requests

4 participants