Skip to content

Commit 1df1a7c

Browse files
committed
HDDS-2002. Update documentation for 0.4.1 release.
Signed-off-by: Anu Engineer <aengineer@apache.org> (cherry picked from commit b661dcf)
1 parent d0d9c49 commit 1df1a7c

25 files changed

+269
-258
lines changed

hadoop-hdds/docs/content/beyond/Containers.md

Lines changed: 41 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,9 @@ Docker heavily is used at the ozone development with three principal use-cases:
2525
* __dev__:
2626
* We use docker to start local pseudo-clusters (docker provides unified environment, but no image creation is required)
2727
* __test__:
28-
* We create docker images from the dev branches to test ozone in kubernetes and other container orchestator system
29-
* We provide _apache/ozone_ images for each release to make it easier the evaluation of Ozone. These images are __not__ created __for production__ usage.
28+
* We create docker images from the dev branches to test ozone in kubernetes and other container orchestrator system
29+
* We provide _apache/ozone_ images for each release to make it easier for evaluation of Ozone.
30+
These images are __not__ created __for production__ usage.
3031

3132
<div class="alert alert-warning" role="alert">
3233
We <b>strongly</b> recommend that you create your own custom images when you
@@ -36,7 +37,7 @@ shipped container images and k8s resources as examples and guides to help you
3637
</div>
3738

3839
* __production__:
39-
* We document how can you create your own docker image for your production cluster.
40+
* We have documentation on how you can create your own docker image for your production cluster.
4041

4142
Let's check out each of the use-cases in more detail:
4243

@@ -46,38 +47,41 @@ Ozone artifact contains example docker-compose directories to make it easier to
4647

4748
From distribution:
4849

49-
```
50+
```bash
5051
cd compose/ozone
5152
docker-compose up -d
5253
```
5354

54-
After a local build
55+
After a local build:
5556

56-
```
57+
```bash
5758
cd hadoop-ozone/dist/target/ozone-*/compose
5859
docker-compose up -d
5960
```
6061

6162
These environments are very important tools to start different type of Ozone clusters at any time.
6263

63-
To be sure that the compose files are up-to-date, we also provide acceptance test suites which start the cluster and check the basic behaviour.
64+
To be sure that the compose files are up-to-date, we also provide acceptance test suites which start
65+
the cluster and check the basic behaviour.
6466

65-
The acceptance tests are part of the distribution, and you can find the test definitions in `./smoketest` directory.
67+
The acceptance tests are part of the distribution, and you can find the test definitions in `smoketest` directory.
6668

6769
You can start the tests from any compose directory:
6870

6971
For example:
7072

71-
```
73+
```bash
7274
cd compose/ozone
7375
./test.sh
7476
```
7577

7678
### Implementation details
7779

78-
`./compose` tests are based on the apache/hadoop-runner docker image. The image itself doesn't contain any Ozone jar file or binary just the helper scripts to start ozone.
80+
`compose` tests are based on the apache/hadoop-runner docker image. The image itself does not contain
81+
any Ozone jar file or binary just the helper scripts to start ozone.
7982

80-
hadoop-runner provdes a fixed environment to run Ozone everywhere, but the ozone distribution itself is mounted from the including directory:
83+
hadoop-runner provdes a fixed environment to run Ozone everywhere, but the ozone distribution itself
84+
is mounted from the including directory:
8185

8286
(Example docker-compose fragment)
8387

@@ -91,7 +95,9 @@ hadoop-runner provdes a fixed environment to run Ozone everywhere, but the ozone
9195
9296
```
9397

94-
The containers are conigured based on environment variables, but because the same environment variables should be set for each containers we maintain the list of the environment variables in a separated file:
98+
The containers are configured based on environment variables, but because the same environment
99+
variables should be set for each containers we maintain the list of the environment variables
100+
in a separated file:
95101

96102
```
97103
scm:
@@ -111,23 +117,32 @@ OZONE-SITE.XML_ozone.enabled=True
111117
#...
112118
```
113119

