Personally, i think that using dates (or other form of timestamps) in filenames is not necessarily a good idea: the advantage of knowing when it was created/last modified without relying on inode information is somewhat alleviated by the unability to restrict the creation of files to a certain number of generations.
The usual case is like this: create a daily backup and keep a certain number of generations (say: 5). One option is to create a script creating a timestamp-named output file and then another script to delete the 6th-oldest such file (if it exists). Run both scripts daily. Possible problem: the second script is oftenly forgotten and the backups fill up your diskspace.
Another option is to create a file with a fixed name and apply logic to rename this file until a name for deletion is reached after a certain number of generations:
Advantage: you only need one script and you never have to bother with a process filling up your diskspace with numbers of old backups.
Ok so once again im back with what is probably a beginner question although somewhat more complicated (for me) than the last.
Background:
A client has a daily backup which is carried out via rsync.
Due to this, when they move a file around that file is then coppied a second time.
On top of... (4 Replies)
Hi guys iv been working on a bit of script to do a backup and restore
Im going to uni next year and trying to prepare myself
Basically all im wanting is a simple script that shows a menu and does what ever the user inputs
here is my code
#!/bin/sh
# Backup des
backup= "/root/Russell/"... (2 Replies)
Hi Everyone,
we are running rsync with --backup mode, Are there any rsync options to remove backup folders on successful deployment?
Thanks in adv. (0 Replies)
Hello,
I am facing a very strange problem when I run my script manuallu ./Fetchcode which is using to connect with MKS integrity from linux end it workks fine but when I run it from cron it doesn't work.Can someone help me
1) How could I check my script when it is running from cron like... (3 Replies)
Help. My script is working fine when executed manually but the cron seems not to catch up the command when registered.
The script is as follow:
#!/bin/sh
for file in file_1.txt file_2.txt file_3.txt
do
awk '{ print "0" }' $file > tmp.tmp
mv tmp.tmp $file
done
And the cron... (2 Replies)
HI all, im new to shell scripting. need your guidence for my script. i wrote one script and is attached here
Im explaining the requirement of script.
AIM: Shell script to run automatically as per scheduled and backup few network devices configurations. Script will contain a set of commands... (4 Replies)
We are taking backup of our application data(cobol file system, AIX/unix) before and after EOD job runs. The data size is approximately 260 GB in biggest branch. To reduce the backup time, 5 parallel execution is scheduled through control-m which backups up the files in 5 different *.gz. The job... (2 Replies)
We are taking backup of our application data(cobol file system, AIX/unix) before and after EOD job runs. The data size is approximately 260 GB in biggest branch. To reduce the backup time, 5 parallel execution is scheduled through control-m which backups up the files in 5 different *.gz. The job... (8 Replies)
I am having one heck of a time, and I need anyone that can assist in finding my issue here....
First off, here is the script we are using:
pastebin dot com slash njwUg6vd
All usernames and passwords have been edited out. We are using an actual database user, and not root (tried both).
I... (0 Replies)
Hi All,
During my virtual machine power on i have rc3.d script to accept user inputs like IP address. This script gets executed during first time boot up. It was working fine till my VM is using RHEL6.5. Now we migrated to RHEL 7 environment. While accepting the user inputs in console, I... (4 Replies)
Discussion started by: kalpeer
4 Replies
LEARN ABOUT DEBIAN
seivot
SEIVOT(1) General Commands Manual SEIVOT(1)NAME
seivot - benchmark backup application (obnam)
SYNOPSIS
seivot [--benchmark-fsck] [--config=FILE] [--description=TEXT] [--drop-caches] [--dump-config] [--dump-memory-profile=METHOD]
[--dump-setting-names] [--encrypt-with=KEYID] [--file-size=SIZE] [--generate-manpage=TEMPLATE] [--generations=COUNT] [-h] [--help]
[--incremental-data=SIZE] [--initial-data=SIZE] [--larch-branch=LARCH-BRANCH] [--list-config-files] [--log=FILE] [--log-keep=N]
[--log-level=LEVEL] [--log-max=SIZE] [--log-mode=MODE] [--no-default-configs] [--obnam-branch=OBNAM-BRANCH] [--obnam-config=FILE]
[--obnam-profile=NAMEPATTERN] [--output=FILE] [--profile-name=PROFILE-NAME] [--program=PROGRAM] [--sftp-delay=SFTP-DELAY]
[--use-existing=DIR] [--use-sftp-repository] [--use-sftp-root] [--verify] [--version] [FILE]...
DESCRIPTION
seivot benchmarks a backup application. It has been written primarily for obnam(1), but could be extended for other backup applications.
seivot generates some live data using genbackupdata(1), and then runs the backup application. It then generates some more live data, and
runs a second backup generation, etc. It stores the measurements in an output file. See seivots-summary(1) for a tool to show data from
such files in a tabular fashion. (seivot does not itself show the tabular data, because one is rarely interested in the output from just
one run, and instead wants to contrast it with other runs).
OPTIONS --benchmark-fsck
benchmark fsck?
--config=FILE
add FILE to config files
--description=TEXT
free-form description of this backup run
--drop-caches
clear Linux kernel cache before running commands (will ask for sudo pasword
--dump-config
write out the entire current configuration
--dump-memory-profile=METHOD
make memory profiling dumps using METHOD, which is one of: none, simple, meliae, or heapy (default: simple)
--dump-setting-names
write out all names of settings and quit
--encrypt-with=KEYID
encrypt backups with KEYID
--file-size=SIZE
size of files to create
--generate-manpage=TEMPLATE
fill in manual page TEMPLATE
--generations=COUNT
total number of generations to measure (5)
-h, --help
show this help message and exit
--incremental-data=SIZE
add SIZE live data for additional generations (1024)
--initial-data=SIZE
size of initial live data (1024)
--larch-branch=LARCH-BRANCH
bzr branch from which to use larch (default is installed larch)
--list-config-files
list all possible config files
--log=FILE
write log entries to FILE (default is to not write log files at all); use "syslog" to log to system log, or "none" to disable log-
ging
--log-keep=N
keep last N logs (10)
--log-level=LEVEL
log at LEVEL, one of debug, info, warning, error, critical, fatal (default: debug)
--log-max=SIZE
rotate logs larger than SIZE, zero for never (default: 0)
--log-mode=MODE
set permissions of new log files to MODE (octal; default 0600)
--no-default-configs
clear list of configuration files to read
--obnam-branch=OBNAM-BRANCH
bzr branch from which to run obnam (default is installed obnam)
--obnam-config=FILE
use FILE as an Obnam configuration file
--obnam-profile=NAMEPATTERN
store Python profiling output in files named after NAMEPATTERN (no profiling, unless set); %(foo)s in pattern gets filled in, where
foo is op (for backup/restore/etc), gen, or order (cumulative/time)
--output=FILE
write output to FILE, instead of standard output
--profile-name=PROFILE-NAME
name of backup use-case profile name (for documentation purposes only)
--program=PROGRAM
program to benchmark (obnam)
--sftp-delay=SFTP-DELAY
add an artificial delay (in milliseconds) to all SFTP transfers
--use-existing=DIR
use exiting DIR for initial generation
--use-sftp-repository
access backup repository over the network via sftp
--use-sftp-root
access backup repository over the network via sftp
--verify
verify restored data
--version
show program's version number and exit
EXAMPLE
To run a simple benchmark:
seivot --initial-data=10G --incremental-data=1G
SEE ALSO seivots-summary(1), obnam(1).
SEIVOT(1)