milvus-logo
LFAI
< Docs

update_password()

This method updates the password of a specified user. You have to specify the name, old password, and new password of the user.

This operation does not change the header of the currently running Milvus connection and may results in connection errors. Therefore, close all Milvus connections established by a user before updating the user's password.

Invocation

update_password(user, old_password, new_password)

Parameters

ParameterDescriptionTypeRequired
userName of a userStringTrue
old_passwordOriginal password of the userStringTrue
new_passwordNew password of the userStringFalse

Returns

No return.

Example

from pymilvus import connections, utility
connections.connect()
utility.update_password(user, old_password, new_password)
connections.connect(user=user, password=new_password)
users = utility.list_usernames()
print(f"users in Milvus: {users}")
Feedback

Was this page helpful?