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

Push failed. Can't delete temp index file. Warning on service stop #18691

Closed
bota87 opened this issue Feb 9, 2022 · 31 comments
Closed

Push failed. Can't delete temp index file. Warning on service stop #18691

bota87 opened this issue Feb 9, 2022 · 31 comments
Labels
issue/needs-feedback For bugs, we need more details. For features, the feature must be described in more detail

Comments

@bota87
Copy link

bota87 commented Feb 9, 2022

Gitea Version

1.16.1

Git Version

2.35.1.windows.2

Operating System

Windows server 2012

How are you running Gitea?

Gitea is running as a windows service, it's installed with the package gitea-1.16.1-windows-4.0-amd64.exe

Database

SQLite

Can you reproduce the bug on the Gitea demo site?

No

Log Gist

No response

Description

Often the push from a client to the gitea remote get stuck for a lot of time.
Looking at the log I found this

2022/02/09 15:57:49 ...es/git/repo_index.go:59:func1() [E] failed to remove tmp index file: remove C:\Windows\TEMP\index3937789675: Impossibile accedere al file. Il file è utilizzato da un altro processo.
2022/02/09 16:55:04 ...es/git/repo_index.go:59:func1() [E] failed to remove tmp index file: remove C:\Windows\TEMP\index1770678566: Impossibile accedere al file. Il file è utilizzato da un altro processo.
2022/02/09 16:56:59 ...es/git/repo_index.go:59:func1() [E] failed to remove tmp index file: remove C:\Windows\TEMP\index3990406363: Impossibile accedere al file. Il file è utilizzato da un altro processo.
2022/02/09 17:00:57 ...eue/queue_channel.go:98:func1() [W] ChannelQueue: push_update-channel Terminated before completed flushing
2022/02/09 17:01:57 .../graceful/manager.go:226:doHammerTime() [W] Setting Hammer condition

This temp index folders are empty, I've tried to remove that but I can't until I stop the gitea service. This take a lot of time and sometime even fail and I have to terminate the gitea process from the task manager.
During the stop of the service this lines are added to the log, even after a restart without any remote push

2022/02/09 17:11:01 ...eue/queue_channel.go:98:func1() [W] ChannelQueue: task-channel Terminated before completed flushing
2022/02/09 17:11:01 ...eue/queue_channel.go:98:func1() [W] ChannelQueue: push_update-channel Terminated before completed flushing
2022/02/09 17:11:01 ...eue/queue_channel.go:98:func1() [W] ChannelQueue: notification-service-channel Terminated before completed flushing
2022/02/09 17:11:01 .../graceful/manager.go:226:doHammerTime() [W] Setting Hammer condition
2022/02/09 17:11:02 .../graceful/manager.go:243:doTerminate() [W] Terminating

Screenshots

No response

@zeripath
Copy link
Contributor

zeripath commented Feb 9, 2022

I'm having difficulty understanding what it is you're reporting.

I think you might be reporting a possible db deadlock. In which case it would be helpful to give us more logs.

@bota87
Copy link
Author

bota87 commented Feb 9, 2022

I posted all the log that I have. I try to set a more verbouse log level

@bota87
Copy link
Author

bota87 commented Feb 10, 2022

I set the log level to info, restarted the service, do a fetch from a client, stopped the service. Here the log
I tried the same without the fetch. Here the log

@zeripath
Copy link
Contributor

Logs

When you are reporting bugs or issues it is helpful to give us DEBUG logs.

In fact the issue proforma expressly asks you to do that and links to a helpful section of the documentation that to do that: https://docs.gitea.io/en-us/logging-configuration/#debugging-problems

I will copy that below:

Debugging problems

When submitting logs in Gitea issues it is often helpful to submit
merged logs obtained by either by redirecting the console log to a file or
copying and pasting it. To that end it is recommended to set your logging to:

[database]
LOG_SQL = false ; SQL logs are rarely helpful unless we specifically ask for them

...

[log]
MODE = console
LEVEL = debug ; please set the level to debug when we are debugging a problem
ROUTER = console
COLORIZE = false ; this can be true if you can strip out the ansi coloring

Sometimes it will be helpful get some specific TRACE level logging restricted
to messages that match a specific EXPRESSION. Adjusting the MODE in the
[log] section to MODE = console,traceconsole to add a new logger output
traceconsole and then adding its corresponding section would be helpful:

