Date: Sat, 8 Jul 2006 12:29:32 -0500 From: Dan Nelson <dnelson@allantgroup.com> To: Ensel Sharon <user@dhp.com> Cc: freebsd-questions@freebsd.org Subject: Re: can iostat _really_ behave like top ? Message-ID: <20060708172932.GA94800@dan.emsphone.com> In-Reply-To: <Pine.LNX.4.21.0607081256170.12027-100000@shell.dhp.com> References: <Pine.LNX.4.21.0607081256170.12027-100000@shell.dhp.com>
next in thread | previous in thread | raw e-mail | index | archive | help
In the last episode (Jul 08), Ensel Sharon said: > When I run `top`, I get a single screen (ncurses ?) that refreshes itself > _in place_. > > However, when I run iostat in "top mode": > > iostat -h -w 1 > > it does not refresh in place, rather it creates line after line, > eventually scrolling off the screen, etc. > > Is there any way to use iostat like top, so I can have a single, > constantly refreshing screen to look at once in a while ? How about something like: iostat -h -w 1 | sed -e "/tty/s/^/$(echotc cl)/" to insert a clearscreen whenever the header is printed (i.e. the device ordering changes or 20 lines are printed) Then again, what do you have against scrolling? With your original command, not only do you see the last screenful of stats even when devices change order, but you can scroll back and see farther back if you want to. -- Dan Nelson dnelson@allantgroup.com
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20060708172932.GA94800>