IP to URL redirection
Hi,
I have Apache and Tomcat Apache both are running on my server. I have also configured mod_jk connector. I am able to access web apps of tomcat using Apache server but currenty i am accessing that like, 10.10.10.10/web now I want to redirect that to some domain like if I hit url like web.myserver.com will open 10.10.10.10/web. how can I do that? Thanks. |
Quote:
https://httpd.apache.org/docs/curren.../examples.html As with other threads, please try to show some effort: http://www.linuxquestions.org/questi...ll-4175585685/ http://www.linuxquestions.org/questi...-a-4175582122/ http://www.linuxquestions.org/questi...ue-4175583331/ |
I have tried making changes in httpd.conf
using ServerAlias,ServerName,Redirect permanent, but after making changes in httpd.conf when i tried to restart services it gives error like "Job for httpd.service failed because the control process exited with error code. See "systemctl status httpd.service" and "journalctl -xe" for details." when I checked with "journalctl -xe" it shows me error like "Aug 04 01:06:19 server.com restartsrv_httpd[25767]: AH00526: Syntax error on line 312 of /usr/local/apache/conf/httpd.conf:" when i gone through some documentations of Apache I don't find any mistake in my Syntax as I have followed it from the documents. even I have cross checked it might be spell mistakes or extra spaces but nothing like that. |
ServerAlias has taken me little near to the thing which I required but not done yet. after using ServerAlias i can access with url such as web.myserver.com/web instead of web.myserver.com
|
I found issues is with domain can any one help in this?
i have tried many things to point web.myserver.com to 10.10.10.10/web but than i found web.myserver.com is pointing to 10.10.10.10. so whatever the changes I made in httpd were not worth. is that possible to point a domains A record to 10.10.10.10/web? or any other way by which I can solve this? Thanks |
What version of apache is it?
There are few reasons to edit httpd.conf. This isn't one of them. |
Your question is not entirely clear . . .
If you want to resolve a domain-name (that is not known to the Internet at large), to an (internal) IP-address, then you must either be running a DNS = Domain-Name Server process on your network. Or, your Internet router might have this capability built-in. The DNS, when given the question, "where is www.myserver.com?", sticks its hand up in the air (like the annoying know-it-all that is a fixture in every classroom) and says: "I know, teacher! I know! It's 10.10.10.10!" So, your web-browser opens a connection to that IP-address on port #80 and sends the data. Included in the "HTTP headers" is, among other things, the actual target (www.myserver.com) that was requested. When Apache (or nginix), sitting there listening to some IP-address such as 10.10.10.10, receives a new connection, it is able to determine from the HTTP headers what domain-name was used, or if an IP-address-only was used. It uses this information to attempt to locate a <VirtualHost> entry. (Or, it uses its default.) This is what determines how Apache first classifies the incoming request and then responds to it. |
I used rinetd some years ago, and it's still available from fedora 23 repos. It's pretty old, and I don't know if it supports ipv6. It runs as a daemon and you edit a simple configuration file to set up all your redirects. It was useful and easy for ipv4 anyway.
|
Quote:
If via internet you need to buy the domain, if only in your local network then you need to configure your DNS server and make an A or host record and point it to your server. Check out this link for some basic DNS usage and terminology: https://support.dnsimple.com/article...ame-alias-url/ Good luck!!! |
Quote:
Cpanel::Easy::Apache v3.32.14 rev9999 |
Quote:
|
Quote:
and of course you need to create an A record for each one of them. |
@JJJCR
Quote:
|
Quote:
But if the OP got a control on the DNS and sub-domain parking is allowed, I think he can do something like this web-web.myserver.com |
check out this link: http://www.inmotionhosting.com/suppo...t-changing-url
Text below from above link: Quote:
|
All times are GMT -5. The time now is 06:51 PM. |