linux下部署springboot项目用到的一些命令

来源:互联网 发布:james cameron 知乎 编辑:程序博客网 时间:2024/05/03 23:25

1.查看端口情况

netstat –apn | grep 8080

2.杀死一个进程

kill -9 pid #pid 为相应的进程号

3.删除文件夹

rm -rf /home/java/jdk1.8

4.查看是否已经安装了mysql

rpm -qa | grep -i mysql有值输出则说明已经安装过了,若空白则没有安装

5.安装mysql时遇到的一篇比较靠谱的帖子

https://www.oschina.net/code/snippet_2426852_49915

6.用rpm安装的过程中可能会提示签名的错误,可以用如下命令安装

rpm -ivh MySQL-server-5.5.46-1.linux2.6.x86_64.rpm --force --nodeps

7.安装zk(zookeeper)并配置

7.1 tar -zxvf /home/zookeeper/zookeeper-3.3.6.tar.gz

7.2 cd /home/zookeeper/zookeeper-3.3.6/conf

7.3 cp zoo_sample.cfg zoo.cfg

7.4 vi zoo.cfg

7.5编辑效果如下:

# The number of milliseconds of each tick  tickTime=2000  # The number of ticks that the initial  # synchronization phase can take  initLimit=10  # The number of ticks that can pass between  # sending a request and getting an acknowledgement  syncLimit=5  # the directory where the snapshot is stored.  dataDir=/usr/zookeeper  dataLogDir=/usr/zookeeper/log  # the port at which the clients will connect  clientPort=2181

7.6设置环境变量

export ZOOKEEPER_INSTALL=/home/zookeeper/zookeeper-3.3.6

export PATH=$PATH:$ZOOKEEPER_INSTALL/bin 

7.7启动zk    ./zkServer.sh start

写的比较乱,想写给自己看,也能够帮助到其他人。


我们曾如此渴望命运的波澜,到最后才发现:人生最曼妙的风景,竟是内心的淡定与从容……我们曾如此期盼外界的认可,到最后才知道:世界是自己的,与他人毫无关系



0 4
原创粉丝点击