Please read this before reporting a bug:
https://wiki.archlinux.org/title/Bug_reporting_guidelines
Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.
REPEAT: Do NOT report bugs for outdated packages!
https://wiki.archlinux.org/title/Bug_reporting_guidelines
Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.
REPEAT: Do NOT report bugs for outdated packages!
FS#28864 - [mutt] 1.5.21 does not respect /etc/resolv.conf settings
Attached to Project:
Arch Linux
Opened by Lubos Kolouch (kolcon) - Sunday, 11 March 2012, 12:10 GMT
Last edited by Gaetan Bisson (vesath) - Wednesday, 27 June 2012, 15:45 GMT
Opened by Lubos Kolouch (kolcon) - Sunday, 11 March 2012, 12:10 GMT
Last edited by Gaetan Bisson (vesath) - Wednesday, 27 June 2012, 15:45 GMT
|
DetailsDescription:
When mutt is launched, it remembers the DNS settings from /etc/resolv.conf and keeps using them, even if the resolv.conf file has been changed. This is causing problem when hibernating the laptop and resuming in another network, where the original DNS server is not accessible (cannot resolve the smtp name). Mutt that is included in Gentoo behaves correctly. Additional info: * package version(s) * config and/or log files etc. Steps to reproduce: 1. Launch mutt 2. Suspend/hibernate 3. Resume in another network with different DNS settings 4. Try to send email 5. Fail |
This task depends upon
Closed by Gaetan Bisson (vesath)
Wednesday, 27 June 2012, 15:45 GMT
Reason for closing: Won't fix
Additional comments about closing: I see no solution to this problem, but please ask to reopen if you come up with a patch or identify the source of your issue.
Wednesday, 27 June 2012, 15:45 GMT
Reason for closing: Won't fix
Additional comments about closing: I see no solution to this problem, but please ask to reopen if you come up with a patch or identify the source of your issue.
Just try it yourself - launch mutt, then put some nonsense to /etc/resolv.conf, but mutt will
happily continue to use the "cached" DNS of the SMTP server. Or at least does in my arch installation.
Tried both ways:
- Launching mutt with working resolv.conf, then changing it do nonsense and trying to send mail (couldn't resolve the hostname of course)
- Launching mutt with broken resolv.conf, then changing it to a working one and trying to send mail (worked)
I have mutt 1.5.21-6 and use net-auto-wireless from netcfg to connect to my network (so nothing updating resolv.conf automatically).
What I am supposed to do with "something like", no muttrc, no clue as to how your Mutt handles outgoing emails, etc.
I assume you are using sendmail or msmtp and the bug is actually there, but I am not going to search for your bug myself.
Everything works as expected here.
However note that I'm not the person who opened this bug, I just tried to add an additional sample.
I have "smtp_url" and "smtp_pass" set in .muttrc and have neither sendmail nor msmtp nor smtp-forwarder installed, so I suppose I use a method internal to mutt or at least included in the package.
The exact steps I took:
Open mutt, compose test mail to myself.
Open /etc/resolv.conf, comment out every line, add new line "nameserver 256.256.256.256" (note the invalid/nonsensical ip),save
Try to send mail
Get error "Could not find host smtp.gmail.com" (in german)
Now for the other way around:
Close mutt, open mutt again (with the invalid resolv.conf), compose new test mail
Open /etc/resolv.conf, remove erronous line, uncomment old working lines ("nameserver 172.16.100.12","nameserver 8.8.8.8","nameserver 8.8.4.4"),save
Try to send mail
Success
Now note that this is exactly the way it is expected, and I could _not_ reproduce the bug.
I have exactly the same issue Fabian described (even with smtp.gmail.com)
from my .muttrc:
set smtp_url = "smtp://name@company:5557/" (or smtp.gmail.com in another setup)
Test scenario:
1) empty resolv.conf
2) Start mutt
3) Try to send email : Could not find the host "smtp.gmail.com"
4) adding correct nameserver to resolv.conf
5) Try to send email: Could not find the host "smtp.gmail.com"
6) Close mutt
7) Open mutt
8) Try to send email: Email sent OK
9) empty resolv.conf
10) Try to send email: Email sent OK
11) Close mutt
12) Open mutt
13) Try to send email: Could not find the host "smtp.gmail.com"
Is it a bit clearer now?
I am quite sure my .muttrc is not the issue as I have the same one working fine under Gentoo
on the same laptop...
1) created a new user with empty profile (only modified .muttrc) - same (wrong) behaviour
2) ping smtp.gmail.com works as expected (works if /etc/resolv.conf correct, does not if incorrect)
3) tried firefox - works as expected (same like 2)
4) tried newsbeuter (console news program) - works as expected (same like 2)
5) tried irssi (IRC) - works as expected (same like 2)
So, what would you suggest to try further and why this seems to misbehave only in mutt?
1) I sent email to gmail with valid resolv.conf
strace : http://paste.pocoo.org/show/570389/
2) I emptied the resolv.conf and tried to send, email sent OK
strace : http://paste.pocoo.org/show/570391/
Does it help?
To me this is a standard behavior; the mystery is why Gentoo works differently.
You should probably consider asking on the upstream mailing list.
Should it really be cached when you can wake the notebook in completely different
network with different DNS settings?