SafeNet from an ops view

I come from an Ops and integrator perspective. While I try to “play a programmer on TV”, I have a long way to be able to say I am so.

So I was trying to set up a 3 computer SafeNet. The CLI seemed to be my entry point, at least with that, I could do some basic functions is the view I had.

I was using basic VMs running windows 10 on Azure. I tried to use the script found at sn_api/ at master · maidsafe/sn_api · GitHub

After some trial, error and research, I ended up needing to have the c++ dev tools installed to get the sn_ binaries to run. Seems a bit odd as I thought rust binaries could run without help, so I think this should be addressed in the binary publish step to include what is needed to run.

So following the CLI readme, I was able to get safe -V to run. Yay.
safe node install I get the install message ok and then safe node run-baby-fleming
and it’s 10 nodes are running.

I keep following the readme and add the test next and then

ivan@safe3 MINGW64 ~

$ safe networks check

Checking current setup network connection information…

Well, this is embarrassing.

sn_cli had a problem and crashed. To help us diagnose the problem you can send us a crash report.

So my point is that this is all still very confusing to me.

I have apps that I am overseeing being developed that are not currently FOR SafeNet, but would be really awesome to use SafeNet in particular for data storage.
I work in F# on dotnet. Say what you will, but dotnet is a huge ecosystem and supporting it will be extremely helpful in developers adopting SafeNet.

I am referencing this page a lot

And this diagram in particular

I actually just found this Inter repository dependencies
So that still leaves me with questions.

I am willing to spend resources for this to be an easy process for me and others, but I want to spend wisely in that I do not want to work on something that is already being addressed.

Upon standard deployment, will a particular machine have 1 node or multiple nodes? I think it is 1 and the script is starting 10 so there is a local net.

Want I want is to have an installer that allows me to start it and it handles everything needed. I then want to be able to do configuration to chose to install a node or the number of nodes.

I want to be able to connect multiple machines to one SafeNet and have that be a simple process.

So that leads me to my next question of what is the minimum setup needed to have a node on one machine connect to another? What is the underlying routing needed in order for SafeNet to work? Meaning, two computers with IP4 in the same network mask connected through a switch. i.e. and TCP? Or even IP6.
But then when we get to one network through routers to another network (like on the current internet) what is needed to connect and run on the internet side in order for SafeNet to operate?

So once I understand how to make my own testnet then I need to figure out how my F# or dotnet app then accesses the SafeNet to say store it’s files.
The ffi seems to be the one option but that seems like it is old so now I see sn_csharp but I am still confused on where to access that.

So am I just confused at this in trying to get setup and how to do things. If I am able to lay this out and such, I am happy to publish posts or a blog or even update GitHub readme if I can create a clear picture.


Forum is surprisingly quiet right now. I’d cc: @bochaco and @joshuef on the state of FFI (which I think they maybe aren’t moving away from?) and sn_sharp.


Yes, there is massive churn as we race to launch right now. From the CLI you should be able to setup and run your own network easily. Running a local network from ip4 or 6 is also possible.

FFI has been ignored along with c# etc. for now as all resources are on launch of the core network. We are inclined to go for WASI.WASM binary releases for interoperability, but have not decided on that just yet.

As I say we have dropped pretty much all for launch, I Am sure the guys will jump in to help you out, but right now it’s not as easy as it should be for folk to jump in and run their own networks, many do, but there is no simple guide as such. @StephenC can maybe point you to some scripts if that helps.


If you wait a few weeks, let us get this testnet out, then the docs will update and you can try from there. Not ideal, but right now there is too much happening at once for us to update these docs. It would be nice to have feedback on the install/run process from these docs when we do update them.


Thanks lot for sending the report for the issue you had when trying to run the CLI on windows, I know you are aware of already but we’ve added a paragraph to the CLI User Guide to mention this prerequisite for Windows.
But we couldn’t reproduce the issue you had when running the $ safe networks check command, do you still have it after installing latest version of CLI with $ curl -so- | bash ?
Can you confirm which version you get when you do $ safe -V ?


Be aware that there an issue on the way when using wasm-bindgen with WASI. It currently works with Rustc stable, but not nightly so I expect this to break stable too unless wasm-bindgen is updated, which would be great but it’s not planned AFAIK. See: Can't work with wasm32-wasi target from rustc-2021-01-13 · Issue #2471 · rustwasm/wasm-bindgen · GitHub


Nice one Mark, thanks for the heads up.


Am I reading that the testnet is confirmed to launch in less than a month?

1 Like


ivan@safe3 MINGW64 ~
$ safe -V
sn_cli 0.20.0

The email I sent (as directed in the safe command for errors) had a text attachment name of bashconsole.txt
That is copy and pasted from the gitforwindows bash console of the commands.
I can forward to you if you like. or post here. whatever is needed.


Where is that info I want to read it too :wink:


Got it, thanks! I’m seeing there is something else there to try out on our side to try to reproduce the issue, I’ll keep you posted.

1 Like

Following the readme, the issue is when trying to switch to testnet

ivan@safe1 MINGW64 ~
$ safe networks check
Checking current setup network connection information…

