 |
 |
quick terminal command question
|
 |
|
 |
|
Grizzled Veteran
Join Date: Apr 2002
Location: Elbonia
Status:
Offline
|
|
what is the command to show virtual memory usage in the terminal? the one where it shows pageins/pageouts after an interval of say 't' secs.
thanks
|
|
|
| |
|
|
|
 |
|
 |
|
Addicted to MacNN
Join Date: Aug 2000
Location: Retired
Status:
Offline
|
|
Originally posted by 7Macfreak:
what is the command to show virtual memory usage in the terminal? the one where it shows pageins/pageouts after an interval of say 't' secs.
thanks
I believe its the top command
|
|
Power Macintosh Dual G4
SGI Indigo2 6.5.21f
|
| |
|
|
|
 |
|
 |
|
Grizzled Veteran
Join Date: Apr 2002
Location: Elbonia
Status:
Offline
|
|
Originally posted by MacGorilla:
I believe its the top command
no no, its vm_ something
i think
|
|
|
| |
|
|
|
 |
|
 |
|
Senior User
Join Date: Dec 2001
Status:
Offline
|
|
Originally posted by 7Macfreak:
no no, its vm_ something
i think
Try typing that in the terminal and hitting the tab key.
|
|
"Think Different. Like The Rest Of Us."
iBook G4/1.2GHz | 1.25GB | 60GB | Mac OS X 10.4.2
Athlon XP 2500+/1.83GHz | 1GB PC3200 | 120GB | Windows XP
|
| |
|
|
|
 |
|
 |
|
Mac Enthusiast
Join Date: Sep 2000
Status:
Offline
|
|
|
|
|
|
| |
|
|
|
 |
|
 |
|
Forum Regular
Join Date: Oct 2002
Location: Atlanta
Status:
Offline
|
|
It's just vm_stat actually, without that extra S at the end
But as macmike42 suggested - the Tab key is great if you just remember the first couple of characters in a command. Type those first characters and press Tab twice and it will show you commands available that begin with those characters. I use it all the time, but mainly because I'm too lazy to type the whole command through  For example, typing "vm_" and pressing Tab twice will complete the vm_stat command for you. Very nice!
|
|
|
| |
|
|
|
 |
|
 |
|
Grizzled Veteran
Join Date: Apr 2002
Location: Elbonia
Status:
Offline
|
|
vm_stats, that's it, thanks guys
btw, hitting the tab key hint is not consistent. i tried it by typing "to" or just "t" and it SHOULD show top right? but it doesnt.
ah.. just tried it again with 'upt' and it shows uptime
so i guess it requires a minimum of three characters.
oh, another question.. how can i make the terminal save commands that i type in so i can bring them back by hitting the up arrow. basically saving 'history of commands'. this was on by default in 10.1
|
|
|
| |
|
|
|
 |
|
 |
|
Forum Regular
Join Date: Aug 2000
Location: UK
Status:
Offline
|
|
Originally posted by 7Macfreak:
ah.. just tried it again with 'upt' and it shows uptime
so i guess it requires a minimum of three characters.
No, it's becuase there is more than one result that starts with 'up' - there's update_prebinding, update-passwd etc. You have to press tab twice to see the full list.
|
|
|
| |
|
|
|
 |
|
 |
|
Forum Regular
Join Date: Oct 2002
Location: Atlanta
Status:
Offline
|
|
oh, another question.. how can i make the terminal save commands that i type in so i can bring them back by hitting the up arrow. basically saving 'history of commands'. this was on by default in 10.1
Yes, it's actually quite simple. Check out the README in /usr/share/tcsh/examples. Basically, if you don't have a .tcshrc-file in your home directory, do this:
Code:
echo "source /usr/share/tcsh/examples/rc" > ~/.tcshrc
That will get your command-history working.
|
|
|
| |
|
|
|
 |
|
 |
|
Grizzled Veteran
Join Date: Apr 2002
Location: Elbonia
Status:
Offline
|
|
thanks again!
and i seem to come up with another question each time one is answered..
whats the command to show the darwin version/info on the kernel?
|
|
|
| |
|
|
|
 |
|
 |
|
Forum Regular
Join Date: Oct 2002
Location: Atlanta
Status:
Offline
|
|
Originally posted by 7Macfreak:
thanks again!
and i seem to come up with another question each time one is answered..
whats the command to show the darwin version/info on the kernel?
Try this:
|
|
|
| |
|
|
|
 |
|
 |
|
Grizzled Veteran
Join Date: Apr 2002
Location: Elbonia
Status:
Offline
|
|
THANKS! 
and now i'll stop
|
|
|
| |
|
|
|
 |
|
 |
|
Forum Regular
Join Date: Oct 2002
Location: Atlanta
Status:
Offline
|
|
Originally posted by 7Macfreak:
THANKS! 
and now i'll stop
Cheers!  I know how frustating it can be when you know about a command but just can figure out what it is. One thing to do in a situation like that is to use the command apropos or whatis to search for keywords in man-pages.
|
|
|
| |
|
|
|
 |
|
 |
|
Senior User
Join Date: Feb 2003
Location: Atlanta
Status:
Offline
|
|
Originally posted by 7Macfreak:
no no, its vm_ something
i think
Top shows the vm stats also. That's what I've always used.
|
|
|
| |
|
|
|
 |
|
 |
|
Forum Regular
Join Date: Oct 2002
Location: Atlanta
Status:
Offline
|
|
Originally posted by coolmacdude:
Top shows the vm stats also. That's what I've always used.
Yes, but vm_stat shows more detailed information about your virtual memory. Running
will for example give you updated information every second. Top works as well, but will not give you as extensive information as vm_stat.
Gosh, am I talking in circles? Maybe I need some sleep

|
|
|
| |
|
|
|
 |
|
 |
|
Forum Regular
Join Date: Jan 2002
Location: Manitoba
Status:
Offline
|
|
why ot save yourself some time and just alias commands that you will use frequently? i believe that is in the documentation too but essentally you would take a command suh as this:
cdrecord -v speed=16 dev=IODVDServices driveropts=burnfree -data /tmp/bacon.iso
and alias it to somethiung simple like 'burnd' with a line like this in your .tcshrc:
alias burnd="cdrecord -v......."
it is a simple way of not having to remember specific command and their options or for those lazy people like me that get tired of writing out huge command in the terminal. essentially you can almost hotkey all of your commands if you like (ie. vm_stat becomes vm).
|
|
|
| |
|
|
|
 |
|
 |
|
Grizzled Veteran
Join Date: Apr 2002
Location: Elbonia
Status:
Offline
|
|
Originally posted by leffo:
Cheers! I know how frustating it can be when you know about a command but just can figure out what it is. One thing to do in a situation like that is to use the command apropos or whatis to search for keywords in man-pages.
the thing is, i had a file with all these commands explained but i lost the file either while installing 10.2 or switching over to my new PB
thanks for the tip tho. 
|
|
|
| |
|
|
|
 |
 |
|
 |
|
|
|
|
|

|
|
 |
Forum Rules
|
 |
 |
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
|
HTML code is Off
|
|
|
|
|
|
 |
 |
 |
 |
|
 |
|