1NOZZLE_OPEN(3)           Kronosnet Programmer's Manual          NOZZLE_OPEN(3)
2
3
4

NAME

6       nozzle_open - create a new tap device on the system.
7
8

SYNOPSIS

10       #include <libnozzle.h>
11
12       nozzle_t nozzle_open(
13           char         *devname,
14           size_t        devname_size,
15           const char   *updownpath
16       );
17

DESCRIPTION

19       nozzle_open
20
21       devname  - pointer to device name of at least size IFNAMSIZ. if the dev
22       strlen is 0, then the system will assign a  name  automatically.  if  a
23       string  is  specified,  the system will try to create a device with the
24       specified name. NOTE: on FreeBSD the tap device names can only be  tapX
25       where  X  is  a number from 0 to 255. On Linux such limitation does not
26       apply. The name must be unique to the system. If an interface with  the
27       same  name  is  already  configured on the system, an error will be re‐
28       turned.
29
30       devname_size - length of the buffer provided in dev (has to be at least
31       IFNAMSIZ).
32
33       updownpath  -  nozzle supports the typical filesystem structure to exe‐
34       cute actions for: down.d post-down.d pre-up.d up.d in the form of:  up‐
35       downpath/<action>/<interface_name>  updownpath  specifies where to find
36       those directories on the filesystem and it must be an absolute path.
37

RETURN VALUE

39       nozzle_open returns a pointer to a nozzle struct on success NULL on er‐
40       ror and errno is set.
41

SEE ALSO

43       nozzle_close(3), nozzle_set_mtu(3), nozzle_get_fd(3),
44       nozzle_get_mtu(3), nozzle_reset_mtu(3), nozzle_set_up(3),
45       nozzle_get_ips(3), nozzle_set_down(3), nozzle_reset_mac(3),
46       nozzle_get_handle_by_name(3), nozzle_run_updown(3), nozzle_del_ip(3),
47       nozzle_get_mac(3), nozzle_set_mac(3), nozzle_get_name_by_handle(3),
48       nozzle_add_ip(3)
49
51       Copyright (C) 2010-2022 Red Hat, Inc. All rights reserved.
52
53
54
55kronosnet                         2022-05-30                    NOZZLE_OPEN(3)
Impressum