[
https://issues.apache.org/jira/browse/HDFS-4831?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13659980#comment-13659980
]
Colin Patrick McCabe commented on HDFS-4831:
--------------------------------------------
Logs and stack trace from a libhdfs run:
{code}
13/05/16 08:37:01 DEBUG hdfs.BlockReaderLocal: putting FileInputStream for
/test-warehouse/tpch.lineitem/lineitem.tbl back into FileInputStreamCache
[Thread 0x7fffcfc88700 (LWP 2810) exited]
13/05/16 08:37:01 DEBUG ipc.Client: IPC Client (1002500837) connection to
localhost/127.0.0.1:20500 from lskuff sending #9
13/05/16 08:37:01 DEBUG ipc.Client: IPC Client (1002500837) connection to
localhost/127.0.0.1:20500 from lskuff got value #9
13/05/16 08:37:01 DEBUG ipc.ProtobufRpcEngine: Call: getBlockLocations took 2ms
13/05/16 08:37:01 DEBUG hdfs.DFSClient: newInfo = LocatedBlocks{
fileLength=753862072
underConstruction=false
blocks=[LocatedBlock{BP-866712037-127.0.0.1-1366931725003:blk_8973605789866450572_6252;
getBlockSize()=67108864; corrupt=false; offset=0; locs=[127.0.0.1:47890,
127.0.0.1:60135, 127.0.0.1:47287]},
LocatedBlock{BP-866712037-127.0.0.1-1366931725003:blk_6529746879505750363_6253;
getBlockSize()=67108864; corrupt=false; offset=67108864; locs=[127.0.0.1:47890,
127.0.0.1:60135, 127.0.0.1:47287]},
LocatedBlock{BP-866712037-127.0.0.1-1366931725003:blk_7137931742725996903_6254;
getBlockSize()=67108864; corrupt=false; offset=134217728;
locs=[127.0.0.1:47890, 127.0.0.1:60135, 127.0.0.1:47287]},
LocatedBlock{BP-866712037-127.0.0.1-1366931725003:blk_2512286346981490115_6255;
getBlockSize()=67108864; corrupt=false; offset=201326592;
locs=[127.0.0.1:47890, 127.0.0.1:60135, 127.0.0.1:47287]},
LocatedBlock{BP-866712037-127.0.0.1-1366931725003:blk_-4910107063321244927_6256;
getBlockSize()=67108864; corrupt=false; offset=268435456;
locs=[127.0.0.1:47890, 127.0.0.1:60135, 127.0.0.1:47287]},
LocatedBlock{BP-866712037-127.0.0.1-1366931725003:blk_2541626567081697462_6257;
getBlockSize()=67108864; corrupt=false; offset=335544320;
locs=[127.0.0.1:47890, 127.0.0.1:60135, 127.0.0.1:47287]},
LocatedBlock{BP-866712037-127.0.0.1-1366931725003:blk_3773253961084852594_6258;
getBlockSize()=67108864; corrupt=false; offset=402653184;
locs=[127.0.0.1:47890, 127.0.0.1:60135, 127.0.0.1:47287]},
LocatedBlock{BP-866712037-127.0.0.1-1366931725003:blk_9156075801845636610_6259;
getBlockSize()=67108864; corrupt=false; offset=469762048;
locs=[127.0.0.1:47890, 127.0.0.1:60135, 127.0.0.1:47287]},
LocatedBlock{BP-866712037-127.0.0.1-1366931725003:blk_-4734840374398159095_6260;
getBlockSize()=67108864; corrupt=false; offset=536870912;
locs=[127.0.0.1:47890, 127.0.0.1:60135, 127.0.0.1:47287]},
LocatedBlock{BP-866712037-127.0.0.1-1366931725003:blk_7292053749276395282_6261;
getBlockSize()=67108864; corrupt=false; offset=603979776;
locs=[127.0.0.1:47890, 127.0.0.1:60135, 127.0.0.1:47287]}]
lastLocatedBlock=LocatedBlock{BP-866712037-127.0.0.1-1366931725003:blk_-1379632012241044332_6263;
getBlockSize()=15664568; corrupt=false; offset=738197504;
locs=[127.0.0.1:47890, 127.0.0.1:60135, 127.0.0.1:47287]}
isLastBlockComplete=true}
13/05/16 08:37:01 DEBUG hdfs.DFSClient: Connecting to datanode 127.0.0.1:47890
Program received signal SIGPIPE, Broken pipe.
[Switching to Thread 0x7fffebd58700 (LWP 2592)]
0x00007ffff79b2ccd in write () from /lib/x86_64-linux-gnu/libpthread.so.0
(gdb) bt
#0 0x00007ffff79b2ccd in write () from /lib/x86_64-linux-gnu/libpthread.so.0
#1 0x00007fffebf7a4ce in write_fully (env=0x32e79d0, fd=179,
buf=0x7fffebd54a20 "", amt=76)
at
hadoop/hadoop-common-project/hadoop-common/src/main/native/src/org/apache/hadoop/net/unix/DomainSocket.c:586
#2 0x00007fffebf7a623 in
Java_org_apache_hadoop_net_unix_DomainSocket_writeArray0 (env=0x32e79d0,
clazz=<optimized out>, fd=179, b=0x7fffebd56b08, offset=0, length=76)
at
hadoop/hadoop-common-project/hadoop-common/src/main/native/src/org/apache/hadoop/net/unix/DomainSocket.c:902
#3 0x00007fffefb46eee in ?? ()
#4 0x0000000604d1a794 in ?? ()
#5 0x00007fffebd56ac8 in ?? ()
#6 0x0000000604d1b2c8 in ?? ()
#7 0x0000000000000000 in ?? ()
{code}
> Performing direct read using libhdfs sometimes raises SIGPIPE (which in turn
> throws SIGABRT) causing client crashes
> -------------------------------------------------------------------------------------------------------------------
>
> Key: HDFS-4831
> URL: https://issues.apache.org/jira/browse/HDFS-4831
> Project: Hadoop HDFS
> Issue Type: Bug
> Components: libhdfs
> Affects Versions: 2.0.4-alpha
> Reporter: Lenni Kuff
>
> Reading using libhdfs sometimes raises SIGPIPE (which in turn throws SIGABRT
> from JVM_handle_linux_signal). This can lead to crashes in the client
> application. It would be nice if libhdfs handled this signal internally.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira