LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   WARN: stdin/stdout is not a TTY; using /dev/console (https://www.linuxquestions.org/questions/linux-newbie-8/warn-stdin-stdout-is-not-a-tty%3B-using-dev-console-678407/)

alirezan1 10-22-2008 05:28 PM

WARN: stdin/stdout is not a TTY; using /dev/console
 
hi guys
I have an application (DRBD) that I'm trying to start using a bash script. When I start the application with /etc/init.d/drbd start, it looks for another computer to connect to. It asks if the user wants to wait for the peer or not but when I use echo or pass the answer, it just gives me that error message: WARN: stdin/stdout is not a TTY; using /dev/console

Quote:

# service drbd start
Starting DRBD resources: [ d(drbd1) s(drbd1) n(drbd1) ].
..........
***************************************************************
DRBD's startup script waits for the peer node(s) to appear.
- In case this node was already a degraded cluster before the
reboot the timeout is 120 seconds. [degr-wfc-timeout]
- If the peer was available before the reboot the timeout will
expire after 0 seconds. [wfc-timeout]
(These values are for resource 'drbd1'; 0 sec -> wait forever)
To abort waiting enter 'yes' [ 14]:
so I have to say "yes" to abort waiting for peer forever. When I do this:

echo yes | service drbd start
it shows me that error message. Any way I can just do it? anyone?

thanks

JZL240I-U 10-23-2008 02:34 AM

The script starts a new instance of the shell. You have to connect that to your interactive shell (e.g. via parameters). I'd guess (!) that's why your script has no tty.

That is only valid in case i understood your question correctly ;).

alirezan1 10-23-2008 01:43 PM

Quote:

Originally Posted by JZL240I-U (Post 3319459)
The script starts a new instance of the shell. You have to connect that to your interactive shell (e.g. via parameters). I'd guess (!) that's why your script has no tty.

That is only valid in case i understood your question correctly ;).

Can you please tell me how I can do this?

Thanks

JZL240I-U 10-27-2008 09:44 AM

Sorry, I'm no expert and being in a real hurry I don't have the time to search for the place where this was mentioned. Try beginning here:

http://www.tldp.org/LDP/Bash-Beginne...e.html#chap_03

and look for "bash shells" as a key word. Here is more

http://www.tldp.org/guides.html#abs
http://www.justlinux.com/nhf/Shells/..._Commands.html

Good luck.

nikhil.manohar 06-07-2010 09:00 PM

Hello alirezan1,

I'm facing same problem.
Any luck on this? Did you mamange to fix this?

Please help.

Thanks,
NM.


All times are GMT -5. The time now is 08:01 AM.