[log.traceconsole] ; traceconsole here is just a name
MODE = console ; this is the output that the traceconsole writes to
LEVEL = trace
EXPRESSION = ; putting a string here will restrict this logger to logging only those messages that match this expression

(It's worth noting that log messages that match the expression at or above debug
level will get logged twice so don't worry about that.)

STACKTRACE_LEVEL should generally be left unconfigured (and hence kept at
none). There are only very specific occasions when it useful.

@zeripath
Copy link
Contributor

zeripath commented Feb 10, 2022

From the small amount of logs you've given me it appears that Gitea is being shutdown externally.

This is likely by the windows service.

There was an older issue regarding this: #15762 but I'm not sure what's going on here.

@bota87
Copy link
Author

bota87 commented Feb 10, 2022

Hi @zeripath,
thank's for your help.

Here you can find the debug level log

@zeripath
Copy link
Contributor

Yup. Gitea is being shutdown by your windows service.

@bota87
Copy link
Author

bota87 commented Feb 10, 2022

I know that, I start and then stop the windows service.
I'm worried about this warnings on service stop, I think that are related to my issue with push get stuck, I'm wrong?

2022/02/09 17:11:01 ...eue/queue_channel.go:98:func1() [W] ChannelQueue: task-channel Terminated before completed flushing
2022/02/09 17:11:01 ...eue/queue_channel.go:98:func1() [W] ChannelQueue: push_update-channel Terminated before completed flushing
2022/02/09 17:11:01 ...eue/queue_channel.go:98:func1() [W] ChannelQueue: notification-service-channel Terminated before completed flushing

@bota87
Copy link
Author

bota87 commented Feb 10, 2022

Here the push client side, as you can see it fail after 2 minutes.

git.exe push --progress "origin" master:master
warning: ----------------- SECURITY WARNING ----------------
warning: | TLS certificate verification has been disabled! |
warning: ---------------------------------------------------
warning: HTTPS connections may not be secure. See https://aka.ms/gcm/tlsverify for more information.
warning: ----------------- SECURITY WARNING ----------------
warning: | TLS certificate verification has been disabled! |
warning: ---------------------------------------------------
warning: HTTPS connections may not be secure. See https://aka.ms/gcm/tlsverify for more information.
Total 0 (delta 0), reused 0 (delta 0), pack-reused 0
remote:
remote: Gitea: Internal Server Error
remote: * Checking 1 references
To https://192.168.90.44:3000/ComputerService/Procedura2007.git
! [remote rejected]   master -> master (pre-receive hook declined)
error: failed to push some refs to 'https://192.168.90.44:3000/ComputerService/Procedura2007.git'


git did not exit cleanly (exit code 1) (123406 ms @ 10/02/2022 11:12:37)

And the related gitea log

2022/02/10 10:25:33 ...xer/stats/indexer.go:85:populateRepoIndexer() [I] Done (re)populating the repo stats indexer with existing repositories
2022/02/10 10:25:34 cmd/web.go:208:listen() [I] Listen: https://0.0.0.0:3000
2022/02/10 10:25:34 cmd/web.go:212:listen() [I] AppURL(ROOT_URL): https://192.168.90.44:3000/
2022/02/10 10:25:34 cmd/web.go:215:listen() [I] LFS server enabled
2022/02/10 10:25:34 ...s/graceful/server.go:61:NewServer() [I] Starting new Web server: tcp:0.0.0.0:3000 on PID: 2704
2022/02/10 10:25:34 ...s/graceful/server.go:74:func1() [D] Starting server on tcp:0.0.0.0:3000 (PID: 2704)
2022/02/10 10:25:45 ...l/manager_windows.go:159:Execute() [D] Unexpected control request: 14
2022/02/10 10:45:19 ...dules/git/command.go:143:RunWithContext() [D] C:\gitea-repositories\computerservice\procedura2007.git: C:\Program Files\Git\cmd\git.exe -c credential.helper= -c protocol.version=2 -c uploadpack.allowfilter=true -c filter.lfs.required= -c filter.lfs.smudge= -c filter.lfs.clean= upload-pack --stateless-rpc --advertise-refs .
2022/02/10 10:56:27 ...dules/git/command.go:143:RunWithContext() [D] C:\gitea-repositories\computerservice\procedura2007.git: C:\Program Files\Git\cmd\git.exe -c credential.helper= -c protocol.version=2 -c uploadpack.allowfilter=true -c filter.lfs.required= -c filter.lfs.smudge= -c filter.lfs.clean= receive-pack --stateless-rpc --advertise-refs .
2022/02/10 10:57:03 ...l/manager_windows.go:159:Execute() [D] Unexpected control request: 14
2022/02/10 10:57:07 ...l/manager_windows.go:159:Execute() [D] Unexpected control request: 14
2022/02/10 10:57:07 ...l/manager_windows.go:159:Execute() [D] Unexpected control request: 14
2022/02/10 10:58:29 ...c/net/http/server.go:3160:logf() [I] http: TLS handshake error from [::1]:27412: read tcp [::1]:3000->[::1]:27412: wsarecv: Connessione interrotta dal software del computer host.
2022/02/10 10:58:29 ...c/net/http/server.go:3160:logf() [I] http: TLS handshake error from [::1]:27414: read tcp [::1]:3000->[::1]:27414: wsarecv: Connessione interrotta dal software del computer host.

@bota87
Copy link
Author

bota87 commented Feb 10, 2022

Hi tried the same push again without doing nothing client or server side and this time worked.

git.exe push --progress "origin" master:master
warning: ----------------- SECURITY WARNING ----------------
warning: | TLS certificate verification has been disabled! |
warning: ---------------------------------------------------
warning: HTTPS connections may not be secure. See https://aka.ms/gcm/tlsverify for more information.
warning: ----------------- SECURITY WARNING ----------------
warning: | TLS certificate verification has been disabled! |
warning: ---------------------------------------------------
warning: HTTPS connections may not be secure. See https://aka.ms/gcm/tlsverify for more information.
Total 0 (delta 0), reused 0 (delta 0), pack-reused 0
remote:
remote: Create a new pull request for 'master':
remote:   https://192.168.90.44:3000/ComputerService/Procedura2007/compare/develop...master
remote:
remote: . Processing 1 references
remote: Processed 1 references in total
To https://192.168.90.44:3000/ComputerService/Procedura2007.git
07100bc6..42c0df05  master -> master

Success (3110 ms @ 10/02/2022 11:18:32)

gitea log

2022/02/10 10:58:29 ...c/net/http/server.go:3160:logf() [I] http: TLS handshake error from [::1]:27412: read tcp [::1]:3000->[::1]:27412: wsarecv: Connessione interrotta dal software del computer host.
2022/02/10 10:58:29 ...c/net/http/server.go:3160:logf() [I] http: TLS handshake error from [::1]:27414: read tcp [::1]:3000->[::1]:27414: wsarecv: Connessione interrotta dal software del computer host.
2022/02/10 11:04:22 ...dules/git/command.go:143:RunWithContext() [D] C:\gitea-repositories\computerservice\procedura2007.git: C:\Program Files\Git\cmd\git.exe -c credential.helper= -c protocol.version=2 -c uploadpack.allowfilter=true -c filter.lfs.required= -c filter.lfs.smudge= -c filter.lfs.clean= receive-pack --stateless-rpc --advertise-refs .
2022/02/10 11:04:23 ...dules/git/command.go:143:RunWithContext() [D] C:\gitea-repositories\computerservice\procedura2007.git: C:\Program Files\Git\cmd\git.exe -c credential.helper= -c protocol.version=2 -c uploadpack.allowfilter=true -c filter.lfs.required= -c filter.lfs.smudge= -c filter.lfs.clean= rev-parse
2022/02/10 11:04:23 ...dules/git/command.go:143:RunWithContext() [D] C:\gitea-repositories\computerservice\procedura2007.git: C:\Program Files\Git\cmd\git.exe -c credential.helper= -c protocol.version=2 -c uploadpack.allowfilter=true -c filter.lfs.required= -c filter.lfs.smudge= -c filter.lfs.clean= cat-file --batch
2022/02/10 11:04:23 ...dules/git/command.go:143:RunWithContext() [D] C:\gitea-repositories\computerservice\procedura2007.git: C:\Program Files\Git\cmd\git.exe -c credential.helper= -c protocol.version=2 -c uploadpack.allowfilter=true -c filter.lfs.required= -c filter.lfs.smudge= -c filter.lfs.clean= cat-file --batch-check
2022/02/10 11:04:23 ...dules/git/command.go:143:RunWithContext() [D] C:\gitea-repositories\computerservice\procedura2007.git: C:\Program Files\Git\cmd\git.exe -c credential.helper= -c protocol.version=2 -c uploadpack.allowfilter=true -c filter.lfs.required= -c filter.lfs.smudge= -c filter.lfs.clean= rev-list --max-count=1 07100bc6eef5ca74a3cf5cc47506737bd0108ab9 ^42c0df0544833fba6da10a7a87a7e52a2acdde47
2022/02/10 11:04:24 .../queue/workerpool.go:98:zeroBoost() [D] WorkerPool: 1 (for push_update-channel) has zero workers - adding 1 temporary workers for 5m0s
2022/02/10 11:04:24 ...dules/git/command.go:143:RunWithContext() [D] C:\gitea-repositories\computerservice\procedura2007.git: C:\Program Files\Git\cmd\git.exe -c credential.helper= -c protocol.version=2 -c uploadpack.allowfilter=true -c filter.lfs.required= -c filter.lfs.smudge= -c filter.lfs.clean= rev-parse
2022/02/10 11:04:24 ...dules/git/command.go:143:RunWithContext() [D] C:\gitea-repositories\computerservice\procedura2007.git: C:\Program Files\Git\cmd\git.exe -c credential.helper= -c protocol.version=2 -c uploadpack.allowfilter=true -c filter.lfs.required= -c filter.lfs.smudge= -c filter.lfs.clean= cat-file --batch
2022/02/10 11:04:24 ...dules/git/command.go:143:RunWithContext() [D] C:\gitea-repositories\computerservice\procedura2007.git: C:\Program Files\Git\cmd\git.exe -c credential.helper= -c protocol.version=2 -c uploadpack.allowfilter=true -c filter.lfs.required= -c filter.lfs.smudge= -c filter.lfs.clean= cat-file --batch-check
2022/02/10 11:04:24 ...dules/git/command.go:143:RunWithContext() [D] C:\gitea-repositories\computerservice\procedura2007.git: C:\Program Files\Git\cmd\git.exe -c credential.helper= -c protocol.version=2 -c uploadpack.allowfilter=true -c filter.lfs.required= -c filter.lfs.smudge= -c filter.lfs.clean= rev-parse
2022/02/10 11:04:24 ...dules/git/command.go:143:RunWithContext() [D] C:\gitea-repositories\computerservice\procedura2007.git: C:\Program Files\Git\cmd\git.exe -c credential.helper= -c protocol.version=2 -c uploadpack.allowfilter=true -c filter.lfs.required= -c filter.lfs.smudge= -c filter.lfs.clean= rev-list 07100bc6eef5ca74a3cf5cc47506737bd0108ab9..42c0df0544833fba6da10a7a87a7e52a2acdde47
2022/02/10 11:04:24 ...dules/git/command.go:143:RunWithContext() [D] C:\gitea-repositories\computerservice\procedura2007.git: C:\Program Files\Git\cmd\git.exe -c credential.helper= -c protocol.version=2 -c uploadpack.allowfilter=true -c filter.lfs.required= -c filter.lfs.smudge= -c filter.lfs.clean= cat-file --batch
2022/02/10 11:04:24 ...dules/git/command.go:143:RunWithContext() [D] C:\gitea-repositories\computerservice\procedura2007.git: C:\Program Files\Git\cmd\git.exe -c credential.helper= -c protocol.version=2 -c uploadpack.allowfilter=true -c filter.lfs.required= -c filter.lfs.smudge= -c filter.lfs.clean= cat-file --batch-check
2022/02/10 11:04:24 ...dules/git/command.go:143:RunWithContext() [D] C:\gitea-repositories\computerservice\procedura2007.git: C:\Program Files\Git\cmd\git.exe -c credential.helper= -c protocol.version=2 -c uploadpack.allowfilter=true -c filter.lfs.required= -c filter.lfs.smudge= -c filter.lfs.clean= rev-list --max-count=1 07100bc6eef5ca74a3cf5cc47506737bd0108ab9 ^42c0df0544833fba6da10a7a87a7e52a2acdde47
2022/02/10 11:04:24 .../queue/workerpool.go:98:zeroBoost() [D] WorkerPool: 14 (for repo_stats_update-channel) has zero workers - adding 1 temporary workers for 5m0s
2022/02/10 11:04:24 ...dules/git/command.go:143:RunWithContext() [D] C:\gitea-repositories\computerservice\procedura2007.git: C:\Program Files\Git\cmd\git.exe -c credential.helper= -c protocol.version=2 -c uploadpack.allowfilter=true -c filter.lfs.required= -c filter.lfs.smudge= -c filter.lfs.clean= log --name-status -c --pretty=format: --parents --no-renames -z -1 42c0df0544833fba6da10a7a87a7e52a2acdde47
2022/02/10 11:04:24 ...dules/git/command.go:143:RunWithContext() [D] C:\gitea-repositories\computerservice\procedura2007.git: C:\Program Files\Git\cmd\git.exe -c credential.helper= -c protocol.version=2 -c uploadpack.allowfilter=true -c filter.lfs.required= -c filter.lfs.smudge= -c filter.lfs.clean= log --name-status -c --pretty=format: --parents --no-renames -z -1 3329427e1e44c293246aaf1804cb4405494adb26
2022/02/10 11:04:24 ...dules/git/command.go:143:RunWithContext() [D] C:\gitea-repositories\computerservice\procedura2007.git: C:\Program Files\Git\cmd\git.exe -c credential.helper= -c protocol.version=2 -c uploadpack.allowfilter=true -c filter.lfs.required= -c filter.lfs.smudge= -c filter.lfs.clean= log --name-status -c --pretty=format: --parents --no-renames -z -1 8742a70d56fd56cdccf9bdee2c2291c10ff39587
2022/02/10 11:04:25 ...dules/git/command.go:143:RunWithContext() [D] C:\gitea-repositories\computerservice\procedura2007.git: C:\Program Files\Git\cmd\git.exe -c credential.helper= -c protocol.version=2 -c uploadpack.allowfilter=true -c filter.lfs.required= -c filter.lfs.smudge= -c filter.lfs.clean= rev-list --count 42c0df0544833fba6da10a7a87a7e52a2acdde47
2022/02/10 11:04:25 ...dules/git/command.go:143:RunWithContext() [D] C:\gitea-repositories\computerservice\procedura2007.git: C:\Program Files\Git\cmd\git.exe -c credential.helper= -c protocol.version=2 -c uploadpack.allowfilter=true -c filter.lfs.required= -c filter.lfs.smudge= -c filter.lfs.clean= log --name-status -c --format=commit%x00%H %P%x00 --parents --no-renames -t -z 42c0df0544833fba6da10a7a87a7e52a2acdde47 -- .gitignore ConversioneDB FORMS MEDIACAT Icone Installazione Promedia Script ScriptClassi Utilita' Comuni
2022/02/10 11:04:25 ...last_commit_cache.go:32:Put() [D] LastCommitCache save: [42c0df0544833fba6da10a7a87a7e52a2acdde47:Promedia:42c0df0544833fba6da10a7a87a7e52a2acdde47]
2022/02/10 11:04:25 ...last_commit_cache.go:32:Put() [D] LastCommitCache save: [42c0df0544833fba6da10a7a87a7e52a2acdde47::42c0df0544833fba6da10a7a87a7e52a2acdde47]
2022/02/10 11:04:25 ...last_commit_cache.go:32:Put() [D] LastCommitCache save: [42c0df0544833fba6da10a7a87a7e52a2acdde47:ScriptClassi:90e5b3c568681e2031da7795c1e8b55c7903ff57]
2022/02/10 11:04:25 ...dules/git/command.go:143:RunWithContext() [D] C:\gitea-repositories\computerservice\procedura2007.git: C:\Program Files\Git\cmd\git.exe -c credential.helper= -c protocol.version=2 -c uploadpack.allowfilter=true -c filter.lfs.required= -c filter.lfs.smudge= -c filter.lfs.clean= log --name-status -c --format=commit%x00%H %P%x00 --parents --no-renames -t -z 90e5b3c568681e2031da7795c1e8b55c7903ff57 -- .gitignore ConversioneDB FORMS MEDIACAT Icone Installazione Script Utilita' Comuni
2022/02/10 11:04:25 ...dules/git/command.go:143:RunWithContext() [D] C:\gitea-repositories\computerservice\procedura2007.git: C:\Program Files\Git\cmd\git.exe -c credential.helper= -c protocol.version=2 -c uploadpack.allowfilter=true -c filter.lfs.required= -c filter.lfs.smudge= -c filter.lfs.clean= rev-parse
2022/02/10 11:04:25 ...dules/git/command.go:143:RunWithContext() [D] C:\gitea-repositories\computerservice\procedura2007.git: C:\Program Files\Git\cmd\git.exe -c credential.helper= -c protocol.version=2 -c uploadpack.allowfilter=true -c filter.lfs.required= -c filter.lfs.smudge= -c filter.lfs.clean= cat-file --batch-check
2022/02/10 11:04:25 ...dules/git/command.go:143:RunWithContext() [D] C:\gitea-repositories\computerservice\procedura2007.git: C:\Program Files\Git\cmd\git.exe -c credential.helper= -c protocol.version=2 -c uploadpack.allowfilter=true -c filter.lfs.required= -c filter.lfs.smudge= -c filter.lfs.clean= cat-file --batch
2022/02/10 11:04:25 ...last_commit_cache.go:32:Put() [D] LastCommitCache save: [42c0df0544833fba6da10a7a87a7e52a2acdde47:Utilita' Comuni:6346ddcbc645b48932324354e1ea7776816937e8]
2022/02/10 11:04:25 ...last_commit_cache.go:32:Put() [D] LastCommitCache save: [42c0df0544833fba6da10a7a87a7e52a2acdde47:Script:f1932810b42c73a03ce8af9823591f1da053da83]
2022/02/10 11:04:25 ...dules/git/command.go:143:RunWithContext() [D] C:\gitea-repositories\computerservice\procedura2007.git: C:\Program Files\Git\cmd\git.exe -c credential.helper= -c protocol.version=2 -c uploadpack.allowfilter=true -c filter.lfs.required= -c filter.lfs.smudge= -c filter.lfs.clean= log --name-status -c --format=commit%x00%H %P%x00 --parents --no-renames -t -z f1932810b42c73a03ce8af9823591f1da053da83 -- .gitignore ConversioneDB FORMS MEDIACAT Icone Installazione
2022/02/10 11:04:25 ...last_commit_cache.go:32:Put() [D] LastCommitCache save: [42c0df0544833fba6da10a7a87a7e52a2acdde47:.gitignore:0b1894276de6da952fda043fa8e2ef7cbddbcb85]
2022/02/10 11:04:25 ...last_commit_cache.go:32:Put() [D] LastCommitCache save: [42c0df0544833fba6da10a7a87a7e52a2acdde47:Installazione:639bac5993209618cf01394bf62d6b870ab56fce]
2022/02/10 11:04:25 ...dules/git/command.go:143:RunWithContext() [D] C:\gitea-repositories\computerservice\procedura2007.git: C:\Program Files\Git\cmd\git.exe -c credential.helper= -c protocol.version=2 -c uploadpack.allowfilter=true -c filter.lfs.required= -c filter.lfs.smudge= -c filter.lfs.clean= log --name-status -c --format=commit%x00%H %P%x00 --parents --no-renames -t -z 639bac5993209618cf01394bf62d6b870ab56fce -- ConversioneDB FORMS MEDIACAT Icone
2022/02/10 11:04:25 ...last_commit_cache.go:32:Put() [D] LastCommitCache save: [42c0df0544833fba6da10a7a87a7e52a2acdde47:FORMS MEDIACAT:a73f28477e14ff93783c0a16819d20b6ca3db96f]
2022/02/10 11:04:25 ...dules/git/command.go:143:RunWithContext() [D] C:\gitea-repositories\computerservice\procedura2007.git: C:\Program Files\Git\cmd\git.exe -c credential.helper= -c protocol.version=2 -c uploadpack.allowfilter=true -c filter.lfs.required= -c filter.lfs.smudge= -c filter.lfs.clean= log --name-status -c --format=commit%x00%H %P%x00 --parents --no-renames -t -z a73f28477e14ff93783c0a16819d20b6ca3db96f -- ConversioneDB Icone
2022/02/10 11:04:25 ...last_commit_cache.go:32:Put() [D] LastCommitCache save: [42c0df0544833fba6da10a7a87a7e52a2acdde47:Icone:88ca210e902bb58931c7a89c5f5af2c28036bdf9]
2022/02/10 11:04:25 ...dules/git/command.go:143:RunWithContext() [D] C:\gitea-repositories\computerservice\procedura2007.git: C:\Program Files\Git\cmd\git.exe -c credential.helper= -c protocol.version=2 -c uploadpack.allowfilter=true -c filter.lfs.required= -c filter.lfs.smudge= -c filter.lfs.clean= log --name-status -c --format=commit%x00%H %P%x00 --parents --no-renames -t -z 88ca210e902bb58931c7a89c5f5af2c28036bdf9 -- ConversioneDB
2022/02/10 11:04:25 ...last_commit_cache.go:32:Put() [D] LastCommitCache save: [42c0df0544833fba6da10a7a87a7e52a2acdde47:ConversioneDB:8f30670857c33cadda40946d50e59d587938d915]
2022/02/10 11:06:23 ...dules/git/command.go:143:RunWithContext() [D] C:\gitea-repositories\computerservice\procedura2005net.git: C:\Program Files\Git\cmd\git.exe -c credential.helper= -c protocol.version=2 -c uploadpack.allowfilter=true -c filter.lfs.required= -c filter.lfs.smudge= -c filter.lfs.clean= upload-pack --stateless-rpc --advertise-refs .

@zeripath
Copy link
Contributor

  1. Could you try the latest 1.16 head
  2. What is your app.ini [log] section? I do not see any router logs in here. I need to see these.

@bota87
Copy link
Author

bota87 commented Feb 10, 2022

There is a package for the latest 1.16 head?
I missed to add the router entry on the app.ini, now I think it's right

[log]
ROOT_PATH = C:/Program Files/Gitea/log
MODE      = file
LEVEL     = debug
ROUTER    = file

In the mean time I got the failed to remove tmp index file again. Here the log

@bota87
Copy link
Author

bota87 commented Feb 10, 2022

Here the log with the router entry, got the failed to remove tmp index file again

@bota87
Copy link
Author

bota87 commented Feb 10, 2022

If can be usefull the client that cause this info message is windows 11, with windows 10 this dosen't appear
[I] http: TLS handshake error from 192.168.213.3:52009: tls: no cipher suite supported by both client and server

@zeripath
Copy link
Contributor

So I need to see the router.log file too. (This is why the documentation says use MODE=console so that the router logs will be interleaved...)

Anyway... I think that's telling you what the problem is...

https://docs.gitea.io/en-us/config-cheat-sheet/#server-server

Take a look at [server] section and the following settings:

SSL_MIN_VERSION
SSL_MAX_VERSION
SSL_CURVE_PREFERENCES
SSL_CIPHER_SUITES

It would be useful to know if you've set a LOCAL_ROOT_URL and to know what the rest of your app.ini looks like.

At present I don't know if the problem is that Gitea can't talk to itself or if it's git that can't talk to Gitea. The Router logs would help a little with that.

@bota87
Copy link
Author

bota87 commented Feb 10, 2022

Sorry, I didn't know that router log go in a different file. Router.log
I try to set console on MODE and run outside the service to have interleaved log.
I haven't set any of the SSL_* key you mentioned and I haven't set LOCAL_ROOT_URL. Here the app.ini

@zeripath zeripath added the issue/needs-feedback For bugs, we need more details. For features, the feature must be described in more detail label Feb 10, 2022
@bota87
Copy link
Author

bota87 commented Feb 11, 2022

@zeripath I have some logs for you.
The first one show the gitea service stuck at 17:00, I tried to push a branch, notice the unresponsive remote (even the website) then I stopped the service with CTRL+C

After that I restarted the service and tried to push again, this time the server respond but after 2 minutes I got a timeout, I retried again and in 3 seconds the push succeded. Here the client git output, here the gitea log

@bota87
Copy link
Author

bota87 commented Feb 15, 2022

Today the service was stuck again. Here the logs

@zeripath
Copy link
Contributor

hmm... I wonder if this is related to #18734 would it be possible to try the latest 1.16 head https://dl.gitea.io/gitea/1.16?

@bota87
Copy link
Author

bota87 commented Feb 15, 2022

ok I installed the latest 1.16 head, let see how it go.
Before the upgrade I made a backup and got this warning

2022/02/15 12:04:56 cmd/dump.go:262:func2() [W] Unable to remove temporary file: C:\Users\ADMINI~1\AppData\Local\Temp\gitea-db.sql2521112428: Error: remove C:\Users\ADMINI~1\AppData\Local\Temp\gitea-db.sql2521112428: Impossibile accedere al file. Il file è utilizzato da un altro processo.

Complete logs here

@bota87
Copy link
Author

bota87 commented Feb 16, 2022

Unfortunately even with the latest version the server sometime is unresponding.
This time I tried a push, in the mean time I tried to access to the repository website but this times out, after 2 minutes even the push times out, then I tried the push again and as usual it was completed in seconds. Here the logs

@lunny
Copy link
Member

lunny commented Feb 16, 2022

2022/02/16 10:36:32 ...age_stats_nogogit.go:86:func2() [E] Unable to open checker for b26640e9e7dd1caa223607712b0cea986c127833. Error: failed to run attr-check.
 Error: exit status 1
        Stderr:

Looks like it's still related with #18754 .

@bota87
Copy link
Author

bota87 commented Feb 23, 2022

Hi @lunny,
today I got again the timeout on the push, after the timeout I tried to push again and worked in few seconds
2022/02/23 10:09:40 ...c/net/http/server.go:3160:logf() [I] http: TLS handshake error from [::1]:48498: read tcp [::1]:3000->[::1]:48498: wsarecv: Connessione interrotta dal software del computer host.
Here the complete logs

@bota87
Copy link
Author

bota87 commented Feb 23, 2022

Got again the open checker error and then the push timeouts

2022/02/23 16:38:34 ...age_stats_nogogit.go:86:func2() [E] Unable to open checker for 7259fc298bcd5d32dfb69fd6c615ca8cb5aa9b23. Error: failed to run attr-check.
 Error: exit status 1
        Stderr:
...
2022/02/23 17:04:59 ...c/net/http/server.go:3160:logf() [I] http: TLS handshake error from [::1]:49008: read tcp [::1]:3000->[::1]:49008: wsarecv: Connessione i
nterrotta dal software del computer host.

Logs

@bota87
Copy link
Author

bota87 commented Apr 8, 2022

Any news on this?
@lunny @zeripath

@wxiaoguang
Copy link
Contributor

Many different issues are mixed here. I would like to guess:

  • The log [E] failed to remove tmp index file: remove C:\Windows\TEMP\index3937789675 is that Gitea tried to delete some temp files but these files are not closed properly. On Windows, the not-closed files might not be deleted.
    • Since these logs are printed when Gitea stops, it isn't related to the "Push Failed" problem.
  • The log [E] Unable to open checker for 7259fc298bcd5d32dfb69fd6c615ca8cb5aa9b23. Error: failed to run attr-check., it might be a bug, might not. Not sure whether it is related to the push failure.
  • The log [I] http: TLS handshake error from [::1]:49008: read tcp [::1]:3000->[::1]:49008:
    • it looks like you are using wrong protocol/host/port, it's highly likely related to the push failure.

ps: 1.16 is out dated.

As a suggestion, running Gitea on Windows doesn't seem to be a good idea. If you can use docker, you wouldn't have so many troubles.

If you can try 1.17 and provide reproducible steps from scratch (a fresh installation, all configs, all operations), it would be easier for others to help.

@bota87
Copy link
Author

bota87 commented Oct 7, 2022

Hi @wxiaoguang,
I've already updated to 1.17.2 some weeks ago but the issue still persist.
One of the reasons I chose Gitea was that it's easy to install on windows, anyway I tought to move on docker and probably I'll do that once I get really annoyed by this bug.

@wxiaoguang
Copy link
Contributor

Thanks for understanding.

Windows server 2012 seems quite old nowadays 😂 , while Git is a POSIX-based system, I have seen many issues of running Gitea on old Windows for large scale use (git compatibility problem, performance problem). And another challenge is that nowadays few Gitea contributors use Windows for production, so if Windows users can not provide details about bugs, it's really difficult to improve.

@bota87
Copy link
Author

bota87 commented Oct 7, 2022

Just moved the setup to another server with windows server 2019, let's see if there works without problems 🤞

@bota87
Copy link
Author

bota87 commented Oct 14, 2022

haven't had any problem on the last week since the server migration, seems fixed! 🥳

Thank's wxiaoguang

@bota87 bota87 closed this as completed Oct 14, 2022
@twisted-nematic57
Copy link

Lol so is this some kind of Windows 7 era specific bug, I can't afford newer hardware is there no way to fix the attr-check problem??

@go-gitea go-gitea locked and limited conversation to collaborators May 3, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
issue/needs-feedback For bugs, we need more details. For features, the feature must be described in more detail
Projects
None yet
Development

No branches or pull requests

5 participants