[opensuse-autoinstall] multiple autoyast bugs in opensuse 11.2?
Hi, I'm working on an autoyast install for opensuse 11.2, and running into what seems like a lot of bugs in autoyast. Am I doing something wrong? Here are the ones I can recall: * My 'services' block seems to be ignored entirely. In particular, I'm unable to start sshd this way. * For each kind of script, only the first one seems to be run. That is, if I provide two post-scripts, the second isn't being run. It seems like they all should be run. * The proposal page doesn't completely match what actually happens. For example, if I disable the firewall, it's still described as enabled there. (It also doesn't notice that I'm turning on sshd, though that could be due to some other problem.) * I've tried adding blocks for kerberos and samba configs, but these seem to be ignored completely. * The 'networking' block needs more documentation on how to set up static addresses. Are others seeing these problems? Should I be filing bug reports for them? Mike -- To unsubscribe, e-mail: opensuse-autoinstall+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-autoinstall+help@opensuse.org
on Tuesday 16 March 2010 Mike Coleman wrote:
* My 'services' block seems to be ignored entirely. In particular, I'm unable to start sshd this way.
yast2-runlevel package is installed?
* For each kind of script, only the first one seems to be run. That is, if I provide two post-scripts, the second isn't being run. It seems like they all should be run.
that's new to me. Can you post your XML file?
* The proposal page doesn't completely match what actually happens. For example, if I disable the firewall, it's still described as enabled there. (It also doesn't notice that I'm turning on sshd, though that could be due to some other problem.)
that's a known issue. The proposal screen is only good for partitioning,software,bootloader and all that stage1 stuff. Stage2 stuff that is shown on that page does not reflect the config in your XML file. Maybe I'll fix that but it's not on top of my TODO.
* I've tried adding blocks for kerberos and samba configs, but these seem to be ignored completely.
yast2-samba-client installed? yast2-kerberos-client installed?
* The 'networking' block needs more documentation on how to set up static addresses.
I know :-( -- ciao, Uwe Gansert Uwe Gansert SUSE LINUX Products GmbH, GF: Markus Rex, HRB 16746 (AG Nürnberg) Business: http://www.suse.de/~ug listening to: "Breathe Underwater" by Placebo -- To unsubscribe, e-mail: opensuse-autoinstall+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-autoinstall+help@opensuse.org
On Tue, Mar 16, 2010 at 10:27 AM, Uwe Gansert <ug@suse.de> wrote:
on Tuesday 16 March 2010 Mike Coleman wrote:
* My 'services' block seems to be ignored entirely. In particular, I'm unable to start sshd this way.
yast2-runlevel package is installed?
That did it! Did I miss the doc on this? Is there any way to tell which packages I have to install to enable which sections?
* For each kind of script, only the first one seems to be run. That is, if I provide two post-scripts, the second isn't being run. It seems like they all should be run.
that's new to me. Can you post your XML file?
Here's an example scripts section. I can send the whole thing if need be. For this, the script seems to have been unpacked into /var/adm/autoinstall, but there is no evidence that I can find (during the install or in the logs or the existence of the touched file) that it was run. <scripts> <pre-scripts config:type="list"> <script> <location>http://pxe/autoyast/preinstall.bash</location> <feedback config:type="boolean">true</feedback> <feedback_type>error</feedback_type> <debug config:type="boolean">false</debug> </script> </pre-scripts> <post-scripts config:type="list"> <script> <location>http://pxe/autoyast/postinstall.bash</location> <feedback config:type="boolean">true</feedback> <feedback_type>error</feedback_type> <debug config:type="boolean">false</debug> </script> <script> <source> <![CDATA[ echo "testing second post-install script" touch /post-install-test-2 ]]> </source> <feedback config:type="boolean">true</feedback> <feedback_type>error</feedback_type> <debug config:type="boolean">true</debug> </script> </post-scripts> </scripts> In a previous version the first script was a CDATA script and the second was by location. That aspect doesn't seem to be the cause.
* The 'networking' block needs more documentation on how to set up static addresses.
It doesn't have to be elaborate. Just pasting in a second example showing a simple static IP case would get us about 70% there... Thanks very much for your quick response! Mike -- To unsubscribe, e-mail: opensuse-autoinstall+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-autoinstall+help@opensuse.org
on Tuesday 16 March 2010 Mike Coleman wrote:
Here's an example scripts section. I can send the whole thing if need be. For this, the script seems to have been unpacked into /var/adm/autoinstall, but there is no evidence that I can find (during the install or in the logs or the existence of the touched file) that it was run.
I looked at the code. Try to give your scripts a different: <filename>xyz</filename> I think I know what's happening. Your scripts overwrite each other. Please report back if it works when you added the <filename> -- ciao, Uwe Gansert Uwe Gansert SUSE LINUX Products GmbH, GF: Markus Rex, HRB 16746 (AG Nürnberg) Business: http://www.suse.de/~ug listening to: "Shades" by mind.in.a.box -- To unsubscribe, e-mail: opensuse-autoinstall+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-autoinstall+help@opensuse.org
On Wed, Mar 17, 2010 at 7:25 AM, Uwe Gansert <ug@suse.de> wrote:
I looked at the code. Try to give your scripts a different: <filename>xyz</filename>
That fixed it. Thanks! -- To unsubscribe, e-mail: opensuse-autoinstall+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-autoinstall+help@opensuse.org
On Tue, Mar 16, 2010 at 16:17, Mike Coleman <tutufan@gmail.com> wrote:
* For each kind of script, only the first one seems to be run. That is, if I provide two post-scripts, the second isn't being run. It seems like they all should be run.
Do you keep your scripts in different xml files and merge them? The default merging behaviour of autoyast is rather counter-intuitive (see http://www.suse.de/~ug/autoyast_doc/merging.html).
* The 'networking' block needs more documentation on how to set up static addresses.
For this and most of the other issues, you could also take a look of our now-working config (thanks to Uwe) that I sent today (about mkinitrd). Regarding static adresses, if your machine gets the "right" IP during install, like via boot parameter "hostip=a.b.c.d", you can use <keep_install_network> (as in our config). If your machine does not get the correct IP, I have a working config at work, but I can't access it before next week. Not installing the yast* packages - like Uwe mentioned - was something that always bit me in the beginning. tty, 686f6c6d -- To unsubscribe, e-mail: opensuse-autoinstall+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-autoinstall+help@opensuse.org
On Tue, Mar 16, 2010 at 11:42 AM, 686f6c6d <686f6c6d@googlemail.com> wrote:
Do you keep your scripts in different xml files and merge them? The default merging behaviour of autoyast is rather counter-intuitive (see http://www.suse.de/~ug/autoyast_doc/merging.html).
No merging (yet). Yes, I'm wary of that.
Regarding static adresses, if your machine gets the "right" IP during install, like via boot parameter "hostip=a.b.c.d", you can use <keep_install_network> (as in our config).
Unfortunately, we don't have that here. I was ultimately able to figure this out by using 'yast' to generate sections of the file which I could then tweak... Mike -- To unsubscribe, e-mail: opensuse-autoinstall+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-autoinstall+help@opensuse.org
On Tue, Mar 16, 2010 at 18:23, Mike Coleman <tutufan@gmail.com> wrote:
On Tue, Mar 16, 2010 at 10:27 AM, Uwe Gansert <ug@suse.de> wrote:
yast2-runlevel package is installed?
That did it! Did I miss the doc on this? Is there any way to tell which packages I have to install to enable which sections?
I might be wrong, but i think this isn't in the docs (yet?).
Here's an example scripts section. I can send the whole thing if need be. For this, the script seems to have been unpacked into /var/adm/autoinstall, but there is no evidence that I can find (during the install or in the logs or the existence of the touched file) that it was run.
If the files are there, then I'd assume they were executed, too. Try turning on debugging, that way you'll have an additional /var/adm/autoinstall/scripts/<scriptname>-run with "set -x"-like debug output of the shellscript. For pre-scripts, note these are run *before* the target system is even mounted. So if you write anything anywhere, it doesn't mean it will end up in the target system. The example from the docs[0] for a pre-script is to edit the autoyast profile and reread it. Try something like that, too (because I can't think of anything else useful right now; well, if you have access to the webserver logs, you could put something useless like "wget http://pxe/script1-success" in there). When the post-script is run, the target system is available in /mnt, does your script write or touch something there? (This would explain why your touch in the third script does not show up in the target, you want to touch /mnt/post-install-test-2. Why the echo doesn't show up, I can't tell though.)
* The 'networking' block needs more documentation on how to set up static addresses.
It doesn't have to be elaborate. Just pasting in a second example showing a simple static IP case would get us about 70% there...
I found one of my vmware home-clickups and documentation for it. What i did was this: ---------- 8< ---------- == Network == === IP === * network devices -> network settings -> edit -> overview * add -> next -> statically assigned ip address -> ip address "172.16.98.123", subnet mask "255.255.255.0" -> next -> ok === Route === * network devices -> network settings -> edit -> routing -> default gateway "172.16.98.254" -> ok === Hostname / DNS / resolv.conf === * network devices -> network settings -> edit -> hostname/dns * hostname "new-and-shiny", domain "tengrand" * name server 1 "172.16.98.65", name server 2 "172.16.98.193" * domain search "tengrand" (might be set automatically by dhcp/installer anyway) -> ok ---------- >8 ---------- And it resulted in this xml snippet (the relevant part should be <interfaces> and maybe <routing>) ---------- 8< ---------- <networking> <dhcp_options> <dhclient_hostname_option>AUTO</dhclient_hostname_option> </dhcp_options> <dns> <dhcp_hostname config:type="boolean">true</dhcp_hostname> <domain>tengrand</domain> <hostname>new-and-shiny</hostname> <nameservers config:type="list"> <nameserver>172.16.98.65</nameserver> <nameserver>172.16.98.193</nameserver> </nameservers> <resolv_conf_policy>auto</resolv_conf_policy> <searchlist config:type="list"> <search>tengrand</search> </searchlist> </dns> <interfaces config:type="list"> <interface> <bootproto>static</bootproto> <device>eth0</device> <ipaddr>172.16.98.123</ipaddr> <netmask>255.255.255.0</netmask> <prefixlen>24</prefixlen> <startmode>auto</startmode> <usercontrol>no</usercontrol> </interface> </interfaces> <managed config:type="boolean">false</managed> <routing> <ip_forward config:type="boolean">false</ip_forward> <routes config:type="list"> <route> <destination>default</destination> <device>-</device> <gateway>172.16.98.254</gateway> <netmask>-</netmask> </route> </routes> </routing> </networking> ---------- >8 ----------
Regarding static adresses, if your machine gets the "right" IP during install, like via boot parameter "hostip=a.b.c.d", you can use <keep_install_network> (as in our config).
Unfortunately, we don't have that here. I was ultimately able to figure this out by using 'yast' to generate sections of the file which I could then tweak...
Yeah, we did the same in the beginning: Click together a bit of stuff we knew we'd need, then get the file under version control and edit it with our favorite text editors from there. tty, 686f6c6d 0: http://www.suse.de/~ug/autoyast_doc/createprofile.scripts.html#pre-install.s... -- To unsubscribe, e-mail: opensuse-autoinstall+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-autoinstall+help@opensuse.org
On 3/16/10 3:22 PM, "686f6c6d" <686f6c6d@googlemail.com> wrote:
For pre-scripts, note these are run *before* the target system is even mounted. So if you write anything anywhere, it doesn't mean it will end up in the target system. The example from the docs[0] for a pre-script is to edit the autoyast profile and reread it. Try something like that, too (because I can't think of anything else useful right now; well, if you have access to the webserver logs, you could put something useless like "wget http://pxe/script1-success" in there).
I use pre-install scripts extensively... my solution to capture the output was to run all my work in a subdirectory in /tmp (call it /tmp/myinstall for the purpose of the example) and install a chroot script, executed before the first reboot but after the install, set to run in the default mode which is <chrooted config:type="boolean">false</chrooted> it's actually run before chrooting, so the new root is available on /mnt. My chroot script basically cp -R /tmp/myinstall and into /mnt/var/adm/autoinstall/myinstall ... thus all my logs, scripts and everything else done in pre-install space may be found with the rest of the autoinstall stuff. http://suse.de/%7Eug/autoyast_doc/createprofile.scripts.html#chroot.scripts Works like a charm Tim -- Tim Kirby 651-605-9074 trk@cray.com Cray Inc. Information Systems -- To unsubscribe, e-mail: opensuse-autoinstall+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-autoinstall+help@opensuse.org
On Tue, Mar 16, 2010 at 3:58 PM, Tim Kirby <trk@cray.com> wrote:
I use pre-install scripts extensively... my solution to capture the output was to run all my work in a subdirectory in /tmp (call it /tmp/myinstall for the purpose of the example) and install a chroot script, executed before the first reboot but after the install
I'm doing the same thing (with a smaller bit of data) by sed'ing it into the autoyast config file itself. This seems like a common enough thing to do that maybe it'd be worth making an explicit feature. For example, anything written into /tmp/save (or some better spot) in a pre-script is present in that location in further scripts. Mike -- To unsubscribe, e-mail: opensuse-autoinstall+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-autoinstall+help@opensuse.org
On Tue, Mar 16, 2010 at 3:22 PM, 686f6c6d <686f6c6d@googlemail.com> wrote:
If the files are there, then I'd assume they were executed, too.
Uwe had the solution. Currently it seems that they will not be if they don't have explicit, unique 'filename' tags.
you could put something useless like "wget http://pxe/script1-success"
Is 'wget' specified to be present at the pre-script stage? It'd be nice to have a list of what can be assumed at each point.
When the post-script is run, the target system is available in /mnt
Actually, I've been writing into / in post-scripts and it seems to work. But again, it'd be helpful if the assumptions of each script stage were spelled out a bit more in the doc. Thanks for your help! Mike -- To unsubscribe, e-mail: opensuse-autoinstall+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-autoinstall+help@opensuse.org
on Tuesday 16 March 2010 686f6c6d wrote:
That did it! Did I miss the doc on this? Is there any way to tell which packages I have to install to enable which sections?
I might be wrong, but i think this isn't in the docs (yet?).
no it's not. That it's not documented has historical reasons. In the past there was the rule "all yast modules have to be installed always". That has changed, actually quite a while ago but I did not catch up with autoyast yet. Autoyast still works best if all yast modules are installed :)
When the post-script is run, the target system is available in /mnt,
post-scripts run in stage2 after the reboot. So you are already in the installed system. You mean chroot-scripts with chrooted=false
Unfortunately, we don't have that here. I was ultimately able to figure this out by using 'yast' to generate sections of the file which I could then tweak...
Yeah, we did the same in the beginning: Click together a bit of stuff we knew we'd need, then get the file under version control and edit it with our favorite text editors from there.
I know that vim (and maybe even emacs) is faster than the autoyast UI but if you are in doubt what and how you can configure something, it's not a bad idea to launch the AutoYaST UI to take a look what it will create :) -- ciao, Uwe Gansert Uwe Gansert SUSE LINUX Products GmbH, GF: Markus Rex, HRB 16746 (AG Nürnberg) Business: http://www.suse.de/~ug listening to: "The Last Ninja 3" by mind.in.a.box -- To unsubscribe, e-mail: opensuse-autoinstall+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-autoinstall+help@opensuse.org
On Wed, Mar 17, 2010 at 17:18, Uwe Gansert <ug@suse.de> wrote:
When the post-script is run, the target system is available in /mnt,
post-scripts run in stage2 after the reboot. So you are already in the installed system. You mean chroot-scripts with chrooted=false
My bad. I was actually reading the post*partitioning* docs by mistake. :D tty, 686f6c6d -- To unsubscribe, e-mail: opensuse-autoinstall+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-autoinstall+help@opensuse.org
On Wed, Mar 17, 2010 at 11:18 AM, Uwe Gansert <ug@suse.de> wrote:
That it's not documented has historical reasons. In the past there was the rule "all yast modules have to be installed always". That has changed, actually quite a while ago but I did not catch up with autoyast yet. Autoyast still works best if all yast modules are installed :)
I get it. I work in a shop with hundreds of servers, and I'm somewhat conflicted about installing all of yast. On the one hand, it's handy, but on the other hand, it's sort of an attractive nuisance--it's tempting, but it's not a practical way to make identical changes on a large number of machines (aside from autoyast itself). Mike -- To unsubscribe, e-mail: opensuse-autoinstall+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-autoinstall+help@opensuse.org
participants (4)
-
686f6c6d
-
Mike Coleman
-
Tim Kirby
-
Uwe Gansert