Re: [Evolution] 3.16.3: Failed to refresh folder INBOX,

2015-07-02 Thread Eugene Kanter
Clarification:

DNS server is hosted on the same test system as evolution client - DNS
updates are instantaneous.

The expected behavior is to re-query DNS record when connection timeout
occurred instead of blindly and indefinitely try the same IP address. 

Eugene.

On Tue, 2015-06-23 at 09:24 +0100, Pete Biggs wrote:
  
  
  Connect to an IMAP server, retrieve email. Move IMAP server to 
  another
  address, change DNS record, attempt to retrieve email again. 
  Evolution
  indefinitely keeps trying previous IP address, displaying an error
  Connection timed out.
  
 
 Yes, sounds reasonable to me - in my experience any changes to DNS
 records take a little while to settle down.  DNS entries have a
 lifetime - this lifetime is server configurable and can be anything
 from a few minutes to days depending on how often the administrator 
 of
 the DNS thinks the  entries are likely to change.  The lifetime 
 allows
 the clients to cache the DNS results and most clients won't bother to
 query the DNS again until the entry would have expired.
 
 And it's not an Evolution issue: I very much doubt Evolution is doing
 the actual DNS lookups - after all, that's what libraries are for.
 
 Don't get confused by using utilities such as nslookup - they perform
 the DNS queries themselves so by-pass the cache.
 



___
evolution-list mailing list
evolution-list@gnome.org
To change your list options or unsubscribe, visit ...
https://mail.gnome.org/mailman/listinfo/evolution-list


Re: [Evolution] 3.16.3: Failed to refresh folder INBOX,

2015-06-24 Thread Pete Biggs
On Tue, 2015-06-23 at 17:53 -0600, Zan Lynx wrote:
 On 06/23/2015 02:24 AM, Pete Biggs wrote:
  Don't get confused by using utilities such as nslookup - they 
  perform
  the DNS queries themselves so by-pass the cache.
 
 Only if you tell them to do so. By default dig and nslookup do the query
 to the same resolver IP that the system libraries use.

This isn't the place to argue about DNS lookups.  But yes, they use the
same DNS server by default, but nslookup doesn't use the system name
services for the query, it talks directly to the DNS servers.  Hence it
by-passes any system cache, which was my point. I can see it doing it
using strace and you can change the DNS server it queries from within
the program so it can't just hand off the queries to the OS.

 
 If there is a cache in use, it is inside the Evolution libraries. 

No, as Milan said, Evolution doesn't cache the queries, all such
network activities are handled by other libraries.

  If a
 command-line ping, dig, or host command returns the new IP for a DNS
 name, Evolution should be using that as well.

Not necessarily, it depends on the individual libraries being used.


 If it does not, that would be a bug.

Not necessarily.  The DNS entry has a lifetime, it is not at all
unreasonable for the client to assume that the name-IP mapping is
valid for the entirety of the lifetime.  That's the whole point of it
- i.e. to reduce the number of DNS queries necessary by caching the
results.

P.


___
evolution-list mailing list
evolution-list@gnome.org
To change your list options or unsubscribe, visit ...
https://mail.gnome.org/mailman/listinfo/evolution-list


Re: [Evolution] 3.16.3: Failed to refresh folder INBOX,

2015-06-24 Thread Patrick O'Callaghan
On Wed, 2015-06-24 at 18:05 +0100, Pete Biggs wrote:
 On Wed, 2015-06-24 at 16:59 +0100, Patrick O'Callaghan wrote:
  On Wed, 2015-06-24 at 10:38 +0100, Pete Biggs wrote:
command-line ping, dig, or host command returns the new IP for 
a 
   DNS
name, Evolution should be using that as well.
 
 [[I wish they would fix this line wrapping of quoted content ...]]
 
   
   Not necessarily, it depends on the individual libraries being 
   used.
  
  Strictly that is true, but one would expect a reasonably configured
  system to use a single resolver library for everything. Usually 
  that is
  libresolv.so, which is part of glibc.
 
 No, that's just not so, it's much more complex than that.  Most user
 programs, like ping, use routines like 'gethostbyname' (or their more
 modern equivalent) - those routines get their information from a
 variety of sources - /etc/hosts, YP/NIS, DNS - which ultimately might
 use libresolv.  Gnome applications tend to use the GIO libraries. 
  And
 DNS querying programs like nslookup, host and dig go directly to the
 DNS server.

On my system (Fedora 22) nslookup and evolution both link to libresolv,
though ping doesn't.

 Things are complicate further by systems such as nscd - Name Service
 Cache Daemon that, as it says in the man page, provides a cache for
 the most common name service requests - and that includes hosts. 
  The
 default TTL for hosts in nscd is 1 hour.

I stopped using nscd when I moved away from Sun workstations so who
knows.

 That's why I said in reply to the original poster that you need to be
 careful about using things like nslookup to verify DNS entries since
 other parts of the system may be caching previous results.

I don't dispute that.

poc

___
evolution-list mailing list
evolution-list@gnome.org
To change your list options or unsubscribe, visit ...
https://mail.gnome.org/mailman/listinfo/evolution-list


