Rozdíly
Zde můžete vidět rozdíly mezi vybranou verzí a aktuální verzí dané stránky.
dev:mohlo_by_se_hodit [19.01.2015 20:12] ritchie [Definice max_lag] |
dev:mohlo_by_se_hodit [19.01.2015 20:23] (aktuální) ritchie zalohovani db bez restartu mt serveru |
||
---|---|---|---|
Řádek 75: | Řádek 75: | ||
> | > | ||
>Err, it's kind of complicated isn't it :/ max_lag is not really useful from a client's perspective at all because there is nothing the client can do about it. It's really more useful for people running a server and tuning server-side values. Even then, because max_lag is a weighted average (in effect) using a fixed value for the weight it's uses are (currently) limited (IMO) | >Err, it's kind of complicated isn't it :/ max_lag is not really useful from a client's perspective at all because there is nothing the client can do about it. It's really more useful for people running a server and tuning server-side values. Even then, because max_lag is a weighted average (in effect) using a fixed value for the weight it's uses are (currently) limited (IMO) | ||
+ | |||
+ | ==== Zálohování DB bez restartu MT serveru ==== | ||
+ | |||
+ | http://irc.minetest.ru/minetest/2015-01-19#i_4121156 | ||
+ | |||
+ | vitaminx: | ||
+ | >btw. i just found a method to safely backup map.sqlite *without* stopping the server | ||
+ | >create a file called "backup.sql" and put this inside: | ||
+ | <code> | ||
+ | begin immediate; | ||
+ | .shell cp $HOME/.minetest/worlds/world/map.sqlite $HOME/map.sqlite_backup | ||
+ | rollback; | ||
+ | </code> | ||
+ | >then tell your backup script to execute this line: | ||
+ | <code> | ||
+ | echo ".read backup.sql" | sqlite3 -echo .minetest/worlds/world/map.sqlite | ||
+ | </code> | ||
+ | >DB stays consistent and user stay logged in - they probably notice a short lag while the DB file is copied, thats all | ||
+ | twoelk: | ||
+ | >vitaminx: doesn't rollback freeze youre server? | ||
+ | vitaminx: | ||
+ | >it gets a lock on the DB, so minetest has to wait with it's writes - thats what I mean with short lag | ||
+ | >i will test it today, lets see if its really noticeable | ||
+ | >having a short lag is probably still better then to disconnect all players | ||
+ |