10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hello i am having an issue with bash script and this is the code
now=$(cat hosts1.txt | awk '{print $2;}')
while read n ;do
ssh root@$now 'useradd test1; echo -e "test1\ntest1" | passwd test1 && echo "test1 ALL=(ALL:ALL) ALL" >> /etc/sudoers'
When i execute only part with cat, it... (8 Replies)
Discussion started by: tomislav91
8 Replies
2. Shell Programming and Scripting
Hello,
I'm trying to create a mechanism wherein a set of Production servers will email me the results of system checks like Uptime, NFS Mounts and a Process after every scheduled reboot.
For this, I figured I'd use the @reboot parameter that crond comes with.
I have added the below onliner... (3 Replies)
Discussion started by: pocodot
3 Replies
3. Shell Programming and Scripting
Hello,
Hitting a wall on this one. When at the command prompt it works fine:
# find /home/testuser -name 'PAINT*canvasON.txt'
/home/testuser/PAINT_canvasON.txt
# pwd
/home/testuser
# ls -l PAINT*canvasON.txt
-rw-r--r-- 1 root user 23 Feb 07 02:58 PAINT_canvasON.txt... (2 Replies)
Discussion started by: seekryts15
2 Replies
4. Shell Programming and Scripting
Hello,
Currently i have a script which will disply the results in plain text format.
I want to format the result in more readable format like Making bold headings and format with colors etc. Something like html and send that content as email.
Please help me how i can do that.
I am using... (10 Replies)
Discussion started by: joy lobo
10 Replies
5. Shell Programming and Scripting
Hi!
First off I'm no bin/bash script writer! :( I can make heads and tales of it from the php experience I have and that's all.
Now I managed to piece this script together to go look at directory and remove files that are +60 days. It's finding the files but its not removing them. I... (11 Replies)
Discussion started by: MrBiggz
11 Replies
6. Shell Programming and Scripting
I am running the export command within a view to use that value inside my build script. But while executing it it is saying "export command not found"
My code is as follows:
--------------------------
#!/bin/sh
user="test"
DIR="/bldtmp/"$user
VIEW="test.view1"
echo "TMPDIR before export... (4 Replies)
Discussion started by: dchoudhury
4 Replies
7. Shell Programming and Scripting
Hello,
I'm using csh. I have a file named "setup" that I normally source, e.g.
source setupI'd like a one-liner that sources this file, but excluding lines that contain "DEBUG", e.g.
cat setup | grep -v DEBUG | sourceOf course, the above does not work. How can I execute the results of a... (5 Replies)
Discussion started by: acheong87
5 Replies
8. Shell Programming and Scripting
Hello
I have a script which emails identifies the user ID of a user and sends them an email. A user can enter part of the name of the person he/wants to send the email to. Then I use the ypcat command to identify the UID of that person.
The problem I'm having, is building in an error trap... (1 Reply)
Discussion started by: Glyn_Mo
1 Replies
9. Shell Programming and Scripting
Hi everyone,
I have a csh script that works fine but the output of an rsh command is different if I use boune shell instead cshell.
Is there the possibility to execute only this command in bourne shell from a script declared cshell?
Thanks
Christian (2 Replies)
Discussion started by: bonovox
2 Replies
10. Shell Programming and Scripting
Hi. Thanks for any help with this. I'm not new to programming but I am new to shell programming. I need a script that will
1. execute 'df -k' and return the volume names with specific text
2. surround each line of the above results in opening and closing xml tags
3. insert the results of step... (5 Replies)
Discussion started by: littlejon
5 Replies