LinuxQuestions.org
Review your favorite Linux distribution.
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 03-25-2013, 11:24 AM   #1
roshu10
LQ Newbie
 
Registered: Mar 2013
Posts: 2

Rep: Reputation: Disabled
Obtain the status of all I/O ports connected to system..


hi
how do i get the status of all active I/O ports connected to system ?
As much as i know we can use "lsusb" and "lspci" commands but the problem is it will list all the ports connected to system(it will also list the entries for non active ports also)
how can i solve this problem ??

Any help ??
 
Old 03-25-2013, 11:47 AM   #2
ukiuki
Senior Member
 
Registered: May 2010
Location: Planet Earth
Distribution: Debian
Posts: 1,030

Rep: Reputation: 385Reputation: 385Reputation: 385Reputation: 385
Try this:
Code:
cat /proc/ioports
Also there is a program iotop.

Regards
 
1 members found this post helpful.
Old 03-25-2013, 11:53 AM   #3
roshu10
LQ Newbie
 
Registered: Mar 2013
Posts: 2

Original Poster
Rep: Reputation: Disabled
thanks for reply

Quote:
Originally Posted by ukiuki View Post
Try this:
Code:
cat /proc/ioports
Also there is a program iotop.

Regards
thanks for the reply
can you pl tell much more about iotop program
i have already tried this
cat /proc/ioports
but the problem is it will list many unnecessary things too..

i have to write a program in c language and i will use popen() or system() function to call the commands
which should just list the ports(just mention the ports names and their status..

Last edited by roshu10; 03-25-2013 at 11:55 AM. Reason: for more simplification
 
Old 03-25-2013, 03:14 PM   #4
ukiuki
Senior Member
 
Registered: May 2010
Location: Planet Earth
Distribution: Debian
Posts: 1,030

Rep: Reputation: 385Reputation: 385Reputation: 385Reputation: 385
You can reduce the output for cat using this method, example to list only dma:
Code:
cat /proc/ioports | grep dma
About iotop is probably available in the repositorie for your distro, it is top style output.

Regards
 
1 members found this post helpful.
  


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
opening ports on a windows pc connected to a linux box which serves as a gateway fieska Linux - Security 4 06-02-2009 01:19 AM
Wireless status connected, cannot ping router. vivekjoshi Linux - Wireless Networking 3 02-27-2009 09:19 AM
Obtain file system info with df AQG Solaris / OpenSolaris 1 08-02-2007 08:18 PM
what software I use to monitoring status of cisco ports. xcore_on Linux - Networking 4 07-15-2007 05:00 PM
Check for status of Serial ports in any language? BongFish Programming 11 09-11-2003 01:46 AM

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

All times are GMT -5. The time now is 01:13 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