114-
As you can see we use naming convention. Based on the name of the environment variable, the appropariate hadoop config XML (`ozone-site.xml` in our case) will be generated by a [script](https://github.com/apache/hadoop/tree/docker-hadoop-runner-latest/scripts) which is included in the `hadoop-runner` base image.
120+
As you can see we use naming convention. Based on the name of the environment variable, the
121+
appropriate hadoop config XML (`ozone-site.xml` in our case) will be generated by a
122+
[script](https://github.com/apache/hadoop/tree/docker-hadoop-runner-latest/scripts) which is
123+
included in the `hadoop-runner` base image.
115124

116-
The [entrypoint](https://github.com/apache/hadoop/blob/docker-hadoop-runner-latest/scripts/starter.sh) of the `hadoop-runner` image contains a helper shell script which triggers this transformation and cab do additional actions (eg. initialize scm/om storage, download required keytabs, etc.) based on environment variables.
125+
The [entrypoint](https://github.com/apache/hadoop/blob/docker-hadoop-runner-latest/scripts/starter.sh)
126+
of the `hadoop-runner` image contains a helper shell script which triggers this transformation and
127+
can do additional actions (eg. initialize scm/om storage, download required keytabs, etc.)
128+
based on environment variables.
117129

118130
## Test/Staging
119131

120-
The `docker-compose` based approach is recommended only for local test not for multi node cluster. To use containers on a multi-node cluster we need a Container Orchestrator like Kubernetes.
132+
The `docker-compose` based approach is recommended only for local test, not for multi node cluster.
133+
To use containers on a multi-node cluster we need a Container Orchestrator like Kubernetes.
121134

122135
Kubernetes example files are included in the `kubernetes` folder.
123136

124-
*Please note*: all the provided images are based the `hadoop-runner` image which contains all the required tool for testing in staging environments. For production we recommend to create your own, hardened image with your own base image.
137+
*Please note*: all the provided images are based the `hadoop-runner` image which contains all the
138+
required tool for testing in staging environments. For production we recommend to create your own,
139+
hardened image with your own base image.
125140

126141
### Test the release
127142

128143
The release can be tested with deploying any of the example clusters:
129144

130-
```
145+
```bash
131146
cd kubernetes/examples/ozone
132147
kubectl apply -f
133148
```
@@ -139,13 +154,13 @@ Plese note that in this case the latest released container will be downloaded fr
139154
To test a development build you can create your own image and upload it to your own docker registry:
140155

141156

142-
```
157+
```bash
143158
mvn clean install -f pom.ozone.xml -DskipTests -Pdocker-build,docker-push -Ddocker.image=myregistry:9000/name/ozone
144159
```
145160

146161
The configured image will be used in all the generated kubernetes resources files (`image:` keys are adjusted during the build)
147162

148-
```
163+
```bash
149164
cd kubernetes/examples/ozone
150165
kubectl apply -f
151166
```
@@ -160,10 +175,12 @@ adjust base image, umask, security settings, user settings according to your own
160175

161176
You can use the source of our development images as an example:
162177

163-
* Base image: https://github.com/apache/hadoop/blob/docker-hadoop-runner-jdk11/Dockerfile
164-
* Docker image: https://github.com/apache/hadoop/blob/trunk/hadoop-ozone/dist/src/main/Dockerfile
178+
* [Base image] (https://github.com/apache/hadoop/blob/docker-hadoop-runner-jdk11/Dockerfile)
179+
* [Docker image] (https://github.com/apache/hadoop/blob/trunk/hadoop-ozone/dist/src/main/docker/Dockerfile)
165180

166-
Most of the elements are optional and just helper function but to use the provided example kubernetes resources you may need the scripts from [here](https://github.com/apache/hadoop/tree/docker-hadoop-runner-jdk11/scripts)
181+
Most of the elements are optional and just helper function but to use the provided example
182+
kubernetes resources you may need the scripts from
183+
[here](https://github.com/apache/hadoop/tree/docker-hadoop-runner-jdk11/scripts)
167184

168185
* The two python scripts convert environment variables to real hadoop XML config files
169186
* The start.sh executes the python scripts (and other initialization) based on environment variables.
@@ -205,14 +222,14 @@ Ozone related container images and source locations:
205222
<td>This is the base image used for testing Hadoop Ozone.
206223
This is a set of utilities that make it easy for us run ozone.</td>
207224
</tr>
208-
<tr>
225+
<!---tr>
209226
<th scope="row">3</th>
210227
<td>apache/ozone:build (WIP)</td>
211228
<td>https://github.com/apache/hadoop-docker-ozone</td>
212229
<td>ozone-build </td>
213230
<td> </td>
214231
<td> </td>
215232
<td>TODO: Add more documentation here.</td>
216-
</tr>
233+
</tr-->
217234
</tbody>
218235
</table>

hadoop-hdds/docs/content/beyond/DockerCheatSheet.md

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,9 @@ weight: 4
2222
limitations under the License.
2323
-->
2424

25-
In the `compose` directory of the ozone distribution there are multiple pseudo-cluster setup which can be used to run Ozone in different way (for example with secure cluster, with tracing enabled, with prometheus etc.).
25+
In the `compose` directory of the ozone distribution there are multiple pseudo-cluster setup which
26+
can be used to run Ozone in different way (for example: secure cluster, with tracing enabled,
27+
with prometheus etc.).
2628

2729
If the usage is not document in a specific directory the default usage is the following:
2830

@@ -31,8 +33,7 @@ cd compose/ozone
3133
docker-compose up -d
3234
```
3335

34-
The data of the container is ephemeral and deleted together with the docker volumes. To force the deletion of existing data you can always delete all the temporary data:
35-
36+
The data of the container is ephemeral and deleted together with the docker volumes.
3637
```bash
3738
docker-compose down
3839
```

hadoop-hdds/docs/content/beyond/RunningWithHDFS.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ To start ozone with HDFS you should start the the following components:
5656
2. HDFS Datanode (from the Hadoop distribution with the plugin on the
5757
classpath from the Ozone distribution)
5858
3. Ozone Manager (from the Ozone distribution)
59-
4. Storage Container manager (from the Ozone distribution)
59+
4. Storage Container Manager (from the Ozone distribution)
6060

6161
Please check the log of the datanode whether the HDDS/Ozone plugin is started or
6262
not. Log of datanode should contain something like this:

hadoop-hdds/docs/content/concept/Datanodes.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ actual data streams. This is the default Storage container format. From
3636
Ozone's perspective, container is a protocol spec, actual storage layouts
3737
does not matter. In other words, it is trivial to extend or bring new
3838
container layouts. Hence this should be treated as a reference implementation
39-
of containers under Ozone.
39+
of containers under Ozone.
4040

4141
## Understanding Ozone Blocks and Containers
4242

@@ -51,13 +51,13 @@ shows the logical layout out of Ozone block.
5151

5252
The container ID lets the clients discover the location of the container. The
5353
authoritative information about where a container is located is with the
54-
Storage Container Manager or SCM. In most cases, the container location will
54+
Storage Container Manager (SCM). In most cases, the container location will be
5555
cached by Ozone Manager and will be returned along with the Ozone blocks.
5656

5757

5858
Once the client is able to locate the contianer, that is, understand which
5959
data nodes contain this container, the client will connect to the datanode
60-
read the data the data stream specified by container ID:Local ID. In other
60+
and read the data stream specified by _Container ID:Local ID_. In other
6161
words, the local ID serves as index into the container which describes what
6262
data stream we want to read from.
6363

hadoop-hdds/docs/content/concept/Hdds.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ summary: Storage Container Manager or SCM is the core metadata service of Ozone
2323

2424
Storage container manager provides multiple critical functions for the Ozone
2525
cluster. SCM acts as the cluster manager, Certificate authority, Block
26-
manager and the replica manager.
26+
manager and the Replica manager.
2727

2828
{{<card title="Cluster Management" icon="tasks">}}
2929
SCM is in charge of creating an Ozone cluster. When an SCM is booted up via <kbd>init</kbd> command, SCM creates the cluster identity and root certificates needed for the SCM certificate authority. SCM manages the life cycle of a data node in the cluster.

hadoop-hdds/docs/content/concept/Overview.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ Ozone.
5656

5757
![FunctionalOzone](FunctionalOzone.png)
5858

59-
Any distributed system can viewed from different perspectives. One way to
59+
Any distributed system can be viewed from different perspectives. One way to
6060
look at Ozone is to imagine it as Ozone Manager as a name space service built on
6161
top of HDDS, a distributed block store.
6262

@@ -67,8 +67,8 @@ Another way to visualize Ozone is to look at the functional layers; we have a
6767
We have a data storage layer, which is basically the data nodes and they are
6868
managed by SCM.
6969

70-
The replication layer, provided by Ratis is used to replicate metadata (Ozone
71-
Manager and SCM) and also used for consistency when data is modified at the
70+
The replication layer, provided by Ratis is used to replicate metadata (OM and SCM)
71+
and also used for consistency when data is modified at the
7272
data nodes.
7373

7474
We have a management server called Recon, that talks to all other components

hadoop-hdds/docs/content/concept/OzoneManager.md

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -21,14 +21,14 @@ summary: Ozone Manager is the principal name space service of Ozone. OM manages
2121
limitations under the License.
2222
-->
2323

24-
Ozone Manager or OM is the namespace manager for Ozone.
24+
Ozone Manager (OM) is the namespace manager for Ozone.
2525

2626
This means that when you want to write some data, you ask Ozone
27-
manager for a block and Ozone Manager gives you a block and remembers that
28-
information. When you want to read the that file back, you need to find the
29-
address of the block and Ozone manager returns it you.
27+
Manager for a block and Ozone Manager gives you a block and remembers that
28+
information. When you want to read that file back, you need to find the
29+
address of the block and Ozone Manager returns it you.
3030

31-
Ozone manager also allows users to organize keys under a volume and bucket.
31+
Ozone Manager also allows users to organize keys under a volume and bucket.
3232
Volumes and buckets are part of the namespace and managed by Ozone Manager.
3333

3434
Each ozone volume is the root of an independent namespace under OM.
@@ -57,17 +57,17 @@ understood if we trace what happens during a key write and key read.
5757

5858
* To write a key to Ozone, a client tells Ozone manager that it would like to
5959
write a key into a bucket that lives inside a specific volume. Once Ozone
60-
manager determines that you are allowed to write a key to specified bucket,
60+
Manager determines that you are allowed to write a key to the specified bucket,
6161
OM needs to allocate a block for the client to write data.
6262

63-
* To allocate a block, Ozone manager sends a request to Storage Container
64-
Manager or SCM; SCM is the manager of data nodes. SCM picks three data nodes
63+
* To allocate a block, Ozone Manager sends a request to Storage Container
64+
Manager (SCM); SCM is the manager of data nodes. SCM picks three data nodes
6565
into which client can write data. SCM allocates the block and returns the
6666
block ID to Ozone Manager.
6767

6868
* Ozone manager records this block information in its metadata and returns the
6969
block and a block token (a security permission to write data to the block)
70-
the client.
70+
to the client.
7171

7272
* The client uses the block token to prove that it is allowed to write data to
7373
the block and writes data to the data node.
@@ -82,6 +82,6 @@ Ozone manager.
8282
* Key reads are simpler, the client requests the block list from the Ozone
8383
Manager
8484
* Ozone manager will return the block list and block tokens which
85-
allows the client to read the data from nodes.
85+
allows the client to read the data from data nodes.
8686
* Client connects to the data node and presents the block token and reads
8787
the data from the data node.

hadoop-hdds/docs/content/interface/JavaApi.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -74,21 +74,21 @@ It is possible to pass an array of arguments to the createVolume by creating vol
7474

7575
Once you have a volume, you can create buckets inside the volume.
7676

77-
{{< highlight bash >}}
77+
{{< highlight java >}}
7878
// Let us create a bucket called videos.
7979
assets.createBucket("videos");
8080
OzoneBucket video = assets.getBucket("videos");
8181
{{< /highlight >}}
8282

83-
At this point we have a usable volume and a bucket. Our volume is called assets and bucket is called videos.
83+
At this point we have a usable volume and a bucket. Our volume is called _assets_ and bucket is called _videos_.
8484

8585
Now we can create a Key.
8686

8787
### Reading and Writing a Key
8888

89-
With a bucket object the users can now read and write keys. The following code reads a video called intro.mp4 from the local disk and stores in the video bucket that we just created.
89+
With a bucket object the users can now read and write keys. The following code reads a video called intro.mp4 from the local disk and stores in the _video_ bucket that we just created.
9090

91-
{{< highlight bash >}}
91+
{{< highlight java >}}
9292
// read data from the file, this is a user provided function.
9393
byte [] videoData = readFile("intro.mp4");
9494

hadoop-hdds/docs/content/interface/OzoneFS.md

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ summary: Hadoop Compatible file system allows any application that expects an HD
2121
limitations under the License.
2222
-->
2323

24-
The Hadoop compatible file system interface allpws storage backends like Ozone
24+
The Hadoop compatible file system interface allows storage backends like Ozone
2525
to be easily integrated into Hadoop eco-system. Ozone file system is an
2626
Hadoop compatible file system.
2727

@@ -36,7 +36,7 @@ ozone sh volume create /volume
3636
ozone sh bucket create /volume/bucket
3737
{{< /highlight >}}
3838

39-
Once this is created, please make sure that bucket exists via the listVolume or listBucket commands.
39+
Once this is created, please make sure that bucket exists via the _list volume_ or _list bucket_ commands.
4040

4141
Please add the following entry to the core-site.xml.
4242

@@ -45,6 +45,10 @@ Please add the following entry to the core-site.xml.
4545
<name>fs.o3fs.impl</name>
4646
<value>org.apache.hadoop.fs.ozone.OzoneFileSystem</value>
4747
</property>
48+
<property>
49+
<name>fs.AbstractFileSystem.o3fs.impl</name>
50+
<value>org.apache.hadoop.fs.ozone.OzFs</value>
51+
</property>
4852
<property>
4953
<name>fs.defaultFS</name>
5054
<value>o3fs://bucket.volume</value>

0 commit comments

Comments
 (0)