Flag media stored on the core as private

From LinuxMCE
Revision as of 11:09, 15 March 2007 by Juliet (Talk | contribs)

Jump to: navigation, search
This page was written by Pluto and imported with their permission when LinuxMCE branched off in February, 2007. In general any information should apply to LinuxMCE. However, this page should be edited to reflect changes to LinuxMCE and remove old references to Pluto.

How to set it up

When you initially rip a disk or otherwise transfer media to the Core, normally the Orbiter asks you if you want the media to be public or private. If you specify the media is public then that means it goes in a public folder and every user will be able to view that media. If you specified that the media is private then it goes in a private folder for you so only you will be able to view the media. When you choose one of the media's scenarios that takes you to file as, such as music or movies, you'll see combined together all of the public media and all of your private media.

Mobile phone orbiters are assigned to, or locked onto, a particular user. So the user of a mobile orbiters will always be able to view public media and his own private media. However other orbiters like Web pads, PDA's and on-screen displays are typically shared by the whole family. On the main menu is a button for you to select who is currently using the Orbiters. By default all orbiters allow all users to be selected without entering a PIN code. Therefore even if you mark your media as private, nothing prevents another user in the family from telling the orbiter that he is you and accessing your private media. So with the default settings, marking media as private is more a convenience than rather insuring real privacy.

If you want to ensure the media is truly private, then you need to add some restrictions to the Orbiters, which admittedly means you sacrifice a bit of ease of use. In LinuxMCEAdmin go to the Wizard, Devices, Orbiters page to add restrictions. You can specify, for example, that to select your user account the PIN code is required. Or you can say that only certain users can be selected on certain orbiters if you can control who has physical access to those orbiters. Or you can do a combination. For example, on the restrictions page you could specify that in order to select your user account in the living room, where the Orbiter is shared, a pin code is required, however to selected your user account on the Orbiter in your bedroom, where no one else has access, a pin code is not required.

Once the media is already ripped, or if you're copying your own media from another location, the easiest way to organize the directories and handle what is public vs private is with the network file shares the Core makes available. These files shares work with Linux, Windows and Mac. Simply bring up the Core in your network places using the Core's IP address. For example in Windows, you can choose "start", "run" and type in \\ or whatever is the Core's IP address, or you can use browse network places.

Log into the Core using the same user name and password you use for the LinuxMCE Admin website. You'll see there are two shares which you can attach as network drives, one for the Public folder which everyone shares, and one for your own Private folder. You can then use the File Manager of your choice to move files around, creating directories, and move files between the public and private shares.

Programmer's guide

At boot up the Core creates a samba share for the users by running the SetupUsers*.sh scripts. All the media files and their attributes are stored in the pluto_media database. This is necessary so that the user can search quickly by attribute, such as finding all movies with a certain actor. The UpdateMedia utility is what is responsible for keeping the database in sync with what is really on the hard drive. It uses the NFS's extended attributes to store the database record for all of your files. When you rename or move files, UpdateMedia is automatically run on the modified directory and will scan the files, picking up the attributes, detecting new moved and renamed files, and so on.