LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 08-24-2016, 01:08 PM   #1
TopAngler
LQ Newbie
 
Registered: Aug 2016
Posts: 2

Rep: Reputation: Disabled
Question New CentOS 6.8 Install - Mail Not Working


Hello, I'm new to this forum. I just did my install of Linux... CentOS 6.8 running on a VPS.

I installed a shell script to monitor the server, and setup a cron job to run the script daily. The script is supposed to email me the results... The first time the script ran, I received the following error in my mail spool:

line 6: /bin/mail: No such file or directory

It appears that there is no "mail" program running.

I did some research trying to ascertain whether there is an MTA installed, and whether it's running. I found this command:

# rpm -q sendmail postfix exim qmail
package sendmail is not installed
postfix-2.6.6-6.el6_7.1.x86_64
package exim is not installed
package qmail is not installed

The above seems to indicate that I have Postfix installed. I then executed the following commands:

# postfix stop
postfix/postfix-script: stopping the Postfix mail system
# postfix start
postfix/postfix-script: starting the Postfix mail system

So it appears Postfix is running. But it's not "working". Since I just installed Linux, does Postfix need to be setup or configured in any way?

Or more generally, how do I get "mail" working? What next?

Thank you in advance...
 
Old 08-24-2016, 06:57 PM   #2
Alpha90
Member
 
Registered: Jul 2012
Posts: 97

Rep: Reputation: Disabled
Im not using CentOS but looking at the package list they are using mailx and in the rpm of mailx the binary looks to be /bin/mailx
Check to make sure mailx is installed and if it you just need a symlink.
 
Old 08-25-2016, 09:05 AM   #3
TopAngler
LQ Newbie
 
Registered: Aug 2016
Posts: 2

Original Poster
Rep: Reputation: Disabled
Thanks for your reply. mailx is NOT installed. postfix IS installed.

1. Should I use postfix? If not, what?

2. If postfix, what do I need to do next to get it working - what's the procedure?
 
Old 08-25-2016, 10:10 AM   #4
Habitual
LQ Veteran
 
Registered: Jan 2011
Location: Abingdon, VA
Distribution: Catalina
Posts: 9,374
Blog Entries: 37

Rep: Reputation: Disabled
Quote:
Originally Posted by TopAngler View Post
what's the procedure?
https://wiki.centos.org/HowTos/postfix

Read x 2
Try.
Ask.

Last edited by Habitual; 08-25-2016 at 10:11 AM.
 
Old 08-26-2016, 02:49 AM   #5
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Rocky 9.2
Posts: 18,359

Rep: Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751
postfix is the mta. you'll need mailx (yum install mailx) as a client to actually send mail.
FWIW its in the Base repo which is normally enabled at install time.
Code:
mailx-12.4-8.el6_6.x86_64 : Enhanced implementation of the mailx command
Repo        : base
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
LXer: How to Install iRedMail (Mail Server) on CentOS 7 & RHEL 7 LXer Syndicated Linux News 0 12-29-2015 08:21 AM
how to install zimbra mail server on centos 6.5 32 bit srinath.proventus CentOS 1 11-10-2014 11:06 AM
LXer: Set Up DKIM (DomainKeys Identified Mail) Working With Postfix On CentOS Using OpenDKIM LXer Syndicated Linux News 0 11-16-2012 09:10 AM
Want to install Mail Server on CentOS 5.0 which support both Ldap and Active Drectory ad1325 Linux - Server 2 03-19-2009 12:27 PM
Mail::ClamAV error on install on CentOS 4.4 waelaltaqi Linux - Server 0 02-19-2007 10:58 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 05:34 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration