[ 
https://issues.apache.org/jira/browse/HADOOP-18204?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17523494#comment-17523494
 ] 

cnnc commented on HADOOP-18204:
-------------------------------

infact i find the bug here:

in file:
h2. 
[hadoop|https://github.com/apache/hadoop]/[hadoop-hdfs-project|https://github.com/apache/hadoop/tree/trunk/hadoop-hdfs-project]/[hadoop-hdfs-native-client|https://github.com/apache/hadoop/tree/trunk/hadoop-hdfs-project/hadoop-hdfs-native-client]/[src|https://github.com/apache/hadoop/tree/trunk/hadoop-hdfs-project/hadoop-hdfs-native-client/src]/[main|https://github.com/apache/hadoop/tree/trunk/hadoop-hdfs-project/hadoop-hdfs-native-client/src/main]/[native|https://github.com/apache/hadoop/tree/trunk/hadoop-hdfs-project/hadoop-hdfs-native-client/src/main/native]/[libhdfspp|https://github.com/apache/hadoop/tree/trunk/hadoop-hdfs-project/hadoop-hdfs-native-client/src/main/native/libhdfspp]/[lib|https://github.com/apache/hadoop/tree/trunk/hadoop-hdfs-project/hadoop-hdfs-native-client/src/main/native/libhdfspp/lib]/[reader|https://github.com/apache/hadoop/tree/trunk/hadoop-hdfs-project/hadoop-hdfs-native-client/src/main/native/libhdfspp/lib/reader]/{*}block_reader.cc{*}

*line : 398*

 *if (parent_->bytes_to_read_ > 0) {*

 

*this condition should be:*

 *if (parent_->bytes_to_read_ > = 0) {*

 

 

> java.io.IOException: Version Mismatch (Expected: 28, Received: 520 )
> --------------------------------------------------------------------
>
>                 Key: HADOOP-18204
>                 URL: https://issues.apache.org/jira/browse/HADOOP-18204
>             Project: Hadoop Common
>          Issue Type: Bug
>          Components: hdfs-client
>    Affects Versions: 3.3.0, 3.3.1, 3.2.3, 3.3.2
>         Environment: NAME="openEuler"
> VERSION="20.03 (LTS-SP1)"
> ID="openEuler"
> VERSION_ID="20.03"
>            Reporter: cnnc
>            Priority: Major
>              Labels: libhdfs, libhdfscpp
>         Attachments: test1M.cpp
>
>   Original Estimate: 504h
>  Remaining Estimate: 504h
>
> read 1M bytes from hdfs with libhdfspp, and the  datanode-server report an 
> error like:
>  
> 2022-04-12 20:10:21,872 ERROR 
> org.apache.hadoop.hdfs.server.datanode.DataNode: server1:9866:DataXceiver 
> error processing READ_BLOCK operation  src: /90.90.43.114:47956 dst: 
> /90.90.43.114:9866
> java.io.IOException: Version Mismatch (Expected: 28, Received: 520 )
>         at 
> org.apache.hadoop.hdfs.protocol.datatransfer.Receiver.readOp(Receiver.java:74)
>         at 
> org.apache.hadoop.hdfs.server.datanode.DataXceiver.run(DataXceiver.java:269)
>         at java.lang.Thread.run(Thread.java:748)
> 2022-04-12 20:13:27,615 ERROR 
> org.apache.hadoop.hdfs.server.datanode.DataNode: server1:9866:DataXceiver 
> error processing READ_BLOCK operation  src: /90.90.43.114:48142 dst: 
> /90.90.43.114:9866
> java.io.IOException: Version Mismatch (Expected: 28, Received: 520 )
>         at 
> org.apache.hadoop.hdfs.protocol.datatransfer.Receiver.readOp(Receiver.java:74)
>         at 
> org.apache.hadoop.hdfs.server.datanode.DataXceiver.run(DataXceiver.java:269)
>         at java.lang.Thread.run(Thread.java:748)
>  
>  
> (1) compile test1M.cpp ,using command:
> g++ test1M.cpp -lprotobuf -lhdfspp_static -lhdfs -lpthread -lsasl2 -lcrypto 
> -llz4 -I./ -L./ -o test1M
>  
> (2)and execute test1M with:
> ./test1M  REAL_HDFS_FILE_PATH
>  
> (3) check hadoop logs and you will find erro info like :
> java.io.IOException: Version Mismatch (Expected: 28, Received: 520 )
>         at 
> org.apache.hadoop.hdfs.protocol.datatransfer.Receiver.readOp(Receiver.java:74)
>         at 
> org.apache.hadoop.hdfs.server.datanode.DataXceiver.run(DataXceiver.java:269)
>         at java.lang.Thread.run(Thread.java:748)
>  
>  
>  
>  



--
This message was sent by Atlassian Jira
(v8.20.1#820001)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to