10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
system OS: ubuntu, redhat
shell: /bin/sh
i noticed that if im running a script and i go to a separate terminal and type:
ps -efauxx | egrep "<the-script-name>"
i see that the content of all the variables in the script are all visible. How can i avoid/prevent this?
the scripts in... (4 Replies)
Discussion started by: SkySmart
4 Replies
2. Shell Programming and Scripting
Hi All,
Seeking for your assistance on how to put in variables all the commands in /bin
config files: /home/test/config_file/config.cfg
cat /home/test/config_file/config.cfg
ECHO=/bin/echo
LS=/bin/lsMain script
cat test.sh
source=/home/test/config_file/config.cfg
ECHO=$ECHO
LS=$LS#i... (3 Replies)
Discussion started by: znesotomayor
3 Replies
3. Shell Programming and Scripting
I have very abstract need of "comparing two variables" and take subsequent actions.
please refer to image below
https://lh3.googleusercontent.com/-frNk5iA3q1c/TjI3lE0sWOI/AAAAAAAAAIE/fxzB1w07gas/script_block.JPG
I have a part of script which reads a file and generates variables based on... (4 Replies)
Discussion started by: animesharma
4 Replies
4. Shell Programming and Scripting
For example, I have a simple text file
note:
this a note
a simple note
a very very simple notewhen I use this command,
temp=$(cat "note.txt")then I echo temp, the result is in one line.
echo $temp
note: this a note a simple note a very very simple noteMy variable doesn't have newline.
How... (7 Replies)
Discussion started by: 14th
7 Replies
5. Shell Programming and Scripting
Greetings All,
Need some help, your input is appreciated.
Scenario:
I have five files, each has one line with comletely different content. I execute the command to combine all the five lines of content into a single file.
Goal:
I would like to take that single file that has the... (3 Replies)
Discussion started by: royarellano
3 Replies
6. Shell Programming and Scripting
Hello,
I've created a couple of files within a list using the command "ls -ltr | tail -2 > list" These files are the newest files placed within a directory. From the "list" file, I need to place the filenames as a variable. In which the newest file will be called "new_ctrl" the older file... (4 Replies)
Discussion started by: petersf
4 Replies
7. Shell Programming and Scripting
Hey guys, i have got a problem...zenity is not being able to read my variables in its radiolist options.
as zenity needs a FALSE in front of a radiolist options, i have decided to ...
op=$(awk '{print "FALSE" " " $2} /etc/fstab)
$?=$(zenity --list --text "mount" --radiolist --column... (1 Reply)
Discussion started by: dplate07
1 Replies
8. Shell Programming and Scripting
i want to use multple sql count statements and store these count values in unix variable but in one connection only i.e. in only 1 time database should be hit ,which is the main requirement. (1 Reply)
Discussion started by: sw@pnil
1 Replies
9. Shell Programming and Scripting
Hi All,
I'll get a file whose 2nd line contains 3 fields: filename(variable length), file size char(10), and record count int(10). How do I cut it and put it into 3 variables?
eg: abcd.csv01234567891111111111
now I want: $one = abcd.csv, $two = 0123456789, $three = 1111111111.
I also... (8 Replies)
Discussion started by: Mandab
8 Replies
10. UNIX for Dummies Questions & Answers
With the if statement:
if
How can I make it so it accepts a wildcard after the ${CURR_DAY_MONTH} variable?
Putting
a -f /webtrends/SUN/mrw2/access.${CURR_DAY_DAY}${CURR_DAY_MONTH}*
won't work, right? I think I need some kind of special character so it knows the wildcard is... (3 Replies)
Discussion started by: LordJezo
3 Replies