Hi All,
I have a situation where I need to copy the files having the latest date.
For example I have a file by name bas100e1_jun05. I need to copy it to bas100e1. But when a file by name bas100e1_jul05 is put in the same directory the script should copy the file having the latest month which... (34 Replies)
I want to loop through files in a directory but omit the file with the latest date in my list of files. How would I accomplish this?
Thanks (2 Replies)
Guys,
I've got a quick logic question. I'm pretty savvy when it comes to shell scripting, however, I'm at a loss when it comes to writing a simple shell script to backup only certain files out of the month. I have a directory, for example, /data/backups/websites/domain. In each "domain"... (5 Replies)
Hi everyone,
Please help:)
I have a list of 1000 different files which comes daily to the directory.Some of
the files are not coming to the directory now.
I need to write a shell script to find the latest date and time of the files they
came to the directory. The files should be unique.... (1 Reply)
Hi,
I grep for a pattern in a list of files.
"grep -i -l $pattern *.datx*"
it may give me n number of files.
say for eg, it gives me 2 files.
lock_eicu_20071228_00000000.dat_20071228_05343100
lock_eicu_20080501_00000000.dat_20080501_05343900
out of these 2 files I need to get the... (7 Replies)
hi all,
not sure if this has been posted b4 but i try to search but not valid.
this is my question:
when i do a ls -ltr there will be a list generated as follows:
-rw-r--r-- 1 root sys 923260 Jan 10 04:38 FilePolling.41025.083TL021.xml
-rw-r--r-- 1 root sys 1761337 Jan 10 04:40... (12 Replies)
Hi Folks,
I have one query that there is a folder in which daily several logs files are getting created , I reached to that location through putty but what I observer that 10 files of different date are been created with same name , what I need to see is the latest file ...let say the location is ... (5 Replies)
HI
I have folder in home dir.
/home/kpp/07222013
/home/kpp/07212013
/home/kpp/07202013
Output :--
/home/kpp/07222013
Just find latest date (5 Replies)
Discussion started by: pareshkp
5 Replies
LEARN ABOUT CENTOS
tdbbackup
TDBBACKUP(8) System Administration tools TDBBACKUP(8)NAME
tdbbackup - tool for backing up and for validating the integrity of samba .tdb files
SYNOPSIS
tdbbackup [-s suffix] [-v] [-h]
DESCRIPTION
This tool is part of the samba(1) suite.
tdbbackup is a tool that may be used to backup samba .tdb files. This tool may also be used to verify the integrity of the .tdb files prior
to samba startup or during normal operation. If it finds file damage and it finds a prior backup the backup file will be restored.
OPTIONS -h
Get help information.
-s suffix
The -s option allows the adminisistrator to specify a file backup extension. This way it is possible to keep a history of tdb backup
files by using a new suffix for each backup.
-v
The -v will check the database for damages (currupt data) which if detected causes the backup to be restored.
COMMANDS
GENERAL INFORMATION
The tdbbackup utility can safely be run at any time. It was designed so that it can be used at any time to validate the integrity of tdb
files, even during Samba operation. Typical usage for the command will be:
tdbbackup [-s suffix] *.tdb
Before restarting samba the following command may be run to validate .tdb files:
tdbbackup -v [-s suffix] *.tdb
Note that Samba 4 can use .ntdb files instead, so you should use ntdbbackup on those files.
Samba .tdb files are stored in various locations, be sure to run backup all .tdb file on the system. Important files includes:
o secrets.tdb - usual location is in the /usr/local/samba/private directory, or on some systems in /etc/samba.
o passdb.tdb - usual location is in the /usr/local/samba/private directory, or on some systems in /etc/samba.
o *.tdb located in the /usr/local/samba/var directory or on some systems in the /var/cache or /var/lib/samba directories.
VERSION
This man page is correct for version 3 of the Samba suite.
AUTHOR
The original Samba software and related utilities were created by Andrew Tridgell. Samba is now developed by the Samba Team as an Open
Source project similar to the way the Linux kernel is developed.
The tdbbackup man page was written by John H Terpstra.
Samba 3.6 06/10/2014 TDBBACKUP(8)