Skip to content

Commit

Permalink
Hid empty categories. Added articles from Mike about NavPi. Added CFu…
Browse files Browse the repository at this point in the history
…nd category and article
  • Loading branch information
matt-auckland committed Mar 21, 2019
1 parent b516875 commit 9281417
Show file tree
Hide file tree
Showing 11 changed files with 484 additions and 39 deletions.
3 changes: 3 additions & 0 deletions .github/CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# Contributing

[Read this article](https://navcoin-knowledge-base.netlify.com/technical-support/contribute-to-the-knowledge-base/)
2 changes: 2 additions & 0 deletions content/Block Explorer/_index.en.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,6 @@ date: 2018-12-29T11:02:05+06:00
icon: "fas fa-cubes"
description: "Block explorers are sites that let you look up NavCoin transactions and addresses."
type : "pages"
draft: true

---
7 changes: 7 additions & 0 deletions content/Community Fund/_index.en.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
---
title: "Community Fund"
date: 2018-12-29T11:02:05+06:00
icon: "fas fa-piggy-bank"
description: "Articles related to the Community Fund can be found here."
type : "pages"
---
50 changes: 50 additions & 0 deletions content/Community Fund/creating a community fund proposal.en.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
---
date: "2019-03-18"
title: "Creating a Community Fund proposal"
draft: false
---

### NavCoin Core Wallet


Go to the create proposal page in the Proposal Builder and fill in the form (The proposal builder can be found [here](https://nav-proposal-creator.netlify.com/) )

After filling in the form, click the GENERATE COMMAND button and copy the code that appears below.

Open your NavCoin Core wallet and in the dropdowns select Debug Window under Help.

In the textbox enter `walletpassphrase "passphrase" timeout`, where `"passphrase"` is your wallet’s password and `timeout` is how long you wish to unlock your wallet in seconds.
e.g. `walletpassphrase "MySecurePassword" 30`

With your wallet unlocked, paste in the generated code from the proposal website
e.g. `createproposal mnyKBfcG4cGfhNZQqbBAaN1ujvjyMEg9wt 1000 42595200 "NavCoin Italia meet up event 2019 funding"`

Your proposal has now been submitted.


### NavPi

Open the webview of your NavPi in your web browser
e.g. 192.168.30.247

In the top navigation menu click 'Community Fund'

On the community fund page you will see the Create Proposal form. Fill it in and click the GENERATE COMMAND button

Copy the command that it generates and paste it into the `Command` text input below.

Click the Issue Command button.

Your proposal has now been submitted


### If something went wrong

If something went wrong make sure that:

You have at least 50 NAV in your wallet as this is the minimum fee required to submit a proposal

You pasted in the entire `createproposal` command

Your wallet didn’t relock itself before you pasted in the `createproposal` command (if you’re using the NavCoin Core Wallet)

2 changes: 2 additions & 0 deletions content/NavPay/_index.en.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,6 @@ date: 2018-12-29T11:02:05+06:00
icon: "fas fa-mobile-alt"
description: "NavPay is a lite wallet for desktop and mobile"
type : "pages"
draft: true

---
1 change: 1 addition & 0 deletions content/Paper Wallet/_index.en.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,5 @@ date: 2018-12-29T11:02:05+06:00
icon: "fas fa-wallet"
description: "The Paper Wallet is a way of safely storing your coins offline."
type : "pages"
draft: true
---
1 change: 1 addition & 0 deletions content/Stakeboxes/Update the NavPi.en.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
---
title: How to update the NavPi
date: "2019-03-21"
---

### Updating the User Interface
Expand Down
207 changes: 207 additions & 0 deletions content/Stakeboxes/add swap to a NavPi.en.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,207 @@
---
title: "Creating swap on NavPi SD card"
date: "2019-03-21"
---

These are the consolidated steps from a post by Justin Ellingwood called [Add Swap Space on Ubuntu](https://www.digitalocean.com/community/tutorials/how-to-add-swap-space-on-ubuntu-16-04).

The configuration has been tested on the current version of the NavPi, running Rapsbian GNU/Linux 8 (jessie)

### Prerequisites, Caveats
For best results, it's recommended to utilize a USB drive as your swap space, due to the fact that repeated reads/writes to the SD card will eventually wear it out. You can follow this [USB swap guide](/stakeboxes/configure-navpi-to-use-usb-swap) or proceed with the SD swap configuration below. For example, you may just want to use the SD swap temporarily until you're ready to move to the USB swap solution.

## Let's get started

### Backup your current NavPi img
Before proceeding with this swap configuration, it is worth making a backup image of the SD card so if it fails, you can easily restore to this point.

### Backup your wallet.dat
To ensure you don't lose any coins while making configuration changes to your NavPi, it's essential to backup the wallet.dat file. This holds your private keys. With a backup of the wallet.dat you can always restore your wallet.

First, make sure your have encrypted your wallet. Then proceed with the following steps:

1. Open the WebUI
2. Go to `control`
3. Scroll down to `security`
4. *Click* `Backup Wallet`. This will download the wallet.dat file to your preferred device (USB, HD)
5. Save the wallet backup and rename it to `wallet.dat`

### Check system for swap info

`sudo swapon --show`

### Verify no swap exists

`free -h`

### Check available space on hard drive

`df -h`

### Create swap file

`sudo fallocate -l 2G /navswap`

### Verify correct amount of space reserved

```bash
ls -lh /navswap

Output
-rw-r--r-- 1 root root 1.0G Apr 25 11:14 /navswap`
```

### Make the file only accessible to root

`sudo chmod 600 /navswap`

### Verify permissions change

```bash
ls -lh /navswap
Output
-rw------- 1 root root 2.0G Apr 25 11:14 /navswap
```

### Mark file as swap space

```bash
sudo mkswap /navswap
Output
Setting up swapspace version 1, size = 2048 MiB (1073737728 bytes)
no label. UUID=XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX
```

### Enable swap file

`sudo swapon /navswap`

### Verify that the swap is available

```bash
sudo swapon --show
Output
NAME TYPE SIZE USED PRIO
/navswap file 2G 0B -1
```

### Check the output of the free utility

```bash
free -h
Output
total used free shared buff/cache available
Mem: 488M 37M 96M 652K 354M 425M
Swap: 2.0G 0B 2.0G
```

The swap has been set up successfully. Operating system will begin to use it as necessary.

### Make the Swap File Permanent

First backup your `/etc/fstab` file

` sudo cp /etc/fstab /etc/fstab.bak`

Then add the swap info as follows
```bash
echo '/navswap none swap sw 0 0' | sudo tee -a /etc/fstab
Output
/navswap none swap sw 0 0
```

## Tweak your Swap Settings

Configure your NavPi's performance when dealing with swap.
### Configure swappiness
The swappiness parameter configures how often your system swaps data out of RAM to the swap space. This is a value between 0 and 100 that represents a percentage.
```bash
sudo sysctl vm.swappiness=10
Ouput
vm.swappiness = 10
```
This value is sometimes recommended to improve performance when sufficient memory exists in a system, this value *10* could be considered for the performance being expected.
Make this persist on reboot:
` sudo nano /etc/sysctl.conf`
Add this at bottom of file:
` vm.swappiness=10`
### Adjust the cache pressure
This setting configures how much the system will choose to cache inode and dentry information over other data.
Check the current cache pressure setting:
```bash
cat /proc/sys/vm/vfs_cache_pressure
Ouput
100
```
By default, the system removes inode information from the cache too quickly.
Set this to a more conservative setting like 50:
```bash
sudo sysctl vm.vfs_cache_pressure=50
Output
vm.vfs_cache_pressure = 50
```
Make it persist:
` sudo nano /etc/sysctl.conf`
Add this to bottom of file:
`vm.vfs_cache_pressure=50`
Save and close the file.
### Reboot NavPi
` sudo reboot`
### Verify new swap
```bash
cat /proc/swaps
Output
Filename Type Size Used Priority
/navswap file 2097418 0 -1
```
### Check memory usage with swap in place
There are several options for checking memory use.
Built-in commands include:
`free -h`
`top`
**pro tip** - Install htop, a nice option for monitoring interactively. It's a nice way to filter on running processes, like 'nav'. It combines the functionality of top and iotop into a single screen.

```bash
sudo apt-get install htop
htop
```

You should now see the swap drive being monitored.
Loading

0 comments on commit 9281417

Please sign in to comment.