[GH-ISSUE #2316] permission denied when moving tasks #6634

Closed
opened 2026-04-20 17:13:42 -05:00 by GiteaMirror · 16 comments
Owner

Originally created by @cheetah747 on GitHub (Feb 28, 2026).
Original GitHub issue: https://github.com/go-vikunja/vikunja/issues/2316

Pre-submission checklist

  • I have searched for existing open or closed issue reports with the same problem.

Description

  • When I drag a task to the top first position, an error popup "Internal Server Error" appears in the bottom left corner of the browser. When I drag another task to the top first position, another error "Position repair requires full view recalculation" pops up.

  • The "Internal Server Error" is always reproducible.

  • I press F12 and it shows error :Failed to load resource: the server responded with a status of 500(Internal Server Error)

  • v2.0.0~v2.1.0 both have this problem

Vikunja Version

v2.0.0 and v2.1.0

Browser and version

Windows 11 Chrome 141.0.7390.108,Android Kiwi Browser 124.0.6327.4

Can you reproduce the bug on the Vikunja demo site?

No

Screenshots

Image

Image

Originally created by @cheetah747 on GitHub (Feb 28, 2026). Original GitHub issue: https://github.com/go-vikunja/vikunja/issues/2316 ### Pre-submission checklist - [x] I have searched for existing open or closed issue reports with the same problem. ### Description - When I drag a task to the top first position, an error popup "Internal Server Error" appears in the bottom left corner of the browser. When I drag another task to the top first position, another error "Position repair requires full view recalculation" pops up. - The "Internal Server Error" is always reproducible. - I press F12 and it shows error :Failed to load resource: the server responded with a status of 500(Internal Server Error) - v2.0.0~v2.1.0 both have this problem ### Vikunja Version v2.0.0 and v2.1.0 ### Browser and version Windows 11 Chrome 141.0.7390.108,Android Kiwi Browser 124.0.6327.4 ### Can you reproduce the bug on the Vikunja demo site? No ### Screenshots ![Image](https://github.com/user-attachments/assets/887e2579-6c80-4cc7-8401-bf241ff9467c) ![Image](https://github.com/user-attachments/assets/706001e7-15f5-43d9-b0ad-b80f622961e0)
Author
Owner

@kolaente commented on GitHub (Mar 2, 2026):

What do you see in the server logs?

Error 500 always means something on the server went wrong.

<!-- gh-comment-id:3982562592 --> @kolaente commented on GitHub (Mar 2, 2026): What do you see in the server logs? Error 500 always means something on the server went wrong.
Author
Owner

@cheetah747 commented on GitHub (Mar 2, 2026):

What do you see in the server logs?

Error 500 always means something on the server went wrong.

this is my log:

2026-03-02 18:20:00
time=2026-03-02T10:20:00.464Z level=ERROR component=http method=POST uri=/api/v1/tasks/1098/position status=500 latency=108.508287ms err="disk I/O error: permission denied"
2026-03-02 18:19:54
time=2026-03-02T10:19:54.715Z level=ERROR component=http method=POST uri=/api/v1/tasks/1098/position status=500 latency=113.095432ms err="disk I/O error: permission denied"
2026-03-02 18:17:07
time=2026-03-02T10:17:07.442Z level=ERROR component=http method=POST uri=/api/v1/tasks/1098/position status=500 latency=121.726452ms err="disk I/O error: permission denied"
2026-03-02 18:17:03
time=2026-03-02T10:17:03.614Z level=ERROR component=http method=POST uri=/api/v1/tasks/2285/position status=500 latency=12.165936ms err="Insufficient spacing for localized repair [ProjectViewID: 5]"
2026-03-02 18:16:58
time=2026-03-02T10:16:58.597Z level=ERROR component=http method=POST uri=/api/v1/tasks/1098/position status=500 latency=93.99322ms err="disk I/O error: permission denied"

I have set this:

chown 1000:1000 $PWD/files
chown 1000:1000 $PWD/db

This problem did not exist in previous versions

<!-- gh-comment-id:3983491599 --> @cheetah747 commented on GitHub (Mar 2, 2026): > What do you see in the server logs? > > Error 500 always means something on the server went wrong. this is my log: ``` 2026-03-02 18:20:00 time=2026-03-02T10:20:00.464Z level=ERROR component=http method=POST uri=/api/v1/tasks/1098/position status=500 latency=108.508287ms err="disk I/O error: permission denied" 2026-03-02 18:19:54 time=2026-03-02T10:19:54.715Z level=ERROR component=http method=POST uri=/api/v1/tasks/1098/position status=500 latency=113.095432ms err="disk I/O error: permission denied" 2026-03-02 18:17:07 time=2026-03-02T10:17:07.442Z level=ERROR component=http method=POST uri=/api/v1/tasks/1098/position status=500 latency=121.726452ms err="disk I/O error: permission denied" 2026-03-02 18:17:03 time=2026-03-02T10:17:03.614Z level=ERROR component=http method=POST uri=/api/v1/tasks/2285/position status=500 latency=12.165936ms err="Insufficient spacing for localized repair [ProjectViewID: 5]" 2026-03-02 18:16:58 time=2026-03-02T10:16:58.597Z level=ERROR component=http method=POST uri=/api/v1/tasks/1098/position status=500 latency=93.99322ms err="disk I/O error: permission denied" ``` I have set this: ``` chown 1000:1000 $PWD/files chown 1000:1000 $PWD/db ``` This problem did not exist in previous versions
Author
Owner

@kolaente commented on GitHub (Mar 2, 2026):

Can you post the output of vikunja doctor?

<!-- gh-comment-id:3983525250 --> @kolaente commented on GitHub (Mar 2, 2026): Can you post the output of `vikunja doctor`?
Author
Owner

@cheetah747 commented on GitHub (Mar 2, 2026):

Can you post the output of vikunja doctor?

# docker exec -it vikunja_vikunja /app/vikunja/vikunja  doctor
2026/03/02 10:51:47 failed to create modcache index dir: mkdir /.cache: permission denied
time=2026-03-02T10:51:47.056Z level=INFO msg="Using config file: /etc/vikunja/config.yml"
time=2026-03-02T10:51:47.057Z level=INFO msg="Using SQLite database at: /db/vikunja.db"
Vikunja Doctor
==============

System
  ✓ Version: v2.1.0
  ✓ Go: go1.25.6
  ✓ OS: linux/amd64
  ✓ User: unknown (uid=1000)
  ✓ Working directory: /app/vikunja
  ✓ User namespace: not active

Configuration
  ✓ Config file: /etc/vikunja/config.yml
  ✗ Public URL: not configured (required for many features)
  ✓ JWT secret: configured (auto-generated)

Database (sqlite)
  ✓ Connection: OK
  ✓ Server version: 3.51.1

Files (local)
  ✓ Path: /app/vikunja/files
  ✓ Directory exists: yes
  ✓ Directory permissions: 0755
  ✓ Directory owner: 1000:1000 (uid=1000, gid=1000)
  ✗ Ownership match: directory owned by gid 1000 but Vikunja process is not a member of that group
  ✓ Writable: yes
  ✓ Disk space: 361.3 GB available
  ✓ Stored files: 136 files, 19.6 MB total

Mailer
  ✓ SMTP connection: OK (smtp.qq.com:465)

2 check(s) failed

<!-- gh-comment-id:3983624451 --> @cheetah747 commented on GitHub (Mar 2, 2026): > Can you post the output of `vikunja doctor`? ``` # docker exec -it vikunja_vikunja /app/vikunja/vikunja doctor 2026/03/02 10:51:47 failed to create modcache index dir: mkdir /.cache: permission denied time=2026-03-02T10:51:47.056Z level=INFO msg="Using config file: /etc/vikunja/config.yml" time=2026-03-02T10:51:47.057Z level=INFO msg="Using SQLite database at: /db/vikunja.db" Vikunja Doctor ============== System ✓ Version: v2.1.0 ✓ Go: go1.25.6 ✓ OS: linux/amd64 ✓ User: unknown (uid=1000) ✓ Working directory: /app/vikunja ✓ User namespace: not active Configuration ✓ Config file: /etc/vikunja/config.yml ✗ Public URL: not configured (required for many features) ✓ JWT secret: configured (auto-generated) Database (sqlite) ✓ Connection: OK ✓ Server version: 3.51.1 Files (local) ✓ Path: /app/vikunja/files ✓ Directory exists: yes ✓ Directory permissions: 0755 ✓ Directory owner: 1000:1000 (uid=1000, gid=1000) ✗ Ownership match: directory owned by gid 1000 but Vikunja process is not a member of that group ✓ Writable: yes ✓ Disk space: 361.3 GB available ✓ Stored files: 136 files, 19.6 MB total Mailer ✓ SMTP connection: OK (smtp.qq.com:465) 2 check(s) failed ```
Author
Owner

@kolaente commented on GitHub (Mar 2, 2026):

And this only happens when moving tasks? everyhting else works fine?=

<!-- gh-comment-id:3983752569 --> @kolaente commented on GitHub (Mar 2, 2026): And this only happens when moving tasks? everyhting else works fine?=
Author
Owner

@cheetah747 commented on GitHub (Mar 2, 2026):

Yes, this 500 error currently seems to only occur when dragging a task.

There is also a 401 error.After I drag a task (regardless of whether an error occurs or not) and then log out, the following 401 error is reported. However, if I log out without dragging any tasks after logging in, this does not happen. Everything else is currently working fine.

Image Image
<!-- gh-comment-id:3983825954 --> @cheetah747 commented on GitHub (Mar 2, 2026): Yes, this 500 error currently seems to only occur when dragging a task. There is also a 401 error.After I drag a task (regardless of whether an error occurs or not) and then log out, the following 401 error is reported. However, if I log out without dragging any tasks after logging in, this does not happen. Everything else is currently working fine. <img width="605" height="349" alt="Image" src="https://github.com/user-attachments/assets/0f25667f-bf00-40a0-a6c9-9c5bf4440822" /> <img width="1222" height="632" alt="Image" src="https://github.com/user-attachments/assets/03a5f019-c505-4e76-804b-482f23a053af" />
Author
Owner

@cernst72 commented on GitHub (Mar 2, 2026):

I have the same issue when dragging tasks in the list view (500 + disk I/O error: permission denied in the logs).

Additionally, I have a similar issue when creating a New Saved Filter. The web app says: "Internal Server Error" and the logs say: level=ERROR component=http method=PUT uri=/api/v1/filters status=500 latency=50.03006ms err="disk I/O error: permission denied.
Other write operations are possible, so it doesn't seem to be a general problem with the environment config.

I am using vikunja:2.1.0 with sqlite backend. I can't reproduce it on try.

<!-- gh-comment-id:3985573138 --> @cernst72 commented on GitHub (Mar 2, 2026): I have the same issue when dragging tasks in the list view (500 + `disk I/O error: permission denied` in the logs). Additionally, I have a similar issue when creating a New Saved Filter. The web app says: "Internal Server Error" and the logs say: `level=ERROR component=http method=PUT uri=/api/v1/filters status=500 latency=50.03006ms err="disk I/O error: permission denied`. Other write operations are possible, so it doesn't seem to be a general problem with the environment config. I am using vikunja:2.1.0 with sqlite backend. I can't reproduce it on try.
Author
Owner

@fritzbauer commented on GitHub (Mar 4, 2026):

I have the same issue when creating tasks from the startpage (and via the API if I do not pass the position parameter or set its value to 0). Creating tasks from the projects view is working fine. I traced the network logs and saw that on the startpage it sends "position: 0" and on the projects pages it sends the positions parameter with an actual value.

Notably this issue only started yesterday for me although I ran the nightlies the days before and this issue has been created already 4 days ago.

I had the same ownership error in vikunja doctor and was able to fix it by setting "user: "1000:1000" in the docker-compose.yml. Now vikunja doctor shows green checkmarks for every entry, but the problem continues.

time=2026-03-04T12:57:02.517Z level=ERROR component=http method=PUT uri=/api/v1/projects/1/tasks status=500 latency=8.607536ms err="disk I/O error: permission denied"

Can't reproduce on try.

<!-- gh-comment-id:3997390994 --> @fritzbauer commented on GitHub (Mar 4, 2026): I have the same issue when creating tasks from the startpage (and via the API if I do not pass the position parameter or set its value to 0). Creating tasks from the projects view is working fine. I traced the network logs and saw that on the startpage it sends "position: 0" and on the projects pages it sends the positions parameter with an actual value. Notably this issue only started yesterday for me although I ran the nightlies the days before and this issue has been created already 4 days ago. I had the same ownership error in vikunja doctor and was able to fix it by setting "user: "1000:1000" in the docker-compose.yml. Now vikunja doctor shows green checkmarks for every entry, but the problem continues. `time=2026-03-04T12:57:02.517Z level=ERROR component=http method=PUT uri=/api/v1/projects/1/tasks status=500 latency=8.607536ms err="disk I/O error: permission denied"` Can't reproduce on try.
Author
Owner

@cernst72 commented on GitHub (Mar 4, 2026):

And are you able to create a new Saved Filter?
My instance always fails, since yesterday.
The log (with activated Database Logging) indicates a large transaction starting with INSERT INTO saved_filter and ending with INSERT INTO task_positions which then fails without further reason:

ut_vikunja.1.kmbk2dlpbyjh@xxxx   | time=2026-03-04T16:38:18.367+01:00 level=INFO msg="[SQL] ROLLBACK [] - 12.619µs" component=database
ut_vikunja.1.kmbk2dlpbyjh@xxxx    | time=2026-03-04T16:38:18.367+01:00 level=ERROR component=http method=PUT uri=/api/v1/filters status=500 latency=8.436127ms err="disk I/O error: permission denied"

Further infos:

  • Sqlite Backend
  • Happens in :2.1.0, :unstable from yesterday and meanwhile even in :2.0.0
  • Like @fritzbauer observed, it started ~yesterday
<!-- gh-comment-id:3998390682 --> @cernst72 commented on GitHub (Mar 4, 2026): And are you able to create a new Saved Filter? My instance always fails, since yesterday. The log (with activated Database Logging) indicates a large transaction starting with `INSERT INTO saved_filter` and ending with `INSERT INTO task_positions` which then fails without further reason: ``` ut_vikunja.1.kmbk2dlpbyjh@xxxx | time=2026-03-04T16:38:18.367+01:00 level=INFO msg="[SQL] ROLLBACK [] - 12.619µs" component=database ut_vikunja.1.kmbk2dlpbyjh@xxxx | time=2026-03-04T16:38:18.367+01:00 level=ERROR component=http method=PUT uri=/api/v1/filters status=500 latency=8.436127ms err="disk I/O error: permission denied" ``` Further infos: - Sqlite Backend - Happens in :2.1.0, :unstable from yesterday and meanwhile even in :2.0.0 - Like @fritzbauer observed, it started ~yesterday
Author
Owner

@kolaente commented on GitHub (Mar 4, 2026):

Are you all using sqlite?

<!-- gh-comment-id:4000614963 --> @kolaente commented on GitHub (Mar 4, 2026): Are you all using sqlite?
Author
Owner

@cheetah747 commented on GitHub (Mar 4, 2026):

Are you all using sqlite?

Yes,I‘m using default sqlite.

<!-- gh-comment-id:4000994632 --> @cheetah747 commented on GitHub (Mar 4, 2026): > Are you all using sqlite? Yes,I‘m using default sqlite.
Author
Owner

@fritzbauer commented on GitHub (Mar 5, 2026):

Yes, also using sqlite.

And are you able to create a new Saved Filter?

Just tested. No I am not able to create a new Saved Filter.
Also observed that it is not possible to create tasks for all projects, only for some. The workaround to create a task in a "working" project and moving it to a "broken" project also does not work.

<!-- gh-comment-id:4002311542 --> @fritzbauer commented on GitHub (Mar 5, 2026): Yes, also using sqlite. > And are you able to create a new Saved Filter? Just tested. No I am not able to create a new Saved Filter. Also observed that it is not possible to create tasks for all projects, only for some. The workaround to create a task in a "working" project and moving it to a "broken" project also does not work.
Author
Owner

@fritzbauer commented on GitHub (Mar 8, 2026):

I suspect this commit: 84d563c51b
It seems sqlite tries to access a tmpdir which is not writable.
Setting tmpdir to a writable path in my docker-compose.yml fixes it for me :)
TMPDIR: /db/tmp

