[
https://issues.apache.org/jira/browse/HDFS-17847?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18032515#comment-18032515
]
ASF GitHub Bot commented on HDFS-17847:
---------------------------------------
smajeti22-dev commented on PR #8042:
URL: https://github.com/apache/hadoop/pull/8042#issuecomment-3437725615
> @smajeti22-dev , thanks for working on this!
>
> There are some spotbugs and checkstyle warnings. Could you take a look by
following the links?
Hi @szetszwo , I did update checkstyle warning. spotbugs dont seem to be
related to the current code file.
> OIV exits with code 0 (success) even when the output file is incomplete
> -----------------------------------------------------------------------
>
> Key: HDFS-17847
> URL: https://issues.apache.org/jira/browse/HDFS-17847
> Project: Hadoop HDFS
> Issue Type: Bug
> Components: command
> Affects Versions: 3.1.4, 3.2.4, 3.3.6, 3.4.2
> Reporter: Srinivasu Majeti
> Assignee: Srinivasu Majeti
> Priority: Major
> Labels: pull-request-available
>
> When running hdfs oiv (OfflineImageViewer) to convert an fsimage into CSV,
> the command exits with code 0 (success) even when the output file is
> truncated due to local filesystem quota being exhausted. This prevents users
> or automation scripts from detecting that the operation has failed.
> REPRO PROCEDURE:
> mkdir -p /tmp/oiv_repro/out
> [[email protected] ~]# sudo mount -t tmpfs -o
> size=100k tmpfs /tmp/oiv_repro/out
> [[email protected] ~]# dd if=/dev/zero
> of=/tmp/oiv_repro/out/filler bs=1K count=100
> 100+0 records in
> 100+0 records out
> 102400 bytes (102 kB, 100 KiB) copied, 0.000546265 s, 187 MB/s
> [[email protected] ~]# cd
> /dataroot/ycloud/dfs/nn/current/
> [[email protected] current]# ls -lrth
> total 3.5M
> -rw-r--r-- 1 hdfs hdfs 194 Sep 25 06:27 VERSION
> -rw-r--r-- 1 hdfs hdfs 42 Sep 25 06:29
> edits_0000000000000000001-0000000000000000002
> -rw-r--r-- 1 hdfs hdfs 1.7M Sep 25 07:29
> edits_0000000000000000003-0000000000000015159
> -rw-r--r-- 1 hdfs hdfs 95K Sep 25 08:29
> edits_0000000000000015160-0000000000000015710
> -rw-r--r-- 1 hdfs hdfs 95K Sep 25 09:29
> edits_0000000000000015711-0000000000000016260
> -rw-r--r-- 1 hdfs hdfs 99K Sep 25 10:29
> edits_0000000000000016261-0000000000000016839
> -rw-r--r-- 1 hdfs hdfs 243K Sep 25 10:29 fsimage_0000000000000016839
> -rw-r--r-- 1 hdfs hdfs 62 Sep 25 10:29 fsimage_0000000000000016839.md5
> -rw-r--r-- 1 hdfs hdfs 95K Sep 25 11:29
> edits_0000000000000016840-0000000000000017389
> -rw-r--r-- 1 hdfs hdfs 6 Sep 25 11:29 seen_txid
> -rw-r--r-- 1 hdfs hdfs 251K Sep 25 11:29 fsimage_0000000000000017389
> -rw-r--r-- 1 hdfs hdfs 62 Sep 25 11:29 fsimage_0000000000000017389.md5
> -rw-r--r-- 1 hdfs hdfs 1.0M Sep 25 12:28 edits_inprogress_0000000000000017390
> [[email protected] current]#
> FSIMG=/dataroot/ycloud/dfs/nn/current/fsimage_0000000000000017389
> [[email protected] current]# hdfs oiv -p
> Delimited -i "$FSIMG" -o /tmp/oiv_repro/out/fsimage.csv
> 25/09/25 12:30:20 INFO offlineImageViewer.PBImageTextWriter: Loading string
> table
> 25/09/25 12:30:20 INFO offlineImageViewer.FSImageHandler: Loading 24 strings
> 25/09/25 12:30:20 INFO offlineImageViewer.PBImageTextWriter: Loading inode
> references
> 25/09/25 12:30:20 INFO offlineImageViewer.FSImageHandler: Loading inode
> references
> 25/09/25 12:30:20 INFO offlineImageViewer.FSImageHandler: Loaded 0 inode
> references
> 25/09/25 12:30:20 INFO offlineImageViewer.PBImageTextWriter: Loading
> directories
> 25/09/25 12:30:20 INFO offlineImageViewer.PBImageTextWriter: Loading
> directories in INode section.
> 25/09/25 12:30:21 INFO offlineImageViewer.PBImageTextWriter: Found 784
> directories in INode section.
> 25/09/25 12:30:21 INFO offlineImageViewer.PBImageTextWriter: Finished loading
> directories in 128ms
> 25/09/25 12:30:21 INFO offlineImageViewer.PBImageTextWriter: Loading INode
> directory section.
> 25/09/25 12:30:21 INFO offlineImageViewer.PBImageTextWriter: Scanned 464
> INode directories to build namespace.
> 25/09/25 12:30:21 INFO offlineImageViewer.PBImageTextWriter: Finished loading
> INode directory section in 13ms
> 25/09/25 12:30:21 INFO offlineImageViewer.PBImageTextWriter: Found 2834
> INodes in the INode section
> 25/09/25 12:30:21 INFO offlineImageViewer.PBImageTextWriter: Outputted 2834
> INodes.
> [[email protected] current]# echo $?
> 0
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]