Re: [Evolution] 3.16.3: Failed to refresh folder INBOX,

2015-06-24 Thread Patrick O'Callaghan
On Wed, 2015-06-24 at 10:38 +0100, Pete Biggs wrote:
  command-line ping, dig, or host command returns the new IP for a 
 DNS
  name, Evolution should be using that as well.
 
 Not necessarily, it depends on the individual libraries being used.

Strictly that is true, but one would expect a reasonably configured
system to use a single resolver library for everything. Usually that is
libresolv.so, which is part of glibc. I suppose running in a chroot
environment, or in a VM, could change that.

poc
___
evolution-list mailing list
evolution-list@gnome.org
To change your list options or unsubscribe, visit ...
https://mail.gnome.org/mailman/listinfo/evolution-list


Re: [Evolution] 3.16.3: Failed to refresh folder INBOX,

2015-06-24 Thread Pete Biggs
On Wed, 2015-06-24 at 16:59 +0100, Patrick O'Callaghan wrote:
 On Wed, 2015-06-24 at 10:38 +0100, Pete Biggs wrote:
   command-line ping, dig, or host command returns the new IP for a 
  DNS
   name, Evolution should be using that as well.

[[I wish they would fix this line wrapping of quoted content ...]]

  
  Not necessarily, it depends on the individual libraries being used.
 
 Strictly that is true, but one would expect a reasonably configured
 system to use a single resolver library for everything. Usually that is
 libresolv.so, which is part of glibc.

No, that's just not so, it's much more complex than that.  Most user
programs, like ping, use routines like 'gethostbyname' (or their more
modern equivalent) - those routines get their information from a
variety of sources - /etc/hosts, YP/NIS, DNS - which ultimately might
use libresolv.  Gnome applications tend to use the GIO libraries.  And
DNS querying programs like nslookup, host and dig go directly to the
DNS server.

Things are complicate further by systems such as nscd - Name Service
Cache Daemon that, as it says in the man page, provides a cache for
the most common name service requests - and that includes hosts.  The
default TTL for hosts in nscd is 1 hour.

That's why I said in reply to the original poster that you need to be
careful about using things like nslookup to verify DNS entries since
other parts of the system may be caching previous results.

P.
___
evolution-list mailing list
evolution-list@gnome.org
To change your list options or unsubscribe, visit ...
https://mail.gnome.org/mailman/listinfo/evolution-list


Re: [Evolution] 3.16.3: Failed to refresh folder INBOX,

2015-06-24 Thread Tom
Am Mittwoch, den 24.06.2015, 18:05 +0100 schrieb Pete Biggs: 
 On Wed, 2015-06-24 at 16:59 +0100, Patrick O'Callaghan wrote:
  On Wed, 2015-06-24 at 10:38 +0100, Pete Biggs wrote:
command-line ping, dig, or host command returns the new IP for a 
   DNS
name, Evolution should be using that as well.
 
 [[I wish they would fix this line wrapping of quoted content ...]]

+1 - but, who are they ...

___
evolution-list mailing list
evolution-list@gnome.org
To change your list options or unsubscribe, visit ...
https://mail.gnome.org/mailman/listinfo/evolution-list


Re: [Evolution] 3.16.3: Failed to refresh folder INBOX,

2015-06-24 Thread Milan Crha
Hi,

On Wed, 2015-06-24 at 19:19 +0200, Tom wrote:
 Am Mittwoch, den 24.06.2015, 18:05 +0100 schrieb Pete Biggs: 
  On Wed, 2015-06-24 at 16:59 +0100, Patrick O'Callaghan wrote:
   On Wed, 2015-06-24 at 10:38 +0100, Pete Biggs wrote:
 command-line ping, dig, or host command returns the new IP 
 for a 
DNS
 name, Evolution should be using that as well.
  
  [[I wish they would fix this line wrapping of quoted content ...]]
 
 +1 - but, who are they ...

...those reading GNOME's bugzilla for Evolution bugs against Composer
component. :)

The question is what is correct. Either the cited text can be treated
as Preformatted, which means the line character-width will go beyond
the limit (set to 72 characters by default), or the lines will wrap in
this odd way.

There was a code to merge such wrapped lines and make then a nice
flowing paragraph, but that also doesn't always produce the right code,
because it's hard to know whether the line break is due to line
limitation or intended by the writer (aka there are too many corner
cases).
Bye,
Milan

___
evolution-list mailing list
evolution-list@gnome.org
To change your list options or unsubscribe, visit ...
https://mail.gnome.org/mailman/listinfo/evolution-list


Re: [Evolution] 3.16.3: Failed to refresh folder INBOX,

2015-06-24 Thread Adam Tauno Williams
On Tue, 2015-06-23 at 08:56 +0200, Milan Crha wrote:
 On Mon, 2015-06-22 at 19:11 -0400, Eugene Kanter wrote:
 Evolution indefinitely keeps trying previous IP address,
 displaying an error Connection timed out.
 I see a very similar behaviour with the Firefox, when the network
 changes, it only may have set slightly shorter timeouts.

