Sponsored Content
Top Forums UNIX for Advanced & Expert Users Redirect Topas output to a file Post 302603955 by Corona688 on Friday 2nd of March 2012 11:23:02 AM
Old 03-02-2012
Interactive commands like topas use terminal control sequences to refresh the screen, move the cursor, and the like. Their output won't make sense when viewed with anything except a terminal. This is a frequent question and there's not much of a good solution. Sometimes stripping out the control sequences is enough but more often that just ruins it more, since the text may have been drawn in arbitrary order.

What information are you trying to get, precisely? There's probably more suitable noninteractive programs to get it.
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

redirect output to file?

Hi: I am currently working on a program which requires direct its ouput to a file here is an example ./proram arg_1 arg_2 when program ends all output will be arg_2 file Is that possible I am not a bad programmer, However I am stuck there. Can anyone give a hint? Thanks SW (1 Reply)
Discussion started by: slackware
1 Replies

2. UNIX for Dummies Questions & Answers

Redirect output to a file

Ahhhrrrggg I'm having a brain fart... I want to take the output of a command and redirect it to a file... This works.... $ man cp | cat >> copy_help but this doesn't keytool -help |cat >> keytool_help It just produces... these lines... more keytool_help ] ... ... (11 Replies)
Discussion started by: jimmyc
11 Replies

3. UNIX for Dummies Questions & Answers

redirect output to a file name

Hi all!! is possible to assign the output of some command to filename, i.e. grep_output.txt Otherwise, I want to open a new file which name is inside another, how can I do it? Thanks a lot! (7 Replies)
Discussion started by: csecnarf
7 Replies

4. AIX

topas -P save output

hi i have server monitor script which totally depends upon the output of TOP which works fine on HP. now i am told to put same script on aix i found that topas -P produces same output but it doesnt redirect output to file i have to kill/terminate it. is there any other way to this. as the... (0 Replies)
Discussion started by: zedex
0 Replies

5. AIX

How to redirect output of topas?

Hi , How do i redirect output of topas to a file. i did not find any such option in topas command. Regards, Ashok (2 Replies)
Discussion started by: ashokd001
2 Replies

6. AIX

topas -P output to file

Hi, I need to output to a file, what will be ftp'ed to windows the output of a topas -P command in AIX. I can't install anything in the server (because it's the bank AIX server) but i need to control and keep the history of the % cpu that my processes use. I tried to use topas -R >>... (7 Replies)
Discussion started by: jtmartins
7 Replies

7. Shell Programming and Scripting

How to redirect output of ls to a file?

Hi All, I want to redirect only the file names to a new file from the ls -ltr directroy. how Can i do it. my ls -ltr output will be as below. -rwxr-xr-x 1 118 103 28295 Jul 26 2006 event.podl -rwxr-xr-x 1 118 103 28295 Jul 26 2006 xyz.podl I want my new file... (6 Replies)
Discussion started by: girish.raos
6 Replies

8. Shell Programming and Scripting

script to mail monitoring output if required or redirect output to log file

Below script perfectly works, giving below mail output. BUT, I want to make the script mail only if there are any D-Defined/T-Transition/B-Broken State WPARs and also to copy the output generated during monitoring to a temporary log file, which gets cleaned up every week. Need suggestions. ... (4 Replies)
Discussion started by: aix_admin_007
4 Replies

9. AIX

Record topas command output

How to record output of below command in a text file. topas -P or is there any other command which will do the same thing in AIX. I would like to get a report something similar to below commands. top -b prstat -c (5 Replies)
Discussion started by: NarayanaPrakash
5 Replies

10. Shell Programming and Scripting

Redirect script output to a file and mail the output

Hi Guys, I want to redirect the output of 3 scripts to a file and then mail the output of those three scripts. I used below but it is not working: OFILE=/home/home1/report1 echo "report1 details" > $OFILE =/home/home1/1.sh > $OFILE echo... (7 Replies)
Discussion started by: Vivekit82
7 Replies
CURSES_REFRESH(3)					   BSD Library Functions Manual 					 CURSES_REFRESH(3)

NAME
curses_refresh, refresh, wrefresh, wnoutrefresh, doupdate, leaveok, flushok -- curses terminal update routines LIBRARY
Curses Library (libcurses, -lcurses) SYNOPSIS
#include <curses.h> int refresh(void); int wrefresh(WINDOW *win); int wnoutrefresh(WINDOW *win); int doupdate(void); int leaveok(WINDOW *win, boolf flag); int flushok(WINDOW *win, boolf flag); DESCRIPTION
These functions update the terminal with the contents of stdscr or of the specified window(s). The refresh() function causes curses to propagate changes made to stdscr to the terminal display. Any changes made to subwindows of stdscr are also propagated. The wrefresh() function is the same as the refresh() function, excepting that changes are propagated to the terminal from the window speci- fied by win. The wnoutrefresh() function performs the internal processing required by curses to determine what changes need to be made to synchronise the internal screen buffer and the terminal but does not modify the terminal display. The doupdate() function updates the terminal display to match the internal curses representation of the display. The wnoutrefresh() and doupdate() functions can be used together to speed up terminal redraws by deferring the actual terminal updates until after a batch of updates to multiple windows has been done. The refresh() function is equivalent to wnoutrefresh(stdscr) followed by doupdate(). The leaveok() function determines whether refresh operations may leave the screen cursor in an arbitrary position on the screen. Setting flag to FALSE ensures that the screen cursor is positioned at the current cursor position after a refresh operation has taken place. The flushok() function is used to determine whether or not the screen's output file descriptor will be flushed on refresh. Setting flag to TRUE will cause the output to be flushed. RETURN VALUES
Functions returning pointers will return NULL if an error is detected. The functions that return an int will return one of the following values: OK The function completed successfully. ERR An error occurred in the function. SEE ALSO
curses_pad(3), curses_touch(3), getch(3) NOTES
Calling wrefresh() on a new, unchanged window has no effect. STANDARDS
The NetBSD Curses library complies with the X/Open Curses specification, part of the Single Unix Specification. HISTORY
The Curses package appeared in 4.0BSD. BSD
March 26, 2003 BSD
All times are GMT -4. The time now is 11:09 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy