Statistics
| Branch: | Tag: | Revision:

root / common.sh @ bd59aebc

History | View | Annotate | Download (9.3 kB)

# Date Author Comment
4e403e04 03/05/2014 06:28 pm Dimitris Aragiorgis

Minor changes related to logging

Signed-off-by: Dimitris Aragiorgis <>

6afbe696 03/05/2014 06:28 pm Dimitris Aragiorgis

Some minor fixes..

- Use NETWORK_SUBNET6 since this is exported by Ganeti and not
just SUBNET6
- All logging in helper function
- Do not send GARP or delete neighbor proxy if desired vars are not
set

Signed-off-by: Dimitris Aragiorgis <>

63f1d9e7 03/05/2014 06:28 pm Dimitris Aragiorgis

Introduce get_info helper method

It gets the exported environment and calculates all needed vars for
a specific interface. Use this function early in scripts and as
soon as you extract each interface info in hooks.

Signed-off-by: Dimitris Aragiorgis <>

bd59aebc 03/05/2014 06:28 pm Dimitris Aragiorgis

Make get_info caclulate ebtables chain names

Signed-off-by: Dimitris Aragiorgis <>

bfe9b00f 03/05/2014 06:28 pm Dimitris Aragiorgis

Use env var for logging script

Signed-off-by: Dimitris Aragiorgis <>

cc56d684 03/05/2014 06:28 pm Dimitris Aragiorgis

Use arpsend instead of arping

arpsend comes along with ndsend with vzctl package.
We send only one packet in order not to delay ifup script.

Signed-off-by: Dimitris Aragiorgis <>

77ce5a39 03/05/2014 06:28 pm Dimitris Aragiorgis

Small changes in if* scripts

  • Factor out GARP and neighbor proxy action from setup_routed*
  • Invoke send_garp in kvm-ifup
  • Invoke delete_neighbor_proxy in snf-network-hook

Signed-off-by: Dimitris Aragiorgis <>

fa5bd914 03/05/2014 06:28 pm Dimitris Aragiorgis

Factor out common funtions from dnshook

Signed-off-by: Dimitris Aragiorgis <>

fd80d055 03/05/2014 06:14 pm Dimitris Aragiorgis

Do not add ebtables rule for dhcp response

nfdhpcd opens a socket and binds it with tap interface. So dhcp
response will NOT go though the bridge and ebtables rule is
not needed.

Signed-off-by: Dimitris Aragiorgis <>

e5171922 03/05/2014 06:14 pm Dimitris Aragiorgis

Fix typo in ebtables

If interface has an IP we used to add a rule that does not allow
packets coming from TAP to have a different IP. There was a typo
in if statement and the rule did never apply.

Still, we do NOT want this rule so we fix typo and comment the...

184370fd 03/05/2014 06:14 pm Dimitris Aragiorgis

Create ebtables chains with RETURN policy

This fixes inter-node private networks in case of multicast packets.
Multicast packets are forwarded to all interfaces bridged
on the bridge. Lets assume the following:

prv0 bridge with tap0, tap1, and eth1.
From tap0 comes a multicast packet....

a57b3c64 03/05/2014 06:14 pm Dimitris Aragiorgis

Fix ebtables

1) Add ebtables in INPUT/OUTPUT chains too
This is needed because multicast packets
(e.g. with dst address 01:00:83:xx:xx:xx) do NOT go through forward chain

2) In case of nfdhpcd allow DHCP replies only with src address the
MAC address of incoming device (e.g. prv0)...

1bdc9427 01/13/2014 11:03 am Dimitris Aragiorgis

Move fix-net logic from hooks to if-up

In target node we used to run arping and ndsend. Move these
commands to if-up script.

Introduce helper function to get eui64 and uplink.

Signed-off-by: Dimitris Aragiorgis <>

0363b080 12/09/2013 02:25 pm Dimitris Aragiorgis

return in case expected env vars are not set

In case of IPv6 only setup, IP environment variable should not be
set. Still if we have a routed setup routed_setup_ipv4() gets invoked.

This means that the following command will be invoked:

ip route replace proto static dev tap3 table public...

a336b166 12/07/2013 04:25 pm Dimitris Aragiorgis

Support firewalls based on NINC index, uuid, names

Signed-off-by: Dimitris Aragiorgis <>

1409faba 10/23/2013 03:00 pm Stratos Psomadakis

Serialize the excecution of ebtables processes

ebtables cannot handle multiple userspace ebtables processes running
concurrently. This could lead to failures while setting up or cleaning
up ebtables for VM networks.

ebtables latest release (included in Debian Wheezy) supports ebtables...

38305e4c 05/12/2013 01:11 am Dimitris Aragiorgis

Add vif-custom script and split kvm-vif-bridge

Put functions in /usr/lib/snf-network/common.sh

Signed-off-by: Dimitris Aragiorgis <>