Re: [suse-autoinstall] Disk partitioning with pre script !!
Hi Hans, 1. The class.xml file was missing that header and footer info which I added and restarted the install. It seems the swap is still not there !! 2. rules.xml : is exactly the same as you had mailed earlier. $ cat rules.xml <?xml version="1.0"?> <!DOCTYPE autoinstall SYSTEM "/usr/share/autoinstall/dtd/rules.dtd"> <autoinstall xmlns="http://www.suse.com/1.0/yast2ns" xmlns:config="http://www.suse.com/1.0/configns"> <rules config:type="list"> <rule> <custom1> <script> <![CDATA[ #!/bin/sh mem=$( cat /proc/meminfo | grep -i memtotal | awk '{ print $2 } ' } # Output is in kbytes echo -n $mem ]]> </script> <match>499999</match> <match_type>greater</match_type> </custom1> <result> <profile>classes/largeswap.xml</profile> <continue config:type="boolean">true</continue> </result> </rule> <rule> <custom1> <match>500000</match> <match_type>lower</match_type> </custom1> <profile>classes/smallswap.xml</profile> <continue config:type="boolean">true</continue> <custom1> <match>*</match> <match_type>exact</match_type> </custom1> <result> <profile>classes/autoinst.xml</profile> <continue config:type="boolean">false</continue> </result> </rule> </rules> </autoinstall> $ 3. /var/adm/autoinstall/cache/InstalledSystem.xml is certainly missing the swap partition info. 4. The latest documentation link seems to not working currently. Regards, Ajay
On Wednesday 19 October 2005 15:25, Ajay Mulwani wrote:
2. rules.xml : is exactly the same as you had mailed earlier.
that is broken.
$ cat rules.xml
<?xml version="1.0"?> <!DOCTYPE autoinstall SYSTEM "/usr/share/autoinstall/dtd/rules.dtd"> <autoinstall xmlns="http://www.suse.com/1.0/yast2ns" xmlns:config="http://www.suse.com/1.0/configns"> <rules config:type="list"> <rule> <custom1> <script> <![CDATA[ #!/bin/sh mem=$( cat /proc/meminfo | grep -i memtotal | awk '{ print $2 } ' } #
the line above has a syntax error. First and Last Bracket don't fit together.
echo -n $mem ]]> </script> <match>499999</match> <match_type>greater</match_type> </custom1> <result> <profile>classes/largeswap.xml</profile> <continue config:type="boolean">true</continue> </result> </rule> <rule> <custom1>
the <script> is missing. Copy it from the other rule
<match>500000</match> <match_type>lower</match_type> </custom1>
the <result> is missing
<profile>classes/smallswap.xml</profile> <continue config:type="boolean">true</continue>
close the result here with </result> close the rule here with </rule> and start a the new one with <rule>
<custom1> <match>*</match> <match_type>exact</match_type> </custom1> <result> <profile>classes/autoinst.xml</profile> <continue config:type="boolean">false</continue> </result> </rule> </rules> </autoinstall>
then put everything between <partitions ...> into the largeswap.xml you can't just put one partition into the largeswap.xml and the other partitions into autoyast.xml. I think merging will be messed up then. You can try but I don't expect that to work. I have to take a closer look but the following should work: your largeswap.xml should look something like this with all partitions: <?xml version="1.0"?> <!DOCTYPE profile SYSTEM "/usr/share/autoinstall/dtd/profile.dtd"> <profile xmlns="http://www.suse.com/1.0/yast2ns" xmlns:config="http://www.suse.com/1.0/configns"> <install> <partitioning config:type="list"> <drive> <partitions config:type="list"> <partition> <crypt>twofish256</crypt> <filesystem config:type="symbol">swap</filesystem> <format config:type="boolean">true</format> <loop_fs config:type="boolean">false</loop_fs> <mount>swap</mount> <size>2000mb</size> </partition> <partition> <filesystem config:type="symbol">xfs</filesystem> <partition_type>primary</partition_type> <size>4Gb</size> <mount>/</mount> </partition> </partitions> </drive> </partitioning> </install> </profile> autoinst.xml like this: <?xml version="1.0"?> ... lot of other stuff ... <partitioning config:type="list"> <drive> <initialize config:type="boolean">false</initialize> <use>all</use> <partitions config:type="list"> </partitions> </drive> </partitioning> ... </profile> -- ciao, Uwe Gansert Uwe Gansert, Server Technologies Team SUSE LINUX Products GmbH, Maxfeldstrasse 5, D-90409 Nuernberg, Germany e-mail: uwe.gansert@suse.de, Tel: +49-(0)911-74053-0, Fax: +49-(0)911-74053-476, Web: http://www.suse.de
participants (2)
-
Ajay Mulwani
-
Uwe Gansert