0chain / blobber

A storage provider (blobber) interface to the blockchain and consumers of storage.
Other
19 stars 23 forks source link

Submit transaction error #27

Closed avanaur closed 3 years ago

avanaur commented 3 years ago

I am seeing these submit transaction error on the 0chainBlobber.log

Could this be related to some failures I am getting when doing load tests?

0chain-core-sdk [INFO]   2021/03/08 10:23:09.489305 transaction.go:234: Submitting smart contract transaction to http://198.18.0.71:7071
0chain-core-sdk [INFO]   2021/03/08 10:23:09.489431 transaction.go:234: Submitting smart contract transaction to http://198.18.0.74:7074
0chain-core-sdk [ERROR]  2021/03/08 10:23:12.551362 transaction.go:242: http://198.18.0.74:7074 submit transaction error. Post "http://198.18.0.74:7074/v1/transaction/put": dial tcp 198.18.0.74:7074: connect: no route to host
0chain-core-sdk [ERROR]  2021/03/08 10:23:12.551388 transaction.go:257: 
0chain-core-sdk [INFO]   2021/03/08 10:23:20.551709 transaction.go:293: New transaction interface
0chain-core-sdk [INFO]   2021/03/08 10:23:20.551761 transaction.go:443: Query from http://198.18.0.81:7171/v1/transaction/get/confirmation?hash=caff13518a7afc5d13b8403508b9052e62e9254f3851b7ac294f2e14a8795169&content=lfb
0chain-core-sdk [INFO]   2021/03/08 10:23:20.552727 transaction.go:443: Query from http://198.18.0.81:7171/v1/block/get?round=1369&content=header
0chain-core-sdk [INFO]   2021/03/08 10:23:20.553281 transaction.go:443: Query from http://198.18.0.81:7171/v1/block/get?round=1370&content=header
0chain-core-sdk [INFO]   2021/03/08 10:23:20.554689 transaction.go:293: New transaction interface
0chain-core-sdk [INFO]   2021/03/08 10:23:20.554885 wallet.go:236: Minimum miners used for submit :2
0chain-core-sdk [INFO]   2021/03/08 10:23:20.554908 transaction.go:234: Submitting smart contract transaction to http://198.18.0.74:7074
0chain-core-sdk [INFO]   2021/03/08 10:23:20.554928 transaction.go:234: Submitting smart contract transaction to http://198.18.0.72:7072
0chain-core-sdk [ERROR]  2021/03/08 10:23:23.623362 transaction.go:242: http://198.18.0.74:7074 submit transaction error. Post "http://198.18.0.74:7074/v1/transaction/put": dial tcp 198.18.0.74:7074: connect: no route to host
0chain-core-sdk [ERROR]  2021/03/08 10:23:23.623393 transaction.go:257: 
0chain-core-sdk [INFO]   2021/03/08 10:23:31.623709 transaction.go:293: New transaction interface
0chain-core-sdk [INFO]   2021/03/08 10:23:31.623805 transaction.go:443: Query from http://198.18.0.81:7171/v1/transaction/get/confirmation?hash=56128a929c7bec27a5ca4c7989ef7e282d8c37c14d3f2199febdb54b07193144&content=lfb
0chain-core-sdk [INFO]   2021/03/08 10:23:31.624799 transaction.go:443: Query from http://198.18.0.81:7171/v1/block/get?round=1386&content=header
0chain-core-sdk [INFO]   2021/03/08 10:23:31.625362 transaction.go:443: Query from http://198.18.0.81:7171/v1/block/get?round=1387&content=header
0chain-core-sdk [INFO]   2021/03/08 10:23:31.627575 transaction.go:293: New transaction interface
0chain-core-sdk [INFO]   2021/03/08 10:23:31.627908 wallet.go:236: Minimum miners used for submit :2
0chain-core-sdk [INFO]   2021/03/08 10:23:31.627944 transaction.go:234: Submitting smart contract transaction to http://198.18.0.72:7072
0chain-core-sdk [INFO]   2021/03/08 10:23:31.627953 transaction.go:234: Submitting smart contract transaction to http://198.18.0.73:7073
0chain-core-sdk [INFO]   2021/03/08 10:23:39.630665 transaction.go:293: New transaction interface
0chain-core-sdk [INFO]   2021/03/08 10:23:39.630734 transaction.go:443: Query from http://198.18.0.81:7171/v1/transaction/get/confirmation?hash=1d9ae61cc726b92e78ea72e8ca7a9266270d0c89a00b4ef2ba1f276a8661e81b&content=lfb
0chain-core-sdk [INFO]   2021/03/08 10:23:39.631838 transaction.go:443: Query from http://198.18.0.81:7171/v1/block/get?round=1399&content=header
0chain-core-sdk [INFO]   2021/03/08 10:23:39.632312 transaction.go:443: Query from http://198.18.0.81:7171/v1/block/get?round=1400&content=header
0chain-core-sdk [INFO]   2021/03/08 10:23:39.633817 transaction.go:293: New transaction interface
0chain-core-sdk [INFO]   2021/03/08 10:23:39.634013 wallet.go:236: Minimum miners used for submit :2
0chain-core-sdk [INFO]   2021/03/08 10:23:39.634039 transaction.go:234: Submitting smart contract transaction to http://198.18.0.71:7071
0chain-core-sdk [INFO]   2021/03/08 10:23:39.634053 transaction.go:234: Submitting smart contract transaction to http://198.18.0.74:7074
0chain-core-sdk [ERROR]  2021/03/08 10:23:42.696615 transaction.go:242: http://198.18.0.74:7074 submit transaction error. Post "http://198.18.0.74:7074/v1/transaction/put": dial tcp 198.18.0.74:7074: connect: no route to host
0chain-core-sdk [ERROR]  2021/03/08 10:23:42.696643 transaction.go:257: 
0chain-core-sdk [INFO]   2021/03/08 10:23:50.696994 transaction.go:293: New transaction interface
0chain-core-sdk [INFO]   2021/03/08 10:23:50.697048 transaction.go:443: Query from http://198.18.0.81:7171/v1/transaction/get/confirmation?hash=8498b89b5217c535c35230ddf9fd6b9edd0ea324c8a0d26ae63c0ba4ffcf7c59&content=lfb
0chain-core-sdk [INFO]   2021/03/08 10:23:50.697830 transaction.go:443: Query from http://198.18.0.81:7171/v1/block/get?round=1417&content=header
0chain-core-sdk [INFO]   2021/03/08 10:23:50.699473 transaction.go:443: Query from http://198.18.0.81:7171/v1/block/get?round=1418&content=header

