- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Converting sendmail generics accounts for outgoing...
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Forums
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-03-2002 02:22 AM
тАО05-03-2002 02:22 AM
Converting sendmail generics accounts for outgoing mail
R$+ < @ $=G . > $: < $(generics $1@$2 $) >
which works to replace our domain with that of the required domain for the genericstable users.
I am setting up a HPUX 11.00 sendmail 8.11.1 server and it does not like the syntax of this rule a bit.
Am I going in the right direction trying to do this via rule or is it overcomplicating things? Should the genericstable handle this by itself with the new generics_domains file?
Cheers,
Damo
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-03-2002 10:27 AM
тАО05-03-2002 10:27 AM
Re: Converting sendmail generics accounts for outgoing mail
Make sure that the genericstable keyed database handler is configured in /etc/sendmail.cf. It would look like this:
# Generics table (mapping outgoing addresses)
Kgenerics hash -o /etc/mail/genericstable
The syntax for sendmail rules is quite specific - three parts delimited by one or more tabs:
Rlhs[TAB]rhs[TAB]comment
The rule should look like this:
R$+ < @ $=G . >[TAB]$: < $(generics $1@$2 $) >[TAB]whatever you want to type here
I hope this helps.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-03-2002 11:13 AM
тАО05-03-2002 11:13 AM
Re: Converting sendmail generics accounts for outgoing mail
/usr/contrib/sendmail/usr/newconfig/etc/mail/cf
You'll need m4 if you use some of the more complex features of sendmail 8.11.1 that aren't in the default cf file.
m4 will build a sendmail.cf with the "right" rulesets. My rulesets for generics look like this (note the rulesets are currently commented out):
# Generics table (mapping outgoing addresses)
# Kgenerics dbm /etc/mail/genericstable
# handle generics database
#R$+ < @ $=G . > $: < $1@$2 > $1 < @ $2 . > @ mark
#R$+ < @ *LOCAL* > $: < $1@$j > $1 < @ *LOCAL* > @ mark
#R< $+ > $+ < $* > @ $: < $(generics $1 $: @ $1 $) > $2 < $3 >
#R<@$+ + $* @ $+> $+ < @ $+ >
# $: < $(generics $1+*@$3 $@ $2 $:@$1 + $2@$3 $) > $4 < @ $5 >
#R<@$+ + $* @ $+> $+ < @ $+ >
# $: < $(generics $1@$3 $: $) > $4 < @ $5 >
#R<@$+ > $+ < @ $+ > $: < > $2 < @ $3 >
#R< > $+ < @ $+ . > $: < $(generics @$2 $@ $1 $: $) > $1 < @ $2 . >
#R< > $+ < @ $+ > $: < $(generics $1 $: $) > $1 < @ $2 >
#R< > $+ + $* < @ $+ > $: < $(generics $1+* $@ $2 $: $) > $1 + $2 < @ $3 >
#R< > $+ + $* < @ $+ > $: < $(generics $1 $: $) > $1 + $2 < @ $3 >
#R< $* @ $* > $* < $* > $@ $>canonify $1 @ $2 found qualified
#R< $+ > $* < $* > $: $>canonify $1 @ *LOCAL* found unqualified
#R< > $* $: $1 not found
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-09-2002 11:04 AM
тАО05-09-2002 11:04 AM
Re: Converting sendmail generics accounts for outgoing mail
We receive mail for three domains to one box
Our DNS is on Dom1
Dom1 is masqueraded as Dom2
Dom3 is masqueraded as Dom1
Some mail from Dom1 users is handled by a genericstable as Dom3 users
Mail for Dom1 users is sent via aliases
Here is a go at an mc file for the above scenario:
VERSIONID(`$Id: generic-hpux10.mc,v 8.11 1999/02/07 07:26:02 gshapiro Exp $')
OSTYPE(hpux11)dnl
define(`_MASQUERADE_ENVELOPE_')dnl
define(`confTRY_NULL_MX_LIST',`T')dnl
define(`DATABASE_MAP_TYPE',`dbm')dnl
define(`_CLASS_U_')dnl
#FEATURE(always_add_domain)dnl
MAILER(local)dnl
MAILER(smtp)dnl
FEATURE(`genericstable',`dmb -o /etc/mail/genericstable')dnl
#FEATURE(`masquerade_envelope')dnl
define(`SMART_HOST', smtp:
Cw Dom1 Dom2 Dom3
define(`MASQUERADE_AS', `Dom2')dnl
FEATURE(`limited_masquerade')dnl
LOCAL_CONFIG
MASQUERADE_DOMAIN(`Dom2 Dom1')dnl
define(`MASQURADE_AS'), Dom1')dnl
FEATURE(`limited_masquerade')dnl
LOCAL_CONFIG
MASQUERADE_DOMAIN(`Dom1 Dom3')dnl
I have also noticed that the cf/cf/generic-hpux10.mc (really a HPUX11 file) does not work without this at the beginning:
include(`../m4/cf.m4')
m4 will run but fail.
By the way I will include any final solutions on this page after reading the good comments about finishing off posts.
Any help or clarifications would be gratefully accepted.
Cheers,
Damo
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-10-2002 07:19 AM
тАО05-10-2002 07:19 AM
Re: Converting sendmail generics accounts for outgoing mail
/usr/contrib/sendmail/usr/newconfig/etc/mail/cf/cf
the syntax is
# m4 ../m4/cf.m4 generic-hpux10.mc > sendmail.cf
where
generic-hpux10.mc
has your feature list ... mine looks something like this:
divert(-1)
#
# Copyright (c) 1998, 1999 Sendmail, Inc. and its suppliers.
# All rights reserved.
# Copyright (c) 1983 Eric P. Allman. All rights reserved.
# Copyright (c) 1988, 1993
# The Regents of the University of California. All rights reserved.
#
# By using this file, you agree to the terms and conditions set
# forth in the LICENSE file which can be found at the top level of
# the sendmail distribution.
#
#
#
# This is a generic configuration file for HP-UX 9.x.
# It has support for local and SMTP mail only. If you want to
# customize it, copy it to a name appropriate for your environment
# and do the modifications there.
#
divert(0)dnl
divert(-1)
# Ported changes from sendmail-8.9.3 - Rajesh. Dec 20, 2000.
# Fix for JAGaa30867.
# Enabled local site hiding and masquerading in default sendmail.cf file.
# Adding feature(always_add_domain) and define __MASQUERADE_ENVELOPE_
# Fix for JAGaa30300 - Added support for openmail and uucp mailer and defined
# _X400_UCCP.
# Fix for JAGaa31678.
# Defined _CLASS_U so that it will add the rule to handle UUCP.
#
divert(0)dnl
VERSIONID(`$Id: generic-hpux10.mc,v 8.11 1999/02/07 07:26:02 gshapiro Exp $')
OSTYPE(hpux11)dnl
DOMAIN(generic)dnl
define(`_X400_UUCP_')dnl
define(`_MASQUERADE_ENVELOPE_')dnl
define(`confTRY_NULL_MX_LIST',`T')dnl
define(`LUSER_RELAY',`name_of_luser_relay')dnl
define(`DATABASE_MAP_TYPE',`dbm')dnl
define(`_CLASS_U_')dnl
FEATURE(always_add_domain)dnl
FEATURE(`virtuser_entire_domain')
VIRTUSER_DOMAIN_FILE(`/etc/mail/virtuser-domain')dnl
FEATURE(access_db)dnl
FEATURE(access_db)dnl
FEATURE(blacklist_recipients)dnl
FEATURE(mailertable)dnl
FEATURE(genericstable)dnl
FEATURE(virtusertable)dnl
FEATURE(domaintable)dnl
MAILER(local)dnl
MAILER(smtp)dnl
MAILER(openmail)dnl
MAILER(uucp)dnl
You can also use
/usr/contrib/sendmail/usr/newconfig/etc/mail/cf/cf/gen_cf
if you're doing straight forward stuff.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО06-02-2002 08:49 PM
тАО06-02-2002 08:49 PM
Re: Converting sendmail generics accounts for outgoing mail
I have included an attachment of things I found helpful including the best documentation, tips and tricks and a detailed mc file with explanations.
I hope this is of some help.
Cheers,
Damo