Uploaded image for project: 'Solr'
  1. Solr
  2. SOLR-2019

Jetty sometimes randomly takes a long time to start

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 3.1, 4.0-ALPHA
    • None
    • None

    Description

      I'm hitting this Jetty issue when running Solr's tests that spawn a Jetty:

      http://jira.codehaus.org/browse/JETTY-331

      It seems to be caused by this root cause:

      http://bugs.sun.com/view_bug.do?bug_id=6202721

      Whereby, somehow, Jetty is trying to use cryptographically secure source of randomness to seed seed its HashSessionIdManager. My box doesn't have enough entropy so the read blocks for sometimes 10s of seconds!

      If I forcefully symlink /dev/random -> /dev/urandom, that fixes the hang. Likewise, if I edit the JRE's java.security to set securerandom.source=file:/dev/./urandom, that also fixes it. But I think we can workaround this more "generally" by doing the workaround suggested in the Jetty issue (pass java.util.Random not java.security.SecureRandom).

      However, it's still not clear how widespread / what evns this issue really affects (besides mine)...

      Attachments

        1. SOLR-2019_insecure.patch
          2 kB
          Robert Muir
        2. SOLR-2019.patch
          4 kB
          Robert Muir

        Activity

          People

            Unassigned Unassigned
            mikemccand Michael McCandless
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: