Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.

Bug 1463377

Summary: rear won't backup network config
Product: Red Hat Enterprise Linux 6 Reporter: Blair Aitken <baitken>
Component: rearAssignee: Jakub Mazanek <jmazanek>
Status: CLOSED WONTFIX QA Contact: Tereza Cerna <tcerna>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 6.9CC: akaiser, cww, jmazanek, pcahyna, rmetrich
Target Milestone: rc   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of:
: 1484051 (view as bug list) Environment:
Last Closed: 2017-08-16 16:50:10 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
/bin/rear -d -v mkbackup
none
Patch proposal including basic bridged interface support none

Description Blair Aitken 2017-06-20 16:57:44 UTC
Created attachment 1289743 [details]
/bin/rear -d -v mkbackup

Description of problem:
~~~~~~~~~~~~~~~~~~~~~~~
I have successfully created a ReaR backup (rear -d -v mkbackup )and restored it to new hard drive but it doesn't contain network configuration (/etc/sysconfig/network-scripts is empty) when I am in recover/rescue mode.  I created /etc/rear/site.conf and added this line prior to running the backup:  

   USE_STATIC_NETWORKING=y

but it didn't work.
During recovery (rear recover) I had to run :

 o   ip addr add 10.106.51.20/24 dev bond0.441
 o   ip route add 10.106.6.172 via 10.106.51.1

in order for the restore to work.
What am I doing wrong?


Version-Release number of selected component (if applicable):
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

rear-1.17.2-4.el6.x86_64             Thu Jun 30 09:16:41 2016

Comment 4 Renaud Métrich 2017-06-28 14:24:08 UTC
The issue comes from the way the bridge "br0" is set up in /etc/scripts/system-setup.d/60-network-devices.sh:

ip addr add 10.106.51.20/27 dev br0
ip link set dev br0 up
ip link set dev br0 mtu 1500

The "br0" device doesn't exist unless the corresponding "brctl" command is used.

They are 2 issues here:
1. "brctl" utility is not part of the rescue image
2. "brctl addbr br0" is missing in 60-network-devices.sh

Comment 6 Renaud Métrich 2017-07-10 07:20:52 UTC
Created attachment 1295709 [details]
Patch proposal including basic bridged interface support

This patch has been successfully tested with the following configuration:
1. eth0 + eth1 bonded as bond0 (no IP address)
2. bond0.441 configured as vlan441 on bond0 (no IP address)
3. br0 configured as a bridge on bond0.441 (with IP address)

For now, only STP is configured for the bridge interface. This should be sufficient.
The brctl utility is includes as REQUIRED_PROGS automatically upon need.

The resulting /rootfs/etc/scripts/system-setup.d/60-network-devices.sh file is as follows:

if [ ! -d /sys/class/net/br0/bridge ]; then
    brctl addbr br0
    brctl stp br0 no
fi
ip addr add xxx/xx dev br0
ip link set dev br0 up
ip link set dev br0 mtu 1500
ip link set dev eth0 up
ip link set dev eth0 mtu 1500
ip link set dev eth1 up
ip link set dev eth1 mtu 1500
modprobe bonding max_bonds=1 miimon=100 mode=1 use_carrier=0
ip link set dev bond0 up
ifenslave bond0 eth0 eth1
sleep 5
modprobe 8021q
sleep 5
ip link add link bond0 name bond0.441 type vlan id 441
if [ ! -d /sys/class/net/br0/bridge ]; then
    brctl addbr br0
    brctl stp br0 no
fi
brctl addif br0 bond0.441
ip link set dev bond0.441 up