kalliste Posted September 21, 2005 Report Share Posted September 21, 2005 (edited) Hi All, I'm trying to get the mail command to work. I don't want to setup my own mail server, I just want to use mail to send outgoing mails from the command line or from scripts. I was hoping to set mailrc and main.cf to use my web hosts mail server. so I set main.cf myhostname = <smtp.server> am I going in the right direction? I now get a warning and the machine hangs: postdrop: warning: unable to look up public/pickup: No such file or directory thanks in advance Edited September 21, 2005 by kalliste Quote Link to comment Share on other sites More sharing options...
aioshin Posted September 22, 2005 Report Share Posted September 22, 2005 as I understand, myhostname refers to your linux box hostname or a fully qualified domain name, if not, just localhost, try to install postfix, installing it does not mean that you have installed a mail server, its just an MTA or mail tranport agent, just make it listen to localhost so it wont accept connection from outside since your intention is to just be able to do outgoing mail from a command line. Quote Link to comment Share on other sites More sharing options...
theYinYeti Posted September 22, 2005 Report Share Posted September 22, 2005 Here is my main.cf, minus comments, edited to reflect your need: - mails are transfered to your ISP, and - there's only very limited support for incoming mail. queue_directory = /var/spool/postfix command_directory = /usr/sbin daemon_directory = /usr/lib/postfix mail_owner = postfix default_privs = nobody myhostname = <YOUR FULLY-QUALIFIED HOSTNAME> mydomain = <THE PART AFTER THE LAST DOT IN YOUR myhostname> myorigin = $myhostname mydestination = $myhostname relayhost = <YOUR ISP SMTP SERVER> alias_maps = hash:/etc/postfix/aliases mail_spool_directory = /var/spool/mail mailbox_command = /usr/bin/procmail -Y -a "$DOMAIN" smtpd_banner = $myhostname ESMTP $mail_name ($mail_version) (Mandriva Linux) debugger_command = PATH=/bin:/usr/bin:/usr/local/bin:/usr/X11R6/bin xxgdb $daemon_directory/$process_name $process_id & sleep 5 delay_warning_time = 12 sendmail_path = /usr/sbin/sendmail.postfix newaliases_path = /usr/bin/newaliases.postfix mailq_path = /usr/bin/mailq.postfix manpage_directory = /usr/share/man sample_directory = /usr/share/doc/postfix-2.1.5/samples readme_directory = /usr/share/doc/postfix-2.1.5/README_FILES disable_dns_lookup = yes setgid_group = postdrop unknown_local_recipient_reject_code = 450 html_directory = /usr/share/doc/postfix-2.1.5/html Yves. Quote Link to comment Share on other sites More sharing options...
kalliste Posted September 22, 2005 Author Report Share Posted September 22, 2005 Thanks very much for your help! It's all working dandy now on to my next problem :-) Quote Link to comment Share on other sites More sharing options...
theYinYeti Posted September 23, 2005 Report Share Posted September 23, 2005 You're welcome! I'm glad it did work :) Yves. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.