Welcome to the Treehouse Community

The Treehouse Community is a meeting place for developers, designers, and programmers of all backgrounds and skill levels to get support. Collaborate here on code errors or bugs that you need feedback on, or asking for an extra set of eyes on your latest project. Join thousands of Treehouse students and alumni in the community today. (Note: Only Treehouse students can comment or ask questions, but non-students are welcome to browse our conversations.)

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and a supportive community. Start your free trial today.

Development Tools Console Foundations Processes Processes

Console Foundations - Processes

Jim Hoskins:

I'm stuck at the following point (about 3:58 in video):

1) treehouse ~$ top; 2) ?; 3) F; 4) press key (not specified which key); 5) F - shows "*K %CPU = CPU usage" marked 6) N - shows "*N =%MEM = memory usage (RES) marked; 7) enter.

At this point, I see my new sorting list, but I can't go back to the menu to select "a" to change sort to PID column. How to I go back & forth between the menu and the sorted list? You don't mention which key can or should be pressed to toggle between the menu & the sorted list.

2 Answers

Hi Jim,

Each time you are in the listing screen you can press F to bring up the sort screen.

So on entering top you can press F then a to sort by Process ID (PID) Once this is showing you can press F then k to sort by Percentage CPU (%CPU) as it was when you started. Each time you press the F option you can choose a new sort.

Hope that makes sense.

KB :octopus:

Kieran Black:

Thanks. I appreciate the help. I will try it again a little later today. Linux console is foreign to me. This module is my 1st exposure to it.

Jim Hoskins didn't specify in his video how to go back & forth between the top sorting screen & the top processes list. The 1st time, I pressed the spacebar, but when I pressed it again to go back, it didn't work. "Press any key" needs to be clearly defined. I even tried to look it up by Googling it, & even the people who wrote about the 2 screens didn't mention how to go back & forth between the 2 screens. They assumed a person already knew how to do it.

Like my algebra teachers taught me, "write down every single step & don't skip writing down a single step in order to arrive at the correct solution to the problem." That applies with coding, too.

Aurelian Spodarec
Aurelian Spodarec
10,789 Points

Hi Kathryn,

Could I ask you, how are you doing now? It's over 3months now, and im wondering what you learned, and what you know and how is your journey goiing so far, if thats okayh.

-Aurelian

Aurelian Spodarec:

I completed this assignment successfully.

Aurelian Spodarec
Aurelian Spodarec
10,789 Points

What do you mean? I ment if you learned HTML/CSS or JS and stuff, if 3months ago you were a beginner in all of this, and now you have a good skill to get a job or something : p