Deployment operation

The database can be accessed remotely:
1. Log in to mysql in the command window: mysql> mysql -u root -p
2. After the login is successful, switch to the mysql database: mysql> use mysql;
3. Modify the host field of root: mysql> update user set host ='%' where user ='root';
4. Refresh: mysql> flush privileges;
5. Check whether the host value has been modified successfully: mysql> select host, user from user;

Firewall open ports
view
firewall-cmd --query-port=8080/tcp
open ports
firewall-cmd --permanent --add-port=80/tcp
update firewall rules
firewall-cmd --reload

Packaging
1. Right-click the project -> select Run As
2. Select Maven build in Run As
3. Then fill in
package -Dmaven.test.skip=true in goals
4. Then complete the package

Keep running in the background
screen -S [name] Run screen and
enter the command
CTRL +a +d to exit
screen –ls View background processes
screen –r –d [pid] Enter to view screen processes running in the background
kill -9 [pid] Kill process
screen --Wipe clean up dead processes

-d <job name> Take the specified screen job offline.
-S <job name> Specifies the name of the screen job.
-r <job name> Resume offline screen jobs.
(Detached)---->Hanging state, no terminal can be opened in the connection session
(Attached)---->A terminal can not be opened in the connection session

nohup java -server -Xms1024m -Xmx1024m -Xss512k -XX:+DisableExplicitGC -XX:+UseConcMarkSweepGC -XX:+CMSParallelRemarkEnabled \
		-XX:LargePageSizeInBytes=128m -XX:+UseCMSCompactAtFullCollection -XX:+UseFastAccessorMethods \
		-jar bi-api-0.0.1-SNAPSHOT.jar  --spring.profiles.active=prod >/dev/null 2>&1 &

sh startup.sh start and run

Guess you like

Origin blog.csdn.net/weixin_45530931/article/details/109215953