Description of problem: system-config-kickstart --generate gives error. Version-Release number of selected component (if applicable): system-config-kickstart-2.9.0-1.fc18.noarch.rpm How reproducible: sudo system-config-kickstart --generate ks.cfg Actual results: File "/bin/system-config-kickstart", line 67, in <module> useCliMode(opts.generate) File "/bin/system-config-kickstart", line 41, in useCliMode profileSystem = profileSystem.ProfileSystem(ksHandler) File "/usr/share/system-config-kickstart/profileSystem.py", line 39, in __init__ self.getTimezone() File "/usr/share/system-config-kickstart/profileSystem.py", line 59, in getTimezone lines = open('/etc/sysconfig/clock', 'r').readlines() IOError: [Errno 2] No such file or directory: '/etc/sysconfig/clock' After making a symbolic: sudo cp -s /usr/share/zoneinfo/myContinent/myCity /etc/sysconfig/clock I got past that error but then got: File "/bin/system-config-kickstart", line 67, in <module> useCliMode(opts.generate) File "/bin/system-config-kickstart", line 41, in useCliMode profileSystem = profileSystem.ProfileSystem(ksHandler) File "/usr/share/system-config-kickstart/profileSystem.py", line 39, in __init__ self.getTimezone() File "/usr/share/system-config-kickstart/profileSystem.py", line 65, in getTimezone zone = string.replace(zone, '"', "") UnboundLocalError: local variable 'zone' referenced before assignment In /usr/share/system-config-kickstart/profileSystem.py I changed: zone = string.replace(zone, '"', "") zone = string.replace(zone, "'", "") zone = string.strip(zone) self.ks.timezone(timezone=zone, isUtc=False) For: zone = string.replace(line, '"', "") zone1 = string.replace(zone, "'", "") zone2 = string.strip(zone1) self.ks.timezone(timezone=zone2, isUtc=False) I then got the kickstart file perfectly. Please correct this error.
Does the resulting kickstart file even come close to resembling your system?
Well, the header comes like this: #version=DEVEL (incorrect) # Install OS instead of upgrade install # Keyboard layouts keyboard 'us'# Use CDROM installation media (wrong keyboard & need a new line) cdrom # Root password (omitted lines on purpose) # System timezone timezone WET0WEST,M3.5.0/1,M10.5.0 (probably wrong, it's Lisbon) # System language lang en_US # SELinux configuration selinux --enforcing # Clear the Master Boot Record zerombr # Partition clearing information clearpart --linux %packages (seems to have all my packages listed)
To get the correct timezone I modified /usr/share/system-config-kickstart/profileSystem.py again: Instead of: zone = string.replace(zone, '"', "") zone = string.replace(zone, "'", "") zone = string.strip(zone) I have: zone = os.path.realpath('/etc/localtime') zone = string.replace(zone, "/usr/share/zoneinfo/", "") As per same result as with F16. Some other lines before are not necessary. Maybe I should check the old file. I hope kickstart files are still useful in F18.
system-config-kickstart-2.9.1-1.fc19 has been submitted as an update for Fedora 19. https://admin.fedoraproject.org/updates/system-config-kickstart-2.9.1-1.fc19
Thanks. I will try it out when I can. When custom installing F18 I found 2 problems: 1) Installation fails with just one transaction error, 2) The boot partition is left almost empty and is only recoverable through another installation on the side which detects the first.
Package system-config-kickstart-2.9.1-1.fc19: * should fix your issue, * was pushed to the Fedora 19 testing repository, * should be available at your local mirror within two days. Update it with: # su -c 'yum update --enablerepo=updates-testing system-config-kickstart-2.9.1-1.fc19' as soon as you are able to. Please go to the following url: https://admin.fedoraproject.org/updates/FEDORA-2013-7862/system-config-kickstart-2.9.1-1.fc19 then log in and leave karma (feedback).
Package system-config-kickstart-2.9.1-2.fc19: * should fix your issue, * was pushed to the Fedora 19 testing repository, * should be available at your local mirror within two days. Update it with: # su -c 'yum update --enablerepo=updates-testing system-config-kickstart-2.9.1-2.fc19' as soon as you are able to. Please go to the following url: https://admin.fedoraproject.org/updates/FEDORA-2013-7862/system-config-kickstart-2.9.1-2.fc19 then log in and leave karma (feedback).
Testing system-config-kickstart-2.9.1-2.fc19 I always get default 'us' keyboard: Looking around for the problem I found these 2 solutions: Solution in "/usr/share/system-config-kickstart/profileSystem.py": def getKeyboard(self): kbd = keyboard.Keyboard() # unmodified line = open('/etc/vconsole.conf', 'r').readline() tag, kbd1 = string.split(line, '=') kbd1 = string.replace(kbd1, '"', "") kbd1 = string.replace(kbd1, "\n", "") kbd.set(kbd1) self.ks.keyboard(keyboard=kbd.get()) # unmodified Solution in "/usr/lib/python2.7/site-packages/system_config_keyboard/keyboard.py": def read(self): try: line = open('/etc/vconsole.conf', 'r').readline() # modified except: return self.config = [] (name, value) = line.rstrip("\n").split ('=') self.config.append ([line, name, value.strip ('"'), 0]) self.beenset = 1 return value.strip('"') # added Then "/usr/share/system-config-kickstart/profileSystem.py" becomes: def getKeyboard(self): kbd = keyboard.Keyboard() kbd.set(kbd.read()) # modified self.ks.keyboard(keyboard=kbd.get()) Either way I cannot get rid of the single quotes around the keyboard type.
system-config-kickstart-2.9.1-2.fc19 has been pushed to the Fedora 19 stable repository. If problems still persist, please make note of it in this bug report.
Going forward with system-config-kickstart-2.9.1-2.fc19. After a burnt computer I managed to test the kickstart file. I cannot get a bootable system with the kickstart instalation. Even after selecting "Do not install boot loader" I got the other working F19 system, on the side, destroyed. It could be the fault of mkisofs command. The result is that the important files are not written to grub2, so it's unbootable.
system-config-kickstart --generate doesn't do much about the bootloader config, and it's not at all clear to me (given the lack of info here such as log files or the kickstart file in question) that this is system-config-kickstart's problem. It could be anaconda. Please open a new bug for your new problem.