Skip to content

Commit

Permalink
Organize Docs (#787)
Browse files Browse the repository at this point in the history
* organizing documentation
  • Loading branch information
0o-de-lally authored Oct 29, 2021
1 parent 70272b7 commit d70716f
Show file tree
Hide file tree
Showing 65 changed files with 69 additions and 148 deletions.
30 changes: 30 additions & 0 deletions ol/documentation/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
# 0L Documentation
## CLI
[CLI Cheatsheet](cli_cheatsheet.md)

## Running Tower, i.e Mining.

[Start Tower app](node-ops/tower_mining_VDF_proofs.md)

## Syncing your node
[Sync your node from to an advanced epoch](node-ops/syncing_your_node.md)

## Fullnode Operations
[Starting a Fullnode](node-ops/start_a_full_node.md)

## Validator Node Operations
[Onboard a validator node - easy mode](node-ops/validators/validator_onboarding_easy_mode.md)

[Onboard a validator node - hard mode](node-ops/validators/validator_onboarding_hard_mode.md)

[Run diem-node as daemon](node-ops/validators/validator_daemon_configs.md)

[Troubleshooting Onboarding](node-ops/validators/troubleshoting_onboarding.md)

[What to do when your node falls out of validator set](node-ops/validators/node_falls_out_of_validator_set.md)

[update_validator_to_operator_mapping.md](node-ops/validators/update_validator_to_operator_mapping.md)

# Network Upgrades

[Hot network upgrades](network-upgrades/stdlib_hot_upgrade.md)
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,6 @@ Alice:
# if you don't have a mnemonic
onboard keygen
#if you ALREADY have a mnemonic buy you need to discover your Auth Key. Find out with:
onboard keygen -w
>enter the mnemonic
# send your `auth key` to Bob so he can complete tx
```
Expand All @@ -30,7 +26,7 @@ Needs to send a minimum of 1 GAS coin so that Alice's account gets created.
txs create-user -a <alice's auth key> -c <how many coins to send to alice>
# check that the account was created:
ol -a <alice's ACCOUNT> query --balance
ol query --balance -a <alice's ACCOUNT>
```

## Alice: Create account configurations
Expand All @@ -47,9 +43,6 @@ If you already have a mnemonic, and misplaced your account `address` or `authent
# use keygen with --whoami, or -w
onboard keygen -whoami
> enter your mnemonic now
# you will see the print out of account and authkey
```
## Alice: tell Bob your authkey

Expand All @@ -62,12 +55,13 @@ Send the onboarding transaction
txs create-user -a <alice's auth key> -c <how many coins to send to alice>
```


## Alice or Bob: Confirm the account was created

If the account creation was successful anyone should be able to see Alice's balance (of 1 GAS) with the following command.

```
ol -a <alice's ACCOUNT> query --balance
ol query --balance -a <alice's ACCOUNT>
```

## Alice: Set Slow Wallet, or Community Wallet
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,26 +24,3 @@ If it is not reachable, the `file` option below is possible.
If there is an issue with sequence_number being out of sync. It's like that an automated transaction (like `tower`), got a transaction sent concurrently. Retry the transaction.



## With file:

a. Copy the `account.json` to your local node.

b. Sumbit tx with `txs` app:

```
txs create-validator -f <path/to/json>
```


# New End User Accounts

## With file:

a. Copy the `account.json` to your local node.

b. Sumbit tx with `txs` app:

```
txs create-user -f <path/to/json>
```
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
# Debugging Account state and balances

Use libra client with
Use the "toy" client with

```
cargo run --bin cli -- -u http://localhost:<port> --waypoint <waypoint>
```

Note the `auth_key` of the tower app in question.
Note the `account` of the tower app in question.
Then in the libra shell:
```
query account_state <auth_key>
query account_state <account>
```

and you will see a result like this:
Expand Down Expand Up @@ -76,7 +76,9 @@ Latest account state is:
"00000000000000005942d356f114089d4a46f2f3b0b15b52",
),
delegated_key_rotation_capability: false,
delegated_withdrawal_capability: false,
delegated_wi
thdrawal_capability: false,
role: Empty,
},
)
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
# Stdlib Upgrade payload (v5)
# Stdlib Compilation and Fixtures



## Hot Upgrades for production

Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,21 @@ These instructions target Ubuntu.

1.4. Config dependencies:

`cd </path/to/libra/source/> && . ol/util/setup.sh`
```
cd </path/to/libra/source/>
. ol/util/setup.sh`
```

For more details: (../devs/OS_dependencies.md)

1.5. Build the source and install binaries:

`cd </path/to/libra/source/> && make bins`
```
cd </path/to/libra/source/>
make bins install
```

## 2. Catch-up to the network state, with a `fullnode`

Expand All @@ -32,4 +40,4 @@ You do not need an account for this step, you are simply syncing the database.

2.2. `diem-node --config $HOME/.0L/fullnode.node.yaml`

**You can start the next steps while your node is catching up**
More details in: [syncing_your_node.md](syncing_your_node.md)
Original file line number Diff line number Diff line change
Expand Up @@ -49,9 +49,6 @@ Restore a specific epoch
ol restore --epoch <integer>
```


``

## Hard Mode: If you are not using the `ol` tools

### Restore Epoch Waypoint
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
# Mining VDF proofs
# Running Tower: ie. Mining VDF proofs

These instructions are to run the 0L `tower` app. This creates VDF proof of work, and submits to the chain sequentially.

This documentation uses screen as terminal multiplexer, sure you can also use tmux or run it in a normal terminal session.

## Start a `screen` instance
## Start a `screen` or `tmux` instance

Make `screen` work for backgrounding and resuming sessions:
```
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,9 +1,5 @@
# Running 0L validator as a system service
<<<<<<< HEAD
This guide will create a daemon service which runs a `diem-node` and restarts on failure and on reboot.
=======
This guide will create a daemon service which runs `diem-node` and restarts on failure and on reboot.
>>>>>>> 4d472361166d7f7fa816b02bb0002d3858d68390

Note that this guide:
- targets Ubuntu 20.4.
Expand All @@ -23,11 +19,7 @@ There are a few file paths you will be working from:

This will use a `make` recipe to start the node daemon and install the daemon configs.

<<<<<<< HEAD
First. Copy a template for systemd from `<project root>/util/diem-node.system` into your 0L home path, usually `~/.0L`. This is non-root template file needs to be edited: replace occurrences of `<<YOUR USERNAME!>>` with the username under which the service will run.
=======
First. Copy a template for systemd from `<project root>/util/diem-node.system.template` into your 0L home path, usually `~/.0L`. There are two templates for running as `root` or with a `user`. Note that the non-root template file needs to be edited: replace occurrences of `[USER]` with the username under which the service will run.
>>>>>>> 4d472361166d7f7fa816b02bb0002d3858d68390

BEFORE PROCEEDING: Check you have `~/.0L/diem-node.system` in place and edited with your usename.

Expand All @@ -40,44 +32,21 @@ From the project root:
# Slow Start

## Build binaries and copy to appropriate path
<<<<<<< HEAD
Use `make bins install` or alternatively:


## Create the service configurations for Systemd
In `~/.config/systemd/user/` you should create a file like this. (Note: again, `make daemon` does this for you)
=======
Use `make bins`

## Validator Wizard

If your config files have not been created or misplaced run:
`cargo run -p tower -- val-wizard`

## Create the service configurations for Systemd
cd /lib/systemd/system/
vim diem-node.service
>>>>>>> 4d472361166d7f7fa816b02bb0002d3858d68390

```
# edit this document and replace <<YOUR USERNAME!>> with your linux user
[Unit]
<<<<<<< HEAD
Description=0L Node Service
[Service]
LimitNOFILE=20000
WorkingDirectory=/home/node/.0L
ExecStart=/home/node/bin/diem-node --config /home/node/.0L/validator.node.yaml
=======
Description=Diem Node Service
[Service]
#File descriptors frequently run out
LimitNOFILE=65536
WorkingDirectory=/root/.0L
ExecStart=/usr/local/bin/diem-node --config /root/.0L/node.yaml
>>>>>>> 4d472361166d7f7fa816b02bb0002d3858d68390
Restart=always
RestartSec=10s
Expand All @@ -89,10 +58,6 @@ StandardError=file:/home/node/logs/node.log
[Install]
WantedBy=multi-user.target
Alias=diem-node.service
<<<<<<< HEAD
=======
>>>>>>> 4d472361166d7f7fa816b02bb0002d3858d68390
```
### NOTE: When you update any `*service` file, you must reload `ststemctl`
`systemctl daemon-reload`
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
# Validator Setup


## Requirements
- A unix host machine, e.g Linux Ubuntu 20.4
- A fixed IP address of the machine
Expand Down Expand Up @@ -133,7 +131,8 @@ ol restore
**note**: temporarily: as of v4.2.8 you'll need to increase your host's file descriptors. Fix is in the works. For now:
run this before starting your `tmux` session.
```
# increase file descriptors
# increase file d
escriptors
ulimit -n 100000
# check that they have been increased
ulimit -n
Expand Down
53 changes: 0 additions & 53 deletions ol/documentation/ops/stdlib_upgrade_payload.md

This file was deleted.

24 changes: 12 additions & 12 deletions ol/documentation/roadmap.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,6 @@

### V.5.0.0 +


1. Merge Upstream 1.3.0
1. Package 0L changes as a module
1. Regex libra->diem

1. Packaging of non-stdlib smart contract (module) - Documentation (AD)

1. Audit (JM)
1. Audit of v5 Move contracts.
1. Formal verification of access control to functions.

### Future

1. Cross chain prototype (ZM)
Expand Down Expand Up @@ -74,4 +63,15 @@

1. Genesis from archive
1. create a genesis blob from epoch snapshot
1. modify snapshot to update state before saving genesis.
1. modify snapshot to update state before saving genesis.

### v5.0.0
1. Merge Upstream 1.3.0
1. Package 0L changes as a module
1. Regex libra->diem

1. Packaging of non-stdlib smart contract (module) - Documentation (AD)

1. Audit (JM)
1. Audit of v5 Move contracts.
1. Formal verification of access control to functions.

0 comments on commit d70716f

Please sign in to comment.