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 09-29-2009, 02:05 AM   #1
gr8linux
Member
 
Registered: May 2009
Posts: 44

Rep: Reputation: 15
Smile ping command


hi
i want to know how does ping command work? and what does it mean by option -b, -B, and -d ; i went through the man page but i didnt understand the meaning of these options.... plz help me with some example.
thanx!!!!
 
Old 09-29-2009, 02:10 AM   #2
~sHyLoCk~
Senior Member
 
Registered: Jul 2008
Location: /dev/null
Posts: 1,173
Blog Entries: 12

Rep: Reputation: 129Reputation: 129
Code:
man ping
 
Old 09-29-2009, 02:16 AM   #3
gr8linux
Member
 
Registered: May 2009
Posts: 44

Original Poster
Rep: Reputation: 15
Smile

Quote:
Originally Posted by ~sHyLoCk~ View Post
Code:
man ping
i know this buddy.... and already read this... but the man page couldn't clear these options..
 
Old 09-29-2009, 02:17 AM   #4
linuxlover.chaitanya
Senior Member
 
Registered: Apr 2008
Location: Nagpur, India
Distribution: Cent OS 5/6, Ubuntu Server 10.04
Posts: 4,629

Rep: Reputation: Disabled
Excerpt from man page:

Code:
ping uses the ICMP protocol’s mandatory ECHO_REQUEST datagram to elicit
       an  ICMP  ECHO_RESPONSE from a host or gateway.  ECHO_REQUEST datagrams
       (‘‘pings’’) have an IP and ICMP header, followed by  a  struct  timeval
       and  then  an  arbitrary  number  of ‘‘pad’’ bytes used to fill out the
       packet.
Code:
-b     Allow pinging a broadcast address.

       -B     Do not allow ping to  change  source  address  of  probes.   The
              address is bound to one selected when ping starts.
Code:
 -d     Set  the SO_DEBUG option on the socket being used.  Essentially,
              this socket option is not used by Linux kernel.
What did not you understand in this? Can you elaborate?
 
Old 09-29-2009, 03:06 AM   #5
markush
Senior Member
 
Registered: Apr 2007
Location: Germany
Distribution: Slackware
Posts: 3,979

Rep: Reputation: 850Reputation: 850Reputation: 850Reputation: 850Reputation: 850Reputation: 850Reputation: 850
Hi gr8linux,

ping is part of the icmp-protocol (Internet-Control-Message-Protokol). I'd suggest to google for icmp. Reading http://en.wikipedia.org/wiki/Interne...ssage_Protocol will point you in the right direction.

Markus
 
Old 09-29-2009, 03:10 AM   #6
GlennsPref
Senior Member
 
Registered: Apr 2004
Location: Brisbane, Australia
Posts: 3,366
Blog Entries: 33

Rep: Reputation: 216Reputation: 216Reputation: 216
Hi generally I use the ping command like this...

ping -c 4 (address number or website name)
This will send a ping 4 times to the related address and display the outcome of each. -c = count

cheers, Glenn

Last edited by GlennsPref; 09-29-2009 at 03:11 AM.
 
Old 09-29-2009, 03:20 AM   #7
Fred Caro
Member
 
Registered: May 2007
Posts: 999

Rep: Reputation: 166Reputation: 166
dear sir

ping is the same essentially on Windows as on unix. The minus p,t, and god knows what is an option, which takes a bit of learning- best of luck.

Fred.
 
Old 09-29-2009, 10:22 AM   #8
BashTin
Member
 
Registered: May 2003
Location: West Midlands, United Kingdom.
Distribution: Slackware 14.1
Posts: 261

Rep: Reputation: 32
Your kidding me right linuxlover.chaitanya. You expect a none geek to understand those man page entries??

Code:
Allow pinging a broadcast address.

       -B     Do not allow ping to  change  source  address  of  probes.   The
              address is bound to one selected when ping starts.
which means??

Code:
 -d     Set  the SO_DEBUG option on the socket being used.  Essentially,
              this socket option is not used by Linux kernel.
and this? Just set the debug log level I suppose??

BashTin
 
Old 09-29-2009, 11:23 AM   #9
malekmustaq
Senior Member
 
Registered: Dec 2008
Location: root
Distribution: Slackware & BSD
Posts: 1,613

Rep: Reputation: 433Reputation: 433Reputation: 433Reputation: 433Reputation: 433
gr8linux,

if you want to read something about tcp-ip you may visit this site link.

Hope this helps.
 
Old 09-29-2009, 01:54 PM   #10
Wim Sturkenboom
Senior Member
 
Registered: Jan 2005
Location: Roodepoort, South Africa
Distribution: Slackware 10.1/10.2/12, Ubuntu 12.04, Crunchbang Statler
Posts: 3,786

Rep: Reputation: 282Reputation: 282Reputation: 282
Your question is not about ping but about networking. If you don't understand networking, you can not understand some of the ping options.

So time to study some networking 'basics'. If I had a link, I would provide one; sorry.
 
Old 12-24-2009, 12:00 AM   #11
jhon1986
LQ Newbie
 
Registered: Dec 2009
Posts: 2

Rep: Reputation: 0
Thanks

Hi I am jhon.
 
Old 12-24-2009, 12:01 AM   #12
jhon1986
LQ Newbie
 
Registered: Dec 2009
Posts: 2

Rep: Reputation: 0
Thanks

advertising removed

Last edited by pixellany; 12-24-2009 at 09:35 AM.
 
Old 12-24-2009, 12:12 AM   #13
linuxlover.chaitanya
Senior Member
 
Registered: Apr 2008
Location: Nagpur, India
Distribution: Cent OS 5/6, Ubuntu Server 10.04
Posts: 4,629

Rep: Reputation: Disabled
And that looks like SPAM............Reported.
 
  


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
[SOLVED] Piping twice the ping command noeldum Linux - Newbie 3 07-05-2009 10:39 AM
ping command hck_sec General 10 03-01-2007 06:48 PM
Simple question about command syntax ping/log ping results ohalnet Linux - Networking 1 07-25-2006 05:46 AM
ping command hypnotiks Linux - Networking 1 07-15-2004 10:34 PM
Ping command Manny88 Linux - General 41 09-24-2003 02:27 PM


All times are GMT -5. The time now is 03:56 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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration