can i forward apache to another ipaddress?

i want to forward all incoming localhost:83 to another ipaddress for internal users only



the localhost is where im setting up the changes in the conf file in apache its already listening at port 83
and i have a few virtual servers setup now im just in need of a forward to another machine

i want to forward to this
ip is at 192.168.1.2 on port 80
LVL 1
aot2002Asked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

ramazanyichCommented:
for localhost virtual section you can use following config:

RewriteEngine on
RewriteCond   %{REMOTE_HOST}  ^\.your_internal_domain\.com$
RewriteRule   ^(.+)         http://192.168.1.2/$1 [R,L]

0
aot2002Author Commented:
<VirtualHost *:83>
       # DocumentRoot "C:/Program Files/NuSphere/TechPlat/apache/htdocs/video/"
RewriteEngine on
RewriteCond   %{REMOTE_HOST}  ^\.your_internal_domain\.com$
RewriteRule   ^(.+)         http://192.168.1.2/$1 [R,L]
</VirtualHost>


>>>> ok heres my apache httpd.conf
page cannot be displayed
WHAT GIVES ???
0
aot2002Author Commented:
shouldne the 192.168.1.2 be ok if i can paste it in a webbrowser
0
Cloud Class® Course: Microsoft Azure 2017

Azure has a changed a lot since it was originally introduce by adding new services and features. Do you know everything you need to about Azure? This course will teach you about the Azure App Service, monitoring and application insights, DevOps, and Team Services.

ramazanyichCommented:
yes, first you should try http://192.168.1.2 in browser.
You can replace it by hostname in config : eg http://www.myhost.com/$1 
Also what I see that you put RewriteRules to default VirtualHost. Do you have separate Virtual Host for 192.168.1.2 ?
0
aot2002Author Commented:
>>Do you have separate Virtual Host for 192.168.1.2 ?

No should I ?

also the http://192.168.1.2 comes right up .??

0
ramazanyichCommented:
Just tried on my PC:
RewriteEngine on
RewriteCond %{REMOTE_ADDR}  217.136.120.62$
RewriteRule ^(.+) http://www.google.com/search?q=$1 [L,R]

And it works fine.
0
aot2002Author Commented:
ok but are you placing these in the virtual servers area
0
ramazanyichCommented:
RewriteEngine on
is on main server area
and RewriteCond and RewriteRule in VirtualServer area
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Apache Web Server

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.