Download your favorite Linux distribution at LQ ISO.
Go Back > Forums > Linux Forums > Linux - Server
User Name
Linux - Server This forum is for the discussion of Linux Software used in a server related context.


  Search this Thread
Old 06-10-2008, 08:29 AM   #1
LQ Newbie
Registered: Apr 2006
Posts: 8

Rep: Reputation: 0
How to forward traffic to one subdomain do a different internal IP.

Hi all,

I'm running Debian on my server with a standard LAMP setup with Bind and Vmware. I am virtualising another copy of debian on this so that I can host Zimbra in a clean environment.

I have one external IP address and a domain name to go with it. I want traffic that goes to to go to my copy of zimbra in the VM rather than to the host machine's apache server.

I've been suggested to use iptables - but despite my best efforts I can not get this to work. There are quite a few threads in this sort of area - but none seem to come to a usable conclusion. Any help would be greatly appreciated!
Old 06-10-2008, 12:15 PM   #2
Registered: Apr 2006
Distribution: CentOS openSUSE
Posts: 48

Rep: Reputation: 8
What exactly is it that you're having problems with? If you need to open ports in the firewall then this article should help:

If you are running your VM in a NAT environment then you'll ned to use a Split DNS set-up, article here: You will also need a valid /etc/hosts file, details in the documentation here:

There is actually a support forum at Zimbra for the Open Source user (which I guess you're using). Your problems have more than likely been answered already if you search there.
Old 06-10-2008, 12:42 PM   #3
LQ Newbie
Registered: Apr 2006
Posts: 8

Original Poster
Rep: Reputation: 0
Thanks for your post.
What I am actually trying to achieve is less to do with zimbra than it is to do with my DNS and networking setup.

I am trying to get it so that when a user goes to they get taken to my homepage - which is running under apache, but when they go to they go to my copy of zimbra instead. If I had two IP addresses this would be easy - but I need both of my servers on my internal network to respond to different subdomains on the same IP.

Hope this clarifies somewhat.
Old 06-11-2008, 12:27 AM   #4
Registered: Aug 2005
Location: Malaysia - KULMY / CNXTH
Distribution: Slackware, Fedora, FreeBSD, Sun O/S 5.10, CentOS
Posts: 780
Blog Entries: 6

Rep: Reputation: 75
FYI as dedicated zimbra mail server taken the port 80
so u unable to use others domain inside the server but there ia a way to do that, by pointing zimbra to use another port eg, 81

then you have to use apache virtualhost and proxy pass to point MAIL domain to use port 81 instead of port 80 , and reserve port 80 to ur sub/domain

i can provide step by step if this is the thing u need because i have done this on my mail server , user login will not need to care about the port




dnsbind, subdomain

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

Similar Threads
Thread Thread Starter Forum Replies Last Post
iptables: forward traffic through server Swakoo Linux - Networking 3 03-31-2008 12:59 AM
Forward of subdomain zone with BIND 9.2.3 geroq Linux - Networking 0 03-06-2006 08:07 AM
How can I forward all traffic to to using IPtables? abefroman Linux - Networking 1 10-06-2005 04:19 PM
iptables forward traffic alaios Linux - Networking 1 09-28-2005 05:43 AM
forward subdomain to ip & port andjules Linux - Networking 6 12-11-2002 05:11 PM > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 01:35 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration