logs: add netns information to logs

All log messages now contain information about what network namespace
they've originated in. Since xml result files are generated
automatically, the information about the network namespace is already
present in them.

Signed-off-by: Ondrej Lichtner <olichtne@redhat.com>
Signed-off-by: Jiri Pirko <jiri@resnulli.us>
add vti support

This patch adds support for vti devices. There is no configuration
supported beyond purely creating the device. The recipe format is:

<vti id="xyz" netns="aa">
    <options>
        <option name="local" value="1.1.1.1"/>
        <option name="remote" value="1.1.1.2"/>
        <option name="key" value="1"/>
    </options>
</vti>

Where the key option is mandatory and local and remote options are
optional (though I don't know if such a device is usable). The netns
attribute is optional as usual.

Signed-off-by: Ondrej Lichtner <olichtne@redhat.com>
Signed-off-by: Jiri Pirko <jiri@resnulli.us>
add loopback support

This patch adds support for loopback devices. It doesn't do any loopback
configuration at the moment (except adding ip addresses), but it does
enable users to work with loopback devices in their recipes.
Important notes:
* Loopback devices are not part of the matching algorithm, it is assumed
that they already exist on every host.
* You can only define _ONE_ loopback device per host per network
namespace, LNST checks for this and will raise an exception if you
specify more.

recipe example:
<lo id="lo_secure" netns="secure">
    <addresses>
        <address>192.168.1.1/24</address>
    </addresses>
</lo>

Signed-off-by: Ondrej Lichtner <olichtne@redhat.com>
Signed-off-by: Jiri Pirko <jiri@resnulli.us>
TaskAPI: add support for network namespaces

Python tasks now support using network namespaces via the optional
'netns' argument of the 'run' and 'config' methods. If the command is
running in the background, running the wait/intr/kill methods of the
ProcessAPI object will automatically use the namespace of the associated
namespace.

Signed-off-by: Ondrej Lichtner <olichtne@redhat.com>
Signed-off-by: Jiri Pirko <jiri@resnulli.us>
signal commands no longer use the netns attribute

This patch improves the usability of signal commands by storing
information about running background commands of the machine. The
controller can then use this information to send the signal command to
the correct network namespace without requiring this information from
the user. Because of this the 'netns' attribute (recipe) is no longer
accepted for signal commands.

RecipeParser also sets the 'netns' attribute of the internal command
structure to the default value 'None'.

Signed-off-by: Ondrej Lichtner <olichtne@redhat.com>
Signed-off-by: Jiri Pirko <jiri@resnulli.us>
Machine: fix use of get_remaining_time method call

If the background command was running in a non-root network namespace,
the method call would fail. This commit fixes that problem.

Signed-off-by: Ondrej Lichtner <olichtne@redhat.com>
Signed-off-by: Jiri Pirko <jiri@resnulli.us>
RecipeParser: fix tag reference in a vlan exception

The vlan variable is undefined, the iface_tag variable should be used
instead.

Signed-off-by: Ondrej Lichtner <olichtne@redhat.com>
Signed-off-by: Jiri Pirko <jiri@resnulli.us>