[PATCH] Update parse-kickstart for the new bootloader command.
by Chris Lumens
---
dracut/parse-kickstart | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/dracut/parse-kickstart b/dracut/parse-kickstart
index 0b047e0..3258107 100755
--- a/dracut/parse-kickstart
+++ b/dracut/parse-kickstart
@@ -163,7 +163,7 @@ class DisplayMode(commands.displaymode.FC3_DisplayMode):
elif self.displayMode == DISPLAY_MODE_GRAPHICAL:
return "inst.graphical"
-class Bootloader(commands.bootloader.F19_Bootloader):
+class Bootloader(commands.bootloader.F21_Bootloader):
def dracut_args(self, args, lineno, obj):
if self.extlinux:
return "extlinux"
--
1.8.3.1
10 years, 1 month
[blivet:master 0/6] A bunch of pylint inspired patches
by Anne Mulhern
These are a bunch of, I believe, extremely non-controversial pylint inpsired
changes courtesy of David Shea.
The only question, I think, is whether some of these should also be queued up
for RHEL7.1. If you have an opinion on that, please speak up.
The sooner I can push these, the less rebasing I'll have to do!
David Shea (6):
Fix logging function string format warnings.
Fixed some questionable indentation
Specify regular expressions containing backslashes as raw strings
Removed a redundant definition of NoDisksError
Removed an unnecessary semicolon
Update to the new raise syntax
blivet/__init__.py | 136 ++++++++++-----------
blivet/arch.py | 6 +-
blivet/dasd.py | 216 +++++++++++++++++++++++++++++++++
blivet/deviceaction.py | 2 +-
blivet/devicefactory.py | 110 ++++++++---------
blivet/devicelibs/dasd.py | 3 +-
blivet/devicelibs/edd.py | 28 ++---
blivet/devicelibs/lvm.py | 10 +-
blivet/devicelibs/mdraid.py | 6 +-
blivet/devicelibs/swap.py | 6 +-
blivet/devices.py | 76 ++++++------
blivet/devicetree.py | 282 ++++++++++++++++++++++----------------------
blivet/errors.py | 3 -
blivet/fcoe.py | 14 +--
blivet/formats/__init__.py | 18 +--
blivet/formats/disklabel.py | 10 +-
blivet/formats/fs.py | 36 +++---
blivet/formats/luks.py | 6 +-
blivet/formats/prepboot.py | 12 +-
blivet/formats/swap.py | 2 +-
blivet/iscsi.py | 51 ++++----
blivet/partitioning.py | 266 +++++++++++++++++++++--------------------
blivet/platform.py | 16 +--
blivet/pyudev.py | 2 +-
blivet/udev.py | 22 ++--
blivet/util.py | 30 ++---
blivet/zfcp.py | 89 +++++++-------
27 files changed, 832 insertions(+), 626 deletions(-)
create mode 100644 blivet/dasd.py
--
1.8.3.1
10 years, 1 month
[master][PATCH] Fix filtering the _storage_playground out
by Vratislav Podzimek
Dumping Blivet instance takes quite a lot of time and makes Anaconda's GUI
unresponsive for a long time before python-meh's window appears.
Signed-off-by: Vratislav Podzimek <vpodzime(a)redhat.com>
---
pyanaconda/exception.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/pyanaconda/exception.py b/pyanaconda/exception.py
index a06b51e..0786335 100644
--- a/pyanaconda/exception.py
+++ b/pyanaconda/exception.py
@@ -234,7 +234,7 @@ def initExceptionHandling(anaconda):
"_intf._currentAction._xklwrapper",
"_intf._currentAction._spokes[\"KeyboardSpoke\"]._xkl_wrapper",
"_intf._currentAction._storage_playground",
- "_intf._currentAction._spokes[\"CustomSpoke\"]._storage_playground",
+ "_intf._currentAction._spokes[\"CustomPartitioningSpoke\"]._storage_playground",
"_intf._currentAction.language.translations",
"_intf._currentAction.language.locales",
"_intf._currentAction._spokes[\"PasswordSpoke\"]._oldweak",
--
1.8.5.3
10 years, 1 month
[PATCH] Fix the argument list passed to the payloadInitialize thread (#1079628)
by David Shea
I missed one of the calls to payloadInitialize when I added the
instclass argument.
---
pyanaconda/ui/gui/spokes/network.py | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/pyanaconda/ui/gui/spokes/network.py b/pyanaconda/ui/gui/spokes/network.py
index 595c90b..a9e818e 100644
--- a/pyanaconda/ui/gui/spokes/network.py
+++ b/pyanaconda/ui/gui/spokes/network.py
@@ -1429,7 +1429,8 @@ class NetworkStandaloneSpoke(StandaloneSpoke):
threadMgr.wait(constants.THREAD_PAYLOAD)
- threadMgr.add(AnacondaThread(name=constants.THREAD_PAYLOAD, target=payloadInitialize, args=(self.storage, self.data, self.payload)))
+ threadMgr.add(AnacondaThread(name=constants.THREAD_PAYLOAD, target=payloadInitialize,
+ args=(self.storage, self.data, self.payload, self.instclass)))
self.network_control_box.kill_nmce(msg="leaving standalone network spoke")
--
1.8.5.3
10 years, 1 month
[PATCH rhel7-branch] network: don't pop HWADDR twice for vlan on s390 (#1061646)
by Radek Vykydal
Related: rhbz#1061646
---
dracut/parse-kickstart | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/dracut/parse-kickstart b/dracut/parse-kickstart
index 562d4f9..a8ece63 100755
--- a/dracut/parse-kickstart
+++ b/dracut/parse-kickstart
@@ -393,7 +393,7 @@ def ksnet_to_ifcfg(net, filename=None):
shutil.copyfile(srcpath, dstpath)
if net.bondslaves:
- ifcfg.pop('HWADDR')
+ ifcfg.pop('HWADDR', None)
ifcfg['TYPE'] = "Bond"
ifcfg['BONDING_MASTER'] = "yes"
ifcfg['NAME'] = "Bond connection %s" % dev
@@ -418,7 +418,7 @@ def ksnet_to_ifcfg(net, filename=None):
if net.teamslaves:
- ifcfg.pop('HWADDR')
+ ifcfg.pop('HWADDR', None)
ifcfg['TYPE'] = "Team"
ifcfg['NAME'] = "Team connection %s" % dev
ifcfg['TEAM_CONFIG'] = "'" + net.teamconfig + "'"
@@ -442,7 +442,7 @@ def ksnet_to_ifcfg(net, filename=None):
if net.vlanid:
interface_name = net.interfacename or "%s.%s" % (dev, net.vlanid)
- ifcfg.pop('HWADDR')
+ ifcfg.pop('HWADDR', None)
ifcfg['TYPE'] = "Vlan"
ifcfg['VLAN'] = "yes"
ifcfg['VLAN_ID'] = net.vlanid
--
1.7.11.7
10 years, 1 month
[master] Two minor fixes for text mode exception handling
by Vratislav Podzimek
Vratislav Podzimek (2):
Define two env variables removing useless warnings
Make sure the error info message starts on a new line
data/systemd/anaconda-direct.service | 2 +-
data/systemd/anaconda.service | 2 +-
pyanaconda/exception.py | 4 ++--
3 files changed, 4 insertions(+), 4 deletions(-)
--
1.8.5.3
10 years, 1 month
[PATCH] Avoid the "unable to init server" message.
by David Shea
This message is only printed by the "broadway" backend, and the broadway
backend is only used because Gdk tries every backend if it can't figure
out what is going on, so just don't use that backend. The content of the
"Unable to init server" message changed recently which is why it started
getting past our false-positive filter again.
---
tests/pylint/pylint-false-positives | 1 -
tests/pylint/runpylint.sh | 5 +++++
2 files changed, 5 insertions(+), 1 deletion(-)
diff --git a/tests/pylint/pylint-false-positives b/tests/pylint/pylint-false-positives
index e2b0c09..faa1019 100644
--- a/tests/pylint/pylint-false-positives
+++ b/tests/pylint/pylint-false-positives
@@ -83,6 +83,5 @@
^E0611:[ 0-9]*,[0-9]*: No name '_isys' in module 'pyanaconda'$
^E0611:[ 0-9]*,[0-9]*:.*: No name '_isys' in module 'pyanaconda'$
^E0712:[ 0-9]*,[0-9]*:.*: Catching an exception which doesn't inherit from BaseException: GError$
-^Unable to init server$
gi/module.py:[0-9]*: Warning: g_hash_table_insert_internal: assertion 'hash_table != NULL' failed$
^ g_type = info\.get_g_type\(\)$
diff --git a/tests/pylint/runpylint.sh b/tests/pylint/runpylint.sh
index 971a8f9..0e32c3b 100755
--- a/tests/pylint/runpylint.sh
+++ b/tests/pylint/runpylint.sh
@@ -28,6 +28,11 @@ unset TERM
# Don't try to connect to the accessibility socket
export NO_AT_BRIDGE=1
+# Force the GDK backend to X11. Otherwise if no display can be found, Gdk
+# tries every backend type, which includes "broadway," which prints an error
+# and keeps changing the content of said error.
+export GDK_BACKEND=x11
+
# If $top_srcdir has not been set by automake, import the test environment
if [ -z "$top_srcdir" ]; then
top_srcdir="$(dirname "$0")/../.."
--
1.9.0
10 years, 1 month
[PATCH] Sync up step counts in install.py with reality.
by Chris Lumens
Our counts were off, plus a lot of steps are conditionalized which was not
being reflected in the count we established beforehand.
---
pyanaconda/install.py | 44 ++++++++++++++++++++++++++++++++++----------
1 file changed, 34 insertions(+), 10 deletions(-)
diff --git a/pyanaconda/install.py b/pyanaconda/install.py
index be2e1a5..a7e9d38 100644
--- a/pyanaconda/install.py
+++ b/pyanaconda/install.py
@@ -52,12 +52,22 @@ def _writeKS(ksdata):
def doConfiguration(storage, payload, ksdata, instClass):
from pyanaconda.kickstart import runPostScripts
- step_count = 6
+ willWriteNetwork = not flags.flags.imageInstall and not flags.flags.dirInstall
+ willRunRealmd = ksdata.realm.discovered
+
+ # configure base, create users, configure addons, initramfs, post-install
+ step_count = 5
+
+ # network, maybe
+ if willWriteNetwork:
+ step_count += 1
+
# if a realm was discovered,
# increment the counter as the
# real joining step will be executed
- if ksdata.realm.discovered:
+ if willRunRealmd:
step_count += 1
+
progressQ.send_init(step_count)
# Now run the execute methods of ksdata that require an installed system
@@ -74,7 +84,7 @@ def doConfiguration(storage, payload, ksdata, instClass):
ksdata.xconfig.execute(storage, ksdata, instClass)
ksdata.skipx.execute(storage, ksdata, instClass)
- if not flags.flags.imageInstall and not flags.flags.dirInstall:
+ if willWriteNetwork:
with progress_report(_("Writing network configuration")):
ksdata.network.execute(storage, ksdata, instClass)
@@ -93,7 +103,7 @@ def doConfiguration(storage, payload, ksdata, instClass):
with progress_report(_("Generating initramfs")):
payload.recreateInitrds(force=True)
- if ksdata.realm.discovered:
+ if willRunRealmd:
with progress_report(_("Joining realm: %s") % ksdata.realm.discovered):
ksdata.realm.execute(storage, ksdata, instClass)
@@ -112,6 +122,9 @@ def doInstall(storage, payload, ksdata, instClass):
The two main tasks for this are putting filesystems onto disks and
installing packages onto those filesystems.
"""
+ willRunRealmd = ksdata.realm.join_realm
+ willInstallBootloader = not flags.flags.dirInstall and not ksdata.bootloader.disabled
+
# First save system time to HW clock.
if flags.can_touch_runtime_system("save system time to HW clock"):
timezone.save_hw_clock(ksdata.timezone)
@@ -120,16 +133,27 @@ def doInstall(storage, payload, ksdata, instClass):
# those are the ones that take the most time.
steps = len(storage.devicetree.findActions(type="create", object="format")) + \
len(storage.devicetree.findActions(type="resize", object="format"))
- steps += 6
- # pre setup phase, packages setup, packages, bootloader, realmd,
- # post install
- progressQ.send_init(steps)
+
+ # pre setup phase, post install
+ steps += 2
+
+ # realmd, maybe
+ if willRunRealmd:
+ steps += 1
+
+ # bootloader, maybe
+ if willInstallBootloader:
+ steps += 1
# This should be the only thread running, wait for the others to finish if not.
if threadMgr.running > 1:
+ progressQ.send_init(steps+1)
+
with progress_report(_("Waiting for %s threads to finish") % (threadMgr.running-1)):
map(log.debug, ("Thread %s is running" % n for n in threadMgr.names))
threadMgr.wait_all()
+ else:
+ progressQ.send_init(steps)
with progress_report(_("Setting up the installation environment")):
ksdata.firstboot.setup(storage, ksdata, instClass)
@@ -148,7 +172,7 @@ def doInstall(storage, payload, ksdata, instClass):
# Discover information about realms to join,
# to determine additional packages
- if ksdata.realm.join_realm:
+ if willRunRealmd:
with progress_report(_("Discovering realm to join")):
ksdata.realm.setup()
@@ -171,7 +195,7 @@ def doInstall(storage, payload, ksdata, instClass):
payload.postInstall()
# Do bootloader.
- if not flags.flags.dirInstall and not ksdata.bootloader.disabled:
+ if willInstallBootloader:
with progress_report(_("Installing bootloader")):
writeBootLoader(storage, payload, instClass, ksdata)
--
1.8.3.1
10 years, 2 months
[PATCH] Do not attempt to run authconfig if it doesn't exist.
by Chris Lumens
While I'm at it, don't force installation of authconfig and firewalld. These
are defined as default packages in the core group, which means that for all
interactive users they will always be installed. This is true for almost all
kickstart users too. The only ones who will be affected are those who either
specifically remove these packages themselves or use --nocore. Those people
don't want the package to exist anyway.
---
pyanaconda/install.py | 2 +-
pyanaconda/kickstart.py | 8 ++++++--
2 files changed, 7 insertions(+), 3 deletions(-)
diff --git a/pyanaconda/install.py b/pyanaconda/install.py
index ffaeab2..be2e1a5 100644
--- a/pyanaconda/install.py
+++ b/pyanaconda/install.py
@@ -155,7 +155,7 @@ def doInstall(storage, payload, ksdata, instClass):
# anaconda requires storage packages in order to make sure the target
# system is bootable and configurable, and some other packages in order
# to finish setting up the system.
- packages = storage.packages + ["authconfig", "firewalld"] + ksdata.realm.packages
+ packages = storage.packages + ksdata.realm.packages
if not ksdata.bootloader.disabled:
packages += storage.bootloader.packages
diff --git a/pyanaconda/kickstart.py b/pyanaconda/kickstart.py
index 53c6d6f..51f77d3 100644
--- a/pyanaconda/kickstart.py
+++ b/pyanaconda/kickstart.py
@@ -229,6 +229,10 @@ def getAvailableDiskSpace(storage):
class Authconfig(commands.authconfig.FC3_Authconfig):
def execute(self, *args):
+ cmd = "/usr/sbin/authconfig"
+ if not os.path.exists(ROOT_PATH+cmd):
+ return
+
args = ["--update", "--nostart"] + shlex.split(self.authconfig)
if not flags.automatedInstall and \
@@ -237,9 +241,9 @@ class Authconfig(commands.authconfig.FC3_Authconfig):
args += ["--enablefingerprint"]
try:
- iutil.execWithRedirect("/usr/sbin/authconfig", args, root=ROOT_PATH)
+ iutil.execWithRedirect(cmd, args, root=ROOT_PATH)
except RuntimeError as msg:
- log.error("Error running /usr/sbin/authconfig %s: %s", args, msg)
+ log.error("Error running %s %s: %s", cmd, args, msg)
class AutoPart(commands.autopart.F20_AutoPart):
def execute(self, storage, ksdata, instClass):
--
1.8.3.1
10 years, 2 months