LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 06-06-2012, 08:41 AM   #1
g_paschoal
Member
 
Registered: Oct 2009
Posts: 131

Rep: Reputation: 15
Tunnel IPs. Easy question


Hi People,

I have a server which hosts a email marketing application. I just got another server and I want to use that server to send emails also
I've decided to create a tunnel IPs between them.

Server A (email server)
Server B (the other server)


On server A I did:

ip tunnel add tun1 mode ipip remote <ip_server_B> local <ip_server_A>
ifconfig tun1 10.0.0.1 netmask 255.255.255.0 pointopoint 10.0.0.2

On server B I did:
ip tunnel add tun1 mode ipip remote <ip_server_A> local <ip_server_B>
ifconfig tun1 10.0.0.2 netmask 255.255.255.0 pointopoint 10.0.0.1


Everything seems to be working OK. I can ping each other tun interface with the private IP I choose.

My question is. Now.. How can I make my application to send email via server B ? Is there any internal route I still need to do ?


Thank You!
 
Old 06-07-2012, 06:38 PM   #2
Ser Olmy
Senior Member
 
Registered: Jan 2012
Distribution: Slackware
Posts: 3,345

Rep: Reputation: Disabled
Obviously, server A and server B can reach one another directly, since you're able to set up an IP-in-IP tunnel between them.

My question is: Why the tunnel? Why not just use server B as a mail relay?
 
Old 06-08-2012, 02:26 PM   #3
g_paschoal
Member
 
Registered: Oct 2009
Posts: 131

Original Poster
Rep: Reputation: 15
Because I will need more IPs from other servers. Server C and Server D let's say.

BUt the email software will be sending emails via private networks (10.11.0.1) let say... and them it should hit the tunneled IP. But I don't know if it will go out to the internet...

Is there anything to do ? maybe some route on the server ?

Thanks
 
Old 06-08-2012, 06:43 PM   #4
Ser Olmy
Senior Member
 
Registered: Jan 2012
Distribution: Slackware
Posts: 3,345

Rep: Reputation: Disabled
I still don't quite understand what you're trying to accomplish. If servers C and D can access the Internet through a NAT router and thus reach server A, they should be able to use it as a mail relay.

But anyway, if you're setting up a tunnel between servers A and B in order to have servers C and D go through server A to reach server B, you will need to do the following:
  • Server A must have a route entry for the private network of servers B, C and D, pointing at the remote tunnel IP (10.0.0.1 in this case)
  • Servers B and C must have a route entry for the IP of server A, pointing to server B (or they must use server B as the default gateway)
 
Old 06-09-2012, 04:07 PM   #5
g_paschoal
Member
 
Registered: Oct 2009
Posts: 131

Original Poster
Rep: Reputation: 15
All servers (A, B, C and D) has access to the internet. However the email software is installed just on server A.

A tunnel was created using their valid IPs. Then I assign a private IP to each tun* interface.

But if server A send emails to this private IP let say (10.0.0.1) then it should go via tunnel to the server B and them go out to the internet via servers B's valid IP that was tunneled.

I need to do this with several IPs.

Did you get it ?

Thanks for your help.
 
Old 06-09-2012, 04:12 PM   #6
g_paschoal
Member
 
Registered: Oct 2009
Posts: 131

Original Poster
Rep: Reputation: 15
Also, keep in mind that I don't know if tunneling is the right solution here. Maybe you can suggest something else.

What I need to do is have server A ( the server that has the mailing software) send emails via its IP address and use another's servers IP address to send emails as well.

Thanks
 
Old 06-09-2012, 04:44 PM   #7
Ser Olmy
Senior Member
 
Registered: Jan 2012
Distribution: Slackware
Posts: 3,345

Rep: Reputation: Disabled
Quote:
Originally Posted by g_paschoal View Post
All servers (A, B, C and D) has access to the internet. However the email software is installed just on server A.
By "email software", do you mean some piece of software that sends out emails? Or do you mean a mail server?
Quote:
Originally Posted by g_paschoal View Post
A tunnel was created using their valid IPs. Then I assign a private IP to each tun* interface.

But if server A send emails to this private IP let say (10.0.0.1) then it should go via tunnel to the server B and them go out to the internet via servers B's valid IP that was tunneled.
If server B is a mail server acting as a relay for server A, then it will forward mails from server A to any and all recipients. A tunnel is not required for this.

It sounds like what you're really looking for is a mail relay, in which case you should forget about the tunnel and set up Postfix or sendmail on server B, perhaps with SMTP authentication.

If that does not suit your requirements, then you need to explain in more detail why server B needs to be involved in these mail transactions.
 
Old 08-30-2012, 05:28 AM   #8
fafa
LQ Newbie
 
Registered: Aug 2012
Posts: 2

Rep: Reputation: Disabled
Hello everyone

g_paschoal have you solved this problem ?? Let me know please if this problem is solved

I have the same problem, someone have a solution ?
 
Old 08-30-2012, 05:45 AM   #9
descendant_command
Senior Member
 
Registered: Mar 2012
Posts: 1,876

Rep: Reputation: 643Reputation: 643Reputation: 643Reputation: 643Reputation: 643Reputation: 643
Quote:
Originally Posted by g_paschoal View Post
What I need to do is have server A ( the server that has the mailing software) send emails via its IP address and use another's servers IP address to send emails as well.
So, basically you want help to obfuscate the source IP while sending out bulk 'marketing emails'?

edit: oh - old thread ...

Last edited by descendant_command; 08-30-2012 at 05:46 AM.
 
1 members found this post helpful.
Old 08-31-2012, 05:44 AM   #10
fafa
LQ Newbie
 
Registered: Aug 2012
Posts: 2

Rep: Reputation: Disabled
not that, just we want to manage our server for mailing.
ips of sending are allocated and assigned to a server, and the server of sending (smtp server) is separeted, so we want to connecte to the remote server and use the Ips, but the sending in not from the same server because it not contains Ip.
 
  


Reply



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



Similar Threads
Thread Thread Starter Forum Replies Last Post
6-to-4 tunnel setup question vlyamtse Linux - Networking 0 03-16-2012 11:23 AM
Bind Failover IPs to users over SSH (using SOCKS) Tunnel SonicFire Linux - Networking 3 12-13-2011 07:54 AM
Another SSH Tunnel Question pinoyskull Linux - Server 2 09-27-2010 08:46 PM
Question about a GRE Tunnel zerounu Linux - Networking 1 03-09-2004 09:04 AM
gigabyte easy tunnel skeletal29 Linux - Hardware 2 10-01-2002 04:21 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 03:08 PM.

Main Menu
Advertisement
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
Open Source Consulting | Domain Registration