Linux Archive

Linux Archive (http://www.linux-archive.org/)
-   Crash Utility (http://www.linux-archive.org/crash-utility/)
-   -   Write OPTIONS for s390x net devs on non-network install methods (#649301) (http://www.linux-archive.org/crash-utility/507726-write-options-s390x-net-devs-non-network-install-methods-649301-a.html)

David Cantrell 03-30-2011 08:42 PM

Write OPTIONS for s390x net devs on non-network install methods (#649301)
 
Make sure the LAYER2 and PORTNO values collected by linuxrc.s390 are
translated to an appropriate OPTIONS line for the ifcfg-DEVICE file on
the target system. This happens during network install methods because
loader converts those values in to an OPTIONS line, but if you use the
hard drive install method, the values are never translated to OPTIONS.
Do the translation in network.py to ensure we get those values on all
install methods.
---
network.py | 8 ++++++++
1 files changed, 8 insertions(+), 0 deletions(-)

diff --git a/network.py b/network.py
index 84776e4..2e518b4 100644
--- a/network.py
+++ b/network.py
@@ -216,6 +216,14 @@ class Network:
if info.has_key(key):
self.netdevices [info["DEVICE"]].set((key, info[key]))

+ osa_opts = []
+ for key in ("LAYER2", "PORTNO"):
+ if info.has_key(key) and info[key] == "1":
+ osa_opts.append(key.lower() + "=" + info[key])
+
+ if osa_opts:
+ self.netdevices[info["DEVICE"]].set(("OPTIONS", " ".join(osa_opts)))
+
self.netdevices [info["DEVICE"]].set(('useIPv4', flags.useIPv4))
self.netdevices [info["DEVICE"]].set(('useIPv6', flags.useIPv6))

--
1.7.1

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@redhat.com
https://www.redhat.com/mailman/listinfo/anaconda-devel-list

"Brian C. Lane" 03-30-2011 10:30 PM

Write OPTIONS for s390x net devs on non-network install methods (#649301)
 
On Wed, Mar 30, 2011 at 10:42:18AM -1000, David Cantrell wrote:
> Make sure the LAYER2 and PORTNO values collected by linuxrc.s390 are
> translated to an appropriate OPTIONS line for the ifcfg-DEVICE file on
> the target system. This happens during network install methods because
> loader converts those values in to an OPTIONS line, but if you use the
> hard drive install method, the values are never translated to OPTIONS.
> Do the translation in network.py to ensure we get those values on all
> install methods.
> ---

Ack.

--
Brian C. Lane | Anaconda Team | IRC: bcl #anaconda | Port Orchard, WA (PST8PDT)
_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@redhat.com
https://www.redhat.com/mailman/listinfo/anaconda-devel-list


All times are GMT. The time now is 06:33 AM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.