This message was deleted.
# general
s
This message was deleted.
s
@Daniel Gerendas how do you configure the zoneaware policy? Can you describe the changes you made?
d
In bookkeeper.conf set this:
ensemblePlacementPolicy=org.apache.bookkeeper.client.ZoneawareEnsemblePlacementPolicy
and in broker.conf set both
bookkeeperClientRackawarePolicyEnabled=false
and
bookkeeperClientRegionawarePolicyEnabled=false
and played around with different rack settings with the following command:
Copy code
bin/pulsar-admin bookies set-bookie-rack --bookie bookie1:3181 --hostname bookie-host:3181 --group test --rack us-east-1/us-east-1a/rack1
s
it looks like both
bookkeeperClientRackawarePolicyEnabled
and
bookkeeperClientRegionawarePolicyEnabled
are set to
false
d
yes, because I thought both should be false, as we would like to use Zoneaware placement
s
Bookkeeper client does have an implementation
ZoneawareEnsemblePlacementPolicy
. However, I don't think this is used by Pulsar. ZoneawareEnsemblePlacementPolicy is similar to
RackawarePolicy
. Pulsar supports
Rackaware
and
Regional
as part of its tooling. So in most of the cloud environments, you can map
zone
to
rack
(your network path would be something like
us-east-1/us-east-1a
). Then you can enable
bookkeeperClientRackawarePolicyEnabled
. Then you should be good.
d
oh, all clear, will try that then, Thank you very much for the help Sijie!
@sijieg I’ve set the
bookkeeperClientRackawarePolicyEnabled
to true in the broker.conf and the ensemblePlacementPolicy in bookkeeper.conf to
org.apache.bookkeeper.client.RackawareEnsemblePlacementPolicy
and configured the racks for the bookies like this:
Copy code
testgroup    {
    172.16.2.190: 3181=BookieInfoImpl(rack=us-east-1a, hostname=172.16.2.190: 3181),
    172.16.1.112: 3181=BookieInfoImpl(rack=us-east-1a, hostname=172.16.1.112: 3181),
    172.16.3.6: 3181=BookieInfoImpl(rack=us-east-1b, hostname=172.16.3.6: 3181)
}
and I’m still getting the following warning:
Copy code
New ensemble: [172.16.2.190:3181, 172.16.3.6:3181, 172.16.1.112:3181] is not adhering to Placement Policy. quarantinedBookies: []
after setting the racks should I restart bookkeeper or broker? I’ve tried a few things but nothing really worked. Your help would be appreciated. Thanks in advance
s
@Hang Chen thoughts?
h
• What’s the configuration of https://github.com/apache/pulsar/blob/a0372f4b91b4bd6600093cdb52e2db5d6ab8497e/conf/broker.conf#L1007? • Have you tried to the three bookie to three racks? • Have you tried to restart the broker?
The rack name should be
/us-east-1a
instead of
us-east-1a
d
bookkeeperClientMinNumRacksPerWriteQuorum
was set to 2, I just set the bookies to 3 different racks, added the
/
to the rack names and restarted the broker, but still getting the warning
s
@Daniel Gerendas It looks like you only have 2 racks, no?
h
Would you please create an issue in Apache Pulsar repo and describe the steps of how to reproduce it? We will take a look
Share the broker’s and bookie’s log will be more helpful, thanks.
d
h
@Daniel Gerendas Would you please check the latest comment?
👀 1