BROKER enable fails

Hi all,

I’m trying to send my bro cluster some messages via pybroker.

On the bro side I run the a.bro script and I get the following error :

line 12: value used but not set (Broker::enable)
line 13: value used but not set (Broker::listen)

Is there anything else I should load to get this script working ?

Any ideas about the source of the problem ?

here is a.bro :

@load base/frameworks/broker

module test;

const broker_port: port = 9999/tcp &redef;
redef exit_only_after_terminate = T;
redef Broker::endpoint_name = "listener";

event bro_init()
	{
	Broker::enable();
	Broker::listen(broker_port, "127.0.0.1");
	}

event Broker::incoming_connection_established(peer_name: string)
	{
	print "Broker::incoming_connection_established", peer_name;
	}

event Broker::incoming_connection_broken(peer_name: string)
	{
	print "Broker::incoming_connection_broken", peer_name;
	terminate();
	}

Thanks,

B




Hi all,

I'm trying to send my bro cluster some messages via pybroker.

On the bro side I run the a.bro script and I get the following error :
line 12: value used but not set (Broker::enable)
line 13: value used but not set (Broker::listen)

Is there anything else I should load to get this script working ?
Any ideas about the source of the problem ?

here is a.bro :

@load base/frameworks/broker

module test;

const broker_port: port = 9999/tcp &redef;redef
exit_only_after_terminate = T;redef Broker::endpoint_name =
"listener";
event bro_init()
  {
  Broker::enable();
  Broker::listen(broker_port, "127.0.0.1");
  }
event Broker::incoming_connection_established(peer_name: string)
  {
  print "Broker::incoming_connection_established", peer_name;
  }
event Broker::incoming_connection_broken(peer_name: string)
  {
  print "Broker::incoming_connection_broken", peer_name;
  terminate();
  }

Thanks,

B

Sounds like yesterday:
http://mailman.icsi.berkeley.edu/pipermail/bro/2017-March/011652.html

OK I can now send messages and it works :slight_smile: thanks

How do you implement it in a clustered environment ?

Every instance of bro (manager and workers) will try to listen to the same port I assume (because broctl will not start while a single bro instance does work)

Is there a way of updating a table in a cluster environment for only one bro instance (manager) and make sure it will be synchronized for instances in the cluster ?

Thanks

B