# Node Installation

## 1. Checking OS

Currently, OS supports Ubuntu 18.04, CentOS 7.

```bash
~# cat /etc/os-release
    NAME="Ubuntu"
    VERSION="18.04.4 LTS (Bionic Beaver)"
~# apt-get update && \
      apt-get -y install sudo
~# sudo apt update
~# sudo apt upgrade
~# sudo apt install jq curl wget vim tar openssh-server net-tools -y
 # if it already installed it automatically skips
```

## 2. Checking HOME folder

```bash
~# export | grep HOME
    declare -x HOME="/home/omnione" | declare -x HOME="/root"
# in case, HOME="/root"
~# usermod -d /home/omnione <UserName>

```

## 3. Install Java and check

```bash
~# sudo apt install openjdk-8-jdk
~# java -version
    openjdk version "1.8.0_232"
    OpenJDK Runtime Environment (AdoptOpenJDK)(build 1.8.0_232-b09)
    OpenJDK 64-Bit Server VM (AdoptOpenJDK)(build 25.232-b09, mixed mode)
```

## 4. Install eosio/eosio.cdt&#x20;

```bash
~# mkdir install
~# cd install

# eosio
~/install# git clone --recursive [source URL]

```

#### Check installation

```bash
~/install# nodeos -v
    v2.0.5
~/install# keosd -v
    v2.0.5
~/install# cleos version client
    v2.0.5
~/install# whereis nodeos
    nodeos: /usr/bin/nodeos
~/install# ls -al /usr/bin/nodeos
    lrwxrwxrwx 1 root root 29 Apr 21 18:08 /usr/bin/nodeos -> ../opt/eosio/2.0.5/bin/nodeos
```

## 5. Install Contract&#x20;

```bash
~# cd ~
~# git clone --recursive [source URL]
~# cd ./eosio.contract/
~eosio.contracts# ./build.sh
~eosio.contracts# cd ./build/contracts/
~eosio.contracts/build/contracts# pwd
    /home/omnione/eosio.contracts/build/contracts
```

{% hint style="info" %}
Addresses from pwd command are used to deploy the contact in the next step.
{% endhint %}

###

## 6. create Wallet and executing Wallet(keosd)

#### Wallet create

```bash
# cleos wallet create --to-console
Creating wallet: default
Save password to use in the future to unlock this wallet.
Without password imported keys will not be retrievable.
"PW5Kewn9L76X8Fpd....................t42S9XCw2"
```

{% hint style="info" %}
Save the Wallet's password separately -> "PW5Kewn9L76X8Fpd....................t42S9XCw2"&#x20;
{% endhint %}

#### Check Wallet open and List

```bash
# wallet open
~# cleos wallet open

# wallet list
~# cleos wallet list
Wallets:
[
  "default"
]
```

#### Check Wallet folder

```bash
# wallet 폴더 확인
~# ls -al $HOME/eosio-wallet
total 16
drwxr-xr-x 2 root root 4096 Jul 13 06:10 .
drwx------ 1 root root 4096 Jul 13 06:10 ..
-rw-r--r-- 1 root root 2900 Jul 10 05:42 config.ini
-rw------- 1 root root  439 Jul 10 05:45 default.wallet
```

#### Execute keosd

```bash
~# pkill keosd # 실행중인 keosd 중지 후 실행
~# keosd wallet open
~# cleos wallet unlock --password PW123...XYZ
```

#### Check Wallet

```bash
# wallet open 확인 (default, 별(*) 표시가 있어야 합니다.)
~# cleos wallet list
Wallets:
[
  "default *"
]
```

## 7. import Private Key to the executed Wallet

&#x20;-> Script file / command (TBD)

```bash
~# cleos wallet import --private-key privateKey1Ddhs..................AM6KU2rdWSkA
imported private key for: EOS7WD2KwZLof..................KUzJyePLFqGNknytq

~# cleos wallet import --private-key privateKey2FdSF..................df6KU2reTXas
imported private key for: EOS5jtZK8qVAC..................kv1pTmyaoe24McGMv
```

#### Key check

```bash
~# cleos wallet private_keys --password PW5Jw8uKkk..........Ty97VN7oDHsrg
[
  [
    "EOS7WD2KwZLof..................KUzJyePLFqGNknytq",
    "privateKey1Ddhs..................AM6KU2rdWSkA"
  ],[
    "EOS5jtZK8qVAC..................kv1pTmyaoe24McGMv",
    "privateKey2FdSF..................df6KU2reTXas"
  ]
]
```


---

# 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://dev-en.omnione.net/node-creation/untitled-1/installation-type-bp/installing-node.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.
