10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi all,
Please somebody help me with this:
I want to check if the files listed in a text file, are found under a directory or not.
For example: the file is list_of_files.txt, which contains inside this rows:
# cat list_of_files
logs
errors
paths
debug
#
I want to check if these... (3 Replies)
Discussion started by: arrals_vl
3 Replies
2. UNIX for Dummies Questions & Answers
Hello Experts,
Here are my requirements.
I want to monitor a directory and retrieve file properties like file names along with file sizes of files being generated today and that exceeds a threshold limit (say 10MB) using a shell script.
Basically this shell script should monitor (kinda... (1 Reply)
Discussion started by: RamanM
1 Replies
3. Shell Programming and Scripting
I'm finally about to make the jump from PHP's mysql driver to the newer mysqli one using the mysqli converter tool.
The tool is called by this command line:
php /usr/share/nginx/html/rather/converter/cli.php -d -p ".php,.shtml,.inc" -u -b -v -w >> /tmp/convert.log
e.g. at the web root:... (2 Replies)
Discussion started by: dheian
2 Replies
4. Shell Programming and Scripting
Hi
I want a script which continously searches for a work "MAX xonnections reached" in log file . As soon as it sees the message it needs to do series of steps
1) execute netstat command and redirect output to a file in /tmp
2) again continue monitoring the log file .
this job should run until... (2 Replies)
Discussion started by: mskalyani9
2 Replies
5. Shell Programming and Scripting
Hi,
I am not able to figure out what the problem is:
getting the following error
sqltst.sh: 1: not found
here is the script
#!/bin/sh
. /home/dev1/.profile
. /home/dev1/.infenv
`sqlplus -s $REPDB_LOGON << EOF
SET SERVEROUT ON
SET FEEDBACK OFF
SET HEADING OFF
SET TRIMSPOOL... (4 Replies)
Discussion started by: svajhala
4 Replies
6. Shell Programming and Scripting
I am trying to use a loop to strip of the funny character ^M at the end of all lines in each file found in current directory and I have used the following in a script:
find . -type f -name '*.txt' | while read file
do
echo "stripping ^M from ..."
ex - "$file" > $tempfile
%s/^M//g
wq!
# mv... (4 Replies)
Discussion started by: bisip99
4 Replies
7. Shell Programming and Scripting
Hi,
This is a quick one.
I have got a review comment in one of the scripts that i wrote:
"In UNIX script it not advisable to use cd to a directory and then run command."
Is this true?
I was trying to cd to log directory and use some cat or head or ls command.
Many Thanks,
Sam (2 Replies)
Discussion started by: samplify
2 Replies
8. Shell Programming and Scripting
I want the output of the find command to be printed and also the total files found by it. Can someone help in this.
Obviously $ find . -type f | wc -l will not output the files found but only the count. I want both. There can be millions and trillions of files so dont want the output of find... (3 Replies)
Discussion started by: amicon007
3 Replies
9. Shell Programming and Scripting
I have the following statement in script:
find ${LANDING_FILE_DIR}${BTIME_FILENAME_PATTERN2} -print | while read file; do
...
done
When there are no files located by the find comand it returns:
"find: bad status-- /home/rnitcher/test/....." to the command line
How do I get control in... (3 Replies)
Discussion started by: mavsman
3 Replies
10. Filesystems, Disks and Memory
Hi Friends,
How can I Restore the Files present under "lost+found" Directory of a FileSystem (in Solaris & Tru64 OS) to their original Locations.
Now-a-days I am loosing lots of files in 2 of my Machines,
One running Solaris8 and other Tru64(Digital) Unix.
Thanx in... (1 Reply)
Discussion started by: dhasarath
1 Replies