Hellow guys,
I am trying install mlflow. I install it by anaconda and want to start with systemctl. Bellows are my config and setting. mlflow.services
[Unit]
Description=MLflow
Documentation=https://mlflow.org/docs/latest/index.html
[Service]
WorkingDirectory=/my_root_folder/mlflow
User=my_user
Group=my_user
EnvironmentFile=-/my_root_folder/mlflow/env
ExecStart=/my_anaconda_path/envs/zdp_mlflow/bin/mlflow server --host 0.0.0.0 --port 8081 --app-name basic-auth --backend-store-uri $DATABASE_URL --serve-artifacts --artifacts-destination s3://mlflow-artifacts/artifacts
StandardOutput=file:/my_log_folder/mlflow-stdout.log
StandardError=file:/my_log_folder/mlflow-stderr.log
Restart=always
[Install]
WantedBy=multi-user.target
The env file located in /my_root_folder/mlflow/env
BASE_DIR="/my_root_folder/mlflow"
DATABASE_URL="mysql+mysqldb://my_user:my_pass@my_host:3306/my_database"
ARTIFACT_ROOT="$BASE_DIR/mlartifacts"
MLFLOW_AUTH_CONFIG_PATH="$BASE_DIR/basic_auth.ini"
MLFLOW_S3_ENDPOINT_URL="http://localhost:9000"
AWS_ACCESS_KEY_ID="w44T3qJatKdpynlRAoD8"
AWS_SECRET_ACCESS_KEY="gEaYUzKtOarG8bZV3iP6kTnoBdCk2gTHZ9SMhhS3"
MLFLOW_S3_IGNORE_TLS=true
LD_LIBRARY_PATH="$LD_LIBRARY_PATH:/user/lib/mysql8/lib/"
LD_PRELOAD=/lib64/libstdc++.so.6
and here is my auth config path located at $BASE_DIR/basic_auth.ini
[mlflow]
default_permission = NO_PERMISSIONS
database_uri = mysql+mysqldb://my_user:my_pass@my_host:3306/my_database_auth
admin_username = admin
admin_password = c59m8A3aM
When I start mlflow by systemctl start mlflow, it print error
mlflow: File "/my_anaconda_path/envs/zdp_mlflow/lib/python3.8/importlib/__init__.py", line 127, in import_module
mlflow: return _bootstrap._gcd_import(name[level:], package, level)
mlflow: File "<frozen importlib._bootstrap>", line 1014, in _gcd_import
mlflow: File "<frozen importlib._bootstrap>", line 991, in _find_and_load
mlflow: File "<frozen importlib._bootstrap>", line 975, in _find_and_load_unlocked
mlflow: File "<frozen importlib._bootstrap>", line 671, in _load_unlocked
mlflow: File "<frozen importlib._bootstrap_external>", line 843, in exec_module
mlflow: File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed
mlflow: File "/my_anaconda_path/envs/zdp_mlflow/lib/python3.8/site-packages/mlflow/server/auth/__init__.py", line 112, in <module>
mlflow: auth_config = read_auth_config()
mlflow: File "/my_anaconda_path/envs/zdp_mlflow/lib/python3.8/site-packages/mlflow/server/auth/config.py", line 27, in read_auth_config
mlflow: default_permission=config["mlflow"]["default_permission"],
mlflow: File "/my_anaconda_path/envs/zdp_mlflow/lib/python3.8/configparser.py", line 960, in __getitem__
mlflow: raise KeyError(key)
mlflow: KeyError: 'mlflow'
systemd: mlflow.service: main process exited, code=exited, status=1/FAILURE
systemd: Unit mlflow.service entered failed state.
systemd: mlflow.service failed.
systemd: mlflow.service holdoff time over, scheduling restart.
systemd: start request repeated too quickly for mlflow.service
systemd: Unit mlflow.service entered failed state.
systemd: mlflow.service failed.
I was
- Create both database for app and auth
- Search error on stackoverflow and mlflow git hub issue
- Create minio service and key pair
Some one help me explain what is error and how can I fix it. Thanks in advance.