Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Too slow docker boot on NFS mounts #6554

Closed
druppy opened this issue May 10, 2021 · 6 comments
Closed

Too slow docker boot on NFS mounts #6554

druppy opened this issue May 10, 2021 · 6 comments
Labels
💊 bug Something isn't working 📦 deployment Related to deployments ⚓️ docker Categorizes as related to Docker
Milestone

Comments

@druppy
Copy link
Contributor

druppy commented May 10, 2021

Describe the bug

I have been using the docket image as part of a new HELM v3 upgrade I made (I have no idea where to publish this as of now), and it works really good, except for a small detail.

When starting my docker image, it took a really long time to startup, and in fact the k8s cluster I used ended up terminating the container as the live check only works when the service are running.

I took a deep look inside the container, and found that there where a chown -R $USER:$USER /data command running. This would normally not be a problem for small and physical mounts, but my setup was a really large (20k+ files) NFS mount.

I have therefor made a pull request #6553 , that change the start.sh to test if /data have the ownership we expect, and then only run the chown command when needed. There could be an argument about what happens if one of the files down the /data tree have changed ownership, and yes ... that would be a problem. But I assume that the chown command are here to ease migration, and not to keep file ownership in sync.

I really hope this could get pulled, to allow for better NFS integration.

Gogs version and commit
master

Git version
2.30.2

Operating system
Debian Linux

Database
PostgrSQL

To Reproduce

Steps to reproduce the behavior:

  1. setup docker image using a large NFS mount as /data
  2. start the container
  3. observe really long boot (depending on the location on your NFS server.

Can you reproduce the bug at https://try.gogs.io?
Nope, this is boot relevant

Expected behavior
Fast boot

Actual behavior
Really long startup time

@unknwon unknwon added 💊 bug Something isn't working 📦 deployment Related to deployments labels Feb 10, 2022
@julienfabre
Copy link

I'm having the same issue and would love to see this merged !

@unknwon unknwon added the status: needs feedback Tell me more about it label Mar 11, 2022
@unknwon
Copy link
Member

unknwon commented Mar 11, 2022

Hey @julienfabre, I just merged #6553, and it takes about an hour to finish automated Docker build for gogs/gogs:latest.

@unknwon unknwon moved this to QA in Gogs Roadmap Mar 11, 2022
@julienfabre
Copy link

Thank you @unknwon , I'm not seeing the fix in the latest release from today though (https://github.com/gogs/gogs/releases/tag/v0.12.5), do you plan to release it separately?

@unknwon
Copy link
Member

unknwon commented Mar 11, 2022

@julienfabre I haven't QA it myself just in case it breaks anything, so did not include in today's patch release. If I get the chance to do the sanity check, it could be included in the next patch release (which is currently no planned).

@unknwon unknwon added ⚓️ docker Categorizes as related to Docker and removed status: needs feedback Tell me more about it labels Mar 11, 2022
@unknwon unknwon added this to the 0.12.5 milestone Mar 13, 2022
@unknwon
Copy link
Member

unknwon commented Mar 13, 2022

QA seems good, will be included in 0.12.6.

@unknwon unknwon closed this as completed Mar 13, 2022
Repository owner moved this from QA to Done in Gogs Roadmap Mar 13, 2022
@unknwon
Copy link
Member

unknwon commented Mar 19, 2022

The 0.12.6 has been released that includes the patch of the reported issue.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jun 18, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
💊 bug Something isn't working 📦 deployment Related to deployments ⚓️ docker Categorizes as related to Docker
Projects
No open projects
Status: Done
Development

No branches or pull requests

3 participants
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy