10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hello Experts,
In one of my shell script, I've been trying to calculate mod and saving it in a variable, below is what I have tried but it isn't working.
Any help appreciated!!!
#!/bin/bash
num1=4
num2=3
echo "Number one is $num1"
echo "Number two is $num2"
mod_final=$(( echo "num1%num2"... (7 Replies)
Discussion started by: mukulverma2408
7 Replies
2. AIX
Hi guys,
Anyone encountered the following error.
1.) all keys and passphrases worked on aix 7.1.2
2.) upgraded to aix 7.1.3sp5
3.) none of the keys / passphrases work anymore.
4.) when generating new keys without passphrase everything is ok.
5.) when generating keys with passphrase and... (16 Replies)
Discussion started by: NoLogic001
16 Replies
3. Shell Programming and Scripting
My .bash_profile file: source $HOME/build.variables My build.variables file: export threads="$(${threads:-$(lscpu | egrep "CPU\(s\):|Thread" | $]\)\n.
*Thread.*\(]\)@\1*\2@;Ta")])})"threads=$(lscpu | egrep "CPU\(s\):|Thread" | $]\)\n.*Thread.*\(]\)@\1*\2@;Ta")The above codes when not comment out... (7 Replies)
Discussion started by: charlieandlinux
7 Replies
4. Shell Programming and Scripting
hi
I have a script to login from a host "A" to a list of hosts in a file and perform some commands inside it...its somethin like this
for i in `cat file`
do
ssh -t $i " command1 ; command2; ..."
done
I wanna save the outputs in a file in the current host "A" i.e from where I am... (3 Replies)
Discussion started by: ningy
3 Replies
5. Shell Programming and Scripting
Hi,
I have problems when you save a variable of a command. I have put the following line:
CONEXION_BAGDAD = $ (grep-c "Please login with USER and PASS" $ LOG_FILE_BAGDAD)
But I returned the following error:
syntax error at line 67: `CONEXION_BAGDAD = $ 'unexpected
Because it can happen?... (2 Replies)
Discussion started by: danietepa
2 Replies
6. Shell Programming and Scripting
Hi,
I want to execute some script on the remote session and transfer the processed file on remote machine to local machine.
I tried with ssh-keygen and ssh-copy-id but seems that this has been disable on the remote machines,
Is there any possiblity that I can save the remote username and... (7 Replies)
Discussion started by: maruthavanan
7 Replies
7. UNIX for Dummies Questions & Answers
Hi,
I currently have a shell script where it captures in the value in to 'TOTAL' and outputs to a file, i want to capture another value of a query in to another variable and output it.
Current script:
sqlplus -s $user <<EOD | read TOTAL
set heading off
set pages 0
set feedback off
set... (1 Reply)
Discussion started by: ravi0435
1 Replies
8. UNIX for Dummies Questions & Answers
Hello,
I have a shell script containing a command string in the following format:
command1 | command2 | cut -c9-16
The output from this is a record number (using characters 9-16 of the original output string) e.g. ORD-1234
I wish to save this value to a variable for use in later commands... (4 Replies)
Discussion started by: philjo
4 Replies
9. Shell Programming and Scripting
Hi,
#Script mentioned below
txt=($(echo `./demo1.sh`))
p=0
for p in "$txt"
do
col=($(./generateTable /import/data01/sri/Developer/SqlReport/Lab/23/${var} "$p"))
.
.
.
.
done
o/p displayed upon executing a script called "demo1.sh" is as below(two seperate lines):... (2 Replies)
Discussion started by: villain41
2 Replies
10. Shell Programming and Scripting
Hi,
I am new to shell scripting, I am trying to write a shell script, which will automate the process of mailing the invoices at the end of the day. For major part I am using Oracle database function.
The problem is I want to capture the value returned by the Oracle function into the script... (2 Replies)
Discussion started by: prasad01
2 Replies