Uploaded image for project: 'PHP Legacy Driver'
  1. PHP Legacy Driver
  2. PHP-884

php_network_getaddresses: getaddrinfo failed

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major - P3
    • Resolution: Works as Designed
    • Affects Version/s: 1.4.1, 1.4.2
    • Fix Version/s: None
    • Component/s: pecl-mongo
    • Environment:
      OS: Ubuntu 12.04
      PHP: 5.3.10-1ubuntu3.4
      mongo: mongodb-10gen 2.2.4
      php-mongo: 1.4.1/1.4.2
    • Backwards Compatibility:
      Fully Compatible
    • # Replies:
      2
    • Last comment by Customer:
      false

      Description

      I am using 3 mongoDB instances with replicaset.
      On backend I am used ZendFramework 1.12 + SnatyMongo
      My config for ShantyMongo looks like:
      hosts.0.host = '127.0.0.1'
      hosts.0.port = '27017'
      hosts.0.username = 'user'
      hosts.0.password = '12345'
      hosts.1.host = '127.0.0.1'
      hosts.1.port = '27018'
      hosts.1.username = 'user'
      hosts.1.password = '12345'
      hosts.2.host = '127.0.0.1'
      hosts.2.port = '27019'
      hosts.2.username = 'user'
      hosts.2.password = '12345'
      database = 'datebase_prod'
      replicaSet = true

      It's will create connection string like:
      mongodb://user:12345@127.0.0.1:27017,user:12345@127.0.0.1:27018,user:12345@127.0.0.1:27019/datebase_prod

      The problem, when I add username and password, I start get error: MongoCollection::findOne(): php_network_getaddresses: getaddrinfo failed: Name or service not known

      It's just only warning, but is there any solution to fix that.

        Attachments

          Activity

            People

            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:
                Days since reply:
                6 years, 35 weeks, 6 days ago
                Date of 1st Reply: