You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@iotdb.apache.org by GitBox <gi...@apache.org> on 2021/10/28 06:08:03 UTC

[GitHub] [iotdb] yschengzi opened a new pull request #4253: [To rel/0.12][IOTDB-1893] Can not release file lock in sync verify singleton

yschengzi opened a new pull request #4253:
URL: https://github.com/apache/iotdb/pull/4253


   The steps to reproduce are as follows:
   1. Start the receiver service on a server A
   2. Start the sender service on a server B
   3. Start sync function sender on a server B
   4. start benchmark to write datas on a server B
   5. At last ,Check whether the data is successfully synchronized
   Actual results in logs:
   2021-10-26 11:18:11,111 [Thread-1] ERROR o.a.i.d.s.s.t.SyncClient:181 - Unable to remove lock file: /home/xzh/iotdb/0.12.0/apache-iotdb-0.12.0-all-bin/data/system/sync/172.20.31.3_5555/sync_lock
   java.nio.channels.ClosedChannelException: null
   at sun.nio.ch.FileLockImpl.release(FileLockImpl.java:58)
   at org.apache.iotdb.db.sync.sender.transfer.SyncClient.lambda$lockInstance$0(SyncClient.java:178)
   at java.lang.Thread.run(Thread.java:748)
   2021-10-26 11:26:33,619 [pool-8-IoTDB-RPC-Client-2] ERROR o.a.t.s.TThreadPoolServer$WorkerProcess:315 - Thrift error occurred during processing of message.
   org.apache.thrift.transport.TTransportException: null
   at org.apache.thrift.transport.TIOStreamTransport.read(TIOStreamTransport.java:132)
   at org.apache.thrift.transport.TTransport.readAll(TTransport.java:86)
   at org.apache.iotdb.rpc.TElasticFramedTransport.readFrame(TElasticFramedTransport.java:110)
   at org.apache.iotdb.rpc.TElasticFramedTransport.read(TElasticFramedTransport.java:105)
   at org.apache.thrift.transport.TTransport.readAll(TTransport.java:86)
   at org.apache.thrift.protocol.TBinaryProtocol.readAll(TBinaryProtocol.java:425)
   at org.apache.thrift.protocol.TBinaryProtocol.readI32(TBinaryProtocol.java:321)
   at org.apache.thrift.protocol.TBinaryProtocol.readMessageBegin(TBinaryProtocol.java:225)
   at org.apache.thrift.TBaseProcessor.process(TBaseProcessor.java:27)
   at org.apache.thrift.server.TThreadPoolServer$WorkerProcess.run(TThreadPoolServer.java:310)
   at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
   at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
   at java.lang.Thread.run(Thread.java:748)
   
   this is because Runtime.getRuntime().addShutdownHook() add a hook before jvm shut down, but the file stream of file lock may be close before releasing, so the file lock can not release.
   
   solution:
       open a new file to lock the file stream


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: reviews-unsubscribe@iotdb.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [iotdb] HTHou merged pull request #4253: [To rel/0.12][IOTDB-1893] Can not release file lock in sync verify singleton

Posted by GitBox <gi...@apache.org>.
HTHou merged pull request #4253:
URL: https://github.com/apache/iotdb/pull/4253


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: reviews-unsubscribe@iotdb.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org