Deploying dnetcoin node

1.Download the dnetcoin code and compile

Recommended environment: Ubuntu 16.04, 18.04, 20.04

./autogen.sh
./configure
make
make install

2.dnetcoin client component

namedescription
dnetcoinddnetcoin daemon(non-GUI)
dnetcoin-qtdnetcoin client(GUI)
dnetcoin-clidnetcoind CLI(RPC/Rest)

Stable version download

Linux

Windows

MacOS

3.Running the dnetcoin client

Start the dnetcoin client via daemon or dnetcoin-qt(GUI)

  • Start using the daemon:

    To start in daemon mode, you need to use the dnetcoin-cli tool to send commands to control dnetcoin.

    Every command executed by dnetcoin-cli is to remotely call the JSON-RPC interface provided by dnetcoind, so before you start the dnetcoin client, you must configure the RPC information.

    The easiest way to do this is to create a dnetcoin.conf file in the dnetcoin data directory, the content is as follows:

    rpcuser=$custom_username
    rpcpassword=$custom_password
    # default 19332
    rpcport=19332

    You can specify the data directory or use the default (recommended to use the default).The following are the default paths for different system environments:

    OSPATH
    Linux$USER/.dnetcoin
    WindowsC:\Users\$USER\AppData\Roaming\DNetcoin
    Mac$USER/Library/Application Support/DNetcoin

    Complete the dnetcoin.conf configuration in the data directory to start dnetcoin:

    # "datadir" : Specify the data directory 
    # "testdnet": Specified as test chain
    dnetcoind -testdnet [-datadir=YOUR_CUSTOM_DIR] -daemon
  • Start with dnetcoin-qt:

    # "datadir" : Specify the
    
     data directory 
    #   (default datadir: 
    #      Linux: $USER/.dnetcoin
    #      Windows: C:\Users\$USER\AppData\Roaming\DNetcoin
    #      Mac: $USER/Library/Application Support/DNetcoin
    #   )
    # "testdnet": Specified as test chain
    
    # Linux/Mac
    dnetcoin-qt -testdnet [-datadir=YOUR_CUSTOM_DIR]
    
    # Windows
    dnetcoin-qt.exe -testdnet [-datadir=YOUR_CUSTOM_DIR]

    Executing commands on the dnetcoin-qt page is very simple, just open the console page:

    alt qt-console

4.Synchronize block

When the dnetcoin client is start finished, it will try to obtain the dnetcoin blockchain seed node and perform block synchronization. If the testdnet chain has generated more blocks, it may take some time to complete the synchronization. During the synchronization process, you cannot perform command operations on the blockchain temporarily, and you need to wait for the block synchronization to complete.

5.dnetcoin storage design

Next, we use the dnetcoin data structure to build a private virtual network.

For virtual network applications, dnetcoin provides three storage structures, each of which belongs to a specified type of namespace. Including dnet, dnetOVC (virtual network control node), dnetOVR (virtual network proxy(data) node):

  • "dnet" namespace

    Each "dnet" namespace has a unique storage address, which we call the dnet_id.

    The storage information structure is:

    namevalue
    dnetvlan node "address"Virtual IP address
    ...(multiple dnetvlan node addresses)...(Virtual IP per client)...
    _OVC_VLAN_LIST_Use public OVC, the value is "public";
    Use private OVC, the value is "OVC(private) namespace address (OVC ID)";
    _OVR_VLAN_LIST_OVR(private) namespace address (OVR ID)
  • "dnetOVC" namespace

    Each dnetOVC namespace has a unique address, which we call ovc_id.

    The storage information structure is:

    namevalue
    OVC node addressPublic ip:port
    ...(Multiple OVC node addresses)......(public ip:port of each ovc)...
  • "dnetOVR" namespace

    Each dnetOVR namespace has a unique address, we call it ovr_id.

    namevalue
    OVR node address(empty)
    ...(Multiple OVR node addresses)(empty)

Tip: How to use these three types of namespaces will be introduced later.

6.dnetcoin wallet

