LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 07-11-2012, 01:04 AM   #1
LittleMaster
Member
 
Registered: Jun 2012
Posts: 121
Blog Entries: 1

Rep: Reputation: Disabled
Problem in apache redirect using ProxyPassReverse


Hi

Currently im running my site on ipaddress 10.200.2.26:70.i had mapped my ipaddress to domain.net and domain.com.when i tried to map the domain domain.com to http://10.200.2.26:70 it never seems to works.Any suggestion to solve the issue


NameVirtualHost *:80

<VirtualHost *:70>
ServerName domain.com
ServerAlias www.domain.com
ProxyPass / http://10.200.2.26:70/
ProxyPassReverse / http://10.200.2.26:70/
</VirtualHost>
 
Old 07-11-2012, 01:52 AM   #2
acid_kewpie
Moderator
 
Registered: Jun 2001
Location: UK
Distribution: Gentoo, RHEL, Fedora, Centos
Posts: 43,417

Rep: Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985
what abuot it doesn't work??

Based on the limited config you've provided, you're not listening for vhosts on port 70, only port 80.
 
Old 07-11-2012, 02:21 AM   #3
LittleMaster
Member
 
Registered: Jun 2012
Posts: 121

Original Poster
Blog Entries: 1

Rep: Reputation: Disabled
Hi
when i type domain.com its pointing to 10.200.2.26:80.Currently im trying out to point domain.com to http://10.200.2.26:70.whether i can achieve these redirection using proxypass are else i have to do these redirect configuration using mod rewrite rules.Any suggestion
 
Old 07-11-2012, 03:13 AM   #4
acid_kewpie
Moderator
 
Registered: Jun 2001
Location: UK
Distribution: Gentoo, RHEL, Fedora, Centos
Posts: 43,417

Rep: Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985
domain names have NOTHING to do with port numbers, you can't associate one to the other from the clients perspective, that's not how DNS works.

You may well be missing the very point of virtual hosts though. The point being that you use the SAME port and differentiate the content to server based on the host name.
 
Old 07-11-2012, 03:44 AM   #5
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 13,163
Blog Entries: 1

Rep: Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032
Quote:
NameVirtualHost *:80

<VirtualHost *:70>
...
This is wrong. You should use the same notation for both NameVirtualHost and VirtualHost
Code:
NameVirtualHost *:80

<VirtualHost *:80>
...
 
Old 07-11-2012, 04:44 AM   #6
jsaravana87
Member
 
Registered: Aug 2011
Location: Chennai,India
Distribution: Redhat,Centos,Ubuntu,Dedian
Posts: 558
Blog Entries: 5

Rep: Reputation: Disabled
Hi
Dont require mod proxy ,mod rewrite do these function .You can just achieve these by using two virtualhost configuration by differing DocumentRoot


NameVirtualHost *:80

<VirtualHost *:80>
ServerName domain.com
ServerAlias www.domain.com
DocumentRoot ...
</VirtualHost>

<VirtualHost *:80>
ServerName domain.net
ServerAlias www.domain.net
DocumentRoot ... point the Document root of domain.net and remaining stuff inside your virtualhost
</VirtualHost>
 
  


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
Apache 2.2.3 ProxyPassReverse problem... epoh Linux - Software 0 09-05-2008 11:43 AM
Problem with Redirect in Apache kaplan71 Linux - Software 20 10-10-2006 02:09 AM
Apache VirtualHost Redirect Problem... SiLiCoN Linux - Networking 5 05-03-2005 08:41 AM
Apache URL redirect problem kdogksu Linux - Networking 2 03-26-2005 02:22 PM
Apache ReWriteRule, ProxyPassReverse, and Allow From directives yakkerty Linux - Networking 3 06-24-2004 01:21 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 03:32 AM.

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