I have a file named Atoms that has a list of atoms listed vertically, like:
O
C
Na
etc. There is a variable number of them.
I want to count their occurences in another file. I want to do this by saving each atom as a variable, preferabbly in an associative array, then counting how... (3 Replies)
Hi Friends,
i have small issue,...
here is my problem............:)
i am using two unix box A and B ..using my script i am able to connect from A to B without password(using ssh option like below).
A:-> ssh user@B-2.10.32.23
but i declared one variable in A which is something... (5 Replies)
I need to capture the homedir using the ssh command and then saving it to a variable.
The results from the following command is what I need to capture to a variable:
NOTE: the value I'm getting back is also incorrect. as it seems to be getting the home dir from the local server and not the... (2 Replies)
Friends,
I want to write a script. The logic follows
1. Script starts
2. SSH to Remote Machine and check whether /home/testUser dir is there or not.
3. If it is there, am assigning a value to a variable. else not
4. If the variable is set, the do the copy from remote machine to my local... (2 Replies)
hi there
I am trying to get a value from a remote machine into a local variable. To get this value i want to use awk but im having trouble getting it to run, am i escaping in the right places here and using the right quotes (i must have tried a million combinations :()
# VAR=`ssh server1... (5 Replies)
# dir=/mnt
# ssh -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no root@10.0.2.3 'cd $dir;ls'
The $dir doesn't take effect any help?? ( I want use variable to do something
Thanks in advance (1 Reply)
Hi All,
i am writing a shellscript to compare cksum of the file in local machine and after copying to remote machine. i am not able to assign command output value to variable in remote machine through SSH. PFB code for this.
code:
###### Get File size of the file in local remote system
... (3 Replies)
Hi, I've an issue in a shell script:
I'm opening an ssh connection to a remote server, then I want to store the result of a ls command in a variable, but it doesn't work: the ls is done on the local machine.
ssh user@server << EOF
ls # works as expected (ls is done remotely)
test=`ls` # the... (1 Reply)
Hi Guys n Girls,
Below im using a while command to wait for a file on another server then carrying on with the script.....
I dont believe the $Sausage1 variable is being passed to the other server so its not finding the file. If i replace the variable with the date then it works as expected.
... (2 Replies)
hi Gurus,
Have been struggling with this for a while
I have 2 servers , lets say local A and remote B, I need to use both as a part of a pipeline. The folder structure is shared between the two, so I can access the same files and folders from both A and B.
When I try to ssh into B from A,... (15 Replies)