Hide

What's this?

commandlinefu.com is the place to record those command-line gems that you return to again and again.

Delete that bloated snippets file you've been using and share your personal repository with the world. That way others can gain from your CLI wisdom and you from theirs too. All commands can be commented on, discussed and voted up or down.


Get involved!

You can sign-in using OpenID credentials, or register a traditional username and password.

First-time OpenID users will be automatically assigned a username which can be changed after signing in.

Universal configuration monitoring and system of record for IT.
Hide

Stay in the loop…

Follow the Tweets.

Every new command is wrapped in a tweet and posted to Twitter. Following the stream is a great way of staying abreast of the latest commands. For the more discerning, there are Twitter accounts for commands that get a minimum of 3 and 10 votes - that way only the great commands get tweeted.

» http://twitter.com/commandlinefu
» http://twitter.com/commandlinefu3
» http://twitter.com/commandlinefu10

Subscribe to the feeds.

Use your favourite RSS aggregator to stay in touch with the latest commands. There are feeds mirroring the 3 Twitter streams as well as for virtually every other subset (users, tags, functions,…):

Subscribe to the feed for:

Hide

News

May 19, 2015 - A Look At The New Commandlinefu
I've put together a short writeup on what kind of newness you can expect from the next iteration of clfu. Check it out here.
March 2, 2015 - New Management
I'm Jon, I'll be maintaining and improving clfu. Thanks to David for building such a great resource!
Hide

Top Tags

Hide

Functions

Psst. Open beta.

Wow, didn't really expect you to read this far down. The latest iteration of the site is in open beta. It's a gentle open beta-- not in prime-time just yet. It's being hosted over at UpGuard (link) and you are more than welcome to give it a shot. Couple things:

  • » The open beta is running a copy of the database that will not carry over to the final version. Don't post anything you don't mind losing.
  • » If you wish to use your user account, you will probably need to reset your password.
Your feedback is appreciated via the form on the beta page. Thanks! -Jon & CLFU Team

Count TCP States From Netstat

Terminal - Count TCP States From Netstat
netstat -an | awk '/tcp/ {print $6}' | sort | uniq -c
2010-05-06 17:04:37
User: Kered557
Functions: awk netstat sort uniq
1
Count TCP States From Netstat

Counts TCP states from Netstat and displays in an ordered list.

Alternatives

There are 4 alternatives - vote for the best!

Terminal - Alternatives

Know a better way?

If you can do better, submit your command here.

What others think

Something similar can be done with lsof:

# lsof | awk '/TCP/ { print $NF }' | sort | uniq -c

Comment by zlemini 340 weeks ago

Not long ago, a brand new craze of females result from across the world: Over-sized handbag. A number of choose given that they assume that cool, and some use them commercially their own adaptability. If you have never but made the purchase, listed below are my personal explanations why each lady really should have this type of bag in their closet. 1. Place Oversized could handbags are big! You can place every thing you'll need inside it as well as have a number of area quit inside. You can place your own secrets, budget, papers, equipment, make-up, telephone and all sorts of what exactly you need for your baby (in case you have a single) and also a section of the second half's things. With the very much storage space isn't any speculate that a majority of ladies have turn out to be dependent on such a budget. 2. Overall flexibility An large handbag could be http://www.hermesbeltsbirkinkellybag.co.uk/ changed to the diaper bag or even a bag where you can carry your current home gym equipment. They're intelligent and have as numerous spaces when you bring your paperwork as well as your little one's dairy inside same bag without them perhaps getting deeper. This particular is really what We phone an efficient girls bag! 3. Fashion Oversized females handbags have returned in fashion, for those times you want to have an elegant seem you definitely need to have no less than one bag on this kind. It certainly won't be long before you are going to completely get into appreciate with it and do not want to overlooked. In add-on, they search great along with any everyday attire, you will find a pair of trousers or maybe a mini blouse with good heeled footwear. 4 They generate you peer thinner If there's something it is going to make females leaner, then you can certainly bet of which object will unquestionably become # 1 within a bit of time. And this transpired with large handbags, way too. Because they can be big and ready, many people right away sketch their particular awareness. Thus, whenever people consider the individual who possesses all of them, by means of contrast with all the bag, the thing is that the face way slimmer. This is the foremost method I've seen of which dropping a couple pounds in the eyes of others without doing nearly anything! Large women of all ages handbags include the best selection for effective women who want to have every one of the important issues with these. They could be challenging occasionally, but they're extremely helpful as well as attractive, usually are not are they going to wish to throw in the towel?

Comment by stephanieg915 1 day ago

Your point of view

You must be signed in to comment.