
Re: The Holy Grail: A reliable Mini 2/Working YAMJ
Here you go:
Donwload the zip file (below), unzip it and copy the
mountSwap file to the root of a USB stick.
Insert the USB stick into your Playon and detach all other USB drives.
Boot your Playon.
On your PC open a Telnet of PuTTY session with the Playon, e.g. by typing
telnet <IP address of the Playon> in the Search window of the menu Start. If you use PuTTY you will know how to do this.
The user name for the Playon is
root and no password is required. Ignore the warning cannot change to home directory, because after logging in you are in the home directory.
Copy and paste the following line to the Telnet window and press Enter:
Code:
cp /tmp/usbmounts/sda1/mountSwap /usr/local/etc/
This will copy the mountSwap script to the /usr/local/etc directory in the flash memory of your Playon.
Copy and paste the following line to the Telnet window and press Enter:
Code:
echo -e '\n/usr/local/etc/mountSwap &\n' >> /usr/local/etc/rcS
This will add the line
/usr/local/etc/mountSwap & to the rcS (equivalent of autoexec.bat) script, which will call the mountSwap routine when the Playon boots.
Reboot your Playon by typing the command
reboot in Telnet. The connection will be lost.
Now swapping will be enabled if a swap partition is found on one of the attached disk drives. If more than one swap partition is found, only the first one found will be used.
So you must create a Linux swap partition (128 MB suffices) on one or both of your USB disks. Use the Mini Tools you used before.
You can check if swapping is operational by typing
free in aTelnet session. See the sample session below, in which the mountSwap script is tested before modification of the rcS script. If you test before you have a swap partition on one of your USB drives, swapping obviously will not be enabled.
The script is stored in the Playon's flash memory and will remain functional until you reinstall the firmware.
I omitted all error trapping from the scripts. So you use the script completely at your own responsibility and risk. In the worst case you may have to reinstall the firmware in the safe mode to undo the changes of the script.