Comments (8)
You can inform this option in your configuration file using 'additional_options' like this:
adapter :mysql do
user 'user'
password 'password'
database 'database'
skip_tables ['table1', 'table2', 'table3']
options do
host '123.45.678.90'
port '80'
socket '/tmp/socket.sock'
end
additional_options '--single-transaction'
end
from backup.
This isn't really an issue, but we could perhaps just implement that this is default behavior. What are the pros en cons of using --single-transaction
?
from backup.
As far as I know you almost always want to use
additional_options '--single-transaction --quick'
if your database supports transactions (mysql does)
from backup.
Thanks for pointing that out, I will mark this as a consideration. Might be a good idea set these options as defaults.
from backup.
Mysql doesn't support transactions, some storage engine does, like InnoDB. I don't think this option should be enabled by default, because other people uses other storage engines.
from backup.
Good point, I did not know that. In that case it's not wise to set it as default since it will literally break MySQL adapter for some users.
I guess the commented out template in the backup configuration file will be enough to point out the option IS available but needs to be activated: additional_options '--single-transaction'
.
We could additionally add this that line: --quick
so it would make: --single-transaction --quick
.
from backup.
I will add the --single-transaction --quick
to the generated template, but leave it commented out. Maybe add a comment that tell it to uncomment this line if the database is large so that it doesn't lock tables and such, but that it isn't supported for all storage engines.
from backup.
That sounds like a great idea. Thanks.
from backup.
Related Issues (20)
- New release HOT 3
- Local storage rotation keeps trying to delete an old backup that doesn't exist anymore HOT 3
- OpenSSL encryptor: deprecated key derivation used HOT 4
- Fails to build under Ruby 2.4.0 (duplicate but with solution)
- Backup-ng has been forked! HOT 1
- `dogapi` dependency using old version of `json` gem, breaking install HOT 9
- Storage configuration for Minio (S3) HOT 3
- add variable date in file HOT 1
- Error installing atomic HOT 1
- Upgrade docs for v5 HOT 1
- Error dumping tablespaces HOT 4
- Logger::Logfile::Error: Log File at '/root/Backup/log/backup.log' is not writable HOT 1
- Support as Docker Container HOT 2
- Keep not working with S3 HOT 5
- Not working in Ruby 3.1 HOT 5
- toc.dat is not being packed in the postgres tarball HOT 1
- RAILS 7 cannot use backup version 4.x HOT 1
- Ruby 3.2.2 not working HOT 3
- gzip: stdin: invalid compressed data--format violated HOT 2
- Error when building native extensions - Ubuntu 22.04 HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from backup.