mirror of
https://github.com/go-gitea/gitea.git
synced 2026-03-12 10:39:38 -05:00
Gitea slow on corperate Windows 10 environment #3078
Closed
opened 2025-11-02 05:00:03 -06:00 by GiteaMirror
·
31 comments
No Branch/Tag Specified
main
release/v1.25
release/v1.24
release/v1.23
release/v1.22
release/v1.21
release/v1.20
release/v1.19
release/v1.18
release/v1.17
release/v1.16
release/v1.15
release/v1.14
release/v1.13
release/v1.12
release/v1.11
release/v1.10
release/v1.9
release/v1.8
v1.25.3
v1.25.2
v1.25.1
v1.25.0
v1.24.7
v1.25.0-rc0
v1.26.0-dev
v1.24.6
v1.24.5
v1.24.4
v1.24.3
v1.24.2
v1.24.1
v1.24.0
v1.23.8
v1.24.0-rc0
v1.25.0-dev
v1.23.7
v1.23.6
v1.23.5
v1.23.4
v1.23.3
v1.23.2
v1.23.1
v1.23.0
v1.23.0-rc0
v1.24.0-dev
v1.22.6
v1.22.5
v1.22.4
v1.22.3
v1.22.2
v1.22.1
v1.22.0
v1.23.0-dev
v1.22.0-rc1
v1.21.11
v1.22.0-rc0
v1.21.10
v1.21.9
v1.21.8
v1.21.7
v1.21.6
v1.21.5
v1.21.4
v1.21.3
v1.21.2
v1.20.6
v1.21.1
v1.21.0
v1.21.0-rc2
v1.21.0-rc1
v1.20.5
v1.22.0-dev
v1.21.0-rc0
v1.20.4
v1.20.3
v1.20.2
v1.20.1
v1.20.0
v1.19.4
v1.21.0-dev
v1.20.0-rc2
v1.20.0-rc1
v1.20.0-rc0
v1.19.3
v1.19.2
v1.19.1
v1.19.0
v1.19.0-rc1
v1.20.0-dev
v1.19.0-rc0
v1.18.5
v1.18.4
v1.18.3
v1.18.2
v1.18.1
v1.18.0
v1.17.4
v1.18.0-rc1
v1.19.0-dev
v1.18.0-rc0
v1.17.3
v1.17.2
v1.17.1
v1.17.0
v1.17.0-rc2
v1.16.9
v1.17.0-rc1
v1.18.0-dev
v1.16.8
v1.16.7
v1.16.6
v1.16.5
v1.16.4
v1.16.3
v1.16.2
v1.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.0-rc1
v1.3.2
v1.3.1
v1.3.0
v1.3.0-rc2
v1.3.0-rc1
v1.2.3
v1.2.2
v1.2.1
v1.2.0
v1.2.0-rc3
v1.2.0-rc2
v1.1.4
v1.2.0-rc1
v1.1.3
v1.1.2
v1.1.1
v1.1.0
v1.0.2
v1.0.1
v1.0.0
v0.9.99
Labels
Clear labels
$20
$250
$50
$500
backport/done
💎 Bounty
docs-update-needed
good first issue
hacktoberfest
issue/bounty
issue/confirmed
issue/critical
issue/duplicate
issue/needs-feedback
issue/not-a-bug
issue/regression
issue/stale
issue/workaround
lgtm/need 2
modifies/api
modifies/translation
outdated/backport/v1.18
outdated/theme/markdown
outdated/theme/timetracker
performance/bigrepo
performance/cpu
performance/memory
performance/speed
pr/breaking
proposal/accepted
proposal/rejected
pr/wip
pull-request
reviewed/wontfix
💰 Rewarded
skip-changelog
status/blocked
topic/accessibility
topic/api
topic/authentication
topic/build
topic/code-linting
topic/commit-signing
topic/content-rendering
topic/deployment
topic/distribution
topic/federation
topic/gitea-actions
topic/issues
topic/lfs
topic/mobile
topic/moderation
topic/packages
topic/pr
topic/projects
topic/repo
topic/repo-migration
topic/security
topic/theme
topic/ui
topic/ui-interaction
topic/ux
topic/webhooks
topic/wiki
type/bug
type/deprecation
type/docs
type/enhancement
type/feature
type/miscellaneous
type/proposal
type/question
type/refactoring
type/summary
type/testing
type/upstream
Mirrored from GitHub Pull Request
Milestone
No items
No Milestone
Projects
Clear projects
No project
No Assignees
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: github-starred/gitea#3078
Reference in New Issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @mike-jl on GitHub (Mar 20, 2019).
6a6656a, but was the same since 1.6[x]): (also tried MSSQL but no difference)Description
Gitea on my Work PC is generally very slow.
My PC has plenty of resources left according to resmon.
Changing to the commit view of the repo takes 9.4 seconds.
Trying to create a pull request between two branches, the loading time after selecting the branch is 50 sencods.
I already tried disabling the antivirus, and it does help (pull request goes down to 42 seconds), but that's still way to much.
Any way to debug what is taking so long?
I looked at ProcessExplorer, but all i can see is that gitea spawns a view git processes in that time. Maybe i just need to know where to look..
Thanks in advance!
@lunny commented on GitHub (Mar 20, 2019):
That's maybe caused by
sqlite_unlock_notifyand I think You maybe change your database if you have enough resources.@mike-jl commented on GitHub (Mar 20, 2019):
As i said i already tried with a local MSSQL installation and ended up with the same performance...
Should i try MySQL?
I could try it in a local installation, but for prod my only options are MSSQL or SQLite...
@lunny commented on GitHub (Mar 20, 2019):
@michiil haven't found you mentioned MSSQL on above messages. I run a gitea instance with MSSQL on macOS it's fast and I cannot reproduce your problem since I have not windows with MSSQL installed.
@mike-jl commented on GitHub (Mar 20, 2019):
Maybe i should have made it more clearly..
Its also fast on my private windows machine, or on my private linux server.
It has to have to do something with the corporate environment...
@mike-jl commented on GitHub (Mar 20, 2019):
Here is a log with REDIRECT_MACARON_LOG = true and LEVEL = Trace
This is from selecting the branch in a new pull request.
https://gist.github.com/michiil/1d91ef87fb6a248e746014d5959e4eb3
@lunny commented on GitHub (Mar 20, 2019):
Does your pull request have many commits or changed files?
@mike-jl commented on GitHub (Mar 20, 2019):
Its 41 commits and 147 changed files.
About 100 of the changed files are new images.
But still, on my linux server at home with far inferior hardware it takes 1.38 seconds...
@lafriks commented on GitHub (Mar 27, 2019):
Could this be problem with resolving federated avatars?
@mike-jl commented on GitHub (Mar 28, 2019):
I don't think so, i got the following lines in my config:
@zeripath commented on GitHub (Mar 28, 2019):
So do you think it's the starting of the git process that's taking the time?
How long is the PATH on that Windows server? Is it possible that Windows it's having to look through large numbers of directories to find git? Is there a slow virtual drive on the path so your corporate Windows has to do Windows networking to check for the file before it finally finds git? Presumably git is on the local server?
Similarly presumably your repositories are local to that server and are not on some shared drive so that when gitea has to look it doesn't have to do cross network lookup?
@mike-jl commented on GitHub (Mar 28, 2019):
That could very well be it.
The path is pretty long yes, but everything is local.
Is there a way to point gitea to the git executional so it doesn't have to search through the path?
@zeripath commented on GitHub (Mar 28, 2019):
Explicitly set the path when you execute gitea either through a bat file (or I think it's possible on a lnk file.)
@mike-jl commented on GitHub (Mar 28, 2019):
Here are some measurements that i made:
Normal PATH with Antivirus:
© Gitea Version: 6a6656a Seite: 53899ms Vorlage: 46065msOnly git in PATH with Antivirus:
© Gitea Version: 6a6656a Seite: 41122ms Vorlage: 35044msOnly git in PATH without Antivirus:
© Gitea Version: 6a6656a Seite: 34646ms Vorlage: 29545msSo the PATH is a big issue! Maybe that should be added to the docs?
Unfortunately i can't disable antivirus permanently, but 12 seconds is a lot better!
Still not as good as i would expect from that machine, but maybe that's the windows tax..
@zeripath commented on GitHub (Mar 28, 2019):
Ok so simplifying the path was one thing. The next is, are you still using 1.6? Prior to #4921 every time you wanted to do a pr Gitea would mindlessly clone and do a full checkout, perform the merge and push. As you can imagine that takes forever - so #4921 significantly reduces the amount of work involved. Now Windows is fairly bad at keeping file caches around so if you try to clone a repo this will be expensive especially with the hooks for antivirus.
I think #4921 is only in version 1.8 and the current master but it's well recommended to try that to see if it makes things better.
@mike-jl commented on GitHub (Apr 3, 2019):
Nope i'm on 1.8 (rc2 now).
@mike-jl commented on GitHub (Apr 10, 2019):
Just tried #6478 and it definitely solves this issue 👍
@typeless commented on GitHub (Apr 11, 2019):
Maybe we should have an optional setting in
app.inifor the absolute path ofgit?Edit:
Or even better (easier), Gitea can lookup the path of git first and then using the absolute path subsequently.
@lunny commented on GitHub (Apr 11, 2019):
@typeless We can give an option of git command, which could be an absolute path or not.
@typeless commented on GitHub (Apr 11, 2019):
@lunny If we decide to add an option, it would be better if this option is by default unset and optional.
Minimizing the "required" changes to configurations during installing Gitea is desirable.
@ve3 commented on GitHub (May 28, 2019):
I installed Gitea on Windows 10 pro. The main repository page with less than 50 files take me ...
I think it is too slow.
Here is the settings
@typeless commented on GitHub (May 29, 2019):
@ve3 A fix has already been merged for 1.9, which would help if it has the same root cause.
@Ziflin commented on GitHub (May 31, 2019):
I've got a similar issue (just switched from Windows 7 to Windows 10) and a repository with ~250 files and 5 commits is taking quite a bit longer now on Windows 10 Pro (close to 2x slower) with identical configs in Gitea and both using Sqlite3. The repositories do use Git LFS and maybe 20 files are LFS files, so I'm not sure if that's related. (I'm also using Git v2.21.0 and Gitea v1.8.2.)
I also checked on several of the repos on the Gitea test server (https://try.gitea.io/) and the times there for the main Repository pages are like Page: ~15-20ms and Template: ~2ms. Those are 100-200 times faster than what I'm seeing on my (newly installed) Windows 10 Pro machine on the same network using a SSD drive. I would certainly like the times to be closer to that for such a small repository :). It does look like for non-repository pages (such as the user profile page) I get maybe Page: 6-10ms and Template: 1-3ms
Is there a way to tell what is taking so long? I have similar options as @ve3 so everything should be "local".
Thanks!
@lunny commented on GitHub (Jun 1, 2019):
@Ziflin could you try gitea with mysql or other databases except sqlite3?
@Ziflin commented on GitHub (Jun 1, 2019):
@lunny Sorry, I'm not able to on this machine. One of the reasons we're using Gitea was the single file install. Is there a way to profile what's taking time apart from the Page and Template times?
@zeripath commented on GitHub (Jun 1, 2019):
You might find one of the 1.9 nighties quicker.
@Ziflin commented on GitHub (Jun 1, 2019):
@zeripath Are those prebuilt somewhere or do I need to build it myself?
@sapk commented on GitHub (Jun 1, 2019):
@Ziflin you can found the binary here: https://dl.gitea.io/gitea/master/ and there is a pprof export to diagnose botleneck but it is not well documented. https://github.com/go-gitea/gitea/issues/6240
@Ziflin commented on GitHub (Jun 1, 2019):
@sapk and @zeripath I just tested the latest v1.9.0 and that seems to have fixed my issues. What was taking:
Page: 1420msandTemplate: 430+msIs now taking:
Page: 19msandTemplate: 4msSo whatever happened in v1.9 seems to have fixed it. All I did was copy over the old exe with the new one.
Thanks!
@zeripath commented on GitHub (Jun 1, 2019):
You should thank @filipnavara
@Ziflin commented on GitHub (Jun 1, 2019):
Hehe, well thanks @filipnavara! That was a great improvement!
@stale[bot] commented on GitHub (Jul 31, 2019):
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs during the next 2 weeks. Thank you for your contributions.