https://pinot.apache.org/ logo
#troubleshooting
Title
# troubleshooting
a

Alice

04/04/2022, 10:27 AM
Hi, team: ‘java.lang.IllegalArgumentException: must provide a password for admin’ error occurred when I use ‘./bin/pinot-admin.sh StartBroker -configFileName ./conf/pinot-broker-7011.conf’ to start Pinot broker. I have the same config as listed in the example. I have started Pinot controller according to the example config and it started successfully. Any idea what’s wrong the the broker config? pinot.broker.access.control.class=org.apache.pinot.broker.broker.BasicAuthAccessControlFactory pinot.broker.access.control.principals=admin,user pinot.broker.access.control.principals.admin.password=verysecret pinot.broker.access.control.principals.user.password=secret
m

Mayank

04/04/2022, 4:48 PM
From the code it seems like it is unable to find the password for
admin
in the property. However, your settings in the conf seem correct. Also, the exact same configs work in the integration test, so this is a bit confusing. My guess is there is something else going on in your setup that is causing the property to be not set?
a

Alice

04/05/2022, 3:31 AM
@User What other setting it might be? 😇
m

Mayank

04/05/2022, 4:26 AM
Can’t really think of anything, @User any thoughts?
a

Alexander Pucher

04/05/2022, 11:45 PM
@User this should work. are you on a windows machine? there might be invisible line endings etc
a

Alice

04/06/2022, 3:32 AM
I did the test on Pinot 0.9.3 and it failed. But the same config worked on Pinot 0.10. Guess I should use 0.10 and do more tests.
👍 1
@User Sorry about the confusion. I just found I had a wrong broker config on Pinot 0.10. After I adjusted it, the error occurred again, just like it did on Pinot 0.9.3.
a

Alexander Pucher

04/06/2022, 7:37 AM
@User I just set up a minimal example with a new-ish pinot master. the config above seems to work attached to an AuthQuickstart cluster. (1) Run AuthQuickstart via console or IDE (2) Create
broker.conf
Copy code
pinot.broker.access.control.class=org.apache.pinot.broker.broker.BasicAuthAccessControlFactory
pinot.broker.access.control.principals=admin,user
pinot.broker.access.control.principals.admin.password=verysecret
pinot.broker.access.control.principals.user.password=secret
(3)
bin/pinot-admin.sh StartBroker -configFileName ./broker.conf -zkAddress localhost:2123 -clusterName QuickStartCluster
(4)
curl localhost:8099/query/sql -XPOST -d '{"sql":"SELECT * FROM baseballStats"}
returns 180 (reject, expected) (5)
curl localhost:8099/query/sql -XPOST -d '{"sql":"SELECT * FROM baseballStats"}' -H 'Authorization: Basic YWRtaW46dmVyeXNlY3JldA=='
returns results (success, expected) In order to debug this would you mind sharing (a) which OS/platform you’re on, and (b) your full broker config file?
a

Alice

04/06/2022, 8:00 AM
@User Really sorry for all this trouble. Thank you for checking it. I finally copied the characters from the source code instead of from the doc and it started to work.