Current network setup in your system doesn’t match any of your networks in the CLI config. Use ‘networks switch’ command to switch to any of them

ivan@safe1 MINGW64 ~
$ safe networks add maidsafe-testnet
Network ‘maidsafe-testnet’ was added to the list. Connection information is located at ‘

ivan@safe1 MINGW64 ~
$ safe networks switch maidsafe-testnet
Switching to ‘maidsafe-testnet’ network…
Fetching ‘maidsafe-testnet’ network connection information from ‘’ …
Well, this is embarrassing.

sn_cli had a problem and crashed. To help us diagnose the problem you can send us a crash report.

We have generated a report file at “C:\Users\ivan\AppData\Local\Temp\report-23ea81d5-d75c-4a97-9584-339ddff0e007.toml”. Submit an issue or email with the subject of “sn_cli Crash Report” and include the report as an attachment.

  • Authors: bochaco <redacted>, Josh Wilson <redacted>

We take privacy seriously, and do not perform any automated error collection. In order to improve the software, we rely on people to submit reports.

Thank you kindly!

ivan@safe1 MINGW64 ~

1 Like

I just re-read this…
" This requires that the sn_node , sn_authd and CLI themselves be installed in the correct locations on the system"
that might be my issue. I have not installed anything else…

did the
$ safe auth install
Latest release found: sn_authd v0.2.0
[00:00:00] [========================================] 5.44MB/5.44MB (0s) Done
Creating ‘C:\Users\\authd’ folder
Installing sn_authd.exe binary at C:\Users\\authd …

doing then
$ safe auth start

did not really return. It just hangs there for. After a few minutes, I did a past or a safe -V, not really which command brought back the bash prompt.

$ safe auth status
Sending request to authd to obtain a status report…
| Safe Authenticator status | |
| Authenticator daemon version | 0.2.0 |
| Is there a Safe currently unlocked? | No |
| Number of pending authorisation requests | 0 |
| Number of notifications subscribers | 0 |

ivan@safe1 MINGW64 ~
$ safe networks
Well, this is embarrassing.

sn_cli had a problem and crashed. To help us diagnose the problem you can send us a crash report.

So it seams to be related to the system not knowing the network thing.

The error in your report is:

Panic occurred in file 'C:\Users\runneradmin\.cargo\registry\src\\tokio-1.2.0\src\runtime\blocking\' at line 85
cause = 'there is no reactor running, must be called from the context of a Tokio 1.x runtime'

Which is very weird as we haven’t upgraded Tokio to v1 yet, so that’s why I initially thought you were building it yourself or something like that.

1 Like

Nope, way not to that level here. Literally just trying to follow along the readme in github…


Been doing some digging on this and made some progress in narrowing down the crash cause - it appears the issue only occurs when attempting to switch to a non-local config file, i.e. Ivan is attempting to switch to a config file on S3.

Note that this is NOT only on Windows, I’ve replicated on macOS as well, so no doubt also reproducible on Linux distros.

I’ve logged a GitHub issue with my findings here so it will be tracked there to resolution.

@IvanRainbolt First of all, thanks for flagging this! You can actually continue experimenting without this issue affecting you as the config file you were attempting to switch to on S3 is only actually of any use when we have a hosted shared testnet up & running that everyone connects to. At this point in time we are working on a new testnet, so nothing is live for you to connect to. Once a new testnet is up we would upload a new config file to S3 and make it public so everyone who wants to connect to the testnet can point to it and bootstrap via the IP(s) in it.

It seems from your text above that you have already worked through the Run a local network section of the CLI user guide so you are on the right track.
You can skip the Connect to a shared network (maybe other than trying safe node join if you want to add more local nodes), Switch networks and Set network bootstrap address sections until a public testnet is released - at that point you could have, for example, a network config for a local network on your machine, the maidsafe hosted network (config on S3) and maybe even a community hosted network, being able to switch between them with ease.

It’s great you caught caught this issue now as it would have been a frustrating one to find and have to track down just as we were about to make a testnet announcement. It will of course need to be fixed as a priority.


Thanks a lot @StephenC , I was able to reproduce it on linux and found the root cause already, it’s due to one of the CLI dependencies (reqwest) that is already making use of Tokio v1 which is incompatible with all versions < 1, thus the error we see is due to this incompatibility.

Good news is today we started upgrading Tokio across the board, so the following PR will solve this issue in CLI: chore(tokio): upgrade tokio to v1.3.0 by bochaco · Pull Request #728 · maidsafe/sn_api · GitHub


If there is any, I’m up for it !


I am very excited for WASI, but I think it will be at least a year (could be quite an understatement), before we see it capable of networking and cryptography. They’re working on some implementations, but so far there is no specification of how the capabilities are supposed to work. It’s full in progress (various issues on GitHub and pull requests), but I wouldn’t bet on it anytime soon. It does support filesystem capabilities (implemented in Rust and wasmtime), but that’s very different from sockets/networking.

In short, a lot of parts have to come together before it’s really usable. If the WASI specification is ‘done’, compilers like Rust have to implement it, and then the WASM runtimes like Node.js/V8 and wasmtime will have to support it.