LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (https://www.linuxquestions.org/questions/slackware-14/)
-   -   newbie modifying sendmail configuration for IPv6... (https://www.linuxquestions.org/questions/slackware-14/newbie-modifying-sendmail-configuration-for-ipv6-777071/)

janhe 12-20-2009 12:10 PM

newbie modifying sendmail configuration for IPv6...
 
My goal is to make sendmail accept connections over IPv6.

ok, this is the diff from after my edit:
Code:

root@computer-compaq:/usr/share/sendmail/cf/cf# diff -u sendmail-slackware.mc sendmail-slackware-ipv6.mc
--- sendmail-slackware.mc      2009-06-26 21:50:54.000000000 +0200
+++ sendmail-slackware-ipv6.mc  2009-12-20 18:57:55.000000000 +0100
@@ -37,6 +37,8 @@
 EXPOSED_USER(`root')dnl
 dnl# Also accept mail for localhost.localdomain:
 LOCAL_DOMAIN(`localhost.localdomain')dnl
+DAEMON_OPTIONS(`Name=MTA-v4, Family=inet')
+DAEMON_OPTIONS(`Name=MTA-v6, Family=inet6')
 MAILER(local)dnl
 MAILER(smtp)dnl
 MAILER(procmail)dnl

I ran m4 and copied the file to /etc/mail/:
Code:

root@computer-compaq:/usr/share/sendmail/cf/cf# m4 sendmail-slackware-ipv6.mc > ../../sendmail-slackware-ipv6.cf
root@computer-compaq:/usr/share/sendmail/cf/cf# cp /usr/share/sendmail/sendmail-slackware-ipv6.cf /etc/mail/sendmail.cf

The result:
Code:

root@computer-compaq:/usr/share/sendmail/cf/cf# sh /etc/rc.d/rc.sendmail restart
Starting sendmail MTA daemon:  /usr/sbin/sendmail -L sm-mta -bd -q25m
554 5.3.5 /etc/mail/sendmail.cf: line 265: Unknown address family inet6 in Family=option
Starting sendmail MSP queue runner:  /usr/sbin/sendmail -L sm-msp-queue -Ac -q25m

It doesn't listen to IPv6.

Doesn't sendmail support IPv6 by default on slackware? How can I check that?

Do I have to modify some other configuration file? Which one?

janhe 12-20-2009 04:50 PM

I just found out that the slackware package doesn't support IPv6 (I think)

When I run this, I don't see the "NETINET6" option under "Compiled with:"
Code:

/usr/sbin/sendmail -bt -d0.4 < /dev/null
I will now look into recompiling the package...

Hints and tips are appreciated. Apparently I need to modify the site.config.m4 file. I've looked a few times at the slackbuild, and I'm not sure if it uses this file.

janhe 12-21-2009 04:03 AM

Allright, I recompiled the packages for sendmail and sendmail-cf.

The slackbuild from Pattrick does compile from source and uses site.local.m4.

I added this line to site.local.m4 and reran the slackbuild:
Code:

APPENDDEF(`confENVDEF', `-DNETINET6')
Now it supports IPv6!

Apparently you cannot run sendmail on port 25 for IPv6 and on port 25 for IPv4, so I had to change the MTA line to this:
Code:

DAEMON_OPTIONS(`Name=MTA-v4, Family=inet, Family=inet6')
Then it accepts IPv4 and IPv6.


All times are GMT -5. The time now is 01:56 AM.