General :: Cp 'limit' Numbered Backups?

Mar 17, 2011

I currently use cp to backup data. I prefer it over rsync. I use the -b switch to make a backup of data and recently found you can use --backup=t to create numbered backups.Using --backup=t means that I could end up having 100 versions of a file if I change it 100 times. With the -b switch I will only ever have 2 versions. Is it possible to limit the numbered backups to 5 for example? So I would only ever have 5 versions?

View 2 Replies


ADVERTISEMENT

General :: Rsync Incremental Backups Rather Than Full Backups?

Nov 12, 2009

How do you get Rsync to do incremental backups rather than full backups? At the moment I have a script that will create a backup folder (if it doesnt already exist) then copy the source files into the backup directory with the command

rsync $VERBOSE --exclude=$TARGET/ $EXCLUDE --exclude '/Ls-wtgl1c8/**' -rt --delete $source/ $TARGET/$source/ >> $LOG_FILE

Target is where the files will be backed up to Sources is the dir(s) to be backed up Exclude files is the list of files not to backup
log file is where the output will be saved to. At the moment it only does full backups, but I would only like to do incremental, how would this be achieved? Am I missing out an option in the Rsync that is required.

View 9 Replies View Related

General :: Sed: Perform Replacement Only On Even-numbered Lines?

Jul 20, 2010

I'm sure this is possible but I can't figure it out. I have a file formatted like this:

Code:
>SEQUENCE1
FGFD665:?@663:BBBBAA?A@<<4!1004699<7444399>???888455555?AAA?AABBB@@@<<<34
>SEQUENCE2
>&<4!1004699<7444399>???888455555?AAA?AABBB@@@<<<34BBB@@
>SEQUENCE3
???888455555?AAA?AABBB@@@<<<341004699<7444399>???888BBB@@

The odd-numbered lines containing >SEQUENCE# are the headers and the even-numbered lines containing a variety of characters represent DNA sequence read quality scores.

I want to replace all of the greater-than (">") symbols in the quality scores (even-numbered lines) with a "0" but I want to leave the greater-than symbols on the odd-numbered lines alone. I would just use sed -i '/^>/! s/>/0/g' $FileName but sometimes the quality scores begin with a ">" as well.

I'm sure there is a simple modification of a normal sed command with an "n" inserted somewhere but I can't figure it out.

View 3 Replies View Related

General :: Command To Swap Even And Odd Numbered Lines In A File

May 28, 2010

I'm looking for a command to swap the even/odd numbered lines in a file. Example input file:

Code:

1
2
3
4

[code]...

Example output file:

Code:

2
1
4
3

[code]....

I'm sure there's a way to do it with sed, awk, grep and the like but it's been many years since I've used these commands on a daily basis and I can't seem to figure out the correct syntax.

View 2 Replies View Related

CentOS 5 :: Scheduled Unattended Backups With Alerts If The Backups Fail

Feb 3, 2011

I've been a DOS/Windows guy for 20 years, and recently became a SW test lab helper. My company uses CentOS for a lot, so I've become familiar with it, but obviously not as comfortable as I am with Windows.

Here's what I have planned:

machine: Core 2 Duo E8400, 8GB DDR2, 60GB SSD OS drive, ATI 4650 video card, other storage is flexible (I have 3 1TB drives and 4 750GB drives around that can be used in this machine.)

uses: HTPC, Network Storage, VMWare server host: SMTP, FTP server, and Web server virtual machines

I've figured out how to do much of this, but I haven't figured out how to do backups in Linux. I've been spoiled with Windows, with the built in backup system so simple to use. I find myself overwhelmed with the array of backup software, and unable to determine which to use. none of them seem to do everything I need them to do, but some come close, I think. I'm hoping someone here can help me out in figuring out which program to use and how to use it.

Here is what I need the backup software to do:
1. scheduled unattended backups, with alerts if the backups fail
2. a weekly full backup with incremental every 12 hours
3. removing the old backups when the new full backup runs, I would prefer to keep 2 weeks of backups, but that's not necessary
4. a GUI would be preferable, since my arthritic fingers don't always do as I want them to do. I typo things a lot, and the label worn off my backspace can attest to that.

View 7 Replies View Related

