Nold360 / docker-borgbackup

13 stars 3 forks source link

Restore: Read-only file system (:ro) #1

Closed markuskonojacki closed 6 years ago

markuskonojacki commented 6 years ago

Hi, if you're using the recomended docker-compose.yml you'll get a problem if you try to restore.

   # Include every volume-Path you might want to backup!
   - "/var/lib/docker/:/var/lib/docker:ro"
-------- Borg Docker Backup --------
Global BORG_CREATE_OPTIONS: -s --progress
 ----> Starting Restore of Containter bookstack_mysql_1
 -> Pausing Container...
 -> Restoring Archive 'bookstack_mysql_1+2018-05-18_07:35'...
Warning: Attempting to access a previously unknown unencrypted repository!
Do you want to continue? [yN] yes (from BORG_UNKNOWN_UNENCRYPTED_REPO_ACCESS_IS_OK)
Warning: File system encoding is "ascii", extracting non-ascii filenames will not be supported.
Hint: You likely need to fix your locale setup. E.g. install locales and use: LANG=en_US.UTF-8
var/lib/docker/volumes/bookstack_mysql-data/_data/ib_buffer_pool: open: [Errno 30] Read-only file system: '/var/lib/docker/volumes/bookstack_mysql-dat$
var/lib/docker/volumes/bookstack_mysql-data/_data/ibtmp1: open: [Errno 30] Read-only file system: '/var/lib/docker/volumes/bookstack_mysql-data/_data/$
var/lib/docker/volumes/bookstack_mysql-data/_data/ibdata1: open: [Errno 30] Read-only file system: '/var/lib/docker/volumes/bookstack_mysql-data/_data$
var/lib/docker/volumes/bookstack_mysql-data/_data/ib_logfile0: open: [Errno 30] Read-only file system: '/var/lib/docker/volumes/bookstack_mysql-data/_$
# [...] many more lines
var/lib/docker/volumes/bookstack_mysql-data/_data: attrs: [Errno 30] Read-only file system: '/var/lib/docker/volumes/bookstack_mysql-data/_data'
 -> Restarting Container...
-> Restore Done!

You can't restore if you mount the volume :ro. Remove the :ro and it works like a charm. But could this have any unwanted consequences?

Nold360 commented 6 years ago

yea, sure every volume must be mounted read-write to restore. I'm just used to use "ro" by default somehow... ^^

fixed in 263817c4c793eb1526ecd07456048cb15770e562