Memory Error: Cannot create new nodes when running locally


I have been trying to play around with sovrin locally, and I’ve been run into a bit of a wall starting up new nodes as per the tutorial here. When I run the following:

start_sovrin_node 9701 9702

I get this error:

Traceback (most recent call last):
  File "/home/ubuntu/.local/bin/start_sovrin_node", line 46, in <module>
  File "/home/ubuntu/.local/lib/python3.5/site-packages/sovrin_node/server/", line 62, in __init__
    self.graphStore = self.getGraphStorage(name)
  File "/home/ubuntu/.local/lib/python3.5/site-packages/sovrin_node/server/", line 91, in getGraphStorage
  File "/home/ubuntu/.local/lib/python3.5/site-packages/plenum/server/", line 452, in _getOrientDbStore
  File "/home/ubuntu/.local/lib/python3.5/site-packages/plenum/persistence/", line 22, in __init__
    self.createDb(dbName, dbType, storageType)
  File "/home/ubuntu/.local/lib/python3.5/site-packages/plenum/persistence/", line 36, in createDb
    self.client.db_create(dbName, dbType, storageType)
  File "/home/ubuntu/.local/lib/python3.5/site-packages/pyorient/", line 331, in db_create
    .prepare((name, type, storage)).send().fetch_response()
  File "/home/ubuntu/.local/lib/python3.5/site-packages/pyorient/messages/", line 344, in fetch_response
    super(DbCreateMessage, self).fetch_response()
  File "/home/ubuntu/.local/lib/python3.5/site-packages/pyorient/messages/", line 261, in fetch_response
  File "/home/ubuntu/.local/lib/python3.5/site-packages/pyorient/messages/", line 245, in _decode_all
  File "/home/ubuntu/.local/lib/python3.5/site-packages/pyorient/messages/", line 172, in _decode_header
    serialized_exception = self._decode_field( FIELD_STRING )
  File "/home/ubuntu/.local/lib/python3.5/site-packages/pyorient/messages/", line 363, in _decode_field
    _decoded_string = _len )
  File "/home/ubuntu/.local/lib/python3.5/site-packages/pyorient/", line 139, in read
    buf = bytearray(_len_to_read)
--- Logging error ---
Traceback (most recent call last):
  File "/usr/lib/python3.5/logging/", line 71, in emit
    if self.shouldRollover(record):
  File "/home/ubuntu/.local/lib/python3.5/site-packages/plenum/common/logging/", line 20, in shouldRollover
    bool(RotatingFileHandler.shouldRollover(self, record))
  File "/usr/lib/python3.5/logging/", line 185, in shouldRollover = self._open()
  File "/usr/lib/python3.5/logging/", line 1037, in _open
    return open(self.baseFilename, self.mode, encoding=self.encoding)
NameError: name 'open' is not defined
Call stack:
  File "/usr/lib/python3.5/asyncio/", line 431, in __del__
  File "/usr/lib/python3.5/asyncio/", line 56, in close
  File "/usr/lib/python3.5/asyncio/", line 98, in close
  File "/usr/lib/python3.5/asyncio/", line 410, in close
    logger.debug("Close %r", self)
Message: 'Close %r'
Arguments: (<_UnixSelectorEventLoop running=False closed=False debug=True>,)

Any advice much appreciated!


@william10 How much RAM do you have? Also what version of OrientDB are you running? Also version of pyorient, you can find it by doing pip freeze | grep pyorient


@william10 Looking at the link you supplied, I’m assuming you installed the Sovrin software via pip. Is that correct? Along with the questions asked by lovesh, can you provide just a little more information on your environment. Is this a VM that you are running? Which version of Ubuntu are you running?


@lovesh @trev - Thanks for the responses. I’ve installed Sovrin on an Amazon EC2 running Ubuntu 16.04 with 1 GB of RAM via pip. I’m running OrientDB version 2.2.17 and pyorient 1.5.4.


@william10, since you are using Ubuntu, you may want to move over to installing via apt instead of pip, which will handle a lot more of the dependencies for you. Regarding the RAM, 1 GB is probably a little low to run the setup described in the document, though we should get @lovesh’s response to that, as that’s a setup he is more familiar with than I am. Alternatively, I could provide you with an AWS CloudFormation template that would set up a small Sovrin cluster for you. It’s not official in any way, but it is one that I use for my own testing.


@trev - While we wait on @lovesh, would be happy to try out the CloudFormation template. As for installing via apt/pip, can sovrin be installed via apt?

apt-cache search sovrin

turns up no results. Or did you mean installing dependencies via apt?


@william, with apt there are 2 packages to install, sovrin-node and sovrin-client, here is a google doc that describes it Regarding the RAM, 1 GB is low considering the resource requirements of OrientDB which is required by nodes but soon we will we moving to a different database and then would be able to run with much less resources


Thanks, @lovesh. I’ll give those instructions a go in a setup with a bit more RAM. What would you recommend as a minimum?


2 GB at a minimum, 4 GB recommended.


Thanks! Would definitely still be interested in checking out the CloudFormation template, @trev. Would definitely save some setup headaches.


In that document:

sudo apt-key adv --keyserver --recv-keys D82D8E35
sudo apt-key adv --keyserver --recv-keys EAA542E8

did not work for me and I used the following instead:

sudo wget -O - | sudo apt-key add -
sudo wget -O - | sudo apt-key add -


@fabienpe Thats surprising, i will have our build guy have a look at this. Thanks for reporting this.


@fabienpe Can you provide the error message or other details? Our build confirmed it works for him, he is on Ubuntu 16.04




Do you have a proxy?

Btw, your approach also good, may be we will change our docs.

sudo wget -O - | sudo apt-key add -
sudo wget -O - | sudo apt-key add -


Maybe that’s the reason. I’ll check with our IT guys.


They confirmed it’s a firewall issue.


Sorry for the delay here. I’ve published the template here:
Documentation is still a little sparse, but feel free to ask me questions.