The dnet virtual network uses the above data structures,users write data according to different namespaces, and these data will be packaged into blocks and confirmed by miners.

Tip: To write data into the block, you need to pay a little dnet coins to encourage miners to verify the data. so, our wallet needs to have a balance in order to operate the data.

In the testdnet environment, we do not need to build a mining pool or use a mining machine to mine, we can mine through a simple command line on the client side.

  • Use CLI:

    # Mining 1 time
    dnetcoin-cli [-datadir=YOUR_CUSTOM_DIR] generate 1 
  • Use dnetcoin-qt:

    Open the console page and enter

    generate 1

You can also transfer money from other dnetcoin wallets with balance, or apply from the d.network website.

7.dnet

Prerequisite: dnetcoin wallet needs to have balance

We divide a large virtual network into multiple small units, each of which is independent and isolated,these small units are called "dnet".

Each "dnet" has security isolation, only the dnetvlan nodes in the same "dnet" can communicate with each other, and the information channels are also encrypted.

Create dnet:

  • Use CLI: (Returns the dnet namespace address, ie: dnetId)

    # "dnet_alias" : dnet alias
    dnetcoin-cli [-datadir=YOUR_CUSTOM_DIR] dnet_create $dnet_alias
  • You can also use the "dnetcoin-qt", which is simpler and more intuitive: alt dnet_create_info

Tip: It takes a little dnet coins to create a dnet,the submitted data is packaged into the block and waits for miners to verify it. (Verification takes some time, depending on the mining time.)

Role Description:

The "dnet" created by the wallet owner is called the dnet admin.

Only dnet admin can add, delete, or modify the information in the dnet (except for query, the dnet blockchain data is public, and any block dnet client can view it).

dnet admin can create one or more "dnet", and then add dnetvlan nodes that need networking to the specified dnet.

Add dnetvlan node to dnet

A dnet contains at least two or more dnetvlan nodes, using the address of each dnetvlan node as a unique identifier, and assigning virtual IPs by the dnet admin. (Virtual IPs assigned within the same group should avoid conflicts)

Tip: Only dnet admin can operate dnet, and data writing requires a little dnet coins.

  • Use CLI:

    (Please enter the parameters in the correct order.)

    # "dnet_id"          : dnet id
    # "client_address"   : dnetvlan node address
    # "client_virtual_ip : dnetvlan virtual IP
    #                      ("Administrator" assigns IP, do not conflict with IP)
    dnetcoin-cli [-datadir=YOUR_CUSTOM_DIR] dnet_add_node $dnet_id $client_address $client_virtual_ip
  • Use dnetcoin-qt: alt dnet_add_node_info

Add ovc namespace to dnet

The dnetvlan nodes inside dnet are controlled by dnetOVC, you need to specify an ovc namespace for dnet.

You can specify your own private ovc, or use a public ovc.

Tip: Only dnet admin can operate dnet, and data writing requires a little dnet coins.

Use the public OVC wizard:

  • Use CLI:
    # "dnet_id" : dnet id
    # "ovc_id"  : fixed value: public
    dnetcoin-cli [-datadir=YOUR_CUSTOM_DIR] dnet_add_ovc $dnet_id public
  • Use dnetcoin-qt:
    alt dnet_add_pub_ovc_info

Use the private OVC wizard:

  • Use CLI:

    # "dnet_id" : dnet id
    # "ovc_id"  : ovc id
    dnetcoin-cli [-datadir=YOUR_CUSTOM_DIR] dnet_add_ovc $dnet_id $ovc_id
  • Use dnetcoin-qt: alt dnet_add_private_ovc_info

For private OVC creation, please refer to the next section for instructions.

Add ovr namespace to dnet

In most cases, dnetvlan nodes under ovc control can communicate directly with each other.

However, in rare cases, some dnetvlan nodes cannot establish direct connections with peers. In this case, data needs to be forwarded through the proxy node. Agent nodes are called "ovr nodes".

