Uploaded image for project: 'HBase'
  1. HBase
  2. HBASE-21048

Get LogLevel is not working from console in secure environment

Log workAgile BoardRank to TopRank to BottomAttach filesAttach ScreenshotBulk Copy AttachmentsBulk Move AttachmentsVotersWatch issueWatchersCreate sub-taskConvert to sub-taskMoveLinkCloneLabelsUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • None
    • 3.0.0-alpha-1, 1.4.10, 2.3.0
    • None
    • Reviewed
    • Support get|set LogLevel in secure(kerberized) environment.

    Description

      When we try to get log level of specific package in secure environment, getting SocketException.

      hbase/master/bin# ./hbase org.apache.hadoop.hbase.http.log.LogLevel -getlevel host-xxxx:16010 org.apache.hadoop.hbase
      Connecting to http://host-xxxx:16010/logLevel?log=org.apache.hadoop.hbase
      java.net.SocketException: Unexpected end of file from server
      

      It is trying to connect http instead of https 

      code snippet that handling only http in LogLevel.java

       public static void main(String[] args) {
          if (args.length == 3 && "-getlevel".equals(args[0])) {
            process("http://" + args[1] + "/logLevel?log=" + args[2]);
            return;
          }
          else if (args.length == 4 && "-setlevel".equals(args[0])) {
            process("http://" + args[1] + "/logLevel?log=" + args[2]
                    + "&level=" + args[3]);
            return;
          }
      
          System.err.println(USAGES);
          System.exit(-1);
        }
      

      Attachments

        Issue Links

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            weichiu Wei-Chiu Chuang Assign to me
            chandrasekharn Chandra Sekhar
            Votes:
            0 Vote for this issue
            Watchers:
            9 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Slack

                Issue deployment