10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi Gurus,
Not able to catch what's going wrong here. I just want to get output as "tree".
server:/mk/app/nexapp $ echo $SHELL
/usr/bin/ksh
server:/mk/app/nexapp $ export db_name1="tree"
server:/mk/app/nexapp $ export i=1
1st try:
server:/mk/app/nexapp $ echo $(db_name$i)
ksh: db_name1: ... (3 Replies)
Discussion started by: mukesh.lalwani
3 Replies
2. UNIX for Dummies Questions & Answers
Guys,
I want to join two files. You might have seen this many times. I just don't get the desired output.
Searching the forum, No proper links :(
Input:
File1
test1
test2
test3
File2
is bad
is not bad
Output Needed:
test1 is bad
test2 is bad (4 Replies)
Discussion started by: PikK45
4 Replies
3. Shell Programming and Scripting
I have a string of source files
ENBL_PX11_LIBSRC = pltsub.f xpltlib.f xbuplot.cI want to replace .f and .c with .o
to get
ENBL_PX11_LIBOBJ = pltsub.o xpltlib.o xbuplot.o
However I am having trouble doing this with subst. (5 Replies)
Discussion started by: kristinu
5 Replies
4. Shell Programming and Scripting
Hello
I have a output file that contains the next info:
host_name LET-234-WDFD-2
address 10.11.0.62
host_name XWERWE-234-WEDF-EMEEH-GIDF-3
address 10.11.32.48
host_name DFG-745-WE-EMEEEH-GIDF-4
address 10.11.32.176
host_name ... (6 Replies)
Discussion started by: capilla
6 Replies
5. Shell Programming and Scripting
So I need a script that does the following:
If a certain user is logged in
Run `command`
Else
Echo “incorrect user”
This is my first stab...which doesn't work:
#!/bin/bash
X="user=`ls -l /dev/console | cut -d " " -f 4`"
Y="foobar"
echo $X
echo $Y (4 Replies)
Discussion started by: doubleminus
4 Replies
6. Shell Programming and Scripting
Hi, On the log Netscape log, I need to grep for 500 error. I am doing that but I also get 1500 in that same log.
cat access |grep "500"
Results:
"GET /css/RBR.css HTTP/1.1" 200 15000 304 - - - 399 639 523 164 0
This not what I need... Please advice. (4 Replies)
Discussion started by: samnyc
4 Replies
7. Shell Programming and Scripting
Hi,
I'm quite new to scripting and I want to modify following line of an existing script:
MYVAR=`subst |grep 'L:\\\:' | sed -e 's/.*\\\//'`;
What I have to do is to use the content of a variable instead of the constant expression 'L:\\\:' as the grep string to be matched.
Assuming I already... (5 Replies)
Discussion started by: snowbiker99
5 Replies
8. Shell Programming and Scripting
why won't below work?
I am trying to see
a)sipfile has username of the system.
b)it will read the sipfile and do a grep function against the /etc/passwd
c)it will save that output to /tmp/result..
but my script is just hanging...
#!/usr/bin/perl -w
open(SIPFILE, "</tmp/sipfile")
... (4 Replies)
Discussion started by: hankooknara
4 Replies
9. Shell Programming and Scripting
Hi everybody
I want to create 20 file using simple script - listed bellow-.
But the script doesn't work.
I hope anyone guide me to correct this script
----------------
The script
integer number=01
until (($number==21))
do
>TELE-LOG-$number
number=$number+01
echo $number
done
exit... (4 Replies)
Discussion started by: so_friendly
4 Replies
10. Shell Programming and Scripting
I want to find out Row which starts with, the user specified details to a script.
In general I know what command to be given.
awk '$0~/^Vi/' BReject
But I need to pass on $1 param of command line at the place of 'Vi'.
I tried with -v subst=$1
awk -v subst=$1 '$0~/^subst/' BReject
But it... (5 Replies)
Discussion started by: videsh77
5 Replies