No se puede iniciar Minio en Ubuntu debido a que no se puede crear el acceso al archivo (/mnt/data/.minio.sys/tmp) denegado.

No se puede iniciar Minio en Ubuntu debido a que no se puede crear el acceso al archivo (/mnt/data/.minio.sys/tmp) denegado.

Estoy instalando la última versión de minio en ubuntu 18.04 siguiendo las instrucciones de instalación de minio desde aquí.

Después de la instalación, intente ejecutarlo con sudo systemctl start minio.service

pero no funcionó con el mensaje.

...skipping...
● minio.service - MinIO
   Loaded: loaded (/etc/systemd/system/minio.service; disabled; vendor preset: enabled)
   Active: failed (Result: exit-code) since Thu 2022-12-08 17:03:45 CST; 2min 1s ago
     Docs: https://docs.min.io
  Process: 5072 ExecStart=/usr/local/bin/minio server $MINIO_OPTS $MINIO_VOLUMES (code=exited, status=1/FAILURE)
  Process: 5050 ExecStartPre=/bin/bash -c if [ -z "${MINIO_VOLUMES}" ]; then echo "Variable MINIO_VOLUMES not set in /etc/default/minio"; exit 1; fi (code=exited, status=0/SUCCES
 Main PID: 5072 (code=exited, status=1/FAILURE)

12月 08 17:03:45 nky systemd[1]: minio.service: Service hold-off time over, scheduling restart.
12月 08 17:03:45 nky systemd[1]: minio.service: Scheduled restart job, restart counter is at 5.
12月 08 17:03:45 nky systemd[1]: Stopped MinIO.
12月 08 17:03:45 nky systemd[1]: minio.service: Start request repeated too quickly.
12月 08 17:03:45 nky systemd[1]: minio.service: Failed with result 'exit-code'.
12月 08 17:03:45 nky systemd[1]: Failed to start MinIO.

Se nota que hay algo mal con 'MINIO_VOLUMES', pero configuré la variable en /etc/default/minio

MINIO_ROOT_USER=myminioadmin
MINIO_ROOT_PASSWORD=minio-secret-key-change-me
# MINIO_VOLUMES sets the storage volume or path to use for the MinIO server.
MINIO_VOLUMES="/mnt/data"

Luego intenté usar el comando minio para iniciar el servidor.

minio server /mnt/data  --console-address :9090

Están apareciendo más errores

Error: unable to rename (/mnt/data/.minio.sys/tmp -> /mnt/data/.minio.sys/tmp-old/de70b42d-9451-4876-8d28-c5aba44f331b) file access denied, drive may be faulty please investigate (*fmt.wrapError)
       6: internal/logger/logger.go:258:logger.LogIf()
       5: cmd/prepare-storage.go:88:cmd.bgFormatErasureCleanupTmp()
       4: cmd/xl-storage.go:252:cmd.newXLStorage()
       3: cmd/object-api-common.go:61:cmd.newStorageAPI()
       2: cmd/format-erasure.go:678:cmd.initStorageDisksWithErrors.func1()
       1: internal/sync/errgroup/errgroup.go:123:errgroup.(*Group).Go.func1()

API: SYSTEM()
Time: 19:47:11 UTC 12/08/2022
Error: unable to create (/mnt/data/.minio.sys/tmp) file access denied, drive may be faulty please investigate (*fmt.wrapError)
       6: internal/logger/logger.go:258:logger.LogIf()
       5: cmd/prepare-storage.go:95:cmd.bgFormatErasureCleanupTmp()
       4: cmd/xl-storage.go:252:cmd.newXLStorage()
       3: cmd/object-api-common.go:61:cmd.newStorageAPI()
       2: cmd/format-erasure.go:678:cmd.initStorageDisksWithErrors.func1()
       1: internal/sync/errgroup/errgroup.go:123:errgroup.(*Group).Go.func1()
ERROR Unable to use the drive /mnt/data: drive access denied: Invalid arguments specified

Respuesta1

Finalmente encontré que el problema es que la nueva versión del servidor minio no es compatible con los archivos minio antiguos, así que eliminé todos los archivos minio y creé una nueva carpeta para el minio. entonces funciona.

información relacionada