Updates for Web project publications

Source: Internet
Author: User

In the project after the release often need to modify the bug, to solve the various problems, to upgrade the project, this time will need to be deployed, on-line project update version.
This article briefly describes some of the key points that appear (not to be welcomed)
1. Use tools such as Idea,eclipse to fight the war package
1). Open the Idea development tool and find project Structure under File ... (Note: The lower version of idea is found in the Nevigate directory)


2). In the open page, locate artifacts, click "+" on the right, define the name of the war package and the path to save the war package, if shown below. MF file not found in Accept.war, then continue with the configuration. Otherwise, after the project runs under the set path cannot find the war package, click the below green plus sign to select Directory Content, select your current project's Webroot directory, and then save the configuration.


3). Click "Build" and select "Build Artifacts" ...


4). Then select the name of the previously defined input war package, choose "Build", about a minute to complete the package, after the completion of the project to find an "out" directory, there is Xxxx.war, you can get tomcat under deployment


2. Copy the ready-made war package to the Tomcat/webapp directory of both servers (the number of servers is not necessarily)
1). First copy the items in the WebApp in the original server into a directory to save
#cp/opt/tomcat8.5-comp/webapps/comp.war/opt/local/comp.war
2). Then temporarily shut down the two servers (note)
Go to the Bin directory of two servers to execute
#./shutdown.sh
3). Delete the items in the WebApps and enter WebApps in the two servers respectively
#rm-RF Comp Comp.war
4). Copy the prepared war package to both servers
#cp/medir/war Package Path/opt/tomcat8.5-comp/webapps
Send the war package under the WebApps to another WebApps
#scp Comp.war [Email Protected]:/opt/tomcat8.5-comp/webapps/comp.war
Run two tomcat servers
#./startup.sh
3.Nginx
1). Enter the Nginx installation directory
#cd/usr/local/nginx/
2). Query the running Nginx
#ps aux | grep nginx
3). Force Close
#kill-9 2207
#kill-9 2208
4). Restart
To see if the configuration file is correct
#sbin/nginx-t
Restart Nginx (enter sbin) reload configuration
#./nginx-s Reload
Method 2
Add-t before starting the command
./NGIN-T-C
5). Common errors
If the startup fails, you can see the error message in the Error.log file in the logs directory.
I encountered two errors during the first installation and also the most easily encountered problem, which is listed here
Come out convenient for everyone to meet the same problem when quickly resolved.
1. Port occupancy Issues
The service in my profile is listening on port 80 because the IIS,80 port is deployed on the machine
is occupied by the default site, the site is closed, the problem is recorded in the error log is
Like that.
2017/01/15 10:44:12 [Emerg] 8800#5988:bind () to 0.0.0.0:80 failed (10013:an attempt is made to access a socket in a- Forbidden by its access permissions)
If you encounter a similar error, verify that the port is occupied or blocked by the firewall
2.Nginx is in the same directory in Chinese
The error log roughly outputs a bit of content
2017/01/15 11:55:55 [Emerg] 5664#8528:createfile () "E:\ software \nginx-1.7.8/conf/nginx.conf" failed (1113:no mapping for the U Nicode character exists in the target Multi-Byte code page)
3. Enable Cache times Error
2017/01/15 17:26:50 [Emerg] 17068#20356:shared zone "Cache_one" has no equal addresses:02cf0000 vs 02a20000
2017/01/15 17:26:50 [alert] 11536#11228:worker process 17068 exited with code 1
I have not found a solution, some people say restart the service, or cache settings a little bit more, I tried a bit useless, the official website is said, can only think windwos under no solution.
: the cache and other modules which require shared memory
: Not on Windows Vista and later due to address space layout
: randomization being enabled in these Windows versions.
4. On client login Http://211.147.135.xxx/ajjweb/indexLog.do?action=index detect the success of the deployment
Note: 1.asserts directory changes to be timely configuration of new

Updates for Web project publications

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.