Ditto,  I would not expect this kind of change to work 'normally' as it
is not a normal change.

If you need to do this kind of thing regularly [why?] I would recommend
using a script or NetworkManager to cause an offline/online event,  or
else use a virtual machine.
-- 
Adam Tauno Williams mailto:awill...@whitemice.org GPG D95ED383
Systems Administrator, Python Developer, LPI / NCLA

___
evolution-list mailing list
evolution-list@gnome.org
To change your list options or unsubscribe, visit ...
https://mail.gnome.org/mailman/listinfo/evolution-list


Re: [Evolution] 3.16.3: Failed to refresh folder INBOX,

2015-06-24 Thread Zan Lynx
On 06/24/2015 11:05 AM, Pete Biggs wrote:
 Gnome applications tend to use the GIO libraries.  And
 DNS querying programs like nslookup, host and dig go directly to the
 DNS server.
 
 Things are complicate further by systems such as nscd - Name Service
 Cache Daemon that, as it says in the man page, provides a cache for
 the most common name service requests - and that includes hosts.  The
 default TTL for hosts in nscd is 1 hour.

The only time I see references to nscd is in horrible confusing bugs.

If they ignore the DNS TTL and set it to 1 hour I can see why.

I sure hope that GIO hasn't copied that stupid idea. A more probable GIO
user bug is doing the resolve and saving the address object for later
use, never considering that the IP will be different next time.
___
evolution-list mailing list
evolution-list@gnome.org
To change your list options or unsubscribe, visit ...
https://mail.gnome.org/mailman/listinfo/evolution-list


Re: [Evolution] 3.16.3: Failed to refresh folder INBOX,

2015-06-24 Thread Adam Tauno Williams
On Wed, 2015-06-24 at 10:38 +0100, Pete Biggs wrote:
 On Tue, 2015-06-23 at 17:53 -0600, Zan Lynx wrote:
  On 06/23/2015 02:24 AM, Pete Biggs wrote:
  If it does not, that would be a bug.
 Not necessarily.  The DNS entry has a lifetime, it is not at all
 unreasonable for the client to assume that the name-IP mapping is
 valid for the entirety of the lifetime.  That's the whole point of 
 it
 - i.e. to reduce the number of DNS queries necessary by caching the
 results.

If it is a bug then it is a bug in MANY libraries and applications used
on a wide variety of platforms [not just GNOME/LINUX].  It likely means
nginx and squid are categorically broken.

The DNS lifetime determines how long it is cached by another DNS server
or a resolver. Clients do not much care about TTL.  

It is very common - if not expected - for clients to *assume* that DNS
look-up results are essentially static.

-- 
Adam Tauno Williams mailto:awill...@whitemice.org GPG D95ED383
Systems Administrator, Python Developer, LPI / NCLA

___
evolution-list mailing list
evolution-list@gnome.org
To change your list options or unsubscribe, visit ...
https://mail.gnome.org/mailman/listinfo/evolution-list


Re: [Evolution] 3.16.3: Failed to refresh folder INBOX,

2015-06-23 Thread Milan Crha
On Mon, 2015-06-22 at 19:11 -0400, Eugene Kanter wrote:
 Move IMAP server to another address, change DNS record

Hi,
these are low-level things users usually cannot do, right? I mean, you
can change a local network, like unplug the wire and connect using
WiFi, but the server address will stay the same, including the DNS
record, no?

 Evolution indefinitely keeps trying previous IP address,

Right. There is done some caching of the route, not directly in
evolution, but in GIO streams/gnutls/..., which evolution relies on. it
also relies on the network change notifications, which are received
through GNetworkMonitor. There can be an issue in the IMAPx code, how
it processes the network change notifications.

 displaying an error Connection timed out.

What happens next? Does the IMAP account reconnect properly after this
timeout error when you try to do anything else with it (or the same
action with it)?

I see a very similar behaviour with the Firefox, when the network
changes, it only may have set slightly shorter timeouts.
Bye,
Milan

___
evolution-list mailing list
evolution-list@gnome.org
To change your list options or unsubscribe, visit ...
https://mail.gnome.org/mailman/listinfo/evolution-list


Re: [Evolution] 3.16.3: Failed to refresh folder INBOX,

2015-06-23 Thread Zan Lynx
On 06/23/2015 02:24 AM, Pete Biggs wrote:
 Don't get confused by using utilities such as nslookup - they perform
 the DNS queries themselves so by-pass the cache.

Only if you tell them to do so. By default dig and nslookup do the query
to the same resolver IP that the system libraries use.

If there is a cache in use, it is inside the Evolution libraries. If a
command-line ping, dig, or host command returns the new IP for a DNS
name, Evolution should be using that as well.

If it does not, that would be a bug. Because IP addresses do get changed
now and then, and users with laptops rarely close email programs when
you can just leave programs open and suspend/resume the machine.
___
evolution-list mailing list
evolution-list@gnome.org
To change your list options or unsubscribe, visit ...
https://mail.gnome.org/mailman/listinfo/evolution-list