[GH-ISSUE #514] Strange errors after start "error in Proto: no error specified" #512

Closed
opened 2026-03-15 22:53:26 +03:00 by kerem · 3 comments
Owner

Originally created by @sintanial on GitHub (Jun 16, 2018).
Original GitHub issue: https://github.com/hickory-dns/hickory-dns/issues/514

I try to use new version (trust-dns-resolver 0.9.0). And receives errors after start

This is simple example to reproduce error on my mac

extern crate env_logger;
extern crate futures;
#[macro_use]
extern crate log;
extern crate tokio;
extern crate tokio_io;
extern crate trust_dns_resolver;

use futures::Future;
use tokio::runtime::Runtime;

fn main() {
    env_logger::init();

    use trust_dns_resolver::config::ResolverConfig;
    use trust_dns_resolver::config::ResolverOpts;
    use trust_dns_resolver::ResolverFuture;

    let resolver = ResolverFuture::new(ResolverConfig::default(), ResolverOpts::default());

    let process = resolver
        .map_err(|_| ())
        .and_then(move |resolver| {
            let query_process = resolver.lookup_ip("github.com")
                .and_then(move |lookup| {
                    Ok(())
                });

            query_process.map_err(|_| ())
        });


    let mut runtime = Runtime::new().unwrap();
    runtime.spawn(process);
    runtime.shutdown_on_idle().wait().unwrap();
}

When i start this program with enabling logger i see in log some errors

DEBUG 2018-06-16T09:00:57Z: tokio_reactor::background: starting background reactor
DEBUG 2018-06-16T09:00:57Z: tokio_reactor: loop process - 1 events, 0.000s
DEBUG 2018-06-16T09:00:57Z: tokio_reactor: loop process - 1 events, 0.000s
DEBUG 2018-06-16T09:00:57Z: tokio_reactor: loop process - 1 events, 0.000s
DEBUG 2018-06-16T09:00:57Z: tokio_reactor: loop process - 1 events, 0.000s
DEBUG 2018-06-16T09:00:57Z: trust_dns_proto::xfer::dns_handle: querying: github.com A
ERROR 2018-06-16T09:00:57Z: trust_dns_proto::xfer::dns_future: error in Proto: no error specified
ERROR 2018-06-16T09:00:57Z: trust_dns_proto::xfer::dns_future: error in Proto: no error specified
DEBUG 2018-06-16T09:00:57Z: trust_dns_proto::xfer::dns_future: got message from receiver
DEBUG 2018-06-16T09:00:57Z: trust_dns_proto::xfer::dns_future: sending message id: 55569
ERROR 2018-06-16T09:00:57Z: trust_dns_proto::xfer::dns_future: error in Proto: io error
DEBUG 2018-06-16T09:00:57Z: tokio_reactor: dropping I/O source: 3
DEBUG 2018-06-16T09:00:57Z: trust_dns_resolver::name_server_pool: name_server connection failure: future was canceled: Canceled
DEBUG 2018-06-16T09:00:57Z: trust_dns_proto::xfer::dns_future: got message from receiver
DEBUG 2018-06-16T09:00:57Z: trust_dns_proto::xfer::dns_future: sending message id: 52571
ERROR 2018-06-16T09:00:57Z: trust_dns_proto::xfer::dns_future: error in Proto: io error
DEBUG 2018-06-16T09:00:57Z: tokio_reactor: dropping I/O source: 1
DEBUG 2018-06-16T09:00:57Z: trust_dns_resolver::name_server_pool: name_server connection failure: future was canceled: Canceled
DEBUG 2018-06-16T09:00:57Z: trust_dns_proto::xfer::dns_future: got message from receiver
DEBUG 2018-06-16T09:00:57Z: trust_dns_proto::xfer::dns_future: sending message id: 52426
DEBUG 2018-06-16T09:00:57Z: tokio_reactor: loop process - 2 events, 0.000s
DEBUG 2018-06-16T09:00:57Z: tokio_reactor: loop process - 1 events, 0.000s
DEBUG 2018-06-16T09:00:57Z: trust_dns_proto::rr::record_data: reading A
DEBUG 2018-06-16T09:00:57Z: trust_dns_proto::rr::record_data: reading A
DEBUG 2018-06-16T09:00:57Z: tokio_reactor: dropping I/O source: 4
DEBUG 2018-06-16T09:00:57Z: tokio_reactor: dropping I/O source: 2
DEBUG 2018-06-16T09:00:57Z: tokio_reactor: dropping I/O source: 0
DEBUG 2018-06-16T09:00:57Z: tokio_reactor: dropping I/O source: 5
DEBUG 2018-06-16T09:00:57Z: tokio_reactor: loop process - 1 events, 0.000s
DEBUG 2018-06-16T09:00:57Z: tokio_reactor::background: shutting background reactor on idle
DEBUG 2018-06-16T09:00:57Z: tokio_reactor::background: background reactor has shutdown
Originally created by @sintanial on GitHub (Jun 16, 2018). Original GitHub issue: https://github.com/hickory-dns/hickory-dns/issues/514 I try to use new version (trust-dns-resolver 0.9.0). And receives errors after start This is simple example to reproduce error on my mac ```rust extern crate env_logger; extern crate futures; #[macro_use] extern crate log; extern crate tokio; extern crate tokio_io; extern crate trust_dns_resolver; use futures::Future; use tokio::runtime::Runtime; fn main() { env_logger::init(); use trust_dns_resolver::config::ResolverConfig; use trust_dns_resolver::config::ResolverOpts; use trust_dns_resolver::ResolverFuture; let resolver = ResolverFuture::new(ResolverConfig::default(), ResolverOpts::default()); let process = resolver .map_err(|_| ()) .and_then(move |resolver| { let query_process = resolver.lookup_ip("github.com") .and_then(move |lookup| { Ok(()) }); query_process.map_err(|_| ()) }); let mut runtime = Runtime::new().unwrap(); runtime.spawn(process); runtime.shutdown_on_idle().wait().unwrap(); } ``` When i start this program with enabling logger i see in log some errors ``` DEBUG 2018-06-16T09:00:57Z: tokio_reactor::background: starting background reactor DEBUG 2018-06-16T09:00:57Z: tokio_reactor: loop process - 1 events, 0.000s DEBUG 2018-06-16T09:00:57Z: tokio_reactor: loop process - 1 events, 0.000s DEBUG 2018-06-16T09:00:57Z: tokio_reactor: loop process - 1 events, 0.000s DEBUG 2018-06-16T09:00:57Z: tokio_reactor: loop process - 1 events, 0.000s DEBUG 2018-06-16T09:00:57Z: trust_dns_proto::xfer::dns_handle: querying: github.com A ERROR 2018-06-16T09:00:57Z: trust_dns_proto::xfer::dns_future: error in Proto: no error specified ERROR 2018-06-16T09:00:57Z: trust_dns_proto::xfer::dns_future: error in Proto: no error specified DEBUG 2018-06-16T09:00:57Z: trust_dns_proto::xfer::dns_future: got message from receiver DEBUG 2018-06-16T09:00:57Z: trust_dns_proto::xfer::dns_future: sending message id: 55569 ERROR 2018-06-16T09:00:57Z: trust_dns_proto::xfer::dns_future: error in Proto: io error DEBUG 2018-06-16T09:00:57Z: tokio_reactor: dropping I/O source: 3 DEBUG 2018-06-16T09:00:57Z: trust_dns_resolver::name_server_pool: name_server connection failure: future was canceled: Canceled DEBUG 2018-06-16T09:00:57Z: trust_dns_proto::xfer::dns_future: got message from receiver DEBUG 2018-06-16T09:00:57Z: trust_dns_proto::xfer::dns_future: sending message id: 52571 ERROR 2018-06-16T09:00:57Z: trust_dns_proto::xfer::dns_future: error in Proto: io error DEBUG 2018-06-16T09:00:57Z: tokio_reactor: dropping I/O source: 1 DEBUG 2018-06-16T09:00:57Z: trust_dns_resolver::name_server_pool: name_server connection failure: future was canceled: Canceled DEBUG 2018-06-16T09:00:57Z: trust_dns_proto::xfer::dns_future: got message from receiver DEBUG 2018-06-16T09:00:57Z: trust_dns_proto::xfer::dns_future: sending message id: 52426 DEBUG 2018-06-16T09:00:57Z: tokio_reactor: loop process - 2 events, 0.000s DEBUG 2018-06-16T09:00:57Z: tokio_reactor: loop process - 1 events, 0.000s DEBUG 2018-06-16T09:00:57Z: trust_dns_proto::rr::record_data: reading A DEBUG 2018-06-16T09:00:57Z: trust_dns_proto::rr::record_data: reading A DEBUG 2018-06-16T09:00:57Z: tokio_reactor: dropping I/O source: 4 DEBUG 2018-06-16T09:00:57Z: tokio_reactor: dropping I/O source: 2 DEBUG 2018-06-16T09:00:57Z: tokio_reactor: dropping I/O source: 0 DEBUG 2018-06-16T09:00:57Z: tokio_reactor: dropping I/O source: 5 DEBUG 2018-06-16T09:00:57Z: tokio_reactor: loop process - 1 events, 0.000s DEBUG 2018-06-16T09:00:57Z: tokio_reactor::background: shutting background reactor on idle DEBUG 2018-06-16T09:00:57Z: tokio_reactor::background: background reactor has shutdown ```
kerem closed this issue 2026-03-15 22:53:31 +03:00
Author
Owner

@bluejekyll commented on GitHub (Jun 16, 2018):

You’re using a pretty straightforward example there. Can you try the example from here: https://docs.rs/trust-dns-resolver/0.9.0/trust_dns_resolver/#using-the-tokioasync-resolver

If that works, then we can go back and try and figure out what is happening in your example.

<!-- gh-comment-id:397816089 --> @bluejekyll commented on GitHub (Jun 16, 2018): You’re using a pretty straightforward example there. Can you try the example from here: https://docs.rs/trust-dns-resolver/0.9.0/trust_dns_resolver/#using-the-tokioasync-resolver If that works, then we can go back and try and figure out what is happening in your example.
Author
Owner

@sintanial commented on GitHub (Jun 17, 2018):

hmm may be it's dependence by provider, in hotel i always received this errors (it's resolved success but logger show me ERROR logs), but in home wifi your and my example works fine

<!-- gh-comment-id:397903948 --> @sintanial commented on GitHub (Jun 17, 2018): hmm may be it's dependence by provider, in hotel i always received this errors (it's resolved success but logger show me ERROR logs), but in home wifi your and my example works fine
Author
Owner

@bluejekyll commented on GitHub (Jun 17, 2018):

Not much we can do with bad networks ;)

In 0.9 there is a much stronger attempt (thanks to your previous issues that were posted) to resolve no matter what. So it will surprise me if it doesn’t work when it could.

<!-- gh-comment-id:397905532 --> @bluejekyll commented on GitHub (Jun 17, 2018): Not much we can do with bad networks ;) In 0.9 there is a much stronger attempt (thanks to your previous issues that were posted) to resolve no matter what. So it will surprise me if it doesn’t work when it could.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/hickory-dns#512
No description provided.