11-15-2009
Posting Homework in the main forums is not allowed. Thread closed.
9 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
I need to modify a script to send an attatched file. I have researched and read the faq's but have not found a solution for my script. Here is a copy of the code I am using:
#!/bin/sh
mysqldump --opt --skip-add-locks --user=****** --password=******* databasename | gzip >... (3 Replies)
Discussion started by: rickou812
3 Replies
2. Shell Programming and Scripting
When I run this command (showstatus <username> <dbname>) in the prompt, the following will be displayed in the screen:
1. Show processes
2. Start process
3. Stop process
4. Go back to prompt
Once i choose/type Option "1" (which is Show processes), it will display the list of processes... (5 Replies)
Discussion started by: xinoo
5 Replies
3. Shell Programming and Scripting
would like to standardize how we set envs on our unix box, so I thought a menu would be a great way to accomplish this.
The problem I'm experiencing, is the value is set...but ONLY during the time the menu is initiated.
please see below:
> /home/is/bin/r12MENU.sh
... (2 Replies)
Discussion started by: mr_manny
2 Replies
4. Shell Programming and Scripting
I am looking for a shell script or command to automate a process of opening many files in a directory and changing a string of text. Example:
I have a apache web server that uses virtual hosting. There are approximately 2300 vhost entries or files. So in the directory... (2 Replies)
Discussion started by: jaysunn
2 Replies
5. Shell Programming and Scripting
I have a simple script. Do you know what I got this error?
./total_memory.ksh: line 5: '
Thanks
#! /bin/bash
setmem=30177660
totalMemory= grep MemTotal /proc/meminfo | awk '{print $2}'
if ; then
echo "Total memory $totalMemory is less than :$setmem"
exit 1
... (3 Replies)
Discussion started by: Beginer0705
3 Replies
6. UNIX and Linux Applications
I'm looking for terminal programs, which organize and pretty code like HTML or JavaScript.
Thanks!
---------- Post updated at 07:01 AM ---------- Previous update was at 01:49 AM ----------
Found this Online javascript beautifier (1 Reply)
Discussion started by: borobudur
1 Replies
7. Shell Programming and Scripting
---------- Post updated at 11:48 AM ---------- Previous update was at 11:46 AM ----------
Hello all
I have an awk code that successfully creates separate text files based on the first six letters of the second field. What it doesn't do is preserve the header into each resulting file.
... (6 Replies)
Discussion started by: colecandoo
6 Replies
8. Shell Programming and Scripting
#!/bin/bash
>error_log
for s in `cat s.txt`
do
uptime $s >>error_log
echo $s >>error_log
done
The above code produce output with server name and its uptime in 2 different lines .My requirement is to have the same in one line . Please assist (3 Replies)
Discussion started by: vinil
3 Replies
9. Shell Programming and Scripting
write a script using shift and case to receive 11 argument and do the following
--arg1 - print hello message and the current proccess id
--arg2 - read and edit a file based on the value which came along with the arg2.
--arg3 - validate whether all... (1 Reply)
Discussion started by: saku
1 Replies
LEARN ABOUT DEBIAN
bf_tar
BF_TAR(1) Bogofilter Reference Manual BF_TAR(1)
NAME
bf_tar - shell script to write a tar file of a bogofilter directory to stdout
SYNOPSIS
bf_tar [-r] [-R] bogofilter_directory
DESCRIPTION
bf_tar bundles a bogofilter working directory in tar format and copies it to standard output (your console, or where you redirect it, see
EXAMPLES below).
OPTIONS
The -r option causes bf_tar to remove inactive log files after the archive has been written successfully. The default is to leave log
files.
The -R option causes bf_tar to remove inactive log files before the archive is written. This may reduce chances that the resulting archive
is recoverable should it become damaged. The archive may be smaller though. The default is to leave log files.
EXIT STATUS
The script exits with status code 0 if everything went well, and nonzero if it encountered trouble.
EXAMPLES
o bf_tar ~/.bogofilter > outfile.tar
Writes a standard .tar file containing the essential files from ~/.bogofilter to outfile.tar.
o bf_tar ~/.bogofilter | gzip -9 -c > outfile.tar.gz
Writes a gzipped .tar.gz file containing the essential files from ~/.bogofilter to outfile.tar.gz.
o bf_tar `pwd`/mydirectory > outfile.tar
Prepend $(pwd)/ or `pwd`/ if you want to specify an absolute path instead of a relative path.
NOTES
This script is meant for use with Berkeley DB based bogofilter versions.
This script requires a SUSv2 compliant pax utility.
This script expects a SUSv2 compliant shell. Solaris systems should have the SUNWxcu4 package installed (when bogofilter is configured) so
that /usr/xpg4/bin/sh can be used.
AUTHORS
Matthias Andree
Bogofilter 03/15/2010 BF_TAR(1)