File tree Expand file tree Collapse file tree 2 files changed +107
-0
lines changed Expand file tree Collapse file tree 2 files changed +107
-0
lines changed Original file line number Diff line number Diff line change
1
+ # Mongodb 安装
2
+
3
+ <!-- TOC depthFrom:2 depthTo:3 -->
4
+
5
+ - [ 安装] ( #安装 )
6
+ - [ 启动] ( #启动 )
7
+ - [ 脚本] ( #脚本 )
8
+
9
+ <!-- /TOC -->
10
+
11
+ ## 安装
12
+
13
+ 安装步骤如下:
14
+
15
+ (1)下载并解压到本地
16
+
17
+ 进入官网下载地址:https://www.mongodb.com/download-center#community ,选择合适的版本下载。
18
+
19
+ 我选择的是最新稳定版本 3.6.3:https://fastdl.mongodb.org/linux/mongodb-linux-x86_64-3.6.3.tgz
20
+
21
+ 我个人喜欢存放在:` /opt/mongodb `
22
+
23
+ ```
24
+ wget -O /opt/mongodb/mongodb-linux-x86_64-3.6.3.tgz https://fastdl.mongodb.org/linux/mongodb-linux-x86_64-3.6.3.tgz
25
+ cd /opt/mongodb
26
+ tar zxvf mongodb-linux-x86_64-3.6.3.tgz
27
+ mv mongodb-linux-x86_64-3.6.3 mongodb-3.6.3
28
+ mkdir -p /data/db
29
+ ```
30
+
31
+ ## 启动
32
+
33
+ ** 启动 mongodb 服务**
34
+
35
+ ```
36
+ cd /opt/mongodb/mongodb-3.6.3/bin
37
+ ./mongod --dbpath=/data/db
38
+ ```
39
+
40
+ ** 启动 mongodb 客户端**
41
+
42
+ ```
43
+ cd /opt/mongodb/mongodb-3.6.3/bin
44
+ ./mongo
45
+ ```
46
+
47
+ ## 脚本
48
+
49
+ | [ 安装脚本] ( https://github.com/dunwu/linux/tree/master/codes/deploy/tool/mongodb ) |
Original file line number Diff line number Diff line change
1
+ # Redis 安装
2
+
3
+ <!-- TOC depthFrom:2 depthTo:3 -->
4
+
5
+ - [ 安装] ( #安装 )
6
+ - [ 启动] ( #启动 )
7
+ - [ 脚本] ( #脚本 )
8
+
9
+ <!-- /TOC -->
10
+
11
+ ## 安装
12
+
13
+ 安装步骤如下:
14
+
15
+ (1)下载并解压到本地
16
+
17
+ 进入官网下载地址:https://redis.io/download ,选择合适的版本下载。
18
+
19
+ 我选择的是最新稳定版本 4.0.8:http://download.redis.io/releases/redis-4.0.8.tar.gz
20
+
21
+ 我个人喜欢存放在:` /opt/redis `
22
+
23
+ ```
24
+ wget -O /opt/redis/redis-4.0.8.tar.gz http://download.redis.io/releases/redis-4.0.8.tar.gz
25
+ cd /opt/redis
26
+ tar zxvf redis-4.0.8.tar.gz
27
+ ```
28
+
29
+ (2)编译安装
30
+
31
+ 执行以下命令:
32
+
33
+ ```
34
+ cd /opt/redis/redis-4.0.8
35
+ make
36
+ ```
37
+
38
+ ## 启动
39
+
40
+ ** 启动 redis 服务**
41
+
42
+ ```
43
+ cd /opt/redis/redis-4.0.8/src
44
+ ./redis-server
45
+ ```
46
+
47
+ ** 启动 redis 客户端**
48
+
49
+ ```
50
+ cd /opt/redis/redis-4.0.8/src
51
+ ./redis-cli
52
+ ```
53
+
54
+ ## 脚本
55
+
56
+ 以上两种安装方式,我都写了脚本去执行:
57
+
58
+ | [ 安装脚本] ( https://github.com/dunwu/linux/tree/master/codes/deploy/tool/redis ) |
You can’t perform that action at this time.
0 commit comments