LinuxQuestions.org
Register a domain and help support LQ
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices

Reply
 
Search this Thread
Old 02-19-2003, 10:42 AM   #1
Steven6282
LQ Newbie
 
Registered: Feb 2003
Posts: 10

Rep: Reputation: 0
Linux email server and some HTTP server questions


Hello,
I'm trying to set up an email server on my redhat 8.0 linux box. I'm a newb to thi sort of stuff (both linux and servers). Right now I have been able to set me up an HTTP server and a FTP server, but the email server is kicking my butt.

I have the IMAP and POP services running but I can't figure out how to configure these or anything. I've tested sending mail to my domain (thechosenguild.com) and I just get mail returned as undeliverable.

I've checked my ISP no ports are blocked and I have all the ports necessary forwarded through my router.

So can anyone clue me in? How do I configure the email servers in order to be able to receive the emails and check it from outside. (Thats another thing, I tried using mail.thechosenguild.com and that just takes me to my homepage default homepage.)

I've thought about trying to download and install another email server but I'm at a complete loss when looking for one. The only one I've found that even looks promising looks to have an installation process that would take 10 hours lol.

So basically I guess my questions would be, what is a good easy to use email server? How do I set it up so that I can receive email and log in from outside to check it? Oh and I guess I should specify I dont want to spend any money on it unless its cheap.

As far as my HTTP server questions. I just want to know is there a way to set it up so if someone goes to say guest.thechosenguild.com it would take them to a different page than say members.thechosenguild.com?

Thanks for any answers you can give me.
 
Old 02-19-2003, 10:52 AM   #2
fancypiper
Guru
 
Registered: Feb 2003
Location: Sparta, NC USA
Distribution: Ubuntu 10.04
Posts: 5,141

Rep: Reputation: 57
I am confused by your question. I think your questions are referring to an e-mail client rather than an e-mail server.

My basic setup gets the mail from my isp with fetchmail, procmail sorts it and sendmail sends it. You have to configure sendmail to use SMART_HOST.

