]> git.proxmox.com Git - ceph.git/blob - ceph/doc/rbd/iscsi-target-cli-manual-install.rst
bump version to 18.2.4-pve3
[ceph.git] / ceph / doc / rbd / iscsi-target-cli-manual-install.rst
1 ==============================
2 Manual ceph-iscsi Installation
3 ==============================
4
5 **Requirements**
6
7 To complete the installation of ceph-iscsi, there are 4 steps:
8
9 1. Install common packages from your Linux distribution's software repository
10 2. Install Git to fetch the remaining packages directly from their Git repositories
11 3. Ensure a compatible kernel is used
12 4. Install all the components of ceph-iscsi and start associated daemons:
13
14 - tcmu-runner
15 - rtslib-fb
16 - configshell-fb
17 - targetcli-fb
18 - ceph-iscsi
19
20
21 1. Install Common Packages
22 ==========================
23
24 The following packages will be used by ceph-iscsi and target tools.
25 They must be installed from your Linux distribution's software repository
26 on each machine that will be a iSCSI gateway:
27
28 - libnl3
29 - libkmod
30 - librbd1
31 - pyparsing
32 - python kmod
33 - python pyudev
34 - python gobject
35 - python urwid
36 - python pyparsing
37 - python rados
38 - python rbd
39 - python netifaces
40 - python crypto
41 - python requests
42 - python flask
43 - pyOpenSSL
44
45
46 2. Install Git
47 ==============
48
49 In order to install all the packages needed to run iSCSI with Ceph, you need to download them directly from their repository by using Git.
50 On CentOS/RHEL execute:
51
52 .. prompt:: bash >
53
54 sudo yum install git
55
56 On Debian/Ubuntu execute:
57
58 .. prompt:: bash >
59
60 sudo apt install git
61
62 To know more about Git and how it works, please, visit https://git-scm.com
63
64
65 3. Ensure a compatible kernel is used
66 =====================================
67
68 Ensure you use a supported kernel that contains the required Ceph iSCSI patches:
69
70 - all Linux distribution with a kernel v4.16 or newer, or
71 - Red Hat Enterprise Linux or CentOS 7.5 or later (in these distributions ceph-iscsi support is backported)
72
73 If you are already using a compatible kernel, you can go to next step.
74 However, if you are NOT using a compatible kernel then check your distro's
75 documentation for specific instructions on how to build this kernel. The only
76 Ceph iSCSI specific requirements are that the following build options must be
77 enabled:
78
79 .. code-block:: ini
80
81 CONFIG_TARGET_CORE=m
82 CONFIG_TCM_USER2=m
83 CONFIG_ISCSI_TARGET=m
84
85
86 4. Install ceph-iscsi
87 ========================================================
88
89 Finally, the remaining tools can be fetched directly from their Git repositories and their associated services started
90
91
92 tcmu-runner
93 -----------
94
95 Installation:
96
97 .. prompt:: bash >
98
99 git clone https://github.com/open-iscsi/tcmu-runner
100 cd tcmu-runner
101
102 Run the following command to install all the needed dependencies:
103
104 .. prompt:: bash >
105
106 ./extra/install_dep.sh
107
108 Now you can build the tcmu-runner.
109 To do so, use the following build command:
110
111 .. prompt:: bash >
112
113 cmake -Dwith-glfs=false -Dwith-qcow=false -DSUPPORT_SYSTEMD=ON -DCMAKE_INSTALL_PREFIX=/usr
114 make install
115
116 Enable and start the daemon:
117
118 .. prompt:: bash >
119
120 systemctl daemon-reload
121 systemctl enable tcmu-runner
122 systemctl start tcmu-runner
123
124
125 rtslib-fb
126 ---------
127
128 Installation:
129
130 .. prompt:: bash >
131
132 git clone https://github.com/open-iscsi/rtslib-fb.git
133 cd rtslib-fb
134 python setup.py install
135
136 configshell-fb
137 --------------
138
139 Installation:
140
141 .. prompt:: bash >
142
143 git clone https://github.com/open-iscsi/configshell-fb.git
144 cd configshell-fb
145 python setup.py install
146
147 targetcli-fb
148 ------------
149
150 Installation:
151
152 .. prompt:: bash >
153
154 git clone https://github.com/open-iscsi/targetcli-fb.git
155 cd targetcli-fb
156 python setup.py install
157 mkdir /etc/target
158 mkdir /var/target
159
160 .. warning:: The ceph-iscsi tools assume they are managing all targets
161 on the system. If targets have been setup and are being managed by
162 targetcli the target service must be disabled.
163
164 ceph-iscsi
165 -----------------
166
167 Installation:
168
169 .. prompt:: bash >
170
171 git clone https://github.com/ceph/ceph-iscsi.git
172 cd ceph-iscsi
173 python setup.py install --install-scripts=/usr/bin
174 cp usr/lib/systemd/system/rbd-target-gw.service /lib/systemd/system
175 cp usr/lib/systemd/system/rbd-target-api.service /lib/systemd/system
176
177 Enable and start the daemon:
178
179 .. prompt:: bash >
180
181 systemctl daemon-reload
182 systemctl enable rbd-target-gw
183 systemctl start rbd-target-gw
184 systemctl enable rbd-target-api
185 systemctl start rbd-target-api
186
187 Installation is complete. Proceed to the setup section in the
188 `main ceph-iscsi CLI page`_.
189
190 .. _`main ceph-iscsi CLI page`: ../iscsi-target-cli