Reply
Explorer
Posts: 7
Registered: ‎03-09-2015
Accepted Solution

hdfs fsck command issue

[ Edited ]

Hi 

 

When i run  hdfs fsck -list-corruptfileblocks it is saying super user privilege is required .I am logged in as root user .Any idea what could be the reason .

 

 hdfs fsck -list-corruptfileblocks

 

Access denied for user root. Superuser privilege is required
Fsck on path '/' FAILED
FSCK ended at Wed Mar 25 19:42:40 SGT 2015 in 0 milliseconds
Access denied for user root. Superuser privilege is required
Fsck on path '/' FAILED
FSCK ended at Wed Mar 25 19:42:40 SGT 2015 in 0 milliseconds
Access denied for user root. Superuser privilege is required
Fsck on path '/' FAILED
FSCK ended at Wed Mar 25 19:42:40 SGT 2015 in 1 milliseconds
Access denied for user root. Superuser privilege is required
Fsck on path '/' FAILED
FSCK ended at Wed Mar 25 19:42:40 SGT 2015 in 0 milliseconds
Access denied for user root. Superuser privilege is required
Fsck on path '/' FAILED
FSCK ended at Wed Mar 25 19:42:40 SGT 2015 in 0 milliseconds
Access denied for user root. Superuser privilege is required
Fsck on path '/' FAILED
FSCK ended at Wed Mar 25 19:42:40 SGT 2015 in 1 milliseconds
Access denied for user root. Superuser privilege is required
Fsck on path '/' FAILED

Posts: 1,567
Kudos: 289
Solutions: 240
Registered: ‎07-31-2013

Re: hdfs fsck command isse

The superuser for HDFS is 'hdfs' in CDH installations. Please run the
command as the 'hdfs' user instead.

Backline Customer Operations Engineer
Highlighted
Contributor
Posts: 49
Registered: ‎07-26-2016

Re: hdfs fsck command isse

command  :

 

sudo -u hdfs hdfs  fsck -list-corruptfileblocks

 

For deleting corrupted files :

 

sudo -u hdfs hdfs  fsck / -delete

 

 

Thanks.

Announcements