Permalink
Browse files

update readme

  • Loading branch information...
upa
upa committed Aug 9, 2012
1 parent acc2556 commit 2ef5451715e79a18986d90c31ad76d95eea15449
Showing with 134 additions and 894 deletions.
  1. +1 −3 Makefile
  2. +9 −15 README.md
  3. +10 −14 common.h
  4. +5 −300 control.c
  5. +1 −30 control.h
  6. +49 −50 fdb.c
  7. +11 −4 fdb.h
  8. +0 −236 hash.c
  9. +0 −34 hash.h
  10. +5 −24 main.c
  11. +1 −148 net.c
  12. +8 −2 vxlan
  13. +28 −19 vxlan.c
  14. +3 −3 vxlan.h
  15. +3 −12 vxlanctl.c
View
@@ -3,7 +3,7 @@
CC = gcc -Wall -g
-MODULES = error.o fdb.o hash.o iftap.o net.o vxlan.o control.o
+MODULES = error.o fdb.o iftap.o net.o vxlan.o control.o
PROGNAME = vxland vxlanctl
INITSCRIPT = vxlan
@@ -51,9 +51,7 @@ uninstall : $(PROGNAME)
control.c : control.h
error.c : error.h
-fdb.h : hash.h
fdb.c : fdb.h
-hash.c : hash.h
iftap.c : iftap.h
net.h : common.h
net.c : net.h fdb.h error.h sockaddrmacro.h
View
@@ -1,11 +1,9 @@
-hogelan
-=======
-
-hogelan is simple vxlan implementation using Linux tap interface.
+vxlan
+=====
ID : https://tools.ietf.org/html/draft-mahalingam-dutt-dcops-vxlan-00
-hogelan includes "vxland" and "vxlanctl" commands.
+vxlan includes "vxland" and "vxlanctl" commands.
vxland, is vxlan daemon, forwards packet to VXLAN
Overlay Network. vxlanctl is command for controlling vxlan.
You can create/destroy vxlan tunnel interface using
@@ -14,9 +12,11 @@ It can work on Linux Only.
Install
-------
+VXLAN requires uthash package late 1.9.
+Please see http://uthash.sourceforge.net/ .
- % git clone git://github.com/upa/hogelan.git
- % cd hogelan
+ % git clone git://github.com/upa/vxlan.git
+ % cd vxlan
% make
% make install
@@ -36,12 +36,12 @@ IPv4 and IPv6.
### vxland ###
-vxland is daemon for forwarding packet.
+vxland is daemon that creates vxlan instances, and inforward packets.
+ start : _/etc/init.d/vxlan start_
+ stop : _/etc/init.d/vxlan stop_
-Other configurations is installed by vxlanctl.
+Other configurations are installed by vxlanctl.
### vxlanctl ###
@@ -60,12 +60,6 @@ if you want to use vlan, create vlan interface using vconfig.
create <VNI> add vxlan interface
destroy <VNI> delete vxlan interface
- acl <VNI> mac [deny|permit] <Mac Addr> Source Mac Address Filter
- acl <VNI> arp [deny|permit] <v4Addr> ARP Target Address Filter
- acl <VNI> ns [deny|permit] <v6Addr> NS Target Address Filter
- acl <VNI> ra [deny|permit] RA Filter
- acl <VNI> rs [deny|permit] RS FIlter
-
### Create vxlan interface ####
% vxlanctl create 0
View
@@ -5,8 +5,7 @@
#include <sys/types.h>
#include <netinet/in.h>
#include <sys/socket.h>
-
-#include "hash.h"
+#include <uthash.h>
#define VXLAN_PORT_BASE 60000
#define VXLAN_CPORT "60000"
@@ -21,21 +20,19 @@
#define VXLAN_UNIX_DOMAIN "/var/run/vxlan"
-#define ACL_MASK_RA 0x01
-#define ACL_MASK_RS 0x02
struct vxlan_instance {
- u_int8_t vni[VXLAN_VNISIZE];
- char vxlan_tap_name[IFNAMSIZ];
+ /* uthash key */
+ struct vnikey {
+ u_int8_t vni[VXLAN_VNISIZE];
+ } vni;
+ char vxlan_tap_name[IFNAMSIZ];
struct fdb * fdb;
- struct hash acl_mac;
- struct hash acl_ip4;
- struct hash acl_ip6;
- u_int8_t acl_mask;
-
- pthread_t tid;
+ pthread_t tid; /* thread ID of process own VID instance */
int tap_sock;
+
+ UT_hash_handle hh;
};
@@ -47,8 +44,7 @@ struct vxlan {
struct sockaddr_storage mcast_addr; /* vxlan Multicast Address */
int vins_num; /* Num of VXLAN Instance */
- struct hash vins_tuple; /* VXLAN Instance hash table. key is VNI */
-
+ struct vxlan_instance * vins_table; /* VXLAN Instance uthash table */
pthread_t control_tid; /* Control Thread ID */
};
Oops, something went wrong.

0 comments on commit 2ef5451

Please sign in to comment.