Software :: Pam_limits(sudo:session): Wrong Limit Value 'unlimited' For Limit Type 'soft'

Dec 28, 2010

my secure log is flooding with these messages..

sudo: pam_limits(sudo:session): wrong limit value 'unlimited' for limit type 'hard'
Dec 28 22:42:29 yn54 sudo: pam_limits(sudo:session): wrong limit value 'unlimited' for limit type 'soft'
Dec 28 22:42:29 yn54 sudo: pam_limits(sudo:session): wrong limit value 'unlimited' for limit type 'hard'

View 3 Replies View Related

Ubuntu :: Need To Correctly Sort Hex Numbered Files

Feb 5, 2011

I have some files, named E000.svg, E001.svg, E002.svg, ... E07D.svg, E07E.svg, E07F.svg . When I open them in Nautilus, and choose the option Sort Alphabetically, they are sorted:

E000.svg
E00A.svg
E00B.svg
E00C.svg
E00D.svg
E00E.svg
E00F.svg
E001.svg
E01A.svg
E01B.svg
and so on.

This is totally useless for me, so I searched for a solution in Google, and found lots of bug reports. It looks like it's a 'feature' for sorting 10 after 9; but clearly they have forgot that many people don't like or don't need that option. Thinking it was a Nautilus thing, I installed Thunar, but it has the exact useless algorithm. And then I installed PCManFM, but it's also the same. If I can install a file manager that correctly sorts my files? Or will I need to switch to Windows to have it fixed? (not joking here, Windows Explorer doesn't suffer from this feature).

View 9 Replies View Related

Ubuntu Installation :: Launch Bar Icons Numbered?

Feb 9, 2011

I have my 10.10 Unity completely installed, working just fine. I reboot and presto all of my launch bar icons have sequential numbers that weren't there before. Anyone know how to remove the numbers.

View 1 Replies View Related

Programming :: Show The Output Of These Fields In A Certain Way That Every Record Is Numbered?

Mar 25, 2010

i am reading a database flat file with the "awk" command which has 4 fields separated by colon ":" .I want to show the output of these fields in a certain way that every record is numbered e.g

1.some text
2.some text

Is there a way to do this?

View 14 Replies View Related

Server :: Limit The Suphp User Memory Limit?

May 12, 2010

I have a VPS server with 512 MB memory. The php.ini is set so script memory limit = 16 MB. However, I have noticed in my top report, instances like the following:

Quote:

5484 coldclim 25 0 46476 32m 5920 R 0.0 6.4 0:00.93 php

The bold number of 6.4 is the % of sever memory this process is using. 6.4 % of 512 MB of memory is about 32 MB of memory, so it appears that this isn't being limited by php.ini. Am I correct? This leads to the next question: Is there some way to limit the amount of memory a single suphp process can use? (Basically, something like the setting in php.ini which limits suphp processes in the same way.)

View 2 Replies View Related

Ubuntu Multimedia :: Join Ulitple .avi Files With A Numbered Extension?

Sep 19, 2010

This should be easy but despite all the hints and tricks I've read, I cannot make this work. I have 130+ files with the names filename.avi.001, filename.avi.002, filename.avi.003 all the way up to filname.avi.132. How do I join them? A simple cat command does not work, neither does avimerge or any other utility I can find. I'm guessing because the file extension is a number and not .avi. Is there and easy way to rename them all and then join them? I can't be the only one with this issue but I've scoured the forums and found nothing.

View 7 Replies View Related

General :: Automate Backups Over SSH On A Desktop?

Jun 7, 2011

I currently have a setup which allows me to connect to all computers on my home network via SSH and RSA keys. I'm very security-conscious, so all of my keys are passphrase protected. I'd like to essentially set something up where I'm running Unison on a cron job to back up to a file server on my network, which we'll call timmy. I've noticed that the first time I try to use a key on my Ubuntu laptop teeks, I get a dialog which pops up asking me to type in my key passphrase. I've heard that for servers needing to make automated backups like this that one should use ssh-agent to ask for the key passphrase on login/server start. How can I set this up on teeks?

I'd essentially like to have the following happen:When I boot and come into the OS, prompt visually for the passphrase as is done when I first use a key.If I SSH into this computer (as it's internet-facing) and I haven't provided the SSH passphrase yet, then prompt for it. (Sometimes, I might need to remotely reboot the machine over SSH, so I'll be SSH'ing into it after it reboots and I'd like to be able to authenticate the key without having to VNC in and do it manually.)

