MX-760HD AnalysisOfTheLiveSlashTmp

From MvixCommunity

Jump to: navigation, search

/tmp is a ramfs filesystem, which uses a portion of the MX-760HD's 32MB RAM.

Because not every MX-760HD owner has an internal hard disk and becuase the root partition is a read-only romfs file system, /tmp is the only location Unicorn can depend upon to be writable.

As this is the case, they tend to use /tmp inappropriately when compared to Unix standards.

Contents Of /tmp

/tmp/ide

If you have a hard disk included in the unit, /tmp/ide will exist. /tmp/ide/part1 is your first disk partition, /tmp/ide/part2 is your second disk partition and so on.

The mounting of partitions is handled by /usr/curacao/curacao, not by /etc/fstab.

/tmp/usb

If you have USB storage media (thumbstick/flashdisk/hard disk/solid state disk) plugged in to the unit /tmp/usb/disc0/lun0/part0 is present (assuming you only have one partition on your thumbstick).

/tmp/iso

If you open an ISO file through the curacao binary (for example, if you play a DVD image), /tmp/iso is available. It contains the ISO image's contents (via a loopback mount).

Interestingly, if you press stop after playing the ISO image /tmp/iso is still present, and the contents of the ISO are still available under this path.

/tmp/res

/tmp/res is where the On Screen Display (OSD) fonts files are kept. These are the font files used when displaying text on the front panel LCD.

/tmp/config

/tmp/config is where run-time (volatile) configuration data is stored. The contents of /tmp/config is as follows:

  /tmp/config
    |--player.conf (most of the configuration data except network configuration)
    |--resolv.conf (DNS configuration)
    |--smbsnapshot.conf (??)
    |--network
         |
         |--wireless (Wireless configuration data, including non-encrypted key)
         |--wired    (Wired configuration data)
         |--global   (Global network settings)
    |--playlists (Jukebox data, information about most recent played files)

Most probably, curacao is calling /usr/local/bin/pref_saveall.sh to compress all configuration data into /tmp/config.tgz, convert it into a flashable file and save it into flash area /dev/mtd/2.

A few notes about /tmp/res and /tmp/config

Both /tmp/res and /tmp/config have hidden .svn directories under their structures.

This means Unicorn (or whomever made this portion of the firmware) used Subversion for their source control.

Under both of the .svn directories. there is a file called entries. This is a Subversion activity log for commits to the subversion server.

In it, it shows that the URL of the subversion server as being svn://bzbrain/d/trunk/2.5.113.1/system/cubeon/rompkg/tmp/config.

It also shows the date was 2006-08-07. If you use DNS serial number conventions, this would mean the 7th August 2006.

The author of the modifications as listed in the entries files is "nazgul33".

Personal tools