10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
In bash, you can do something like this:
#!/bin/bash
echo -n "What is your name? " > /dev/tty
read thename < /dev/tty
How can I do the same in python?
I have a python script that has the following content:
#!/usr/bin/python2.7
import getpass
import sys
import telnetlib
import... (2 Replies)
Discussion started by: SkySmart
2 Replies
2. Shell Programming and Scripting
Hi, Have a need to run the below command as a "karuser" from a java class which will is running as "root" user. When we are trying to run the below command from java code getting the below error.
Command:
sudo -u karuser -s /bin/bash /bank/karunix/bin/build_cycles.sh
Error:
sudo: sorry,... (8 Replies)
Discussion started by: Satyak
8 Replies
3. Shell Programming and Scripting
Hi All,
I running a unix command using sudo option inside shell script. Its working well. But in crontab the same command is not working and its throwing
"sudo: sorry, you must have a tty to run sudo". I do not have root permission to add or change settings for my userid. I can not even ask... (9 Replies)
Discussion started by: Apple1221
9 Replies
4. UNIX for Advanced & Expert Users
I am not sure if I am using the correct terminology but somehow my tty keeps changing on me. The man pages are confusing to me on what exactly the tty is. This is what I see when I run the tty command. Could anyone explain why my tty keeps changing?
~ $ tty
/dev/pts/1
~ $ tty
/dev/pts/0 (6 Replies)
Discussion started by: cokedude
6 Replies
5. Linux
It's happened multiple times and I can't figure out why it's happening or how to undo it, but hitting CTRL-S seems to disable the given TTY on 'nixes of various flavors. Killing the pid doesn't bring the tty back, I end up having to use other tty's until I reboot.
Anyone got some information for... (2 Replies)
Discussion started by: thmnetwork
2 Replies
6. UNIX for Dummies Questions & Answers
When I do a who command I get the following:
mohit :0 2009-04-07 14:07
mohit pts/0 2009-04-07 17:25 (:0.0)
mohit pts/1 2009-04-09 12:07 (:0.0)
mohit pts/2 2009-04-16 11:38 (:0.0)
mohit pts/3 2009-04-16 16:09 (:0.0)
mohit pts/4 ... (1 Reply)
Discussion started by: mojoman
1 Replies
7. Shell Programming and Scripting
Hey folks! I'm trying to run a tcpdump command that monitors for possible malicious traffic. I want to be able to run this on any of several remote boxes that I monitor which all have different capture interfaces. I've gotten the script to the point where it logs into the box and attempts to run... (8 Replies)
Discussion started by: JASI
8 Replies
8. UNIX for Dummies Questions & Answers
hi iam very new to linux can anyone tell me about pts and tty
acctually today morning i logged into my pc at 9:51
when i have given #who
it has given
sam tty7 9:51
sam pts/1 10:11
so what does it mean (1 Reply)
Discussion started by: praneel2k
1 Replies
9. AIX
Hi All
can anyone tell me what is the meaning of tty,or give me an example of this? (1 Reply)
Discussion started by: magasem
1 Replies
10. Programming
Hi gurus,
Need help to code some tools dealing with all the tty thingies, raw mode etc ....
Can you juss point me to some cool links related to tty programming, i've tried google but found none so far :confused:
Thanks all. (2 Replies)
Discussion started by: andryk
2 Replies