dnetOVR is a namespace that stores multiple ovr resources (OVR nodes). dnetOVC is not only responsible for client node communication, but also for managing and distributing ovr. Therefore, dnet needs to introduce a private OVR to solve the problem that client nodes cannot be directly connected.

  • Use CLI:

    # "dnet_id" : dnet id
    # "ovr_id"  : ovr id
    dnetcoin-cli -testdnet [-datadir=YOUR_CUSTOM_DIR] dnet_add_ovr $dnet_id $ovr_id
  • Use dnetcoin-qt: alt dnet_add_ovr_info

How to create a private dnetOVC namespace is described in the following section.

8.Private dnetOVC

Prerequisite: dnetcoin wallet needs to have balance

dnetOVC is used to control the information communication of each node in the virtual network. This component is essential if you want to build a private virtual network. When adding the OVC namespace ID to the virtual group, you can use the public OVC or build your private OVC. Refer to the public OVC see public dnetOVC

Create private dnetOVC Namespace

  • Use CLI:

    (Returns the namespace address of OVC, ie: OVC Id)

    # "ovc_alias" OVC namespace aliases
    dnetcoin-cli -testdnet [-datadir=YOUR_CUSTOM_DIR] ovc_create $ovc_alias
  • dnetcoin-qt: alt ovc_create_info

Tip: It takes a little dnet coins to create ovc namespace,the submitted data is packaged into the block and waits for miners to verify it. (Verification takes some time, depending on the mining time.)

Role Description:

The "dnetOVC" created by the wallet owner is called the dnetOVC administrator.

Only dnetOVC administrator can add, delete, or modify the information in the group (except for query, the dnet blockchain data is public, and any block dnet client can view it).

Add ovc resources to OVC Namespace

A dnetOVC namespace stores one or more dnetOVC resources(OVC node). A dnetOVC namespace manages multiple OVC resources, which are connected to each other and run in cluster mode. (OVC nodes must have public IP addresses)

  • Use CLI:

    # "ovc_id"      : ovc id 
    # "ovc_address" : ovc node address
    # "ovc_host"    : ovc public ip : ovc port
    #                 (example: 1.2.3.4:1213)
    dnetcoin-cli -testdnet [-datadir=YOUR_CUSTOM_DIR] ovc_add_res $ovc_id $ovc_address $ovc_host
  • Use dnetcoin-qt: alt ovc_add_node_info

9.dnetOVR

Prerequisite: dnetcoin wallet needs to have balance

dnetOVR solves the problem of data transfer when the dnetvlan node cannot be directly connected.

The bandwidth, IO, network stability of the OVR resource server, and the distance between the network and the OVR resource from the client determine the performance of the OVR. We recommend referring to these metrics if you need to deploy a private dnetOVR. (OVC also calculates the dnetvlan optimal OVR node from the dnetOVC namespace)

Create private dnetOVR namespace

  • Use CLI:

    (Returns the namespace address of OVR, ie: OVR Id)

    # "ovr_alias" OVR namespace alias
    dnetcoin-cli [-datadir=YOUR_CUSTOM_DIR] ovr_create $ovr_alias
  • dnetcoin-qt: alt ovr_create_info

Tip: It takes a little dnet coins to create ovr namespace,the submitted data is packaged into the block and waits for miners to verify it. (Verification takes some time, depending on the mining time.)

Role Description:

The "dnetOVR" created by the wallet owner is called the dnetOVR administrator.

Only dnetOVR administrator can add, delete, or modify the information in the group (except for query, the dnet blockchain data is public, and any block dnet client can view it).

dnetOVR namespace add ovr resources

A dnetOVR namespace stores one or more dnetOVR resources(OVR node). (OVR nodes should be deployed in the public network environment as much as possible)

  • Use CLI:
    # "ovc_id"      : ovc id 
    # "ovc_address" : ovc node address
    # "ovc_host"    : ovc public ip : ovc port
    #                 (example: 1.2.3.4:1213)
    dnetcoin-cli [-datadir=YOUR_CUSTOM_DIR] ovc_add_res $ovc_id $ovc_address $ovc_host
  • Use dnetcoin-qt: alt ovr_add_node_info

Edit this page on GitHub