LinuxQuestions.org
Visit the LQ Articles and Editorials section
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices

Reply
 
Search this Thread
Old 05-01-2012, 04:11 AM   #1
sourav garai
LQ Newbie
 
Registered: Mar 2012
Posts: 6

Rep: Reputation: Disabled
Unhappy What does " / " mean?


There was a command i found in a book. This is a single command.

iptables -A FORWARD -m tcp -p tcp -s 0/0 --sport 80 -d 172.16.1.0/24 /
--syn -j DROP

What does " / " mean? The " / " just before --syn.
Is it necessary to give?

Last edited by sourav garai; 05-01-2012 at 04:14 AM.
 
Old 05-01-2012, 04:17 AM   #2
em31amit
Member
 
Registered: Apr 2012
Location: /root
Distribution: Ubuntu, Redhat, Fedora, CentOS
Posts: 190

Rep: Reputation: 55
it should "\" not "/". "\" is just to switch new line in command continuation . it should not be "/" here. It may be they have typed it wrong.
 
1 members found this post helpful.
Old 05-01-2012, 04:25 AM   #3
sourav garai
LQ Newbie
 
Registered: Mar 2012
Posts: 6

Original Poster
Rep: Reputation: Disabled
Smile Thanks

Ya .. i guessed it was for switching to a new line. Can u please suggest a link where i can read more about this?? In the book they have used " / " in all line switching. So i am little confused.
 
Old 05-01-2012, 04:32 AM   #4
em31amit
Member
 
Registered: Apr 2012
Location: /root
Distribution: Ubuntu, Redhat, Fedora, CentOS
Posts: 190

Rep: Reputation: 55
Start with Beginner's guide and understand concepts how to make the rules and logic and MAN pages

check

tldp.org,
http://www.frozentux.net/iptables-tu...-tutorial.html
http://www.thegeekstuff.com/2011/01/...-fundamentals/

and At the last.. google is the best option
 
Old 05-01-2012, 04:40 AM   #5
fukawi1
Member
 
Registered: Apr 2009
Location: Melbourne
Distribution: Fedora & CentOS
Posts: 854

Rep: Reputation: 189Reputation: 189
Quote:
3.1.2.1 Escape Character

A non-quoted backslash ‘\’ is the Bash escape character. It preserves the literal value of the next character that follows, with the exception of newline. If a \newline pair appears, and the backslash itself is not quoted, the \newline is treated as a line continuation (that is, it is removed from the input stream and effectively ignored).
http://www.gnu.org/software/bash/man...cape-Character

Searching the above document for "backslash" will explain all the possible uses of the backslash character as far as BASH is concerned.
 
1 members found this post helpful.
Old 05-01-2012, 05:07 AM   #6
sourav garai
LQ Newbie
 
Registered: Mar 2012
Posts: 6

Original Poster
Rep: Reputation: Disabled
So thats an escape character.
Thanks again.
 
  


Reply

Tags
firewall


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 can I "cat" or "grep" a file to ignore lines starting with "#" ??? callagga Linux - Newbie 7 08-16-2013 07:58 AM
unpredictable "delete" "move to trash" or "cut" file menu option dorianrenato Linux - General 3 11-28-2011 07:41 PM
net working eth0 eth1 wlan0 "no connection" "no LAN" "no wi-fi" Cayitano Linux - Newbie 5 12-09-2007 08:11 PM
Standard commands give "-bash: open: command not found" even in "su -" and "su root" mibo12 Linux - General 4 11-11-2007 11:18 PM
LXer: Displaying "MyComputer", "Trash", "Network Servers" Icons On A GNOME Desktop LXer Syndicated Linux News 0 04-02-2007 09:31 AM


All times are GMT -5. The time now is 12:09 AM.

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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration