Getting started as a customer

(Updated on 25-10-2018)

  1. Overview
  2. Requirements
  3. Installation
  4. Account settings
  5. Tokens deposit
  6. KYC procedure
  7. Rent of resources
  8. Task execution
  9. Finish rent
  10. Finding help

Overview

Customer is a Sonm user, how rents and uses the computing resources of other users (Suppliers) through the system. Getting started in Sonm as a customer requires several steps we describe below. It includes installation, settings and main steps to execute your task using Sonm.

Requirements

You'll need to consider the following before starting the installation:

  • Connect your laptop/PC to a power source. PC may be with MacOS, Windows.
  • Ensure you have an internet connection and browser.

Installation

It's easy to install Sonm components for customer (CLI, Node). Here's what you need to do:

  • Open cmd.
  • Use auto-installation script:

sudo bash -c "$(curl -s https://raw.githubusercontent.com/sonm-io/autodeploy/master/sonm-auto-deploy-consumer.sh)"

We recommend auto-installation, but you may install Sonm components manually:

Account settings

You should have your own Ethereum account to pay for resources in Sonm. Account is your unique identifier for:

  • deals in Sonm blockchain;
  • profile certificates, deal statistics, contact information, etc;
  • personal blacklist (common for all supplier's workers) to not have deals with specified addresses.

We generate your personal account (UTC/JSON keystore file) during the installation. You find keystore path and passphrase with cat ~/.sonm/cli.yaml. Keystore file default location: /etc/sonm/sonm-keystore.

If you want to use your existing account, replace the file in the appropriate folder with yours.

To start working with your account:

  1. Get your keystore file.
  2. Open Sonm GUI.
  3. Create new wallet by clicking “Create wallet” button. Input name, password and password confirmation, choose “livenet” as Ethereum network (“rinkeby” is a testnet). After input click “Create wallet”.
  4. Select “Wallet” -> “Accounts” section in main menu. You will enter to the accounts list.
  5. Click "Import Account" button to add your UTC/JSON keystore file. Select file, enter the account name and passphrase. Click “Add” to finish.
  6. Now you see your account list and funds in Ethereum and Sonm tokens. The account is set up.

IMPORTANT

DON'T FORGET to make a BACK-UP of your KEYSTORE or WHOLE WALLET. You cannot get access to your funds if you loose the keystore.

To export wallet:

  1. Click the "Export wallet" button on the "Accounts" page.
  2. Choose the local folder and click "Save".

Also to verify the installation of Sonm CLI component and check your account please start Sonm CLI and use sonmcli login command. There should be no “Enter password” request.

Payments for the resources in Sonm is performed only in Sonm tokens (SNM). You can buy tokens on one of the cryptocurrency exchanges.

You should have enough SNM to pay for the deal and have some Ether to pay for the deposit operation (Ethereum transaction fee) on your account.

Tokens deposit

Deposit tokens - the next step for replenishing your balance in Sonm blockchain, where you rent and pay for the resources. You may use Sonm GUI or CLI.

To deposit tokens in Sonm CLI use sonmcli token deposit command. To deposit tokens in Sonm GUI go to “Market” -> “Deposit” page and follow the guide steps.

Please NOTICE

We use special Gate smart contracts and Gatekeeper masternodes to validate transactions for deposit SNM tokens to SONM blockchain and withdraw them to main Ethereum network. Transactions are not rapid, there are delays for:

  • validate transaction (include transaction to the block) - this depends on current workload of the main Ethereum network and transaction settings you set ("gas limit" and "gas price");
  • quarantine period for the gate - 15 minutes.

Taking this into account, the normal time to deposit funds in the opposite blockchain is: <the time of mining your transaction + 15 minutes>

KYC procedure

KYC (Know Your Customer) is a procedure that allows a supplier to confirm the identity of the counterparty (customer) participating in a deal before it is conducted. After undergoing KYC verification, a customer can use the resources he has rented on the Sonm platform to run individually created tasks: machine learning, rendering, etc. Users who have not yet passed the KYC procedure can run only the computational tasks included in the Sonm Whitelist.

To complete the KYC procedure and receive “Identified” status you need to:

  • Go into your profile in the Sonm GUI - click profile icon on the top.
  • Click on the “Get Certification” button.
  • Select “Cryptonomica” from the list and follow the guide steps.
  • After the KYC will be completed your status will change to “Identified”.

Rent of resources

To quick rent resources in Sonm GUI:

  1. Go to “Market” -> “Orders” page, or go to “Market” -> “Profiles” page, select Supplier, and in his profile click “Go to orders” button to view his sell orders.
  2. Choose appropriate sell order. Click on the order to see all parameters.
  3. Buy order using “Buy” button, follow the guide steps.
  4. You may see your deals on “Market’ -> “Deals” page. You may see deal details by click on the deal.

Order and deal prices on SONM marketplace are in USD. Payments are executed in SNM tokens by actual exchange SNM/USD exchange price. When you open a deal, SNM tokens from your address are transfered to the marketplace smart contract.

To rent your own resource configuration use Sonm GUI:

  1. Configure your buy order parameters that are necessary for your task: create or edit bid.yaml file
    • Configure the values of RAM, CPU, Network, GPU hashrate. Set the price you may offer.
    • Set the duration of the deal. Zero means that the deal is spot and can be interrupted by the supplier at any time. To solve the problem of machine learning set the time of the deal, the minimum required to complete your task.
  2. Create order on Marketplace to buy resources: sonmcli order create bid.yaml.
  3. Wait a few minutes and check deal is settled: sonmcli deal list. The creation of the deal is carried out automatically, as soon as a suitable sell order will be found on the Sonm marketplace.

Task execution

To execute your task you should prepare a docker container with it and upload container to the Docker storage.

For now the task execution is allowed only in Sonm CLI. Follow the next steps:

  1. Prepare a file with a description of the task: edit task.yaml file. You may see task specification examples on our GitHub.
  2. Start task using sonmcli task start task.yaml --timeout=100m.
  3. Wait until task is started. This process can require long time, because of pulling docker image at worker.
  4. See task logs using sonmcli task logs .

Finish rent

  1. After task execution is ended stop the task: sonmcli task stop .
  2. Finish deal to stop spending Sonm tokens if no other tasks are planned: sonmcli deal close .

Supplier will receive payment for certain deal duration. The rest of SNM tokens freezed on the deal will return to your account!

See Sonm CLI Guide for additional information about task management.

Finding help

If you get stuck, help is always at hand. We are providing you with a 24/7 technical support.

If you experience any errors or difficulties with our product, you can get support via:

Be ready to provide all the required information that will help us to solve your issue.

Check if your SONM platform components working correctly. Do it using our self-check guide.

Also, please make step-by-step description of actions that led to the error and provide us with command outputs.