centos8.1 本地发送邮件配置

centos8.1 本地发送邮件配置

[root@centos8 ~]# mail
bash: mail: command not found...
Failed to search for file: Cannot update read-only repo
[root@centos8 ~]# dnf -y install postfix     安装软件

[root@centos8 ~]# systemctl start postfix
[root@centos8 ~]# ss -ntl

[root@centos8 ~]# mail -s test wei
bash: mail: command not found...
Failed to search for file: Cannot update read-only repo
[root@centos8 ~]# dnf -y install mailx      没发现bash须安装mailx

[root@centos8 ~]# mail -s test wei       发送邮件给普通用户
I am root
how are you
EOT
[root@centos8 ~]#

[wei@centos8 ~]$ pwd               查看所在目录
/home/wei

[wei@centos8 ~]$ mail              查看邮件
Heirloom Mail version 12.5 7/5/10. Type ? for help.
"/var/spool/mail/wei": 1 message 1 new
>N 1 root Sat May 23 09:29 19/571 "test"
& 1
Message 1:
From root@centos8.1.aris Sat May 23 09:29:57 2020
Return-Path: <root@centos8.1.aris>
X-Original-To: wei
Delivered-To: wei@centos8.1.aris
Date: Sat, 23 May 2020 09:29:56 +0800
To: wei@centos8.1.aris
Subject: test
User-Agent: Heirloom mailx 12.5 7/5/10
Content-Type: text/plain; charset=us-ascii
From: root <root@centos8.1.aris>
Status: R

I am root
how are you

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值