예제 #1
0
def _setup_eth(eth, bond):
    '''
    Setup the eth interface to be included in a bond.

    '''
    filename = "/etc/sysconfig/network-scripts/ifcfg-" + eth
    mac = general.get_config_value(filename, "HWADDR")
    general.store_file(filename,
"""DEVICE="%s"
HWADDR=%s
MASTER=%s
SLAVE=yes
NM_CONTROLLED="no"
ONBOOT=yes
USERCTL=no
HOTPLUG=no
BOOTPROTO=none
""" % (eth, mac, bond))
예제 #2
0
파일: netUtils.py 프로젝트: ysoldak/syco
def setup_eth(eth, bond):
    '''
    Setup the eth interface to be included in a bond.

    '''
    app.print_verbose(
        "Setup the eth interface {0} to be included in {1}.".format(eth, bond))
    filename = "/etc/sysconfig/network-scripts/ifcfg-" + eth
    mac = general.get_config_value(filename, "HWADDR")
    general.store_file(
        filename, """# Generated by syco
DEVICE="%s"
HWADDR=%s
MASTER=%s
SLAVE=yes
NM_CONTROLLED="no"
ONBOOT=yes
USERCTL=no
HOTPLUG=no
BOOTPROTO=none
""" % (eth, mac, bond))
예제 #3
0
파일: netUtils.py 프로젝트: Nemie/syco
def setup_eth(eth, bond):
    '''
    Setup the eth interface to be included in a bond.

    '''
    app.print_verbose(
        "Setup the eth interface {0} to be included in {1}.".format(
            eth, bond
        )
    )
    filename = "/etc/sysconfig/network-scripts/ifcfg-" + eth
    mac = general.get_config_value(filename, "HWADDR")
    general.store_file(filename,
"""# Generated by syco
DEVICE="%s"
HWADDR=%s
MASTER=%s
SLAVE=yes
NM_CONTROLLED="no"
ONBOOT=yes
USERCTL=no
HOTPLUG=no
BOOTPROTO=none
""" % (eth, mac, bond))