Format

The XML configuration format provides a consistent file structure, which is easier to learn and remember when attempting to configure a new system.

The AutoYaST2 control file uses XML to describe the system installation and configuration. XML is a commonly used mark up and many users are familiar with the concepts of the language and the tools used to process XML files. If you edit an existing control file or create a control file using an editor from scratch, it is strongly recommended to validate the control file using a validating XML parser.

The following example shows a control file in XML format:

Example 2.1. XML Control File (Profile)

<?xml version="1.0"?>
<!DOCTYPE profile>
 <profile
 xmlns="http://www.suse.com/1.0/yast2ns"
 xmlns:config="http://www.suse.com/1.0/configns">
   <partitioning  config:type="list">
      <drive>
         <device>/dev/hda</device>
         <partitions config:type="list">
           <partition>
              <filesystem config:type="symbol">ext2</filesystem>
              <size>520Mb</size>
              <mount>/</mount>
           </partition>
           <partition>
              <filesystem config:type="symbol">reiser</filesystem>
              <size>1200Mb</size>
              <mount>/data</mount>
           </partition>
         </partitions>
      </drive>
   </partitioning>
   <scripts>
    <pre-scripts>
     <script> 
        <interpreter>shell</interpreter>
	<filename>start.sh</filename>
         <source>

            <![CDATA[
#!/bin/sh 
echo "Starting installation" 
exit 0

]]>

         </source>
     </script>  
    </pre-scripts>
   </scripts>
</profile>