Raspberry pi

I did copy over the DNA file. What is also weird is I always get the same hash even when I input random uuids. I guess I’ll have to investigate whats going on inside holochain. Maybe conductor-api tampers with the input in some way…

Oh, be careful, I have seen myself and others stumbling over this…

The only method that seems to be succesffully returning distinct CellIDs is registerDna, not installAppBundle, which are you using?

I use registerDna() and it seemed to work okay on other platforms.
I might not be using the exact same holochain version on all platforms. Could be a reason for the difference…

One more thing, are you using registerDna directly, or are you in a tryorama context and using a tryorama function called registerDna? Apparently Hedayat was having an issue with the tryorama one, similarly

Figure out my problem. It was not raspberrypi related. It was because uuid got renamed to uid recently. On my raspberry I was using a more recent version that had that change, so it was failing to find an uid and was using the normal dnaHash at all times.

5 Likes

@ddd-mtl I’d be keen to replicate your process. Can you provide some high-level steps? And some clarifying questions for you:

  1. Did you go with a base Debian Arm64 OS?
  2. Did you install the OS using rpi-imager?
  3. Did you end up using NixOS?

I currently have Ubuntu/Gnome with Docker on my 8Gb rpi 4b just to see how well it would run, but I’m happy to use a lighter/faster 64bit OS (Raspberry Pi OS perhaps?). Cheers!

1 Like

That’s awesome @ddd-mtl !!
I have a Raspberry Pi at home so I’m looking forward to playing with it

1 Like

I’m using Ubuntu 20.10 desktop 64bit, that I installed on a usb ssd via berryboot. I don’t use nixOS. Make sure your pi has proper cooling. Compilation is pretty intense, I had to retry a couple of times. Also be ready to be patient, holochain took me 60min to compile…

2 Likes

I’ve successfully built holochain and hc from the GitHub repo and I can build the wasm and pack the dna and happ, but it fails with what looks like cranelift errors when running tryorama tests or spinning up a sandbox.

For anyone attempting this, you will also need to sudo apt install build-essential libssl-dev and of course install Rust before building holochain.

@ddd-mtl how much of that guide did you follow? Did you build wasmer from source? If so, did you run make build wasmer (because the guide is out of date on this step)? I can only get it to build cranelift.

What file did you edit to make this change? Also, how do you control what wasm runtime holochain is using (assuming you can/did)?

Thanks for any light you can shed!

  1. switch to rust nightly: rustup default nightly
  2. git clone wasmer v0.16:
git clone https://github.com/wasmerio/wasmer
git checkout 0.16.2
  1. Change the features in wasmer as mentionned in the article
  2. compile wasmer-runtime and wasmer-runtime-core
  3. Git clone holochain-wasmer ; Change the cargo.toml to use the locally compiled wasmer and compile
  4. Git clone holochain ; Change the cargo.toml to use the locally compiled holochain-wasmer and compile.

Something like:
holochain_wasmer_host = "=0.0.67"
to:
holochain_wasmer_host = { path = "../holochain_wasmer/crates/host" }

1 Like

Thanks for this write up. I also got things working using Singlepass :slight_smile:

Did you try LLVM as well btw? I’m wondering if that it’s an alternative way of doing it.

Alastair

Haven’t tried LLVM or anything else as this was good enough for me. I’m hoping holochain will upgrade to wasmer v1.0

I think that’s in the works. In the meantime, thanks! My nano was handling happ hosting fine yesterday :slight_smile:

1 Like

I obtained holochain, hc and lair-keystore binaries by compiling from source on Raspberry pi 4 in aarch64 architecture. I ran lair-keystore and then holochain as system daemon. It looks like it’s ready to build app with hc cli. I haven’t completed the tests yet but I haven’t used any docker containers or nixos. I compiled and ran it from source with rust directly on Future OS. I encountered a wasm compilation problem as you did, and I fixed this error with my little knowledge of rust. I am just learning the basic structure. After doing some research on Happs, I will create an application and share my observations with you. Sorry for my bad english.

I created an x86_64 docker container. Maybe you want to try it too. I would appreciate it if you let me know if there is something missing. Includes container rust, cargo, holochain, hc, lair-keystore, git and base system.

https://hub.docker.com/r/futurelinux/holochain/tags

You can find it at.

1 Like