---
name: "Network::LinuxConf"
section: "3pm"
platform: "linux"
package: "systemconfigurator"
version: "1.20-1"
release: "Debian 3.0 (Woody)"
platforms: ["linux"]
url: "https://new.carta.tech/Network::LinuxConf"
---

# Network::LinuxConf(3pm)

Linux Conf Networking Module

## NAME

Network::LinuxConf - Linux Conf Networking Module

## SYNOPSIS

```
  my $networking = new Network::LinuxConf(%vars);
```

```
  if($networking->footprint()) {
      $networking->setup();
  }
```

```
  my @fileschanged = $networking->files();
```

## DESCRIPTION

## METHODS

The following methods exist in this module:

- *footprint()*

  This method returns 1 if LinuxConf networking was discovered on the machine, undef if it was not.  The current test checks for the existance of **$chroot/etc/sysconfig/network-scripts/ifup**.

- setup\_interface($interface)

  This sets up the ifcfg-$dev files.  It assumes that it has free reign of these files, which should be valid except for some fairly esoteric networking configurations.

  It sets ONBOOT to yes, DEVICE to `$interface_device` (as specified in the config file).

  If `$interface_type` is 'static', and `$interface_ip` exists, it will set up all the appropriate settings for static ip addresses.  NETMASK will be either the value specified in  `$interface_netmask`, or the appropriate default for the ip address specified.

  If `$interface_type` is 'bootp', the interface is setup of for bootp.

  Otherwise the interface is setup for **dhcp**.

- setup\_global

  setup\_global sets up the default gatway, and the host/domain names via modification of **/etc/sysconfig/network**.  It does not assume that it owns this file.  If the file already exists it will move it to **/etc/systconfig/network.scbak**  first, then create the new file by modifying the lines from the old file that it needs to.

  If it creates a new file it will create a file with NETWORKING, FORWARD\_IPV4, GATEWAY, HOSTNAME, and DOMAINNAME.  NETWORKING will default to  "yes" and FORWARD\_IPV4 will default to "no".

## AUTHOR

```
  Sean Dague <japh@us.ibm.com>
```

## SEE ALSO

SystemConifg::Network, Net::Netmask, perl
