1,安装mailx

使用sudo apt-get install mailx会出现两个包选择

heirloom-mailx和bsd-mailx

区别在于前者配置文件为/etc/mail.rc

我安装了heirloom-mailx这个包

然后配置文件

set from=发送邮箱的地址xx@163.com
set smtp=smtp.163.com
set smtp-auth-user=xx@163.com
set smtp-auth-password=password
set smtp-auth=login

 


发送命令

echo "practice"| mailx -s "Title" xx@163.com

 

相关文章:

  • 2021-07-31
  • 2022-12-23
  • 2021-07-27
  • 2022-12-23
  • 2022-12-23
  • 2021-10-17
  • 2022-01-06
  • 2022-01-06
猜你喜欢
  • 2022-12-23
  • 2022-01-12
相关资源
相似解决方案