Here is the file I found at Suresh Ramasubramanian's email guide:
Code:
divert(-1)
dnl This is the macro config file used to generate sendmail.cf
dnl file. If you modify this file you will have to regenerate 
dnl sendmail.cf by running this macro config through the m4
dnl preprocessor:
dnl
dnl        m4 /home/phil/Documents/sendmail.mc > /etc/sendmail.cf <--Change to your path
dnl
dnl You will need to have the sendmail-cf RPM installed for this
dnl to work, if you use an rpm build of sendmail
dnl
dnl include(`../m4/cf.m4')
dnl
dnl If you compile sendmail from a tarball, use the include above.
dnl In this setup, you should create the file as cf/cf/config.mc 
dnl (in the sendmail source tree: eg. /usr/src/sendmail-8.11.6/cf/cf
dnl Now give the command "sh Build config.cf".  Now copy the file
dnl config.cf as /etc/mail/sendmail.cf (please backup first!)
dnl
dnl If you are using the RPM build of sendmail, use the 
dnl include statement given below instead
dnl
include(`/usr/share/sendmail-cf/m4/cf.m4')
define(`confDEF_USER_ID',``8:12'')
OSTYPE(`linux')
undefine(`UUCP_RELAY')
undefine(`BITNET_RELAY')
define(`confCF_VERSION',`dialup-1.3')
define(`SMART_HOST', `smtp.yourisp.com') <--Change this
define(`confAUTO_REBUILD')
define(`confTO_CONNECT', `1m')
define(`confTO_IDENT',0)
define(`confTRY_NULL_MX_LIST',true)
define(`confDONT_PROBE_INTERFACES',true)
define(`confCON_EXPENSIVE',true)
define(`confDELIVERY_MODE', `queued')
define(`PROCMAIL_MAILER_PATH',`/usr/bin/procmail')
define(`ALIAS_FILE',`/etc/mail/aliases')
MASQUERADE_AS(`yourisp.com') <--Change this
FEATURE(`masquerade_envelope')
FEATURE(`smrsh',`/usr/sbin/smrsh')
FEATURE(`mailertable',`hash -o /etc/mail/mailertable')
FEATURE(`virtusertable',`hash -o /etc/mail/virtusertable')
FEATURE(redirect)
FEATURE(always_add_domain)
FEATURE(use_cw_file)
FEATURE(`use_ct_file')
FEATURE(local_procmail)
MAILER(smtp)
MAILER(procmail)
FEATURE(`access_db')
FEATURE(`blacklist_recipients')
FEATURE(`accept_unresolvable_domains')
FEATURE(`accept_unqualified_senders')
dnl FEATURE(`relay_based_on_MX')
Alter the lines with <--Change this to your situation (and remove the <--Change this from the line).

# Common e-mail tools
sendmail - postfix - sends mail to local users (and internet when configured correctly)
fetchmail - gets mail from internet accounts (non-Hotmail type)
procmail - sorts and delivers into separate mailboxes
mutt - mail client that sucks less than all the others
Email the Linux Way
Suresh Ramasubramanian's email guide
The Linux Mail User HOWTO
The Linux Electronic Mail Administrator HOWTO
Gotmail, a utility to download mail from Hotmail type accounts

Last edited by fancypiper; 02-19-2003 at 10:55 AM.
 
Old 02-19-2003, 10:55 AM   #3
Any
Member
 
Registered: Feb 2003
Location: Uk
Distribution: It varies
Posts: 54

Rep: Reputation: 15
Not sure about your email problem.

But the for the domain thing you need to use Virtual Hosts in Apache(you are using Apache?). Have a look at the 'Virtual Host examples for common setups'

Any
 
Old 02-19-2003, 11:05 AM   #4
Steven6282
LQ Newbie
 
Registered: Feb 2003
Posts: 10

Original Poster
Rep: Reputation: 0
Fancy: I'm not talking about an Email client. When you set up red hat linux 8.0 you have hte option to install Mail Servers. Squirrelmail, IMap, AntiAssassin (or something like that).. all these little things that are meant to work with a mail server not a client. I dont want my email going through someone elses server and me having to fetch it from there.. I want it sent directly to my server.

To put it on someone elses server and fetch it like your talking of doing costs money, and your limited on the accounts and space you can have. And its costs a lot of money for what you get. Unless you use free email stuff from yahoo or hotmail type stuff but thats not what I want.. I want email@mydomain.com.

I've just got to figure out how to setup my mail server and it should work.

Any I'll look into that.. I played around with it some when I was first setting up the HTTP server but didn't play for long just long enough to figure out how to set up my current server thankyou .
 
Old 02-19-2003, 11:30 AM   #5
fancypiper
Guru
 
Registered: Feb 2003
Location: Sparta, NC USA
Distribution: Ubuntu 10.04
Posts: 5,141

Rep: Reputation: 57
The Linux Electronic Mail Administrator HOWTO looks good for setting it up.
 
Old 02-19-2003, 12:29 PM   #6
Steven6282
LQ Newbie
 
Registered: Feb 2003
Posts: 10

Original Poster
Rep: Reputation: 0
*sigh* None of this stuff makes any sense.

I tried that virtual host stuff.. I'm guessing I was editing the right file I dont have a clue, but anyway it didn't work. Even after I copied exactly the way the samples showed in that link you gave me.

And if I use the graphical interface that redhat has for it to try and set them up... it saves the file as completely blank.. dunno if its a bug or what. Anything that I type with thechosenguild.com at the end of it always goes to my main page no matter how I set up the virtual servers. Maybe it has something to do with that sample being only apache 1.3 where as my apache is 2.0. Quite confusing though.

Then as far as the mail goes.. I couldn't find anything relevant to what I'm trying to do in that HOWTO.

And another question I found while playing with some stuff.. I figured out that I have squirellmail installed and the alias for it is /webmail. So I went to my webpage (thechosenguild.com/webmail) and it returned an error saying www._default_.com not found.. wth? Looked through all the config files for squirellmail and I can't find anywhere where it references www._default_.com...

I'm at a loss on all subjects...
 
Old 02-19-2003, 01:17 PM   #7
fsbooks
Member
 
Registered: Jan 2002
Location: Missoula. Montana, USA
Distribution: fedora, slackware, suse
Posts: 447

Rep: Reputation: 31
I use sendmail.

redhat sets up sendmail to only operate as a client. In RH7.3, and it may not have changed, you must eliminate or comment out (preface line with "dnl") the line that reads in /etc/mail/sendmail.mc :

DAEMON_OPTIONS(`Port=smtp,Addr=127.0.0.1, Name=MTA')

and then rebuild your sendmail.cf:

"m4 /etc/mail/sendmail.mc > /etc/mail/sendmail.cf"

Check it, put it in /etc. You will most likely also have to edit create /etc/mail/local-host-names to where you add your host.
The name of course will be depend the setup of sendmail.cf. It is the "file containing names of hosts for which we receive email" and comes after Fw . There are probably other options you may want to use depending on your preferences. Don't forget to restart the sendmail daemon.

Sendmail is easy and complicated at the same time. Just read and re-read the documentation. There is some good stuff in (typically) /usr/share/doc/sendmail, though I recommend the FAQ at http://sendmail.org/faq/ which allows one to track down specific error messages.
 
Old 02-19-2003, 03:39 PM   #8
Steven6282
LQ Newbie
 
Registered: Feb 2003
Posts: 10

Original Poster
Rep: Reputation: 0
Ok well I got the email server working .. on the server. Can send and receive email fine as long as I'm logged into that account on the server computer. Now I gotta figure out how to connect to it from outside the server.

Another question now that I got that part set up, is there anyway to changed sendmail so that if it gets a email that dosn't match a user account, is there anyway to have it redirected automatically to another account? Right now if I was to send email to say webmaster@thechosenguild.com I would get mail returned undeliverable because I dont have a user account set up named webmaster.

I'm still stumped on the virtual hosts thing.. if I add another virtual host and change the name and stuff .. my hole server goes into SSL enabled and wants me to go to https:// instead of http:// and if I go to https:// it denies my connection.

Also if I try to watch another port when I go to restart the server it tells me Error: Listen can only accept one argument.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Questions about what software to use to install a mail+http server system. papitu76 General 1 01-10-2005 02:33 PM
Http Linux file server doc54963 Linux - Enterprise 3 10-14-2004 10:10 PM
Fedora Core 2: Personal, home-based email server issues and questions nmsatyagrahi Linux - Networking 1 07-01-2004 12:46 PM
problem setting up router in linux http server mkepler1 Linux - Networking 1 12-18-2003 12:42 PM
script for http, email, and ftp server cblank Linux - Networking 0 08-09-2001 10:07 AM


All times are GMT -5. The time now is 10:38 AM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration