Internal server error on Repository creation #1928

Closed
opened 2025-11-02 04:18:05 -06:00 by GiteaMirror · 2 comments
Owner

Originally created by @w2ak on GitHub (Jun 13, 2018).

  • Gitea version (or commit ref): 6efdcae
  • Git version: 2.15.2
  • Operating system:
    • docker-compose version 1.21.2, build a133471
    • Docker version 18.03.1-ce, build 9ee9f40
    • Ubuntu 16.04.4 LTS
  • Database (use [x]):
    • PostgreSQL
    • MySQL
    • MSSQL
    • SQLite
  • Can you reproduce the bug at https://try.gitea.io:
    • Yes (provide example URL)
    • No
    • Not relevant (I think)

Description

I tried creating my first repository from the admin and only account of my instance.

I got an Internal server error, the log says

srv_1  | 2018/06/13 05:31:46 [I] [SQL] INSERT INTO `action` (`user_id`,`op_type`,`act_user_id`,`repo_id`,`comment_id`,`is_deleted`,`ref_name`,`is_private`,`content`,`created_unix`) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?) []interface {}{1, 1, 1, 1, 0, false, "", false, "", 1528867906}
srv_1  | [git-module] /data/git/repositories/neze/test.git: git init --bare
srv_1  | 2018/06/13 05:31:46 [I] [SQL] ROLL BACK
srv_1  | 2018/06/13 05:31:46 [...routers/repo/repo.go:146 handleCreateError()] [E] CreatePost: initRepository: InitRepository: chdir /data/git/repositories/neze/test.git: no such file or directory
srv_1  | [Macaron] 2018-06-13 05:31:46: Completed POST /repo/create 404 Not Found in 87.509081ms

However, if I just docker-compose restart, repository creation starts working.

What kind of test or information can I give you to help?

Thank you very much!

Originally created by @w2ak on GitHub (Jun 13, 2018). - Gitea version (or commit ref): 6efdcae - Git version: 2.15.2 - Operating system: - docker-compose version 1.21.2, build a133471 - Docker version 18.03.1-ce, build 9ee9f40 - Ubuntu 16.04.4 LTS - Database (use `[x]`): - [ ] PostgreSQL - [ ] MySQL - [ ] MSSQL - [x] SQLite - Can you reproduce the bug at https://try.gitea.io: - [ ] Yes (provide example URL) - [ ] No - [x] Not relevant (I think) ## Description I tried creating my first repository from the admin and only account of my instance. I got an Internal server error, the log says ``` srv_1 | 2018/06/13 05:31:46 [I] [SQL] INSERT INTO `action` (`user_id`,`op_type`,`act_user_id`,`repo_id`,`comment_id`,`is_deleted`,`ref_name`,`is_private`,`content`,`created_unix`) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?) []interface {}{1, 1, 1, 1, 0, false, "", false, "", 1528867906} srv_1 | [git-module] /data/git/repositories/neze/test.git: git init --bare srv_1 | 2018/06/13 05:31:46 [I] [SQL] ROLL BACK srv_1 | 2018/06/13 05:31:46 [...routers/repo/repo.go:146 handleCreateError()] [E] CreatePost: initRepository: InitRepository: chdir /data/git/repositories/neze/test.git: no such file or directory srv_1 | [Macaron] 2018-06-13 05:31:46: Completed POST /repo/create 404 Not Found in 87.509081ms ``` However, if I just `docker-compose restart`, repository creation starts working. What kind of test or information can I give you to help? Thank you very much!
GiteaMirror added the type/question label 2025-11-02 04:18:05 -06:00
Author
Owner

@w2ak commented on GitHub (Jun 13, 2018):

Note that the logs for the second time show stdout for the git-module:

srv_1  | [git-module] /data/git/repositories/neze/test.git: git init --bare
srv_1  | [git-module] stdout:
srv_1  | Initialized empty Git repository in /data/git/repositories/neze/test.git/
srv_1  |

