Setting Up Mint Unix-like environment from SpareMint distribution

Once all the RPM packages according to the list in the "RPM package installation sequence" are installed, only some minor configuration on Mint is needed to run SpareMint Unix-like environment. It is advantages to run the SpareMint Unix-like environment because most of the applications packaged in RPM expects this environment (because they were packaged to work in that environment). With it you will be able to run the vast amount of applications available like Samba, Apache, Ghostscript etc..without much effort (or patching to make it work).

As with any Unix-like environment, all that is needed is to edit a couple of text files to make this happen. Also note that some configurations requires that the old configuration (those quick & dirty methods and patching to make stuff works) to be remove (mostly by commenting it out). 

  1. Preparing the /etc folder

    After installing Base-1.4.2 rpm, some files in /etc folder will not be over written. We have to manually make adaptions so that the files from the rpm are used instead of those makeshift ones which we copied/created. Delete the following and rename the files from rpm to the original names:
    1. Delete the old group & rename group.rpmnew to group to use the file from the rpm distribution.
    2. Delete the old mnttab & rename mnttab.rpmnew to mnttab to use the file from the rpm distribution.
    3. Delete the old passwd & rename passwd.rpmnew to passwd to use the file from the rpm distribution.
    4. Delete the old shells & rename shells.rpmnew to shells.
    5. Delete the protocol.rpmorig as we will use the file from rpm distribution.
    6. Delete the services.rpmorig as we will use the file from rpm distribution.
    7. Leave the old resolv.conf as it probably customised with your settings.

  2. Creating the /etc/fstab file

    The fstab or filesystem table file provides information about the filesystem on the system, and is used during startup of Sparement. The default fstab is empty, so one needs to be created based on the drives of your Atari system. If you have followed this guide from the start, you would have 3 filesystem - 1st one is tos, 2nd one is Ext2 fs and the 3rd one is Fat32 fs. So create the file with following contents:
        c	/	dos	    root	wheel	750
        d	/	ext2	    root	wheel	777
        e	/	dos	    root	wheel	750
  3. Updating the Symbolic links in MINT.CNF

    All the Unix folders required by Sparemint are created in the drive D: by the RPM packages, find and uncomment all symbolic links in the MINT.CNF file so that Unix styled folders are correctly mapped to the physical folders. Make sure that they are linking to valid D: drive folders.
        sln d:/bin     /bin
        sln d:/boot    /boot
        sln d:/etc     /etc
        sln d:/root    /home
        sln d:/lib     /lib
        sln d:/mnt     /mnt
        sln d:/opt     /opt
        sln d:/root    /root
        sln d:/sbin    /sbin
        sln d:/tmp     /tmp
        sln d:/usr     /usr
        sln d:/var     /var
  4. Updating the hostname

    In the /etc/sysconfig folder is a file called hostname. This text file contain the hostname of the Atari computer and will be applied during bootup. As it does not take into account the environment variable $HOSTNAME specified in MINT.CNF, we write a simple command that writes $HOSTNAME into the file, so the hostname applied during bootup takes on the name as defined by the environment variable $HOSTNAME.
    Create a file with the following content and save it to /d/etc/myhostname. You may want to chmod it to executable.
            echo $HOSTNAME > /d/etc/sysconfig/hostname
    Edit the MINT.CNF file, and add the following line after the setenv and sln block.
            exec u:/bin/bash u:/d/etc/myhostname
  5. Setting the timezone

    Mint can run without setting any time zone information. It's just that Mint will think that your time zone is London/UK. This is fine most of the time. However, if you want to make use of time zone, you need to do the following
    1. Open up a Unix shell and execute the following command to set your time zone. This needs to be done once only.
          zic -l <region/country> -p <region/country>
      where <region/country> is the time zone in your region and country as found in the /user/share/Zoneinfo folder. 

    2. After that edit the MINT.CNF file, and add the following line after the setenv and sln block (before myhost). This will set the time mode to local time. This is needed to be executed every time on boot up, so we add it into the MINT.CNF file.
          exec u:/sbin/tzinit -l
      This command should be as early as possible so that the time related functions works at the correct time zone setting. 

  6. Preparing the console to run the XaAES and the desktop

    SpareMint runs a default console program when it reboots. To make Sparemint execute the AES when it boots up, it is required to modify the file/etc/ttytab which contains the pathname of the default console program.
    Find the following line and comment it
        console "/usr/sbin/getty console"	vt52	on secure 
    Add an additional line to run XaAES loader instead. Running the xaloader.prg will load up XaAES as well as the desktop. Note the use of Unix-like convention for the folder as well as starting from the root, not using the C: drive notation.
         # /etc/ttytab
        # Prinzipiell l„uft auf der console ein normaler getty
        # Es darf nur einer der Eintr„ge aktiv sein!
        console "/c/mint/1-16-cur/xaaes/xaloader.prg"  tw52  on secure
        #console "/usr/sbin/getty console"	vt52	on secure
        #console "/usr/bin/n_aes"		tw52	on secure
        #console "/usr/bin/xaaes"		tw52	on secure

  7. Updating MiNT.CNF to execute mint INIT process at startup

    Finally, edit MINT.CNF to comment out the loading of Xaloader.prg and instead run the INIT process of Unix. The INIT process starts various Unix-like daemons and initialise various subsystem processes like network, syslog etc that are required by the Mint Unix-like environment.
        # start XaAES
    Save the file. 

  8. Reboot to load up the SpareMint flavour of Mint

    Reboot your Atari and during the start up of Mint you will notice a "Welcome to SpareMint" message.
    Several process will run in the background
    Congratulations, you are now running SpareMint.

updated: 19 May 2010
created: 27 April 2010