Skip to content

Latest commit

 

History

History
84 lines (64 loc) · 2.48 KB

README.md

File metadata and controls

84 lines (64 loc) · 2.48 KB

Seguro

This is the work-in-progress repo for Phase 2 of the Seguro implementation for the Urbit project.

More information:

Installation

Dependencies:

Configuration

After installing the clients and server packages of FoundationDB, the default server should be reconfigured for local testing. This can be done using the fdbcli utility on Linux and MacOS:

fdbcli
configure single ssd

This will set the default local FoundationDB cluster to store a single copy of data on disk.

Usage

Run tests

The following command will run all Seguro tests:

make test

Alternatively, the unit or integration tests can be run separately from each other:

make test-unit
make test-integ

Run benchmarks

The following command will run all Seguro benchmarks:

make benchmark

Troubleshooting

The state of the local FoundationDB cluster can be monitored using the fdbcli utility. It's self-documented, but additional information can be found in the official FoundationDB documentation.

However, be warned that the fdbcli can be finicky, and can lie. Some examples:

  • Complaining that there is no memory available with 12GB memory available
  • Complaining that there is no space on the drive available when there is 50GB space available
  • Errors during benchmark tests while the status command shows nothing wrong
  • No errors during benchmark tests while the status command shows memory and storage warnings

Soft Reset

If the test or benchmark suites suffer a fatal error, the local FoundationDB may be stranded in an unclean state. It may be necessary to manually drop keys from the cluster to ensure tests/benchmarks accurately measure correctness/performance:

fdbcli
writemode on
clearrange "" \xFF

The above series of commands will drop all keys from the FoundationDB cluster.

Hard Reset

If the FoundationDB cluster becomes so broken during development that a hard reset is required, the following commands will return the cluster to its initial state after a fresh installation:

sudo systemctl stop foundationdb
sudo rm -rf /var/lib/foundationdb/data
sudo systemctl start foundationdb
fdbcli
configure new single ssd