Solved

Sending email via an ISP account

Posted on 1998-06-11
5
278 Views
Last Modified: 2010-04-20
Hello! I'm a Linux newbie and I'd really appreciate some help with my email problem.

***The problem***:
I can't send email via my ISP.

***What I'm using***
The Slackware 3.4 distribution, kernel 2.0.30, is installed on my personal Linux box.
I'm running BSD sendmail 8.8.7.
I'm successfully using fetchmail 4.4.7 to retrieve and read mail from my account with my ISP using POP and a simple .fetchmailrc file in my home directory:

poll mailserver.my.isp.com
protocol POP3
username <my_username_at_my_ISP>
password <my_password_at_my_ISP>
is <usename_on_my_machine>

This works great for receiving mail.

***What's happening***
When I run the outgoing mail queue to send mail via SMTP through my ISP, I get error messages saying that my machine has an unresolvable host name.

PLease help...

Periclis
0
Comment
Question by:periclis
  • 2
  • 2
5 Comments
 

Author Comment

by:periclis
Comment Utility
Edited text of question
0
 
LVL 2

Accepted Solution

by:
richrussell earned 100 total points
Comment Utility
Check your /etc/hosts and /etc/sendmail.cf files to see that your host name is in there in the right places. Have a look at the man page for sendmail, it's quite useful. Also have a good read through of the howto files.

I got there in the end, so I just run 'ppp-on' then sendmail gets my mail and sends any outgoing.

Have a word with your ISP, they may be able to point you in the right direction. It's worth while getting a good linux book as this is dealt with in quite a few of tem.
0
 

Expert Comment

by:viki
Comment Utility
Hello, you need to modify your sendmail.cf for working in a LAN.
Some variables :
my.domain : your local domain
smtp.my.isp.domain : the SMTP server of your ISP
my.isp.domain : the domain of your ISP

edit a new .mc (ex foo.mc)and type (dnl is commetary):
-------cut --------------------
divert(-1)
dnl Check the location of cf.m4
include(`/usr/lib/sendmail-cf/m4/cf.m4')
OSTYPE(linux)dnl
DOMAIN(generic)dnl
GENERICS_DOMAIN(my.domain)dnl
FEATURE(use_cw_file)dnl
FEATURE(always_add_domain)dnl
FEATURE(masquerade_envelope)dnl
dnl The fiels FROM that the ISP gave you
dnl You will create a .db after ...
FEATURE(genericstable,``hash -N /etc/revaliases'')dnl
define(`confDOMAIN_NAME',`my.ISP.domain')dnl
define(`confSMTP_MAILER',`smtp8')dnl
dnl you will probably change this ...
define(`confDEF_CHAR_SET',`ISO-8859-1')dnl
define(`SMART_HOST',`Smtp:smtp.my.ISP.domain')dnl
dnl
dnl If you use Procmail
dnl location of procmail : /usr/bin/procmail
FEATURE(local_procmail,``/usr/bin/procmail'')
dnl by default /usr/local/bin
FEATURE(local_procmail)
dnl Comment out one of these 2 FEATUREs above
dnl depends of your case ...
dnl
MAILER(local)
MAILER(smtp)
----- cut here ------
You "masquerade" your local domain by a real domain.
You can add the cost ... means that every messages is queued until a PPP connection is made (the command is sendmail -q)
Add in the mc file :
define(`confCON_EXPENSIVE,`True')dnl
define(`SMTP_MAILER_FLAG',`e')dnl

1. Generate the sendmail.cw (save your old /etc/sendmail.cw) with:
$ m4 foo.cw > /etc/sendmail.cw
2. Put in the /etc/hosts the IP address of smtp.my.ISP.domain
XXX.XXX.XXX.XXX smtp.my.IPS.domain smtp
3. Put this line in the /etc/revaliases :
my.domain: real-adresse@my.ISP.domain
4. regenarate the base aliases
sendmail -bi -oA/etc/revaliases
5. kill sendmail
kill `head -1 /var/run/sendmail.pid`
6. restart sendmail with :
/usr/sbin/sendmail -bd -os
(you can modify the rc script to start sendmail with these options)
. OK !
Every message is kept in /var/spool/mqueue and once logged on the Internet type:
/usr/sbin/sendmail -q (to empty the queue)
You can add this line in the ip-up script

Hope this helps
Vikie



0
 

Author Comment

by:periclis
Comment Utility
Thank you very much for the detailed response!
However, there's still a **small problem**:

I can't send mail to myself, or to other users with accounts on the same ISP, no matter whether I use as address

<email_address_at_this_ISP>@<this_ISP_domain>

or

<username_at_this_ISP>@<this_ISP_domain>

I can receive email from users with accounts on the same ISP.

These messages are queued normally when I'm not logegd in to my ISP, but when I log in to my ISP and try to run the queue they bounce with "this address had permanent fatal errors: user unknown".

Messages to recipients on remote addresses are not bouncing, but i don't know yet whether they're getting through.

Periclis
0
 

Expert Comment

by:viki
Comment Utility
Hi,
Have a look on the /var/log/maillog to see what happens (the format of addresses)
Try to log on your linux box with the same account than your ISP gave to you (bloody english on monday morning ;-)).
Or mail me directly (vikie@iname.com)
Bye
Vikie
0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

In my business, I use the LTS (Long Term Support) versions of Linux. My workstations do real work, and so I rarely have the patience to deal with silly problems caused by an upgraded kernel that had experimental software on it to begin with from a r…
1. Introduction As many people are interested in Linux but not as many are interested or knowledgeable (enough) to install Linux on their system, here is a safe way to try out Linux on your existing (Windows) system. The idea is that you insta…
Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:
Learn how to navigate the file tree with the shell. Use pwd to print the current working directory: Use ls to list a directory's contents: Use cd to change to a new directory: Use wildcards instead of typing out long directory names: Use ../ to move…

771 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now