Genome Analysis Toolkit

Variant Discovery in High-Throughput Sequencing Data

GATK process banner

Need Help?

Search our documentation

Community Forum

Hi, How can we help?

Developed in the Data Sciences Platform at the Broad Institute, the toolkit offers a wide variety of tools with a primary focus on variant discovery and genotyping. Its powerful processing engine and high-performance computing features make it capable of taking on projects of any size. Learn more

"Could not determine local host name"

Answered
0

12 comments

  • Avatar
    Genevieve Brandt (she/her)

    Hi Jai Desai,

    This looks like a log4j bug. Could you try the newest version of GATK (4.2.0.0) and let us know if this still occurs? Could you also share your complete command?

    Thank you,

    Genevieve

    0
    Comment actions Permalink
  • Avatar
    Pryce Turner

    Hey Jai Desai,

    Were you ever able to solve this? I'm running into the same issue with HaplotypeCaller. It still runs, but the error output is potentially disruptive.

    Thanks!

    0
    Comment actions Permalink
  • Avatar
    Genevieve Brandt (she/her)

    Thanks for the comment Pryce Turner, it looks like we never got to the bottom of this issue. Could you post your complete command and program log so we can look into it further?

    0
    Comment actions Permalink
  • Avatar
    Pryce Turner

    Hi Genevieve Brandt (she/her), this only happens in a fairly exotic runtime (custom docker image, using the local-gatk.jar without the wrapper, compressed with squashfs) and it only happens when calling `-version`.. I can't reproduce it on anything that I could sensibly ask others to setup and debug. 

    If I can get it to break on something more standard then I will certainly follow-up!

    0
    Comment actions Permalink
  • Avatar
    Genevieve Brandt (she/her)

    Thank you for the update Pryce Turner! I'll follow up with our dev team and see if anyone has any thoughts as well.

    0
    Comment actions Permalink
  • Avatar
    Pryce Turner

    Hi Genevieve Brandt (she/her), I was able to get it down to a very reproducible form! If I run the gatk-local.jar in a docker container started with `--network none`, then it pops up.

    Full Steps:

    1. Build image with Dockerfile

    FROM alpine:latest

    # Install java runtime
    RUN apk add openjdk11-jre

    # Copy GATK assets
    COPY gatk_release/gatk-package-4.2.6.1-local.jar /run/gatk-local.jar

    (Release downloaded from GitHub)

    2. `docker run --rm --network none <built-image> java -jar /run/gatk-local.jar -version`

    3. Output

    2022-08-02 12:20:35,310 main ERROR Could not determine local host name java.net.UnknownHostException: ab4880c3e243: ab4880c3e243: Try again
        at java.base/java.net.InetAddress.getLocalHost(InetAddress.java:1656)
        at org.apache.logging.log4j.core.util.NetUtils.getLocalHostname(NetUtils.java:54)
        at org.apache.logging.log4j.core.LoggerContext.lambda$setConfiguration$0(LoggerContext.java:620)
        at java.base/java.util.concurrent.ConcurrentHashMap.computeIfAbsent(ConcurrentHashMap.java:1705)
        at org.apache.logging.log4j.core.LoggerContext.setConfiguration(LoggerContext.java:620)
        at org.apache.logging.log4j.core.LoggerContext.reconfigure(LoggerContext.java:699)
        at org.apache.logging.log4j.core.LoggerContext.reconfigure(LoggerContext.java:716)
        at org.apache.logging.log4j.core.LoggerContext.start(LoggerContext.java:270)
        at org.apache.logging.log4j.core.impl.Log4jContextFactory.getContext(Log4jContextFactory.java:155)
        at org.apache.logging.log4j.core.impl.Log4jContextFactory.getContext(Log4jContextFactory.java:47)
        at org.apache.logging.log4j.LogManager.getContext(LogManager.java:196)
        at org.apache.logging.log4j.LogManager.getLogger(LogManager.java:599)
        at org.broadinstitute.hellbender.utils.Utils.<clinit>(Utils.java:72)
        at org.broadinstitute.hellbender.Main.<clinit>(Main.java:45)
    Caused by: java.net.UnknownHostException: ab4880c3e243: Try again
        at java.base/java.net.Inet4AddressImpl.lookupAllHostAddr(Native Method)
        at java.base/java.net.InetAddress$PlatformNameService.lookupAllHostAddr(InetAddress.java:929)
        at java.base/java.net.InetAddress.getAddressesFromNameService(InetAddress.java:1529)
        at java.base/java.net.InetAddress$NameServiceAddresses.get(InetAddress.java:848)
        at java.base/java.net.InetAddress.getAllByName0(InetAddress.java:1519)
        at java.base/java.net.InetAddress.getLocalHost(InetAddress.java:1651)
        ... 13 more

    The Genome Analysis Toolkit (GATK) v4.2.6.1
    HTSJDK Version: 2.24.1
    Picard Version: 2.27.1

     

    I can't reproduce the error with `--network none` on the official gatk docker image, but I'm doing things this way to save space :)

    0
    Comment actions Permalink
  • Avatar
    Genevieve Brandt (she/her)

    Thanks Pryce Turner! Ah yes, I remember seeing your other post. I'll definitely follow up with our developer team, but as far as I know, we don't support running GATK without the wrapper script. We do notice that strange errors like this come up without it, but I'll follow up when I get some more answers.

    Here's our article about the gatk command line and the wrapper script: https://gatk.broadinstitute.org/hc/en-us/articles/360035531892-GATK4-command-line-syntax 

    0
    Comment actions Permalink
  • Avatar
    Pryce Turner

    Hey Genevieve Brandt (she/her), thanks for the speedy reply and for linking that article. I've spent a few years in support and the "hey I'm not using this the way I'm supposed to and it's broken" requests definitely didn't get the highest priority! :D

    Nevertheless, I'm curious to hear what the devs say and will soldier-on on my end.

    UPDATE:
    I was mistaken earlier when I said the official docker gatk image didn't elicit the error. I've just tried with a fresh pull (latest tag from docker hub) and running via `docker --network none` and then simply `gatk -version` will reproduce the issue. 

    My confusion was because I tested the official image with podman originally, still using the `--network none` flag, and it doesn't produce the error. Which seems very strange. 

    Hopefully you guys can reproduce this on your end with docker and the official image and I haven't just driven myself mad with all these different test cases.

    0
    Comment actions Permalink
  • Avatar
    Genevieve Brandt (she/her)

    Pryce Turner could you share the command line and log that you get with the docker image?

    0
    Comment actions Permalink
  • Avatar
    Pryce Turner

    Genevieve Brandt (she/her) sure can.

     


    $> docker run --rm --network none broadinstitute/gatk gatk -version


    2022-08-03 20:37:23,349 main ERROR Could not determine local host name java.net.UnknownHostException: de2c81c88ddc: de2c81c88ddc: Temporary failure in name resolution

    at java.net.InetAddress.getLocalHost(InetAddress.java:1506)

    at org.apache.logging.log4j.core.util.NetUtils.getLocalHostname(NetUtils.java:54)

    at org.apache.logging.log4j.core.LoggerContext.lambda$setConfiguration$0(LoggerContext.java:620)

    at java.util.concurrent.ConcurrentHashMap.computeIfAbsent(ConcurrentHashMap.java:1660)

    at org.apache.logging.log4j.core.LoggerContext.setConfiguration(LoggerContext.java:620)

    at org.apache.logging.log4j.core.LoggerContext.reconfigure(LoggerContext.java:699)

    at org.apache.logging.log4j.core.LoggerContext.reconfigure(LoggerContext.java:716)

    at org.apache.logging.log4j.core.LoggerContext.start(LoggerContext.java:270)

    at org.apache.logging.log4j.core.impl.Log4jContextFactory.getContext(Log4jContextFactory.java:155)

    at org.apache.logging.log4j.core.impl.Log4jContextFactory.getContext(Log4jContextFactory.java:47)

    at org.apache.logging.log4j.LogManager.getContext(LogManager.java:196)

    at org.apache.logging.log4j.LogManager.getLogger(LogManager.java:599)

    at org.broadinstitute.hellbender.utils.Utils.<clinit>(Utils.java:72)

    at org.broadinstitute.hellbender.Main.<clinit>(Main.java:45)

    Caused by: java.net.UnknownHostException: de2c81c88ddc: Temporary failure in name resolution

    at java.net.Inet4AddressImpl.lookupAllHostAddr(Native Method)

    at java.net.InetAddress$2.lookupAllHostAddr(InetAddress.java:929)

    at java.net.InetAddress.getAddressesFromNameService(InetAddress.java:1324)

    at java.net.InetAddress.getLocalHost(InetAddress.java:1501)

    ...13 more




    The Genome Analysis Toolkit (GATK) v4.2.6.1

    HTSJDK Version: 2.24.1

    Picard Version: 2.27.1

    Using GATK jar /gatk/gatk-package-4.2.6.1-local.jar

    Running:

    java -Dsamjdk.use_async_io_read_samtools=false -Dsamjdk.use_async_io_write_samtools=true -Dsamjdk.use_async_io_write_tribble=false -Dsamjdk.compression_level=2 -jar /gatk/gatk-package-4.2.6.1-local.jar -version
    0
    Comment actions Permalink
  • Avatar
    Genevieve Brandt (she/her)

    Hi Pryce Turner,

    Thank you for your help describing this strange behavior. The developers agree that we want to try to fix this, so I have a created a github ticket so that they can look into the issue further. Here is the link: https://github.com/broadinstitute/gatk/issues/7983. Any future updates will be discussed there!

    Please let me know if you have any questions.

    Best,

    Genevieve

    0
    Comment actions Permalink
  • Avatar
    Pryce Turner

    Awesome! Subscribed to notifications. Excited to see what comes of it. Thanks for following up.

    0
    Comment actions Permalink

Please sign in to leave a comment.

Powered by Zendesk