setup a mail account without...


i had setup, and for mail goes to owner abc.

but now, i would like to add for a separate user 'john' thats mean john has his own mail box.

beside add new 'john' account to my server before setting the ,

is there any other way to do it?

Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

bsherAuthor Commented:
Adjusted points to 25
This depends on your mail server.
Is this  UNIX box, completely under your control.
Or is this a box/shares server at some ISP.

If your site is hosted at an ISP, you will have to
inquire with them as all of them have their own set of tools to do so.

If you have a UNIX box under your control,
I could help you out.
bsherAuthor Commented:
the mail server i under my control, so ....
Keep up with what's happening at Experts Exchange!

Sign up to receive Decoded, a new monthly digest with product updates, feature release info, continuing education opportunities, and more.

is it a standard sendmail.. is it a UNIX/Linux System?
What is the version of Sendmail?
bsherAuthor Commented:
sendmail version 8.8.7
the 'in the guts' method, that will always work, is to edit the file, and add specific rules that say what to do with mail to a particular user or domain.


adding rules in ruleset 98 is a good start, and a rule like

R foouser < @ $* >     $#local $: baruser
R blockeduser < @ $* >        $#error $@ 5.7.1 $: "blocked address -  mail denied."
R $+ < @ $* > $#local $: catchall

these three rules specify how to handle mail for foodomain. (make sure you specify foodomain as a local host either by adding it to Cw near the top of the, or by putting it in the if you're using one)

the first rule specifies that mail to foouser@foodomain get sent locally to baruser.
the second rule says mail to blockeduser gets bounced with an error message.
the third says anything else sent to ends up in the local user 'catchalll' 's box.

this, and the o'reilly sendamil boox should get you on your way.

BTW, this is not the most simple way to do this. one can user virtuser tables, domain maps, and any number of other ways to accomplish the same thing. but this way _does_ work. wear it in good health.


Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
bsherAuthor Commented:
what i want is create a mail account for a user called without creat a unix account for him?

Is this the way?

I m not very familiar with sendmail

Thanx for help
The question now is how is that user going to access his email.   If you plan to forward that email
somewhere else, you can just use aliases to direct the mail. But if you want someone to access the mail
locally, it will be much easy to creat a local user id.

So. Will this person access the mail from the local machine?  if so creat a local user account.

If not.. you can forward the emails for that person
to a remote system using aliase forwarding.
bsherAuthor Commented:
yes he will access locally....

so i need to create a account for him..

By the way, how to disable ftp and telnet for that account, since i only want him to access mail only?
Disable ftp and telnet for the account.

Easiest thing to do is assign an invalid shell. to that user:

in /etc/passwd file
assign the shell as /nosuchshell /nobin/restricteduser
for that user.

Shell is the last field in the password entry
for example /bin/sh /bin/csh ( bash tcsh ksh etc.. )
this will prevent user from doing ftp and

bsherAuthor Commented:
if i would like to forward, what r the steps i need to do
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Unix OS

From novice to tech pro — start learning today.