View 2 Replies View Related

General :: Rsync Not Doing Incremental Backups?

Jan 21, 2010

I am using rsync to backup dirs on my ubuntu server onto a NAS (which is mounted onto the filesystem), but the problem is that it is constantly doing full backups rather than doing incrementals and I am not really sure why. After doing a bit of expermienting with the script I noticed that if I just backed up a home dir (/home/user) the incremental backups work fine. If however I was to back up a dir like (/home/domain/user) it always does full backups.I have tried various different scripts but still the same end result. The latest script is a variation on the a script found on the samba rsync examples webpage, see below...

#!/bin/bash
# rsyncbu.sh -- backup to nas using rsync
# This script backups files listed in BDIR to the BSERVER. The verbose output along with the date is listed in the LOG_FILE specified
# verbose output

[code]....

View 4 Replies View Related

General :: Backups To External USB Drive?

Mar 1, 2010

I have a small IT consulting business and I am finding many of my clients couldn't afford Microsoft solutions and thus, going without... So a revelation hit me that I could offer Linux solutions, its just that I'm not a Linux guru... So after much research and installations of nearly every latest Linux distro, I decided on ClearOS as a good option for my clients that just require a good File/Print server, firewall and VPN solution... Everything was going fine until I got to the point where I was trying to get it to do backups to a USB drive... ClearOS does not come with the ability to do such, so from further research I found that I could install Webmin to handle that task and that it would not break ClearOS... Great, its just that its not working... It says its working, but its not.

[Code]...

Next I hit the "Save and Backup Now" button to test it out... all says it goes good... But when I check the device, there's nothing saved to it...

So I create another "Filesystem backup", I select the FlexShare directory that I want backed up and this time I select a local directory for the backup to go to... I hit the "Save and Backup Now" button to test it out. all says it goes good... But once again when I check the directory, there's nothing saved to it.

View 1 Replies View Related

General :: What Are Appropriate Filesystem Options For Backups

Mar 12, 2011

I have just purchased a 1 TB external hard disk to be used for backups. The backups will be performed with rsync and since I don't really care about accessing the data from other operating systems, I think I'll use ext3 on the partition. I'll just be backing up my home directory and probably /etc as well. In my home directory, I have a small number of files that are several GB, but most are tens of MB in size or less.

I'm just wondering if there are any special options I should pass when I create the filesystem with mkfs.ext3.

View 6 Replies View Related

General :: How To Do Backups To External USB Drive

Mar 3, 2010

I have a small IT consulting business and I am finding many of my clients couldn't afford Microsoft solutions and thus, going without... So a revelation hit me that I could offer Linux solutions, its just that I'm not a Linux guru... So after much research and installations of nearly every latest Linux distro, I decided on ClearOS as a good option for my clients that just require a good File/Print server, firewall and VPN solution... Everything was going fine until I got to the point where I was trying to get it to do backups to a USB drive... ClearOS does not come with the ability to do such, so from further research I found that I could install Webmin to handle that task and that it would not break ClearOS... Great, its just that its not working... It says its working, but its not...

So here's what I got, ClearOS 5.1 with Webmin 1.5

Here's what I have done to try to make it work after a good installation...

Under "Hardware" and "Partitions on Local Disks", it shows the USB drive as Device B... So I create a partion called "/dev/sdb1" Great, I'm thinking...

So I go to "System" and under "Filesystem backup", I select the FlexShare directory that I want backed up and then I select "/dev/sdb1" as the backup to device...

Next I hit the "Save and Backup Now" button to test it out... all says it goes good... But when I check the device, there's nothing saved to it...

So I create another "Filesystem backup", I select the FlexShare directory that I want backed up and this time I select a local directory for the backup to go to... I hit the "Save and Backup Now" button to test it out... all says it goes good... But once again when I check the directory, there's nothing saved to it...

View 3 Replies View Related

General :: Nightly Bootable Backups Using Dd?

Nov 19, 2010

