You should arrange a regular backup of the Redmine database and the files that users upload/attach. The database can be dumped to a text file with:
where
The attachments are stashed in /var/lib/redmine/default/files and can be backed up with something like:
上面是分别在 terminal 输入命令进行备份。
可以直接写一个备份 shell 脚本,将数据库和文件都备份(数据库会有密码,备份的是redmine_defualt库)。
You can have these commands run automatically by creating a script called /etc/cron.daily/redmine that contains:
Again, be sure to substitute the mysql root password for in the mysqldump command line. The file should be protected so that only root has read permission because you are storing the root password for your mysql installation in this file. That the first line creates a new file every time the script is run. This can eventually create a large number of backups of your database files. You should have a script that purges old ones periodically.
没有评论:
发表评论