# WorkHeart USB node for Ubuntu version

## 1. Minimum system requirements

* **OS**: Ubuntu (Recommended)
* **Storage**: 100GB available storage
* **Memory**: 4GB RAM
* **Processor**: A processor with 6 cores, x86 architecture.

## 2. Install node running program

1. Run the node program using the root user

Use the following command to switch to the root user. You will need to enter the password for the account currently in use on your Ubuntu system. Upon successful switch, the terminal will display the root identifier.

```json
sudo su
```

<div align="left"><figure><img src="/files/aDpyuPFThtPjQAH6lSv8" alt=""><figcaption></figcaption></figure></div>

2. Create a program running directory and navigate to it:

```bash
mkdir -p  /privasea/config && cd  /privasea
```

3. Download the node installation script setup.sh

Note: If executing source setup.sh fails, please refer to the&#x20;

{% content-ref url="/spaces/2GSryxoPXpRdDGxtzpAS/pages/adjBarh9Cf67QXw1fBh9" %}
[Download and installation steps of WorkHeart USB node program for Ubuntu version](/user-node-usage-documentation/comprehensive-guide-to-privanetix-node-acceleration-node-and-workheart-node-setup-and-operation/download-and-installation-steps-of-workheart-usb-node-program-for-ubuntu-version.md)
{% endcontent-ref %}

```bash
# Download the setup.sh script：
wget https://storage.googleapis.com/bkt-privasea-face-pre-public/calc-node/beta/setup.sh

# Grant execution permissions to the setup.sh script:
chmod +x setup.sh

# Run the setup.sh script:
source setup.sh 

# Explanation:
# If you are prompted that the wget command is not found, please do the following or ask ChatGPT:
# To install wget on Ubuntu: sudo apt install wget
```

<figure><img src="/files/IH8tXjqX7KOHMgdJ4QQ1" alt=""><figcaption></figcaption></figure>

4. A directory named `usb-ubuntu-node` will be generated in the same directory as `setup.sh`. This is the node program.\
   Enter the `usb-ubuntu-node` directory, you can see 4 program files

```bash
# Enter the usb-arm-node directory, you can see 4 program files
cd  /privasea/usb-ubuntu-node  &&  ls
# Configure the environment variables required to start the USB driver
source usb-driver.sh 
```

<figure><img src="/files/TlmpD24X83nHaZWh0L3Z" alt=""><figcaption></figcaption></figure>

## 3. Configure  node running program

1. Get keystore file

You can directly use the existing wallet keystore. If there is no keystore file, you can execute the following command to generate it:

**Note**: The program will prompt you to enter a password, <mark style="color:purple;">please remember this password for future use.</mark> The generated keystore file will have a corresponding **node address**, Please keep it properly to avoid losing it, it will be used in the dashboard configuration

```bash
# Enter the program directory
cd  /privasea/usb-ubuntu-node
# Run the calculation node
./calc  new_keystore  
```

<figure><img src="/files/pFMYQPV5Jo41IvxFUE3w" alt=""><figcaption></figcaption></figure>

```bash
Enter password for a new key:   # Enter wallet password
Enter password again to verify:   # Enter password again for confirmation

# After the wallet is successfully generated, you will see the following information:
# account address: 0xed78283432F4F73653e493Df0bEB5EC9FA4C33d3
#  This is the node address you generated, used for binding in the dashboard
# account filename: keystore:/privasea/config/UTC--2024-1216T11-26-41.2628933482--ed78283432f4f73653e493df0beb5ec9fa4c33d3
#  UTC--2024-1216T11-26-41.2628933482--ed78283432f4f73653e493df0beb5ec9fa4c33d3 is the keystore file for the node; this file name is just an example and may differ from your file name.
```

**Instructions**: 0xed78283432F4F73653e493Df0bEB5EC9FA4C33d3  is an example and may differ in your case.

2. Rename the keystore file in the/privasea/usb-ubuntu-node/config folder to wallet\_keystore:

<pre class="language-bash"><code class="lang-bash"><strong># check if there is a keystore file in the /privasea/config directory:
</strong>cd /privasea/usb-ubuntu-node/config &#x26;&#x26; ls

# Rename the keystore file obtained in the previous step:
<strong>mv ./UTC--2024-1216T11-26-41.2628933482--ed78283432f4f73653e493df0beb5ec9fa4c33d3  ./wallet_keystore 
</strong># Replace UTC--2024-1216T11-26-41.2628933482--ed78283432f4f73653e493df0beb5ec9fa4c33d3 with the keystore file name you found

# Check if the wallet_keystore file in the /privasea/usb-ubuntu-node/config folder is correctly modified:
ls 
</code></pre>

<figure><img src="/files/Owj1vfTfTs1ouRZhCcvB" alt=""><figcaption></figcaption></figure>

## 4. Link node address and revenue address

1\. Use the wallet address corresponding to the keystore file to link it with the income address on [dashboard](https://deepsea-beta.privasea.ai/usbNode).

<figure><img src="/files/zUwsm5t7Z0qWSAmisseP" alt=""><figcaption></figcaption></figure>

2. Click set up my node, you will see two pop-up windows of the wallet, you need to click to confirm, and your configuration is complete

<figure><img src="/files/kjIuRfo1W56ni0eHDqRC" alt=""><figcaption></figcaption></figure>

## 5. Start the node

1. Make sure the usb is inserted correctly. You can check the usb connection status in the system.

<pre class="language-bash"><code class="lang-bash"><strong>#Install the lsusb command:
</strong>sudo apt install usbutils 

#Check if there is an inserted USB device among the connected USB devices:
lsusb
</code></pre>

<figure><img src="/files/7lsyxHzwHsxR2jGvDszu" alt=""><figcaption></figcaption></figure>

**Note**: The USB name you see may be different from the screenshot, please refer to yours. Please make sure that the USB can be recognized by the system.

2. Enter the `/privasea/usb-ubuntu-node`, install the USB driver, and then start the node

```shell
# Enter the /privasea/usb-ubuntu-node
cd /privasea/usb-ubuntu-node  && source usb-driver.sh

# Start the compute node:
./calc calc --usb_sn 1245455750

#Parameter explanation:
# --usb_sn 1251559600   //The USB serial number to run, which can be found on the USB packaging

```

* **Note:** You will need to enter the password for the keystore file in the running interface.

<figure><img src="/files/tWsYVhp41GzlizqcQE0V" alt=""><figcaption></figcaption></figure>

3. Successful startup as shown in the figure below.

<figure><img src="/files/pqvnn8SdxPG8Xo3HLqQM" alt=""><figcaption></figcaption></figure>

&#x20;If failed, please check:

{% content-ref url="/pages/TBIGMOE1tFiMttD0sP2e" %}
[How to start the node FAQ](/user-node-usage-documentation/comprehensive-guide-to-privanetix-node-acceleration-node-and-workheart-node-setup-and-operation/how-to-start-the-node-faq.md)
{% endcontent-ref %}

## 6. Stop the node

```bash
ctrl + C
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://privasea.gitbook.io/user-node-usage-documentation/comprehensive-guide-to-privanetix-node-acceleration-node-and-workheart-node-setup-and-operation/workheart-usb-node-for-ubuntu-version.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