Load test result:

This run shows updating file is 3/10 - 30% successful and others such as copy is 2/4 - 20% successful.

go-external-txn-generator_1  | Upload File      : ok      11/11     , inc    0, avg    51, max    96, min    36, favg    10, fmax    10, fmin    10
go-external-txn-generator_1  | Update File      : ok       3/10     , inc    0, avg    38, max    42, min    36, favg    10, fmax    10, fmin    10
go-external-txn-generator_1  | Download File    : ok       6/6      , inc    0, avg    10, max    15, min     7, favg     0, fmax     0, fmin     0
go-external-txn-generator_1  | Copy File        : ok       2/4      , inc    0, avg  7842, max 15668, min    16
go-external-txn-generator_1  | Delete File      : ok       1/2      , inc    0, avg    18, max    18, min    18
go-external-txn-generator_1  | Move File        : ok       5/7      , inc    0, avg    53, max    61, min    47
go-external-txn-generator_1  | Rename File      : ok       2/2      , inc    0, avg    29, max    36, min    23
go-external-txn-generator_1  | Public Share File: ok       6/6      , inc    0, avg     0, max     0, min     0

On the gosdk, the error logs looks like.

go-external-txn-generator_1  | 2021-03-08T10:18:23.619Z DEBUG   extgen/phase6_storage_txns.go:282   To copy file    {"allocation_id": "52bdc59c6f1c7df129430077578fb32556c2d24182674a22a8f84eb81dad868a", "client_id": "d9f1e4f56e5a481bbbff40e24496c2f72732ff89a1ca60ebfbefbbe6203229ce", "file": "/0/1/2/3/4/5/6/7/0file722261417.zcn", "copy_dir": "/"}
go-external-txn-generator_1  | 0box-sdk [ERROR]  2021/03/08 10:18:23.621249 common.go:33: Object tree response : 400
go-external-txn-generator_1  | 0box-sdk [ERROR]  2021/03/08 10:18:23.621276 common.go:33: Object tree response : 400
go-external-txn-generator_1  | 0box-sdk [ERROR]  2021/03/08 10:18:23.621290 copyworker.go:96: Object tree error response: Status: 400 - {"code":"invalid_parameters","error":"invalid_parameters: Invalid path. Could not find object tree"}
go-external-txn-generator_1  | 
go-external-txn-generator_1  |  
go-external-txn-generator_1  | 0box-sdk [ERROR]  2021/03/08 10:18:23.621251 common.go:33: Object tree response : 400
go-external-txn-generator_1  | 0box-sdk [ERROR]  2021/03/08 10:18:23.621301 copyworker.go:96: Object tree error response: Status: 400 - {"code":"invalid_parameters","error":"invalid_parameters: Invalid path. Could not find object tree"}
go-external-txn-generator_1  | 
go-external-txn-generator_1  |  
go-external-txn-generator_1  | 0box-sdk [ERROR]  2021/03/08 10:18:23.621318 copyworker.go:96: Object tree error response: Status: 400 - {"code":"invalid_parameters","error":"invalid_parameters: Invalid path. Could not find object tree"}
go-external-txn-generator_1  | 
go-external-txn-generator_1  |  
go-external-txn-generator_1  | 0box-sdk [ERROR]  2021/03/08 10:18:23.621391 common.go:33: Object tree response : 400
go-external-txn-generator_1  | 0box-sdk [ERROR]  2021/03/08 10:18:23.621427 copyworker.go:96: Object tree error response: Status: 400 - {"code":"invalid_parameters","error":"invalid_parameters: Invalid path. Could not find object tree"}
guruhubb commented 3 years ago

Invalid tree generally means the file is not committed by the blobber and thats probably why the update, copy, delete, move are failing. Try these operations after some time and use the --commit to make sure all the operations are committed to the chain before the other crud operations on the file.

avanaur commented 3 years ago

Cool. I will add the --commit which creates the meta transaction on the following transactions that alter the files.

guruhubb commented 3 years ago

Thanks @avanaur. Did this resolve the issue. If so, please close this issue.

avanaur commented 3 years ago

Adding the commit meta transaction seems to resolve the issue. Will close this ticket.