LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 04-20-2017, 07:08 AM   #1
NotionCommotion
Member
 
Registered: Aug 2012
Posts: 762

Rep: Reputation: Disabled
How to find information about a given process?


For instance, what is "writeback"? Maybe it has always been there, but I don't recognize it. How do I learn what it is? Below is my interpretation of ps's output. Thanks

User: The user who started the process
PID: the process ID
%CPU and %MEM: The resources being used.
VSZ: Virtual memory being used?
RSS: Resident set size, non-swapped virtual memory?
TTY: The terminal accessing?
STAT: The status? For this process, it is in interruptible sleep (waiting for an event to complete) and is high-priority (not nice to other users)?
START: When it was started? Date only and not time?
TIME: The amount of time it has run?
COMMAND: The name of the process?


Code:
michael@raspberrypi3:~ $ ps aux
USER       PID %CPU %MEM    VSZ   RSS TTY      STAT START   TIME COMMAND
...
root        26  0.0  0.0      0     0 ?        S<   Apr13   0:00 [writeback]
...
michael   5330  0.0  0.2   4816  2164 pts/0    R+   11:53   0:00 ps aux
michael@raspberrypi3:~ $ whereis writeback
writeback:
michael@raspberrypi3:~ $ whereis [writeback]
[writeback]:
michael@raspberrypi3:~ $
 
Old 04-20-2017, 07:14 AM   #2
Tanner9
LQ Newbie
 
Registered: Apr 2017
Posts: 7

Rep: Reputation: Disabled
man writeback
 
Old 04-20-2017, 07:21 AM   #3
NotionCommotion
Member
 
Registered: Aug 2012
Posts: 762

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by Tanner9 View Post
man writeback
Code:
michael@raspberrypi3:~ $ man writeback
No manual entry for writeback
michael@raspberrypi3:~ $
In addition to what writeback is, what do the brackets around it mean?
 
Old 04-20-2017, 07:26 AM   #4
Tanner9
LQ Newbie
 
Registered: Apr 2017
Posts: 7

Rep: Reputation: Disabled
Quote:
Originally Posted by NotionCommotion View Post
Code:
michael@raspberrypi3:~ $ man writeback
No manual entry for writeback
michael@raspberrypi3:~ $
In addition to what writeback is, what do the brackets around it mean?
It's not in his post.

Last edited by Tanner9; 04-20-2017 at 07:39 AM.
 
Old 04-20-2017, 03:18 PM   #5
NotionCommotion
Member
 
Registered: Aug 2012
Posts: 762

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by Tanner9 View Post
It's not in his post.
Meaning???
 
Old 04-20-2017, 03:37 PM   #6
linux4evr5581
Member
 
Registered: Sep 2016
Location: USA
Posts: 275

Rep: Reputation: Disabled
The /proc directory is a virtual file system that the kernel uses to communicate with you (and to programs like top) about the the state of a process/program. In that directory you'll find information about all running processes. The processes are the numbers displayed and to view info available on it type ls /proc/number... Also look into file descriptors (fd) as they are given to a process based on what that process wants to do to a file.

Last edited by linux4evr5581; 04-20-2017 at 04:37 PM.
 
Old 04-20-2017, 04:25 PM   #7
Habitual
LQ Veteran
 
Registered: Jan 2011
Location: Abingdon, VA
Distribution: Catalina
Posts: 9,374
Blog Entries: 37

Rep: Reputation: Disabled
Quote:
Originally Posted by NotionCommotion View Post
Code:
michael@raspberrypi3:~ $ ps aux
USER       PID %CPU %MEM    VSZ   RSS TTY      STAT START   TIME COMMAND
...
root        26  0.0  0.0      0     0 ?        S<   Apr13   0:00 [writeback]
Code:
sudo lsof -p 26
and process the results. The pid may change, but lsof -p <pid> is gold.

ss utility/program does same but my.fu there is weak.

Just sayin'

wrt:
Quote:
Originally Posted by NotionCommotion View Post
what do the brackets around it mean?
Believe that would be be indicative of a kernel process or thread. AFAIK, best guess.

Last edited by Habitual; 04-20-2017 at 04:28 PM.
 
Old 04-20-2017, 04:50 PM   #8
hydrurga
LQ Guru
 
Registered: Nov 2008
Location: Pictland
Distribution: Linux Mint 20 MATE
Posts: 8,048
Blog Entries: 5

Rep: Reputation: 2917Reputation: 2917Reputation: 2917Reputation: 2917Reputation: 2917Reputation: 2917Reputation: 2917Reputation: 2917Reputation: 2917Reputation: 2917Reputation: 2917
Square brackets indicate that the process's arguments cannot be located.

https://unix.stackexchange.com/quest...processes-mean
 
Old 04-20-2017, 08:26 PM   #9
AwesomeMachine
LQ Guru
 
Registered: Jan 2005
Location: USA and Italy
Distribution: Debian testing/sid; OpenSuSE; Fedora; Mint
Posts: 5,513

Rep: Reputation: 1009Reputation: 1009Reputation: 1009Reputation: 1009Reputation: 1009Reputation: 1009Reputation: 1009Reputation: 1009
Writeback is a form of data cacheing. It has to do with Linux cacheing memory to a disk and back again. Writeback cacheing is faster but less reliable than writethrough, because it notifies the system that data has been written, before that data is committed to disk. When the system is less busy, it writes the cache commits to disk.

Cacheing is fundamental to computing. Disk is the slowest part of the machine. Memory is faster than disk. And CPU is faster than memory. Cacheing is the art of guessing which data will be needed and keeping it in the faster media.

So, if the CPU can fetch data from memory it's quicker than fetching it from disk. If the cacheing algorithm works, it is correct more often than not.

The CPU also has cacheing in which the CPU guesses what data it might need and keeps it in the CPU cache rather than fetching it out of slower memory. Without cacheing, computers wouldn't work well.

Writeback is the kernel cacheing process.
 
Old 04-20-2017, 10:53 PM   #10
Shadow_7
Senior Member
 
Registered: Feb 2003
Distribution: debian
Posts: 4,137
Blog Entries: 1

Rep: Reputation: 873Reputation: 873Reputation: 873Reputation: 873Reputation: 873Reputation: 873Reputation: 873
The [writeback] brackets means that it's part of the linux kernel. (or very oddly named).

$ egrep -r -i writeback /lib/modules/$(uname -r)/* 2>&1 | grep -i .ko

Seems to be in a lot of things. I'd guess nfs. Although I'm not sure how to test that theory without stopping the usage and unloading the module and checking if it's still in the ps output. Which you can't do if it's not a module and compiled into the kernel as implied by the [] around the process name.

$ lsmod

Should be in both lists whatever it is. Except when not a module.

$ cat /boot/config | grep -i \=y$

If it's not a module it'll be in that list (quite a long one probably).
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Need Help to find the process running by particular user and kill process one by one LittleMaster Linux - Newbie 1 02-09-2013 02:03 PM
Regarding process information Navjot Arora Programming 1 06-19-2012 03:28 PM
How to find which process started a daemon process in autostart? indiajoe Linux - Desktop 4 10-25-2011 02:19 AM
Find process information by name. archShade Linux - Software 1 05-17-2010 12:17 AM
How to find out indone information and datablocks information in a file system chaitanya1982 Linux - Newbie 1 09-24-2008 01:58 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 04:50 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration