ADSL Bridge mode without authentication. 
wic-adsl configuration with Verizon DSL. No username and password supplied by ISP. No PPPoE nor PPPoA used for connection.

https://supportforums.cisco.com/thread/2137389
------------------------------------
Configuration:


interface ATM0
no ip address
ip virtual-reassembly
no snmp trap link-status
no atm ilmi-keepalive
dsl operating-mode auto
!
interface ATM0.1 point-to-point
ip address dhcp
ip nat outside
ip virtual-reassembly
no snmp trap link-status
atm route-bridged ip
pvc 0/35
encapsulation aal5snap




[ view entry ] ( 1787 views )   |  print article
Using an extended ACL as a prefix-list 
Great explanation by Darren:
http://mellowd.co.uk/ccie/?p=2201

Also see CCNP ROUTE (4th print) p. 337, 2nd paragraph.

“...show some particular interesting features for matching routes. With an extended ACL, IOS compares the source IP address parameter to the subnet number of the route and the destination IP address to the subnet mask of the route. For example, the permit ip host 172.16.101.0 host 255.255.255.0 command matches the specific route for subnet 172.16.101.0, specifically with mask 255.255.255.0 .”



[ view entry ] ( 1505 views )   |  print article
Automatic interface shutdown, when tracked interface goes down (Cisco) 
The Embedded Event Manager in IOS 12.4(2)T and higher can integrate with Object Tracking, and will allow you to run a script or IOS commands when the object state changes. With this, you could down the interface easily. If you are interested in this, let me know, and I can give you an example.

Assume you have track 11 setup to watch the interface you care about. You want to shutdown interface Serial0:31 as well in that case:


event manager applet ethertrack
event track 11 state down
action 1.0 syslog msg "Ethernet interface is down; shutting down Serial0:31"
action 2.0 cli command "enable"
action 3.0 cli command "config t"
action 4.0 cli command "interface ser0:31"
action 5.0 cli command "shut"
action 6.0 cli command "end"
action 7.0 syslog msg "Serial0:31 is now down"


Again, this requires 12.4(2)T or higher to be running on the router. It is only an example, but it will take down the serial interface when the tracked object goes down. You could also create a similar applet to watch for the object state to go up, then bring back up the Serial interface.

track 11 setup: track 11 interface FastEthernet0/0 line-protocol

https://supportforums.cisco.com/thread/178216

Also see: tracking reachability

[ view entry ] ( 1319 views )   |  print article
Difference between ACL , Distribution list and route map 
Best answer I found, https://supportforums.cisco.com/thread/2160579 (now I need to figure out where prefix-lists fit in):

“ Hello Chandra,

These tools are often confusing - I am glad you ask.

Let's first talk about ACLs and route maps. ACLs, as you already know, were explained in CCNA as mechanisms to filter packets based on their properties - source and destination addresses, transport layer protocol and ports, flags and perhaps some other attributes. However, this is not the only possible use of ACLs. An ACL is basically a mechanism accepting certain input from the IOS (source, destination, protocol, port, etc.) and returning three possible results:

•found a matching entry and the action is permit
•found a matching entry and the action is deny
•not found any matching entry

Now, because the ACL simply performs a matching operation and gives you a permit or deny result, you can use it in different places where some filtering based on addresses or address-like values is required. One of such applications is filtering the networks that are advertised or redistributed in routing protocols. In this case, we do not filter packets but rather, we filter the prefixes that are carried inside routing protocol's messages.

A route-map is a generalization of ACL. In addition to the capability to match packets or prefixes and permit or deny them, it is also capable of performing certain operations that modify the router's behavior or the attributes of these prefixes. Sometimes, a route-map is explained as an if-then-else mechanism: if some prefixes match some criteria then perform some specific action about them, else move to the next entry in the route-map.

Thus, the main differences between a route-map and an ACL are:

•A route-map can perform matching operations based on very diverse attributes. An ACL performs matching based only on IP addresses, L4 protocols and ports and some additional variables typical for packet headers and contents. In fact, when a route-map needs to perform these kinds of matches, it simply calls an ACL to do this job. However, it can also perform matching on different criteria (AS paths, metrics, route types, outgoing interfaces, ...) that are not matchable by an ACL.
•A route-map can perform a set operation on the packets or prefixes it matched, modifying their route (packets) or their attributes (prefixes). An ACL can only permit or deny them but it can't modify anything about them.

So to put it shortly, an ACL performs matching and filtering based on addressing information. A route-map performs matching, modification and filtering based on several types of matches, and it uses ACLs if the required matching is to be based on addressing information (it may also use other types of matches different from ACLs).

A distribution list is actually a misnomer and does not really belong here A distribution list is really only a command that uses route-maps or ACLs to perform filtering of routing information advertised or received within a particular routing protocol. It is not a standalone filtering mechanism similar to ACLs/route-map. The relation between route-maps or ACLs and distribute lists is the same as the relation between ACLs and "ip access-groups". An ACL is a mechanism to perform filtering while "ip access-group" is a command that uses this ACL to filter packets. In the very same way, an ACL or route-map is a mechanism to perform prefix filtering (and optional modification) while "distribute-list" is the command in the particular routing protocol's configuration that uses this ACL or route-map to filter advertised or received prefixes.

Sometimes a confusion exists about the difference between distribute lists and redistribution. A redistribution is a process of injecting routes from a different source into a particular routing protocol. If filtering is required during this process, route-maps are used. Technically, ACLs could also be used but the Cisco command line does not support referring directly to ACLs when redistributing, so route-maps are used, and these in turn refer to ACLs to perform the actual filtering. A distribute list controls what prefixes are advertised or received within a single routing protocol, i.e. after they have been somehow injected into it, and it does not matter how.

So to sum it up - ACLs and route-maps perform matching, modification and filtering operations. Route-maps can refer to ACLs to perform matching operations based on addressing values. Both route-maps and ACLs can be referred to in a distribute-list command to filter networks advertised or received in a routing protocol. Additionally, route-map are used during redistribution to filter and modify the redistributed networks and their attributes. Route-maps also constitute the main tool used to match and modify attributes of BGP-advertised networks.

A last comment here: increasingly, the ACLs used to filter routing updates are replaced by so-called IP prefix lists. These IP prefix lists are easier to write and understand than ACLs and are evaluated more effectively when matching network prefixes. This would, however, require a totally new thread so I'm not going into that right now

Best regards, Peter ”

[ view entry ] ( 1248 views )   |  print article


Route Summarization (manual): RIP, EIGRP, OSPF and BGP 
//RIP and EIGRP: interface subcommand
(config-if)#ip summary-address rip x.x.x.x x.x.x.x
(config-if)#ip summary-address eigrp x.x.x.x x.x.x.x


//OSPF: router mode subcommand
(config-router)#summary-address x.x.x.x x.x.x.x
// (also see: area "area-id" range "ip-address" "mask")



//BGP
(config-router)#aggregate-address x.x.x.x x.x.x.x ...



[ view entry ] ( 1206 views )   |  print article
Luhn algorithm (PHP) 

function luhn_check($number)
{

	 /* Luhn algorithm number checker - (c) 2005-2008 - planzero.org            *
	 * This code has been released into the public domain, however please      *
	 * give credit to the original author where possible.                      */
	 
	  // Strip any non-digits (useful for credit card numbers with spaces and hyphens)
	  $number=preg_replace('/\D/', '', $number);
	 
	  // Set the string length and parity
	  $number_length=strlen($number);
	  $parity=$number_length % 2;
	 
	  // Loop through each digit and do the maths
	  $total=0;
	  for ($i=0; $i<$number_length; $i++) {
		$digit=$number[$i];
		// Multiply alternate digits by two
		if ($i % 2 == $parity) {
		  $digit*=2;
		  // If the sum is two digits, add them together (in effect)
		  if ($digit > 9) {
			$digit-=9;
		  }
		}
		// Total up the digits
		$total+=$digit;
	  }
	 
	  // If the total mod 10 equals 0, the number is valid
	  return ($total % 10 == 0) ? TRUE : FALSE;
 }


[ view entry ] ( 1711 views )   |  print article
Finding multiples of a number (eg. 3) 
Interview question. For this we need the modulus operator: %
In computing, the modulo operation finds the remainder of division of one number by another.


//Remainder of $a divided by $b
//$a % $b
//echo (5 % 3)."\n"; // prints 2

So,

//main logic
if($number % 3 ==0)
//No remainder(nothing left after division).Number is multiple of 3.

[ view entry ] ( 1179 views )   |  print article
How to swap two numbers (2 variables) without using third variable. 
//Interview question
#input:
num1=50;
num2=100;

#core logic
num1 = num1 + num2;
num2 = num1 - num2;
num1 = num1 - num2;

#output
num1 is 100
num2 is 50



[ view entry ] ( 1187 views )   |  print article
IEEE Standards 
802.11b (wireless)
802.11g (wireless)
802.11a (wireless)

802.1i (WPA2)

802.1q (trunk protocol)
802.1d (STP protocol)
802.1w (RSTP protocol)
802.1s (MIST|MST|MSTP. Feature that creates an instace of RSTP (802.1w) for each VLAN)

802.3ab (1000BASE-T)
802.3z (1000BASE over fiber optic)


802.3af (PoE)
802.1p (layer 2 QoS)
802.1x (switch port-based authentication, AAA, radius)

[ view entry ] ( 1239 views )   |  print article
GNU OS apps 
http://www.gnu.org/manual/manual.html

Useful link to see what GNU apps are available.

[ view entry ] ( 1188 views )   |  print article

<<First <Back | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | Next> Last>>


2024 By Angel Cool