10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi...I am trying to make a script like this:
echo "$mmc" > 123.txt
The variable "mmc" has to be declared right on the beginning of the script, so when I open 123.txt, I get:
My question is, how can I "echo" '$mmc' into 123.txt, retaining the '$mmc' phrase? Which means when... (10 Replies)
Discussion started by: Ryuinferno
2. Shell Programming and Scripting
I'm trying to replace a string with the contents of a file.. I found the below thread that shows how to do this but is there any way to use a variable as the file name in the nawk command?.. When I try I get an error saying
while read groupsvar
... (5 Replies)
Discussion started by: Jazmania
3. Shell Programming and Scripting
First post for Newbie as I am stumped. I need to get certain elements for a specific PID from the ps command. I am attempting to pass the value for the PID I want to retrieve the information for as a variable. When the following is run without using a variable, setting a specific PID,... (3 Replies)
Discussion started by: Coyote270WSM
4. Infrastructure Monitoring
This is the control File (snmplist.fl1)
.220.127.116.11.4.1.718.104.22.168.1.2.3 = STRING: "/vol/vol0/"
.22.214.171.124.4.1.7126.96.36.199.1.2.5 = STRING: "/vol/SMP_sapdata/"
.188.8.131.52.4.1.7184.108.40.206.1.2.7 = STRING: "/vol/SMP_saplog/"
.220.127.116.11.4.1.718.104.22.168.1.2.9 = STRING: "/vol/SRP_saplog/"... (6 Replies)
Discussion started by: riegersteve
5. Shell Programming and Scripting
I have a variable:
$FILENAME = /XXXX/XXXX/XXXX/file.dat
I want to set another variable that will give me this:
So basically i'm chopping up variable $FILENAME.
Not sure cut will do this as i'm looking at different directories so the characther length may be... (2 Replies)
Discussion started by: Pablo_beezo
6. Shell Programming and Scripting
Hi i have two question
In above there are total three words
how can i take all three things in different variable, i dont understand that how to separate dot.
it looks like that
2. i have variable xyz whois value... (7 Replies)
Discussion started by: learnbash
7. Shell Programming and Scripting
I have been working on a script that executes on a number of different operating systems. As a result I was trying to set a variable or perhaps variable array depending on the OS. I tried the following using eval and such but so far have not had any luck. Is there a way to do something like the... (4 Replies)
Discussion started by: scotbuff
8. Shell Programming and Scripting
Hi, this is probably very easy but, how do I define a variable for more than one line.
when I call it, I want it to be exactly like this, don't want all the words on the same line. (10 Replies)
Discussion started by: starks
9. Shell Programming and Scripting
In my shell script I'm using a variable $ICO to speicfy the type of file that I'm processing e.g. VFR = France.
further in my shell I'm trying to programatically set the sql file thtat I want to run :-
however when I check the value (as below) :-
... (4 Replies)
Discussion started by: rjsha1
I have a question about C program for Unix:
Do we have to intialize every variable before we use them in C?
I thought we have to untill I found some programs are not intialize the variable before they were used. (2 Replies)
Discussion started by: whatisthis