I am a Mac user since 1988. I recently discovered Linux Ubuntu and love it. So much that I use it about 95% of the time. On the Mac there is an application I use called Superduper which makes a bootable backup to an external USB drive.

Can I do the same kind of thing using the dd command? I use the excellent Cron GUI Scheduled Tasks. I was hoping that maybe I can use that to schedule nightly bootable backups. Is dd the right tool to use? Once the initial backup is done (which I understand can take a long time), does dd do incremental backups after that.

Looking forward to how I can set this up so that I can just set and forget reassured that bootable backups are occurring overnight.

View 13 Replies View Related

General :: Using USB Extrenal Drive For Backups?

Dec 19, 2010

I have inherited a network server running Redhat Enterprise (4?) which uses an external USB drive for backups. These have been scheduled to run at midnight each night.I want to use 2 external drives to hold the backups (exchanging the usb drive each day). My question is: Is there anything I need to do to a new USB drive before exchanging the drives (eg. formatting etc) or can I simply just plug the new one in and let it run?I apologise for the very basic nature of this question but I have no clue about Linux.

View 6 Replies View Related

General :: Create Backups From Some Copy Protected DVD's?

Apr 14, 2010

I'd like to create backups from some copy protected DVD's, for my private use only.

Does it work this way to circumvent the copy protection mechanisms?

Code:
# dd if=/dev/dvd of=dvd.iso

and then burn dvd.iso on an empty DVD.

View 3 Replies View Related

General :: Excluding Executables In A Sub-directory From Tar Backups?

Jul 29, 2010

Just trying to set up a new backup using tar, but there are a few things I dont want to include. Using --exclude I can exclude sub-directories, but how do I exclude specific files in a subdirectory that are (for instance) executables or have a specific extension?

View 5 Replies View Related

General :: Locate All Emacs Autosaves And Backups In One Folder?

Mar 20, 2010

What do I need to add to my .emacs to get it to save all of my autosaves and backups into one directory? I don't do a lot of .emacs configuration, and I just can't get the variables out of emacsWiki to play right. Anybody mind sharing how they do it? I would prefer to have the saves placed in /tmp/emacs/{username}/{autosaves | backups}

BONUS, configuration to do the same for TRAMP

View 2 Replies View Related

General :: Can Root Create Directory When Not Exists While Backups

Nov 8, 2010

I am getting the databases from mysql and my database name is username_something.
I am getting the username and then puting the respective backups in corresponding folders like

tar bala bla /backups/sql/username/username_something.tar.sql.gz

The problem is system worrks if i have the folder username already there but for new databases if get the error like unknown file path.

How can i do that if username folder is not there it should be created

View 2 Replies View Related

General :: Show Previous Year When Performing Dec Backups In Jan

Jan 25, 2010

I have a script that moves files from one directory to another, based on the numeric date of the file name (i.e., 20091212 would go to the December directory). Now, since this script will be ran at the beginning of the following month (December's files to be tarred and gzipped will be performed the first day of January, and January's in February, etc.), it appears to me that the script will be tricky when it comes time to do the December files in January.

Here's part of the script:
Code:
# Define working directory and target directory.
DIR=/var/log
target=$DIR/month
hostname='uname -n' .....

I can't seem to figure out a way to carry the output of the date command to the next command, and the year for the December files will always be wrong.

View 2 Replies View Related

General :: Mount An ISO Made With Dd If=/dev/sda2 Of=/backups/backup.iso

Feb 26, 2010

this is my structure:

[root@ iso]# fdisk -l
Disk /dev/sda: 250.0 GB, 250059350016 bytes
255 heads, 63 sectors/track, 30401 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System

[Code]....

And I want to restore some files from /dev/VolGroup00/LogVol00.

View 14 Replies View Related

General :: Using AMANDA To Restore Backups Of Red Hat Enterprise AS Release 4?

May 12, 2010

I've run into a problem when trying to restore a file using AMANDA. My setup is as follows: I have a server that runs on Red Hat Enterprise Linux Server release 5.4 and I have a client that runs on Red Hat Enterprise Linux AS release 4. I successfully backed up files on the client using AMANDA.

Now I am trying to restore a file from the backup and restore it to the client running Red Hat Enterprise Linux AS release 4. In order to do this, I have to go through the server which runs Red Hat Enterprise Linux Server release 5.4.

