janeczku / janeczku/docker-dropbox
Continuous file Updates when running two containers to the same folder
- Dominant language
- Shell
- Stars
- 154
- Forks
- 125
- PR merge metrics
- No merged PRs in 30d
Description
Hallo, i have the following problem.
First: System Ubuntu 18.04, Docker version 19.03.2, build 6a30dfc
I have two dropboxes wich i want to sync. So i run two containers:
`docker run -d --restart=always --name=dropbox1 -v /home/user/dropbox:/dbox/Dropbox janeczku/dropbox`
`docker run -d --restart=always --name=dropbox2 -v /home/user/dropbox:/dbox/Dropbox janeczku/dropbox`
I link the two containers to two different accounts. Then i stop both containers and start the first one. When only one container runs everything works just fine. I see my dropbox files in /home/user/dropbox/ - wich is currently only test1.txt - and i see the same file on my Windows PC. Then is start the second container. When the container is up and running the File gets deleted and resyncd on my Windows PC. In the /home/user/dropbox/ folder the file stays but it constantly gets a new "changed" timestamp. When i look at the timestamps it looks the following:
_stat test1.txt
File: test1.txt
Size: 6 Blocks: 8 IO Block: 4096 regular file
Device: 802h/2050d Inode: 18087944 Links: 1
Access: (0644/-rw-r--r--) Uid: ( 1000/ user) Gid: ( 1000/ user)
Access: 2019-09-12 12:58:48.075353393 +0200
Modify: 2019-09-12 10:22:06.000000000 +0200
**Change: 2019-09-12 13:10:21.815200862 +0200**_
4 Seconds later:
_stat test1.txt
File: test1.txt
Size: 6 Blocks: 8 IO Block: 4096 regular file
Device: 802h/2050d Inode: 18087944 Links: 1
Access: (0644/-rw-r--r--) Uid: ( 1000/ user) Gid: ( 1000/ user)
Access: 2019-09-12 12:58:48.075353393 +0200
Modify: 2019-09-12 10:22:06.000000000 +0200
**Change: 2019-09-12 13:10:25.311231190 +0200**_
The Change timestamp is updated:
**Change: 2019-09-12 13:10:25.311231190 +0200
Change: 2019-09-12 13:10:28.915262385 +0200**
And so on. The Problem is that my Windows PC deletes the file and redownloads the "new" but unchanged file. For more Files and bigger folders this is an even bigger problem and messes up the data.
Has anyone a solution?
Contributor guide
No contributing guide indexed for this repository
Research direction
Reproduce the report with the two docker run commands and the shared /home/user/dropbox:/dbox/Dropbox mount, then inspect the file timestamps while both containers run. Trace which container behavior repeatedly changes ctime without changing content; done means the shared folder no longer causes repeated resyncs.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- docker
- Domain
- devops
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100