<!-- gh-comment-id:4019581360 --> @fritzbauer commented on GitHub (Mar 8, 2026): I suspect this commit: https://github.com/go-vikunja/vikunja/commit/84d563c51b6cd15000f4af6e058362c5e45c8dc2 It seems sqlite tries to access a tmpdir which is not writable. Setting tmpdir to a writable path in my docker-compose.yml fixes it for me :) TMPDIR: /db/tmp
Author
Owner

@eikaramba commented on GitHub (Mar 8, 2026):

same problem. the fix was indeed to add the TMPDIR env variable and also to create the folder on the host and make it writable:

env variables:

TMPDIR=/db/tmp

i didn't need to add a volume because /db already was set. but i needed to create the tmp folder and edit permissions

chown 1000:1000 ~/vikunja/db/tmp

<!-- gh-comment-id:4019870399 --> @eikaramba commented on GitHub (Mar 8, 2026): same problem. the fix was indeed to add the TMPDIR env variable and also to create the folder on the host and make it writable: ### env variables: TMPDIR=/db/tmp ### i didn't need to add a volume because /db already was set. but i needed to create the tmp folder and edit permissions chown 1000:1000 ~/vikunja/db/tmp
Author
Owner

@cernst72 commented on GitHub (Mar 8, 2026):

Same here: Setting environment variable in docker-compose

TMPDIR: /app/vikunja/files/tmp

solved my problems. Thanks @fritzbauer!

Could this workaround be included to the DOCKERFILE, @kolaente?

<!-- gh-comment-id:4019968622 --> @cernst72 commented on GitHub (Mar 8, 2026): Same here: Setting environment variable in docker-compose ``` TMPDIR: /app/vikunja/files/tmp ``` solved my problems. Thanks @fritzbauer! Could this workaround be included to the DOCKERFILE, @kolaente?
Author
Owner

@vikunja-bot-app[bot] commented on GitHub (Mar 10, 2026):

This issue has been fixed in #2384, please check with the next unstable build (should be ready for deployment in ~30min, also on the demo).

<!-- gh-comment-id:4034843911 --> @vikunja-bot-app[bot] commented on GitHub (Mar 10, 2026): This issue has been fixed in #2384, please check with the next unstable build (should be ready for deployment in ~30min, also on [the demo](https://try.vikunja.io)).
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/vikunja#6634