Sponsored Content
Top Forums Shell Programming and Scripting <AIX>Problem in purge script, taking very very long time to complete 18.30hrs Post 302344355 by kshji on Sunday 16th of August 2009 04:27:32 AM
Old 08-16-2009
Put together all those lines where rule is same, use find -o option to put together name rules using one find.

There is also meny different kind of finds, some days old or one year old. Think carefully how often you really need to run different kind of finds+rm. Make more than find script file, run once in month, run once in ...

Example something like this:
Code:
find . \( -name '*(MON)*'  -o -name '*(TUE)*' \) -type f

 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

shell script takes long time to complete

Hi all, I wrote this shell script to validate filed numbers for input file. But it take forever to complete validation on a file. The average speed is like 9mins/MB. Can anyone tell me how to improve the performance of a shell script? Thanks (12 Replies)
Discussion started by: ozzman
12 Replies

2. UNIX for Dummies Questions & Answers

fetchmail taking long time to fetchmail...

Hi peeps, We are having around 60 users. The time set to retrieve the mail is 300 sec. But it's taking around 1 hour to deliver mails. I am using debian sarge 3.1. any clues? And how it will affect if I decrease the time? My machine has got 1 p4 3.0 GHZ processor and 1 GB ram. The home... (2 Replies)
Discussion started by: squid04
2 Replies

3. Red Hat

login process taking a long time

I'm having a bit of a login performance issue.. wondering if anyone has any ideas where I might look. Here's the scenario... Linux Red Hat ES 4 update 5 regardless of where I login from (ssh or on the text console) after providing the password the system seems to pause for between 30... (4 Replies)
Discussion started by: retlaw
4 Replies

4. UNIX for Dummies Questions & Answers

gref -f taking long time for big file

grep -f taking long time to compare for big files, any alternate for fast check I am using grep -f file1 file2 to check - to ckeck dups/common rows prsents. But my files contains file1 contains 5gb and file 2 contains 50 mb and its taking such a long time to compare the files. Do we have any... (10 Replies)
Discussion started by: gkskumar
10 Replies

5. UNIX for Dummies Questions & Answers

Job is taking long time

Hi , We have 20 jobs are scheduled. In that one of our job is taking long time ,it's not completing. If we are not terminating it's running infinity time actually the job completion time is 5 minutes. The job is deleting some records from the table and two insert statements and one select... (7 Replies)
Discussion started by: ajaykumarkona
7 Replies

6. Solaris

How to find out bottleneck if system is taking long time in gzip

Dear All, OS = Solaris 5.10 Hardware Sun Fire T2000 with 1 Ghz quode core We have oracle application 11i with 10g database. When ever i am trying to take cold backup of database with 55GB size its taking long time to finish. As the application is down nobody is using the server at all... (8 Replies)
Discussion started by: yoojamu
8 Replies

7. UNIX for Dummies Questions & Answers

ls is taking long time to list

Hi, All the data are kept on Netapp using NFS. some directories are so fast when doing ls but few of them are slow. After doing few times, it becomes fast. Then again after few minutes, it becomes slow again. Can you advise what's going on? This one directory I am very interested is giving... (3 Replies)
Discussion started by: samnyc
3 Replies

8. Shell Programming and Scripting

While loop problem taking too long

while read myhosts do while read discovered do echo "$discovered" done < $LOGFILE | grep -Pi "|" | egrep... (7 Replies)
Discussion started by: SkySmart
7 Replies

9. Shell Programming and Scripting

Wget takes a long time to complete

Hi, I wish to check the return value for wget $url. However, some urls are designed to take 45 minutes or more to return. All i need to check if the URL can be reached or not using wget. How can i get wget to return the value in a few seconds ? (8 Replies)
Discussion started by: mohtashims
8 Replies

10. Shell Programming and Scripting

Script takes too long to complete

Hi, I have a lengthy script which i have trimmed down for a test case as below. more run.sh #!/bin/bash paths="allpath.txt" while IFS= read -r loc do echo "Working on $loc" startdir=$loc find "$startdir" -type f \( ! -name "*.log*" ! -name "*.class*" \) -print | while read file do... (8 Replies)
Discussion started by: mohtashims
8 Replies
UCFR(1) 						      Debian GNU/Linux manual							   UCFR(1)

NAME
ucfr - Update Configuration File Registry: associate packages with configuration files SYNOPSIS
ucfr [options] <Package> <Path to configuration file> DESCRIPTION
Where Package is the package associated with the configuration file (and, in some sense, its owner), and Path to configuration file is the full path to the location (usually under /etc) where the configuration file lives, and is potentially modified by the end user. Please note that usually this means that we register actual files, and not symbolic links to files. ucfr will follow symbolic links and register the real file, and not the symbolic link. This script maintains an association between configuration files and packages, and is meant to help provide facilities that dpkg provides conffiles for configuration files and not shipped in a Debian package, but handled by the postinst by ucf instead. This script is idempo- tent, associating a package to a file multiple times is not an error. It is normally an error to try to associate a file which is already associated with another package, but this can be overridden by using the --force option. OPTIONS
-h, --help Print a short usage message -n, --no-action Dry run. Print the actions that would be taken if the script is invoked, but take no action. -d [n], --debug [n] Set the debug level to the (optional) level n (n defaults to 1). This turns on copious debugging information. -p, --purge Removes all vestiges of the association between the named package and the configuration file from the registry. The association must already exist; if the configuration file is associated with some other package, an error happens, unless the option --force is also given. In that case, the any associations for the configuration file are removed from the registry, whether or not the package name matches. This action is idempotent, asking for an association to be purged multiple times does not result in an error, since attempting to remove an non-existent association is silently ignored unless the --verbose option is used (in which case it just issues a diagnostic). -v, --verbose Make the script be very verbose about setting internal variables. -f, --force This option forces operations requested even if the configuration file in consideration is owned by another package. This allows a package to hijack a configuration file from another package, or to purge the association between the file and some other package in the registry. --state-dir /path/to/dir Set the state directory to /path/to/dir instead of the default /var/lib/ucf. Used mostly for testing. USAGE
The most common case usage is pretty simple: a single line invocation in the postinst on configure, and another single line in the postrm to tell ucfr to forget about the association with the configuration file on purge (using the --purge option) is all that is needed (assum- ing ucfr is still on the system). FILES
/var/lib/ucf/registry, and /var/lib/ucf/registry.X, where X is a small integer, where previous versions of the registry are stored. /etc/ucf.conf EXAMPLES
If the package foo wants to use ucfr to associate itself with a configuration file foo.conf, a simple invocation of ucfr in the postinst file is all that is needed: ucfr foo /etc/foo.conf On purge, one should tell ucf to forget about the file (see detailed examples in /usr/share/doc/ucf/examples): ucfr --purge foo /etc/foo.conf If you want to remove all the conf files for a given package foo, the simplest way is to use ucfq. For example ucfq -w foo | cut -d : -f 1 | while read cfile ; do ucfr -v $cfile ; done SEE ALSO
ucf(1), ucf.conf(5). AUTHOR
This manual page was written Manoj Srivastava <srivasta@debian.org>, for the Debian GNU/Linux system. Debian Feb 16 2018 UCFR(1)
All times are GMT -4. The time now is 07:09 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy