Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #82243
| Date | 2014-12-09 22:41 +0530 |
|---|---|
| Subject | Solution to a problem,write terminal output to file |
| From | Robert Clove <cloverobert@gmail.com> |
| Newsgroups | comp.lang.python |
| Message-ID | <mailman.16774.1418146959.18130.python-list@python.org> (permalink) |
[Multipart message — attachments visible in raw view] - view raw
Hi All, I am facing a problem in python coding that is I have a client server program(programs a re in c code and client and server are its executable) on Linux machine. To run client i do this ./strace -c client and to run server i type this ./strace -c server When i give ctrl+c to client i see some output on the terminal, i want that output in the file i mean i want to send the ctrl+c signal programmatic ally to client after a minute and write the output in the file. if i use subprocess.Popen to execute ./strace -c client and give ctrl+c signal i don''t see any output on the terminal but if i see os.system to execute ./strace -c client i see the output on terminal.Now i want to send the ctrl+c signal to os.system and write the terminal output into a file. Please help me to do that. Can you provide a pseudo script. I will be very thankfull to you. Regards
Back to comp.lang.python | Previous | Next | Find similar | Unroll thread
Solution to a problem,write terminal output to file Robert Clove <cloverobert@gmail.com> - 2014-12-09 22:41 +0530
csiph-web