linux邮件客户端mutt日志文件,发不出邮件
linux上面使用很方便的收发邮件客户端(即MUA),还有一个是mail,大家也可以试试。
在网上找了很多,都说需要msmtp配合使用,其实mutt里面也内建了smtp支持的。
mutt and SMTP mutt can't speak SMTP ... wait, it can ...
... or why mutt should not but slowly becomes an "all-in-1" program. mutt was developed with the concept of "one task per tool", enabling performance through combination with other high quality modular programs. This is an aspect of the "unix philosophy". Putting too much into an application wastes unused resources --either in storage (HDD/RAM) or in run-time performance-- when in many cases people don't even use this extra functionality, or it is covered by some other specialist tool. (With a commercial program you'd even have to pay for the unused code, would you do that if you had the choice?) That's why --so far-- things have been kept separate (or out of mutt). For quite some time basic MRA functionality has been included in mutt, which some consider a breach of the concept and therefore demand inclusion of SMTP support as well (and because "all the other MUAs have SMTP as well"). The original reasons for the MRA part are not recorded (ed: anyone who knows shall fill in), but it makes sense to have MRA in mutt and not MTA: MUA+MRA access&store msgs within your control-reach (pull),
MTA passes msgs beyond your control boundary (push).
On this abstract level, MUA+MRA combined cover area so they can both go into one application like mutt, while MTA covers another. IMAP already works with a folder system, so it's a simple step to include that into mutt, and with the URL-syntax POP can be treated like a remote folder, too. "This entire concept is rubbish and the mutt developers are just plain lazy [to add all the good stuff]." Well, it seems the force of the masses is hard to withstand though ... recently experimental minimal SMTP support has been added to mutt as an option. If you fail to use a separate local MTA with mutt, try this failsafe. But still the preferred way is the MTA way. Choose your own optimal way for (multi-account) maintenance.
在centos7上面,我使用mutt可以直接使用,但是在centos6上面试了下,发不出去邮件,具体原因我也没找到,可能是因为smtp的原因。
后来准备使用其他smtp发送邮件,按照网上的参考试了几个都没有发送出去,最后发现可能是smtp_url配置的问题,按照如下配置,就可以发送了
set envelope_from=yes
set from='youremail@mailserver.com' set realname='nickname'
set use_from=yes
set smtp_pass='yourpassword'
set smtp_url="smtp://mail.mailserver.com:25" #注,这是25端口没有使用加密,url也可以使用smtp://smtp.mailserver.com:port
set smtp_authenticators='gssapi:login'
之前按照网上的smtp_url中,添加了账号
smtp_url="smtp://myemail@mail.com@mail.mailserver.com:25"
smtp_url="smtp://myemail@mail.mailserver.com:25"
上面两种方式,我试了都是发了邮件,也没返回错误,也没有收到邮件,mutt的日志也没有明确的指出哪里出问题了,不过应该是邮件没有发送成功的。
方法二:
通过yum install mutt安装的mutt,如果按照上面方式后,还是不行的话,可以去官网下载最新的包,自己编译,因为可能有的选项默认安装的包没有编译进去。
./configure --prefix=/opt/tmp/mutt --enable-smtp --enable-debug --with-sasl --enable-pop --enable-imap
mutt调试模式:
Debugging Tips Make sure your mutt is built with debugging support enabled and run mutt -v and look for +DEBUG If it isn't, you'll have to rebuild mutt with debugging support: Build-enable debugging in mutt pass the --enable-debug flag to configure along with any other flags you need.
it can also be useful to run make as make CFLAGS=-ggdb in order to get better debugging symbols
Generating a trace file To produce a debug trace, run mutt with the -d2 flag. -d takes a number from -, corresponding to increasing levels of verbosity: errors
network tracing, important state changes
less important information
log spam, e.g. status updates from functions that are called very often
everything, even very confidential information like passwords
For most purposes, level provides the right amount of detail for a bug report.
It may also include some confidential information (email addresses, server URLs), so you should read it over before you send it to anyone.
Feel free to sanitize it -- we'll ask for further information if necessary. Analyzing a crash We'd love to see a debugger back trace. If you have a core file If mutt has produced a core file, run gdb /path/to/mutt <core file>, then enter backtrace at the (gdb) prompt and cut and paste the output. If you don't One common reason for not getting a core dump when mutt crashes is ulimit.
If running ulimit -c returns , that means core dumps are disabled in your login session. Try executing ulimit -c unlimited, then running mutt again. If you still don't have a core dump, you can always run mutt inside of gdb, then generate the backtrace when it crashes: gdb /path/to/mutt
(gdb) run -d2 [other arguments you use]
(make mutt crash)
backtrace
参考:https://dev.mutt.org/trac/wiki/DebugTips
https://nixtricks.wordpress.com/2010/05/05/mutt-configure-mutt-to-receive-email-via-imap-and-send-via-smtp/
https://dev.mutt.org/trac/wiki/MailConcept
linux邮件客户端mutt日志文件,发不出邮件的更多相关文章
- Linux下查看alert日志文件的两种方法
--linux下查看alert日志文件的两种方法: --方法1: SQL> show parameter background_dump_dest; NAME TYPE VALUE ------ ...
- Linux系统的LOG日志文件及入侵后日志的清除
UNIX网管员主要是靠系统的LOG,来获得入侵的痕迹.当然也有第三方工具记录入侵系统的 痕迹,UNIX系统存放LOG文件,普通位置如下: /usr/adm - 早期版本的UNIX/var/adm - ...
- Linux nohup不输出日志文件的方法
引用:https://blog.csdn.net/guotao15285007494/article/details/84136234 最近在Linux上部署视频流推送应用时,由于网络不稳定等原因程序 ...
- linux下查看mysql日志文件的方法
查看mysql日志方法: mysql默认不允许我们查看日志.需要更改一些设置 1 vi 更改配置文件 允许用户查看日志文件 sudo vi /etc/mysql/mysql.conf.d/mysqld ...
- 【linux】linux上 查看tomcat日志文件
1.查看实时日志文件 tail -f catalina.out 2.实时查看日志文件 最后n行 tail -n -f catalina.out 3.退出tail命令 ctrl + C 4.翻页查看 日 ...
- Linux——清除服务器的日志文件
前言 无论多大的磁盘都遭不住日志文件的糟蹋啊,所以还是需要定时的清除一下. 命令 查找所有.log结尾的文件删除 find / -name "*.log" -exec rm -rv ...
- mysql主从复制linux配置(二进制日志文件)
安装mysql,两台机器一主(192.168.131.153),一从(192.168.131.154) 主机配置 修改主/etc/my.cnf文件 添加 #server_id=153 ###服务器id ...
- Linux服务器配置WEB应用日志文件到指定目录
在Linux服务器上配置WEB应用程序日志到指定文件 服务器环境是 RedHat Linux, 其上运行的是 Apache + Tomcat,容器中运行的是我们公司的壹个小型电子商务网站,原来项目 ...
- Powershell Mail module, 发送outbox 里的全部邮件(一个.csv文件代表一封邮件)
把creating mail代码写到调用处,往outbox写入 mailxxx.csv文件,入面记录了邮件的主要内容 写入 #template $TMP = IMPORT-CSV "$($d ...
随机推荐
- python-select异步IO
#实现多任务在同一个线程切换 #!/usr/bin/python from socket import * from select import * from time import ctime so ...
- PTA (Advanced Level) 1010 Radix
Radix Given a pair of positive integers, for example, 6 and 110, can this equation 6 = 110 be true? ...
- [作业] Python入门基础--用户登陆
让用户输入用户名密码 认证成功后显示欢迎信息 输错三次后锁定登陆 #__author:Mifen #date: 2018/11/28 import time #自定义本地用户名和密码 user_nam ...
- serilization 序列化 transient 不被序列化
Serizlizable 作用 对于一个存在于Java虚拟机中的对象来说,其内部的状态只保持在内存中.JVM停止之后,这些状态就丢失了.在很多情况下,对象的内部状态是需要被持久化下来的.提到持久化,最 ...
- Redis(2):常用命令详解
redis命令不区分大小写 通用命令:1. 获得符合规则的键名列表: keys pattern 其中pattern符合glob风格 ? (一个字符) * (任意个字符) [] (匹配其中的任意一 ...
- 怎么让一段xml被识别为字符串
public static String decodeString(String strData) { strData = replaceString(strData, "<" ...
- Linux多进程之间的文件锁
之前对于文件的操作通常在一个进程中完成,最近需要在两个进程中对同一个文件进行操作.故想到了文件锁. Linux下可以使用flock()函数对文件进行加锁解锁等操作.简单介绍下flock()函数: 表头 ...
- 五、线程本地ThreadLocal
一.线程私有 在多线程情况下,对于一个共享的数据可能会产生线程安全问题.最简单的解决办法就是堆访问共享数据的时候加锁,但我们知道加锁是很影响效率的,尤其是像数据库连接这样耗费资源较多的情况下,加锁就意 ...
- K:单例模式中存在的问题
对于单例模式的实现,无论其是否具有懒加载的功能,我们的目标是有且仅生成一个对象.但是,实际上,对于单例模式的一般实现,都会存在着以下的两个问题: 序列化攻击: 对于枚举方式实现的单例模式,并不存在 ...
- 分ip统计网站访问次数
package web.listener; import javax.servlet.ServletContext; import javax.servlet.ServletContextEvent; ...