10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi,
I am new in ksh scripting and if anyone can help that would be great.
I'm writing a script which will SSH to several machines and then would append a certain file from a NAS to the /etc/sudoers file
the problem i am having is after the script connects to a certain server the commands are... (7 Replies)
Discussion started by: galuzan
7 Replies
2. 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
3. Shell Programming and Scripting
am running the small script below.
count_a=48
count_b=48
if ; then
echo "Count matched"
else
echo "count not matched"
fi
I got the below output.
/bin/ksh: [48: not found
count not matched
It was giving the same error when I ran in another box. But I inculded /bin/ksh in the... (10 Replies)
Discussion started by: sathik
10 Replies
4. Shell Programming and Scripting
Hey all, I need some assistance. I'm writing a script to eject tapes from a tape library, but the library is not a queued system and can only eject 15 tapes at a time.
I added paste -d : -s so that it goes through full_tapes and puts each media_id on one line separated by the :.
Now I'm... (2 Replies)
Discussion started by: em23
2 Replies
5. 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
6. 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
7. Shell Programming and Scripting
Ih all,
i have multiples ksh scripts for crontab's unix jobs
they all have same variables declarations and some similar functions
i would have a only single script file to declare my variables, like:
var1= "aaa"
var2= "bbb"
var3= "ccc"
...
function ab { ...}
function bc { ... }... (2 Replies)
Discussion started by: wolfhurt
2 Replies
8. Shell Programming and Scripting
Hello All,
I need to develop a script(SH]) to generate a comparison file between two files old and new file.The script takes in parameter the old file path and the new file path. And the script generates a file containing the comparison between the two files with this details:
- Keys... (2 Replies)
Discussion started by: shahidbakshi
2 Replies
9. 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
10. Shell Programming and Scripting
Hey everyone, I'm newer than new when it comes to this ksh and scripting stuff, and unix in general. I have been thrown into a task at work that
A: They expect me to come up to speed on,
B: Show I can do this. (Program for the workgroup)
Here's the script, part of it, from the overall... (3 Replies)
Discussion started by: Brusimm
3 Replies