设置网站服务器apache tomcat配置,泛域名解析

泛域名  时间:2020-12-30  阅读:()

网站服务器apache+tomcat配置,泛域名解析Web server apache+tomcat conf iguration, universal domain name resolution

1, modify the host file, DNS simulation analysis.

192. 168. 1. 211 cc.com to the CNCA folder

192. 168. 1. 211 xj.cc.com to the CNCA folder

192. 168. 1. 211 xz.cc.com to the CNCA folder

192. 168. 1. 211 *. cc. com to the CNCA folder

2, install Apache

Http://www.apache.org/dist//httpd/binaries/win32/

If you install SQL 2008 after installation will appear 80 port conf lict

CMD, executive

Netstat -aon|findstr "80" search occupy 80 port process Tasklist|findstr process of the "ID" look to occupy the port service

Close service, re install

3, install Tomcat

The default port 8080

If it is unpacked version:

Decompress Tomcat to D:Program FilesTomcat, setting system environment variables:

CATALINA_BASE = D:Program Files omcat

CATALINA_HOME = D:Program Fi les omcat

CLASSPATH =%CATALINA_HOME%l ibservl et-api. jar

JAVA_HOME = D:Program Fi lesJavajdk1.6.0_07

C LAS SPATH

=. ;%Java_Home%l ib oo l s. jar;%Java_Home%l ibdt. jar;

PATH =%Jav a_Home% i n

4, install JK

Http://www.apache.org/dist/tomcat/

Copy mod_jk-1.2. 26-httpd-2.2.4. so to D:Program

FilesApache2.2modules

The following server configuration:

1, the configuration of Tomcat

Find the Tomcat directory of the conf/server.xml file in the <host></host> into the middle of the following statement to modify the default directory:

<Context "path=" docBase= "E:wwwroot" reloadable= "true"crossContext= "true" / >

Here, if the path is not empty, it is set to the virtual directory, the value of path for the virtual directory name.Find the Tomcat directory of the conf/workers.properties file,and compare the text below, if not the same, to modify below the text shall prevail.

Workers.tomcat_home=D:Program FilesTomcat # let mod_jk know Tomcat position module

Workers. java_home=D:Program FilesJavajre1.6.0_07 # let mod_jk know JRE position module

Ps=

Worker. list=ajp13 # module version

Worker.ajp13.port=8009 #working port, if not occupied without modification

Worker.ajp13.host=localhost # this machine, if the above

Apache host is not localhost, modify

Worker.ajp13. type=ajp13 # type

Worker.ajp13. lbfactor=1 # number of agents, without modification

If the file does not exist, according to the above content creation. Any modifications to the Tomcat set to restart will come into effect.

Tomcat configuration method IP on multi domain in detail as follows.

< host name = "localhost" debug = "0" appbase = "d: webapps tomcat 5.0"unpackwars = "true" autodeploy = "true"xmlvalidation = "false" xmlnamespaceaware = "false" >< alias > < / > localhost.com alias

< logger classname = "org.apache.catalina. logger.filelogger"directory= "logs" prefix= "localhost_log. " suffix= ".txt"t imestamp = "true" / >

< context path= "" docbase= "d: tomcat 5.0 webapps gg" reloadable = "true" casesensitive = "false" debug = "0" >

< / context.

> < / host

< host name = "one. localhost" debug = "0" appbase = "d: \ webapps tomcat 5.0"unpackwars = "true" autodeploy = "true"xmlvalidation = "false" xmlnamespaceaware = "false" >< alias > < / > one. localhost.com alias

< logger classname = "org.apache.catalina. logger.filelogger"directory= "logs" prefix= "localhost _log. " suffix= ".txt"t imestamp = "true" / >

< context path= "" docbase= "d: tomcat 5.0 webapps kk\"reloadable="true"casesensitive="false"debug="0" >< / context.

> < / host

2、配置apache

打开d: program fi les apache2.2 conf下的httpd. conf,在最后加入下面这段代码并保存.loadmodule jk_module modules mod_jk-1.2. 26-httpd-2.2.4. so

#此处mo d_ j k的文件为你下载的文件jkworkersf ile "d: program files tomcat conf workers.properties"

#指定tomcat监听配置文件地址jklogfile "d: program files tomcat logs mod_jk2. log"#指定日志存放位置jkloglevel info

#设置虚拟主机

< > virtualhost localhost

#如果非虚拟主机,将< virtualhost localhost >和最后的< /virtualhost >注释或者删除掉即可serveradmin localhost documentroot and wwwroot: /

"directory" e: / wwwroot ">

#您的站点项目所在路径,应与tomcat中的目录设置相同,据说以上两个必须同时设置才可以生效,没有试过不同的时候会有什么情况

messaging localhost directoryindex index. jsp index.html.errorlog logs / shsc error_ log.txt customlog logs / shsc - access _ log.txt common jkmount / servlet / * ajp 13

#让apache支持对servlet传送, 用以tomcat解析jkmount / *. jsp ajp13

Let # Apache support for JSP transmission, using Tomcat analysis

