Support LQ: Use code LQ3 and save $3 on Domain Registration
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
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!


  Search this Thread
Old 11-15-2007, 08:26 AM   #1
LQ Newbie
Registered: Nov 2007
Posts: 1

Rep: Reputation: 0
Calculate total number of mailq items


How would I be able to simply return the total number of mailq items, rather than have the whole mail queue list displayed? I'd like to use something like:

# mailq
2102 results

Ed .
Old 11-15-2007, 11:29 AM   #2
Registered: Apr 2002
Location: in a fallen world
Distribution: slackware by choice, others too :} ... android.
Posts: 23,066
Blog Entries: 11

Rep: Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910

and welcome to LQ!

I currently don't have access to a mail-server, what's the format
you really get? If it's one per line just do
mailq|wc -l



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
How to calculate the total RAM used by several processes rjlee Linux - Software 3 07-19-2007 05:33 PM
I don't understand how to calculate the total value of (ls -l) greeting Linux - General 7 08-12-2006 05:28 AM
How can I see the total number of file locks being currently used? abefroman Linux - Software 1 11-08-2005 06:16 PM
How to limit number of items in .recently-used neo_in_matrix Linux - Newbie 2 06-09-2005 11:04 AM
File Input, how to get number of items? ftgow Programming 1 03-11-2005 01:31 AM

All times are GMT -5. The time now is 08:28 PM.

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