Skip to content

Commit d9272dd

Browse files
authored
Fixing shell usage and YAML config for random input plugin docs. Fixes #1854. (#1858)
Signed-off-by: Eric D. Schabell <[email protected]>
1 parent f26fa66 commit d9272dd

File tree

1 file changed

+43
-23
lines changed

1 file changed

+43
-23
lines changed

pipeline/inputs/random.md

Lines changed: 43 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -21,61 +21,81 @@ In order to start generating random samples, you can run the plugin from the com
2121

2222
From the command line you can let Fluent Bit generate the samples with the following options:
2323

24-
```bash
24+
```shell
2525
$ fluent-bit -i random -o stdout
2626
```
2727

2828
### Configuration File
2929

30-
In your main configuration file append the following _Input_ & _Output_ sections:
30+
In your main configuration file append the following:
3131

3232
{% tabs %}
33-
{% tab title="fluent-bit.conf" %}
34-
```python
35-
[INPUT]
36-
Name random
37-
Samples -1
38-
Interval_Sec 1
39-
Interval_NSec 0
40-
41-
[OUTPUT]
42-
Name stdout
43-
Match *
44-
```
45-
{% endtab %}
46-
4733
{% tab title="fluent-bit.yaml" %}
34+
4835
```yaml
4936
pipeline:
5037
inputs:
5138
- name: random
5239
samples: -1
5340
interval_sec: 1
5441
interval_nsec: 0
42+
5543
outputs:
5644
- name: stdout
5745
match: '*'
5846
```
47+
5948
{% endtab %}
60-
{% endtabs %}
49+
{% tab title="fluent-bit.conf" %}
50+
51+
```text
52+
[INPUT]
53+
Name random
54+
Samples -1
55+
Interval_Sec 1
56+
Interval_NSec 0
57+
58+
[OUTPUT]
59+
Name stdout
60+
Match *
61+
```
6162

63+
{% endtab %}
64+
{% endtabs %}
6265

6366
## Testing
6467

6568
Once Fluent Bit is running, you will see the reports in the output interface similar to this:
6669

67-
```bash
70+
```shell
6871
$ fluent-bit -i random -o stdout
69-
Fluent Bit v1.x.x
70-
* Copyright (C) 2019-2020 The Fluent Bit Authors
71-
* Copyright (C) 2015-2018 Treasure Data
72+
73+
Fluent Bit v4.0.3
74+
* Copyright (C) 2015-2025 The Fluent Bit Authors
7275
* Fluent Bit is a CNCF sub-project under the umbrella of Fluentd
7376
* https://fluentbit.io
7477

75-
[2016/10/07 20:27:34] [ info] [engine] started
78+
______ _ _ ______ _ _ ___ _____
79+
| ___| | | | | ___ (_) | / || _ |
80+
| |_ | |_ _ ___ _ __ | |_ | |_/ /_| |_ __ __/ /| || |/' |
81+
| _| | | | | |/ _ \ '_ \| __| | ___ \ | __| \ \ / / /_| || /| |
82+
| | | | |_| | __/ | | | |_ | |_/ / | |_ \ V /\___ |\ |_/ /
83+
\_| |_|\__,_|\___|_| |_|\__| \____/|_|\__| \_/ |_(_)___/
84+
85+
86+
[2025/07/01 14:44:47] [ info] [fluent bit] version=4.0.3, commit=f5f5f3c17d, pid=1
87+
[2025/07/01 14:44:47] [ info] [storage] ver=1.5.3, type=memory, sync=normal, checksum=off, max_chunks_up=128
88+
[2025/07/01 14:44:47] [ info] [simd ] disabled
89+
[2025/07/01 14:44:47] [ info] [cmetrics] version=1.0.3
90+
[2025/07/01 14:44:47] [ info] [ctraces ] version=0.6.6
91+
[2025/07/01 14:44:47] [ info] [input:mem:mem.0] initializing
92+
[2025/07/01 14:44:47] [ info] [input:mem:mem.0] storage_strategy='memory' (memory only)
93+
[2025/07/01 14:44:47] [ info] [sp] stream processor started
94+
[2025/07/01 14:44:47] [ info] [engine] Shutdown Grace Period=5, Shutdown Input Grace Period=2
95+
[2025/07/01 14:44:47] [ info] [output:stdout:stdout.0] worker #0 started
7696
[0] random.0: [1475893654, {"rand_value"=>1863375102915681408}]
7797
[1] random.0: [1475893655, {"rand_value"=>425675645790600970}]
7898
[2] random.0: [1475893656, {"rand_value"=>7580417447354808203}]
7999
[3] random.0: [1475893657, {"rand_value"=>1501010137543905482}]
80100
[4] random.0: [1475893658, {"rand_value"=>16238242822364375212}]
81-
```
101+
```

0 commit comments

Comments
 (0)