srv_1  | 2018/06/13 05:33:53 [I] [SQL] SELECT `id`, `owner_id`, `lower_name`, `name`, `description`, `website`, `default_branch`, `num_watches`, `n
um_stars`, `num_forks`, `num_issues`, `num_closed_issues`, `num_pulls`, `num_closed_pulls`, `num_milestones`, `num_closed_milestones`, `is_private`, `is_bare`,
`is_mirror`, `is_fork`, `fork_id`, `size`, `is_fsck_enabled`, `topics`, `created_unix`, `updated_unix` FROM `repository` WHERE `id`=? LIMIT 1 []interface {}{1}

srv_1  | 2018/06/13 05:33:53 [I] [SQL] UPDATE `repository` SET `owner_id` = ?, `lower_name` = ?, `name` = ?, `description` = ?, `website` = ?, `def
ault_branch` = ?, `num_watches` = ?, `num_stars` = ?, `num_forks` = ?, `num_issues` = ?, `num_closed_issues` = ?, `num_pulls` = ?, `num_closed_pulls` = ?, `num_
milestones` = ?, `num_closed_milestones` = ?, `is_private` = ?, `is_bare` = ?, `is_mirror` = ?, `is_fork` = ?, `fork_id` = ?, `size` = ?, `is_fsck_enabled` = ?,
 `topics` = ?, `updated_unix` = ? WHERE `id`=? []interface {}{1, "test", "test", "", "", "master", 1, 0, 0, 0, 0, 0, 0, 0, 0, false, true, false, false, 0, 0, f
alse, "null", 1528868033, 1}
srv_1  | 2018/06/13 05:33:53 [I] [SQL] COMMIT
srv_1  | [Macaron] 2018-06-13 05:33:53: Completed POST /repo/create 302 Found in 16.799017ms
@w2ak commented on GitHub (Jun 13, 2018): Note that the logs for the second time show stdout for the `git-module`: ``` srv_1 | [git-module] /data/git/repositories/neze/test.git: git init --bare srv_1 | [git-module] stdout: srv_1 | Initialized empty Git repository in /data/git/repositories/neze/test.git/ srv_1 | srv_1 | 2018/06/13 05:33:53 [I] [SQL] SELECT `id`, `owner_id`, `lower_name`, `name`, `description`, `website`, `default_branch`, `num_watches`, `n um_stars`, `num_forks`, `num_issues`, `num_closed_issues`, `num_pulls`, `num_closed_pulls`, `num_milestones`, `num_closed_milestones`, `is_private`, `is_bare`, `is_mirror`, `is_fork`, `fork_id`, `size`, `is_fsck_enabled`, `topics`, `created_unix`, `updated_unix` FROM `repository` WHERE `id`=? LIMIT 1 []interface {}{1} srv_1 | 2018/06/13 05:33:53 [I] [SQL] UPDATE `repository` SET `owner_id` = ?, `lower_name` = ?, `name` = ?, `description` = ?, `website` = ?, `def ault_branch` = ?, `num_watches` = ?, `num_stars` = ?, `num_forks` = ?, `num_issues` = ?, `num_closed_issues` = ?, `num_pulls` = ?, `num_closed_pulls` = ?, `num_ milestones` = ?, `num_closed_milestones` = ?, `is_private` = ?, `is_bare` = ?, `is_mirror` = ?, `is_fork` = ?, `fork_id` = ?, `size` = ?, `is_fsck_enabled` = ?, `topics` = ?, `updated_unix` = ? WHERE `id`=? []interface {}{1, "test", "test", "", "", "master", 1, 0, 0, 0, 0, 0, 0, 0, 0, false, true, false, false, 0, 0, f alse, "null", 1528868033, 1} srv_1 | 2018/06/13 05:33:53 [I] [SQL] COMMIT srv_1 | [Macaron] 2018-06-13 05:33:53: Completed POST /repo/create 302 Found in 16.799017ms ```
Author
Owner

@lafriks commented on GitHub (Jun 19, 2018):

Looks like there was problem when creating repository directory first time, hard to tell why

@lafriks commented on GitHub (Jun 19, 2018): Looks like there was problem when creating repository directory first time, hard to tell why
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/gitea#1928