Here is the problem I encounter. When I try the restore, it freezes at the extraction process. I've left it running for the night and still it is stuck at the same place. The restore never completes.

So I'm wondering if anyone knows what seems to be the issue? Could it be that the AMANDA driver I installed does not allow restore with different versions of Red Hat? Or is there an update in Red Hat 4 that would fix this issue?

View 7 Replies View Related

General :: Use Bacula To Make Backups Of The Files Stored On The Server?

Apr 14, 2010

I have an ubuntu (8.04.3) server where I use bacula to make backups of the files stored on the server. Ive been trying to find a solution (with no luck) trying to succesfully implement the following:-

A Backup tape for each day of the week besides Thurs which is resused on a weekly basis. For the thursday tapes we have a backup tape corresponding to the week number that the thursday falls so for the first thursday of the month it would be ThursOne For example. These tapes are resued on a monthly basis. We then have a monthly tape that is used on the last thursday of the month. These tapes will be resused on a yearly basis.

Another requirement is just in case a tape is accidently not changed a backup should still occur regardless of what tape is in the drive (so if its tuesday and mondays tape is still in the tape drive it should rewrite that tape).

I did have this successfully set up where the tape was appended after each use rather than being recycled after the nightly backup. But then after a few weeks I would have to manually purge tapes when they became full (which isnt ideal - as Im not always in the office so in my absence it may be that a backup may not take place), so have been playing around and have now got the tapes to be marked as used after a max of 2 jobs (so the backup of the files and the catalog of the night). I also added this line 'Recycle Current Volume = yes' so that it would hopefully recycle the volume in the drive.

However what I am finding is that the tape that should be recycled is not, but in yesterday case the Mondays tape was recycled rather than the Tuesday although Mondays was the last written so Im not even sure why it choose to recycle this tape.

View 1 Replies View Related

General :: Bash Script For Doing Tape Backups - Need Root Password

Feb 14, 2011

I have a bash script that I am using for doing tape backups. The meat of the bash script is
sudo tar --totals -H pax -cvf /dev/st0 *
This all works just fine.

But of course tape functions have to be ran as root, therefore sudo, requiring the standard user to enter the root password. I would like to be in a situation where the standard user does not need (does not know) the root password. I think my solution is add that standard user.
User named dog to the sudo list.

I have reviewed the sudo man page and looked at [URL]. I am still fuzzy.
1- Will adding user 'dog' to this sudo list do what I expect meaning I can run:
sudo tar --totals -H pax -cvf /dev/st0 *
and the user is not queried for the root password
2- How do I do that? and do I make a cmd alais for only: "tar --totals -H pax -cvf /dev/st0 *"
My distro is OpenSuse.

View 17 Replies View Related

General :: Command Line Sending Of Mail Attachments ( DB Backups)?

Dec 17, 2010

I'm am not remotely familiar with the linux operating sytem and just need a simple 'cut and paste solution' that will allow me to send .gz files as mail attachments, from the command line.Recently I moved my website to new hosting company, they are using cpanel and I have set up a couple of commands; the cpanel scheduler runs them for me as required.

1.creates an mysql dump and saves it to folder ( in root of my space )Works fine.2. delete the file created above, after 15 mins. Also works fineWhat I really want to do is email the .gz to myself before it is deleted, this is were I am stuck.This is possible ( I believe ) but it is beyond my understanding and ability to write the scipt/command that will make this happen.Please make any instructions really simple and clear as I am really new to this.on the server and this information is provided below and may be helpful to you (but I certainly to not know anything about this type of stuff)

View 7 Replies View Related

General :: Delete Backups Older Than 7 Days Through Shell Script?

Jul 15, 2011

I am having my own testing server in which mySQL database will be backed up daily. in the format mysql_backup_dd/mm/yy.tar.gz in my home folder I need to setup a cron job to delete the backups older than 7 days.how to do this.

View 3 Replies View Related

General :: Setup A Networked Tape Library To RHEL5 For Backups?

Jul 16, 2010

I have a Dell ml6000 as a network accessed tape library, I need to mount the tape library on my RHEL5 server as a nst* so I can setup backup crons. What is the process i need to follow to set thsi up?

View 2 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved