# Broctl segmentation fault

**URL:** <https://community.zeek.org/t/broctl-segmentation-fault/5483>\
**Category:** Zeek\
**Created:** [October 3, 2018, 6:46pm UTC](https://community.zeek.org/t/broctl-segmentation-fault/5483 "2018-10-03T18:46:00Z")\
**Posts on this page:** 11\
**Page:** 1

<div class="post-metadata">

**Author:** ![sp4ce\_hUtch](https://avatars.discourse-cdn.com/v4/letter/s/8e8cbc/32.png) [@sp4ce\_hUtch](https://community.zeek.org/u/sp4ce_hUtch)\
**Post date:** [October 3, 2018, 6:46pm UTC](https://community.zeek.org/t/broctl-segmentation-fault/5483/1 "2018-10-03T18:46:00Z")

</div>

Hello,

After any build of Bro with Broctl 1.7, I’m experiencing the below error when broctl/scripts/check-config is run…

/opt/bro/share/broctl/scripts/check-config: line 50: 4463 Segmentation fault “${bro}” $check\_option “$@”

Anyone encountered this before? Cannot bypass doing broctl check – broctl start results in failed/crashed processes.

This is on RHEL7.5, after building Bro-2.5.5 (I’ve tried other minor versions since 2.5 – same issue).

Existing Bro cluster on RHEL7.5 boxes with Bro-2.5 and Broctl 1.5 works fine.

Any help would be greatly appreciated.

V/R

**Sean Hutchison**

---

<div class="post-metadata">

**Author:** ![Azoff\_Justin\_S](https://avatars.discourse-cdn.com/v4/letter/a/dec6dc/32.png) [@Azoff\_Justin\_S](https://community.zeek.org/u/Azoff_Justin_S)\
**Post date:** [October 3, 2018, 7:00pm UTC](https://community.zeek.org/t/broctl-segmentation-fault/5483/2 "2018-10-03T19:00:40Z")

</div>

check runs bro with the current configuration to see if it can start, so that's bro segfaulting there.. that's why start also fails..

What do you get if you try each of the following?

&nbsp;&nbsp;&nbsp;&nbsp;bro -v  
&nbsp;&nbsp;&nbsp;&nbsp;bro -NN # just see if this runs or crashes  
&nbsp;&nbsp;&nbsp;&nbsp;bro -b -i lo  
&nbsp;&nbsp;&nbsp;&nbsp;bro -i lo  
&nbsp;&nbsp;&nbsp;&nbsp;bro -i lo local

You can hit control-c if any of those start successfully to get your prompt back.

I'm not aware of any issues like this, so it could be something with your configuration.

Do you have a customized local.bro at all?  
Are you building bro against a particular libpcap or malloc implementation?  
What does ldd /opt/bro/bin/bro output?

---

<div class="post-metadata">

**Author:** ![sp4ce\_hUtch](https://avatars.discourse-cdn.com/v4/letter/s/8e8cbc/32.png) [@sp4ce\_hUtch](https://community.zeek.org/u/sp4ce_hUtch)\
**Post date:** [October 4, 2018, 12:01pm UTC](https://community.zeek.org/t/broctl-segmentation-fault/5483/3 "2018-10-04T12:01:02Z")

</div>

# bro -v  
bro version 2.5.5

# bro -NN  
Segmentation fault

# bro -b -i lo  
listening on lo

^C1538653437.070325 received termination signal  
1538653437.070325 208 packets received on interface lo, 0 dropped

# bro -i lo  
Segmentation fault

# bro -i lo local  
Segmentation fault

# ldd /opt/bro/bin/bro  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;linux-vdso.so.1 =\> (0x00007fff99dfd000)  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;libpcap.so.1 =\> /lib64/libpcap.so.1 (0x00007f148eec1000)  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;libssl.so.10 =\> /lib64/libssl.so.10 (0x00007f148ec50000)  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;libcrypto.so.10 =\> /lib64/libcrypto.so.10 (0x00007f148e7ef000)  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;libresolv.so.2 =\> /lib64/libresolv.so.2 (0x00007f148e5d6000)  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;libz.so.1 =\> /lib64/libz.so.1 (0x00007f148e3c0000)  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;libGeoIP.so.1 =\> /lib64/libGeoIP.so.1 (0x00007f148e190000)  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;libtcmalloc.so.4 =\> /lib64/libtcmalloc.so.4 (0x00007f148dd9b000)  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;libpthread.so.0 =\> /lib64/libpthread.so.0 (0x00007f148db7f000)  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;libdl.so.2 =\> /lib64/libdl.so.2 (0x00007f148d97b000)  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;libstdc++.so.6 =\> /lib64/libstdc++.so.6 (0x00007f148d674000)  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;libm.so.6 =\> /lib64/libm.so.6 (0x00007f148d372000)  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;libgcc\_s.so.1 =\> /lib64/libgcc\_s.so.1 (0x00007f148d15c000)  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;libc.so.6 =\> /lib64/libc.so.6 (0x00007f148cd8f000)  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;libgssapi\_krb5.so.2 =\> /lib64/libgssapi\_krb5.so.2 (0x00007f148cb42000)  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;libkrb5.so.3 =\> /lib64/libkrb5.so.3 (0x00007f148c85a000)  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;libcom\_err.so.2 =\> /lib64/libcom\_err.so.2 (0x00007f148c656000)  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;libk5crypto.so.3 =\> /lib64/libk5crypto.so.3 (0x00007f148c423000)  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;/lib64/ld-linux-x86-64.so.2 (0x00007f148f102000)  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;libkrb5support.so.0 =\> /lib64/libkrb5support.so.0 (0x00007f148c215000)  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;libkeyutils.so.1 =\> /lib64/libkeyutils.so.1 (0x00007f148c011000)  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;libselinux.so.1 =\> /lib64/libselinux.so.1 (0x00007f148bdea000)  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;libpcre.so.1 =\> /lib64/libpcre.so.1 (0x00007f148bb88000)

No custom scripts being loaded via local.bro  
Nothing in particular - did yum install/update of RedHat-based dependencies according to [https://www.bro.org/sphinx/install/install.html#required-dependencies](https://www.bro.org/sphinx/install/install.html#required-dependencies)  
Although I did build it against pfring first, using yum package from ntop repo - same issue, have since removed that and did regular build

Only configure switch was --prefix.

V/R  
Sean

---

<div class="post-metadata">

**Author:** ![johanna](https://avatars.discourse-cdn.com/v4/letter/j/50afbb/32.png) [@johanna](https://community.zeek.org/u/johanna)\
**Post date:** [October 4, 2018, 3:36pm UTC](https://community.zeek.org/t/broctl-segmentation-fault/5483/4 "2018-10-04T15:36:20Z")

</div>

Hi,

Is there a change that you have binary plugins installed (netmap plugin, a few bro-pkg ones)?

They can cause crashes exactly like this. This behavior is fixed with Bro 2.6 (it will output an error message instead).

If that is the case - either recompiling or removing the binary plugins will fix this.

Johanna

---

<div class="post-metadata">

**Author:** ![sp4ce\_hUtch](https://avatars.discourse-cdn.com/v4/letter/s/8e8cbc/32.png) [@sp4ce\_hUtch](https://community.zeek.org/u/sp4ce_hUtch)\
**Post date:** [October 4, 2018, 5:14pm UTC](https://community.zeek.org/t/broctl-segmentation-fault/5483/5 "2018-10-04T17:14:09Z")

</div>

Yes, and I just removed the Bro Kafka plugin and no more error!

Thank you so much.

V/R  
Sean

---

<div class="post-metadata">

**Author:** ![JonZeolla](https://avatars.discourse-cdn.com/v4/letter/j/ccd318/32.png) [@JonZeolla](https://community.zeek.org/u/JonZeolla)\
**Post date:** [October 4, 2018, 9:06pm UTC](https://community.zeek.org/t/broctl-segmentation-fault/5483/6 "2018-10-04T21:06:06Z")

</div>

If you don’t mind, can you share the steps you took to build and install the plug-in? What version?

Jon

---

<div class="post-metadata">

**Author:** ![sp4ce\_hUtch](https://avatars.discourse-cdn.com/v4/letter/s/8e8cbc/32.png) [@sp4ce\_hUtch](https://community.zeek.org/u/sp4ce_hUtch)\
**Post date:** [October 5, 2018, 11:55am UTC](https://community.zeek.org/t/broctl-segmentation-fault/5483/7 "2018-10-05T11:55:30Z")

</div>

Ya, first install librdkafka (there’s probably a newer version – make sure it supports your Kafka broker version) …

curl --silent -L -k [https://github.com/edenhill/librdkafka/archive/v0.9.5.tar.gz](https://github.com/edenhill/librdkafka/archive/v0.9.5.tar.gz) | tar xz

cd librdkafka-0.9.5

./configure

make

make install

Then get bro-plugins repo and build kafka plugin against version of Bro you’re using by pointing it to where you extracted bro source…

git clone [https://github.com/bro/bro-plugins.git](https://github.com/bro/bro-plugins.git)

cd bro-plugins/kafka/

./configure --bro-dist=/path/to/bro-2.#.#

make && make install

Confirm with…

bro -N Bro::Kafka

See [https://archive.apache.org/dist/metron/0.4.0/site-book/metron-sensors/bro-plugin-kafka/index.html](https://archive.apache.org/dist/metron/0.4.0/site-book/metron-sensors/bro-plugin-kafka/index.html) for example configurations.

V/R

Sean

---

<div class="post-metadata">

**Author:** ![JonZeolla](https://avatars.discourse-cdn.com/v4/letter/j/ccd318/32.png) [@JonZeolla](https://community.zeek.org/u/JonZeolla)\
**Post date:** [October 5, 2018, 4:36pm UTC](https://community.zeek.org/t/broctl-segmentation-fault/5483/8 "2018-10-05T16:36:00Z")

</div>

Sounds like you are looking at a very old version of the plugin, since bro/bro-plugins has been completely deprecated at this point. Can you use bro-pkg to install apache/metron-bro-plugin-kafka? It should be a bit more robust and up to date. Let me know if you have any issues when taking this approach.

Jon

---

<div class="post-metadata">

**Author:** ![sp4ce\_hUtch](https://avatars.discourse-cdn.com/v4/letter/s/8e8cbc/32.png) [@sp4ce\_hUtch](https://community.zeek.org/u/sp4ce_hUtch)\
**Post date:** [October 5, 2018, 5:19pm UTC](https://community.zeek.org/t/broctl-segmentation-fault/5483/9 "2018-10-05T17:19:14Z")

</div>

Well, we don’t really have a need to use the bro kafka plugin currently – it was just for a bit of testing previously – but I can use bro-pkg in the future or for other plugins/scripts.

V/R

Sean

---

<div class="post-metadata">

**Author:** ![JonZeolla](https://avatars.discourse-cdn.com/v4/letter/j/ccd318/32.png) [@JonZeolla](https://community.zeek.org/u/JonZeolla)\
**Post date:** [October 5, 2018, 6:58pm UTC](https://community.zeek.org/t/broctl-segmentation-fault/5483/10 "2018-10-05T18:58:30Z")

</div>

Gotcha, yeah please do as that is the most updated code and includes some baseline btests (with more coming in the near future). Feel free to reach out to me via the list if you have any questions/concerns/issues on it - thanks!

Jon

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/zeek/original/1X/f09d732bc2cc7c7cc7e35db67cf4e1d5233ce7a7.png) [@system](https://community.zeek.org/u/system)\
**Post date:** [May 6, 2022, 3:46pm UTC](https://community.zeek.org/t/broctl-segmentation-fault/5483/11 "2022-05-06T15:46:06Z")

</div>


