Welcome to the Linux Foundation Forum!

Lab4: Setting up the world state to use CouchDB

I'm page 32 of the lab. The task is to implement CouchDB as database, instead of the default LevelDB. After updating all the files (docker-compose, and start script). I fired up the network but if fails with message of failure when trying to connect to peer0.org1.example.com. While checking the logs I found that the container fails to start, because it depends on another container: 'couchdbOrg1Peer0'. So far so good, except none of my couchdb containers are working.

This is the error:

couchdbOrg1Peer0          | runtime: failed to create new OS thread (have 2 already; errno=22)
couchdbOrg1Peer0          | fatal error: newosproc
couchdbOrg1Peer0          | 
couchdbOrg1Peer0          | runtime stack:
couchdbOrg1Peer0          | runtime.throw(0x4cb21f, 0x9)
couchdbOrg1Peer0          |     /usr/local/go/src/runtime/panic.go:566 +0x95
couchdbOrg1Peer0          | runtime.newosproc(0xc420028000, 0xc420037fc0)
couchdbOrg1Peer0          |     /usr/local/go/src/runtime/os_linux.go:160 +0x194
couchdbOrg1Peer0          | runtime.newm(0x4d6db8, 0x0)
couchdbOrg1Peer0          |     /usr/local/go/src/runtime/proc.go:1572 +0x132
couchdbOrg1Peer0          | runtime.main.func1()
couchdbOrg1Peer0          |     /usr/local/go/src/runtime/proc.go:126 +0x36
couchdbOrg1Peer0          | runtime.systemstack(0x53ae00)
couchdbOrg1Peer0          |     /usr/local/go/src/runtime/asm_amd64.s:298 +0x79
couchdbOrg1Peer0          | runtime.mstart()
couchdbOrg1Peer0          |     /usr/local/go/src/runtime/proc.go:1079
couchdbOrg1Peer0          | 
couchdbOrg1Peer0          | goroutine 1 [running]:
couchdbOrg1Peer0          | runtime.systemstack_switch()
couchdbOrg1Peer0          |     /usr/local/go/src/runtime/asm_amd64.s:252 fp=0xc420022768 sp=0xc420022760
couchdbOrg1Peer0          | runtime.main()
couchdbOrg1Peer0          |     /usr/local/go/src/runtime/proc.go:127 +0x6c fp=0xc4200227c0 sp=0xc420022768
couchdbOrg1Peer0          | runtime.goexit()
couchdbOrg1Peer0          |     /usr/local/go/src/runtime/asm_amd64.s:2086 +0x1 fp=0xc4200227c8 sp=0xc4200227c0

Any Ideas?

Comments

  • matisalimba
    matisalimba Posts: 17

    Ok, so the problem was that I'm using an Apple M1 laptop instead of the Ubuntu desktop. The error was related to the fabric-couchdbimage being used (latest).

    I digged for a couch db image on docker hub, compatible with my laptop and that did the trick.
    For reference, I used hyperledger/fabric-couchdb:x86_64-0.4.7 instead of hyperledger/fabric-couchdb:latest

  • Bobbijn
    Bobbijn Posts: 133

    @matisalimba, Great job, I am sure your solution will assist other Apple users, Thanks, Bobbi

Categories

Upcoming Training