network config is it possible to use cli and gui ?

wfamy

Active Member
Sep 9, 2019
5
0
41
52
in /etc/network/interfaces i can read
# If you want to manage parts of the network configuration manually,
# please utilize the 'source' or 'source-directory' directives to do
# so.
# PVE will preserve these directives, but will NOT read its network
# configuration from sourced files, so do not attempt to move any of
# the PVE managed interfaces into external files!

is it possible to use cli ovs command and edit file interfaces
what 'source' or 'source-directory' directives mean?
 
hi,
what 'source' or 'source-directory' directives mean?

if you add source-directory /etc/network/interfaces.d in the configuration file, other configuration files you add into /etc/network/interfaces.d/ will affect your network configuration.
is it possible to use cli ovs command and edit file interfaces
it's not recommended to edit this file manually, so instead use GUI or in case you have specific network configurations, add them to the interfaces.d directory as explained. you can use any text editor to write/edit
 
Hello, for anyone that have the same issue.

The source and source-directory are two options in the file /etc/network/interfaces

Here is a quote from the official website, hope that helps:

Lines beginning with "source" are used to include stanzas from other files, so
configuration can be split into many files. The word "source" is followed by the path of
file to be sourced. Shell wildcards can be used. (See wordexp(3) for details.)

Similarly, "source-directory" keyword is used to source multiple files at once, without
specifying them individually or using shell globs. Additionally, when "source-directory"
is used, names of the files are checked to match the following regular expression:
^[a-zA-Z0-9_-]+$. In other words, the names must consist entirely of ASCII upper- and
lower-case letters, ASCII digits, ASCII underscores, and ASCII minus-hyphens. In the
directory path, shell wildcards may be used as well.

When sourcing files or directories, if a path doesn't have a leading slash, it's
considered relative to the directory containing the file in which the keyword is placed.
In the example above, if the file is located at /etc/network/interfaces, paths to the
included files are understood to be under /etc/network.

Currently, "source-directory" isn't supported by network-manager and guessnet.

By default, on a freshly installed Debian system, the interfaces file includes a line to
source files in the /etc/network/interfaces.d directory.
 
  • Like
Reactions: herbokolog