06-26-2018
Quote:
Originally Posted by
haribabu2229
I am using python 2.x.x
I got the solution the error which I got
---------- Post updated at 11:54 AM ---------- Previous update was at 11:50 AM ----------
Always debug the code step by step to catch the loophole
Debug on what? Python tracebacks are ridiculously accurate and would point out any syntax AND some programming errors, so......
You can't possibly be using Python 2.x.x as you are using print functions NOT print statements,
print("\n Console OutPut:", console_output) , AND, your first for loop,
for host in list_of_hosts: , has no indented code to work on which causes a script crash, so again how did you get it to work?
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi,
I have a sheel script that invokes a perl script...Now, instead havin the perl script as a separate file I'd like put the contents in the sheel script itself...But I am not sure how ro run that perl script contents.please help me
Thanks (1 Reply)
Discussion started by: vijay_0209
1 Replies
2. UNIX for Dummies Questions & Answers
The java program is a part of speech tagger -> The Stanford NLP (Natural Language Processing) Group
The goal is to use this script as part of a webpage to tag parts of speech based on a user-inputted string.
I have no idea what to do with the files - I'm a complete *nix noob. I tried running... (4 Replies)
Discussion started by: tguillea
4 Replies
3. Shell Programming and Scripting
Is there a way to run some code in a C-shell script by different shell, like bash?
I have that situation.
I have prepared and perfectly workable bash-skript that now I have to execute under C-shell script, divide it on steps and without creating a new files (with the bash-code parts.)
For... (6 Replies)
Discussion started by: alex_5161
6 Replies
4. UNIX for Dummies Questions & Answers
Hi there can anyone help me
here is my code
echo "Type in a positive number"
read X
I=2
while
do
if
then
echo "It is not prime"
break
else
if
then
echo "It is prime"
break
else
I=$(( $I + 1))
fi
fi (4 Replies)
Discussion started by: FUTURE_EINSTEIN
4 Replies
5. Shell Programming and Scripting
hi All,
Am newbie to unix and would require your help to complete this task.
Condition:
I have a server start up script and I would like to append the code in such a way that it searches for a phrase "process completed" in taillog when server starts up and also should run another script... (9 Replies)
Discussion started by: fop4658
9 Replies
6. UNIX for Advanced & Expert Users
I am more of a newbie, but wanted to post this in this forum as I was afraid no one would look at it in unix forums as it concerns shell scripting. I have a shell script that now runs fine with the exclusion of one line:
x=`su nbadmin -c "ssh -t servery /usr/openv/netbackup/bin/bplist -C... (7 Replies)
Discussion started by: newbie2010
7 Replies
7. Shell Programming and Scripting
If I run 'who -u' interactively or from a script invoked through bash in a tty on my Ubuntu 12LTS box I get an output like this:
testuser pts/0 Dec 9 02:32 . 2163 (host.xx.yy)
running the same through cron I get:
testuser pts/0 2012-12-09 02:32 00:05 2163... (2 Replies)
Discussion started by: latimer
2 Replies
8. Shell Programming and Scripting
Hi,
I want to deploy a (perl) script, in Linux. (Red Hat 7).
Is there a way to protect the script itself from being viewed by the user, but still allow the user to run the script?
I dont want the user to be able to see the source code of the script. (2 Replies)
Discussion started by: BG_JrAdmin
2 Replies
9. Shell Programming and Scripting
Why doesn't the code below run? Am I missing something? Thank you :).
syntax() {
printf "\n\n"
printf "Enter HGVS description of variant(s): "; IFS="," read -a hgvs
&& printf "\n Nothijng entered. Leaving match function." && sleep 2 && return
for ((i=0;... (5 Replies)
Discussion started by: cmccabe
5 Replies
10. OS X (Apple)
Some hackers found a security hole in macOS High Sierra and tweeted it to the world before telling Apple about the problem. You can see the details from PC Magazine's daily news here: Apple Releases Fix for MacOS High Sierra 'Root' Bug. The original story this morning was published before a patch... (6 Replies)
Discussion started by: Don Cragun
6 Replies
LEARN ABOUT DEBIAN
yhsm-linux-add-entropy
yhsm-linux-add-entropy(1) General Commands Manual yhsm-linux-add-entropy(1)
NAME
yhsm-linux-add-entropy - Seed the Linux entropy pool with data from YubiHSM TRNG
SYNOPSIS
yhsm-linux-add-entropy [options]
DESCRIPTION
The YubiHSM uses "Avalanche Noise" TRNG together with USB SOF jitter sampling to feed a DRBG_CTR algorithm (NIST publication SP800-90). The
result has been verified as being random data of good quality by at least one third party cryptographer. <http://sartryck.idg.se/Art/
Yubihsm_1_TW072011.html>
Use this program to add random data from the YubiHSM to the entropy pool of your Linux operating system. This is useful whenever lots of
random data is needed, such as when generating chryptographic keys (GPG-keys), on a server terminating SSL sessions etc.
You may run this script from cron, or in a while-loop. Make sure it does not run at the same time as something else accessing the YubiHSM
though, or the two tasks may interrupt each other - probably making both fail.
OPTIONS
-D, --device
device file name (default: /dev/ttyACM0).
-v, --verbose
enable verbose operation.
-c, --count
number of iterations to run (default: 100).
-r, --ratio
bits per byte read to use. 8 is probably fine, but as a conservative default 2 is used.
--debug
enable debug printout, including all data sent to/from YubiHSM.
EXIT STATUS
0 Entropy added successfully
1 Failure
BUGS
Report python-pyhsm/yhsm-linux-add-entropy bugs in the issue tracker <https://github.com/Yubico/python-pyhsm/issues/>
SEE ALSO
The python-pyhsm home page <https://github.com/Yubico/python-pyhsm/>
YubiHSMs can be obtained from Yubico <http://www.yubico.com/>.
python-pyhsm December 2011 yhsm-linux-add-entropy(1)