JkMount /*.do ajp13

Let#Apache support for.Do transmission, using Tomcat analysis </VirtualHost>

At the beginning of the # behavior can delete notes. I am here to set the configuration of the virtual directory, re designated serverName, DocumentRoot path allocation site, in fact, the Apache configuration can be very flexible, you can not use the virtual directory, directly to modify the default configuration of the site, the editing tool of any text search,such as ServerName, DocumentRoot, ServerAdmin other related items, then the configuration can be modified according to your

actual situation. I suggest that you can try a different configuration, this is a very fun experience.

After all the changes, double-click the Apache icon in the system tray, and then click Start to start the Apache service.In the address bar enter http://localhost/ and http://localhost:8080/respectively, if the result is the same,Apache and Tomcat integration success

3, the configuration of the Apache and Tomcat pan DNS Because of the way that *.yourdomain.com domain could not be configured Tomcat host, which is supported by Apache, as long as the set of*.yourdomain.com can be. In server.xml a<Engine defaultHost="localhost"name="Catalina" >when the non domain pointer to the way when they are submitted to the webapps/ROOT,so as to set up extensive domain name analysis to the default defaultHost on it.

The specific configuration of Apache and Tomcat extensive domain name analysis steps:

You confirm whether the domain name support extensive domain name analysis, now most of the domain name providers to support such services.

Conf igure the Apache pan DNS you

<VirtualHost *.*.*.*: 80>

S erverName *.yourdomai n.com

DocumentRoot /usr/local/jakarta-tomcat-5.0.28/webapps/ROOT ServerAdmin yntsky@gmai l. com

ErrorLog logs/a.ntsky. com_log

</VirtualHost>

The domain name to ROOT

Do not need to do other settings in tomcat, you can keep the original, for some special two level domain name as long as the tomcat/confg/server.xml configuration of<Engine defaultHost="localhost" name= "Catalina" >

Analysis of abc.yourdomain.com information in ABC code 2011-09-07

-----------------------------------------------------------

---------------------

C1009

久久网云-目前最便宜的国内,香港,美国,日本VPS云服务器19.9元/月起,三网CN2,2天内不满意可以更换其他机房机器,IP免费更换!。

久久网云怎么样?久久网云好不好?久久网云是一家成立于2017年的主机服务商,致力于为用户提供高性价比稳定快速的主机托管服务,久久网云目前提供有美国免费主机、香港主机、韩国服务器、香港服务器、美国云服务器,香港荃湾CN2弹性云服务器。专注为个人开发者用户,中小型,大型企业用户提供一站式核心网络云端服务部署,促使用户云端部署化简为零,轻松快捷运用云计算!多年云计算领域服务经验,遍布亚太地区的海量节点为...

rfchost:洛杉矶vps/双向CN2 GIA,1核/1G/10G SSD/500G流量/100Mbps/季付$23.9

rfchost怎么样?rfchost是一家开办了近六年的国人主机商,一般能挺过三年的国人商家,还是值得入手的,商家主要销售VPS,机房有美国洛杉矶/堪萨斯、中国香港,三年前本站分享过他家堪萨斯机房的套餐。目前rfchost商家的洛杉矶机房还是非常不错的,采用CN2优化线路,电信双程CN2 GIA,联通去程CN2 GIA,回程AS4837,移动走自己的直连线路,目前季付套餐还是比较划算的,有需要的可...

腾讯云CVM云服务器大硬盘方案400GB和800GB数据盘方案

最近看到群里的不少网友在搭建大数据内容网站,内容量有百万篇幅,包括图片可能有超过50GB,如果一台服务器有需要多个站点的话,那肯定默认的服务器50GB存储空间是不够用的。如果单独在购买数据盘会成本提高不少。这里我们看到腾讯云促销活动中有2款带大数据盘的套餐还是比较实惠的,一台是400GB数据盘,一台是800GB数据盘,适合他们的大数据网站。 直达链接 - 腾讯云 大数据盘套餐服务器这里我们看到当前...

泛域名为你推荐
php虚拟主机如何用虚拟主机建PHP论坛?com域名空间域名解析,我是一个新手站长,我买了一个空间跟一个COM域名,空间自带一个2级域名,我想把这个COM域名绑定到空间上,咋么办?急急急!求大神帮我,我创建一个游戏论坛,也查不到资料,可以给20元,我的手机13685455534,谢谢中国域名注册中国十大域名注册商ip代理地址IP代理什么意思?免费vps服务器有没有便宜的vps,最好是免费的空间域名空间域名什么意思大连虚拟主机找个大连企业建站公司,大家给推荐一下吧。asp虚拟主机支持ASP MSSQL 的虚拟主机有哪些推荐虚拟主机试用购买虚拟主机为什么商家会让你试用和测试?shopex虚拟主机我有一个PHP1G的虚拟主机,请问做什么站比较合适?
韩国服务器租用 idc评测 瓦工 美国主机评测 t牌 私服服务器 天猫双十一秒杀 京东云擎 debian源 警告本网站 申请个人网页 创梦 世界测速 vip购优惠 vip域名 新世界服务器 阿里云免费邮箱 购买空间 万网服务器 重庆联通服务器托管 更多