<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>http://wiki.linuxmce.org/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Juanfe</id>
	<title>LinuxMCE - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="http://wiki.linuxmce.org/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Juanfe"/>
	<link rel="alternate" type="text/html" href="http://wiki.linuxmce.org/index.php/Special:Contributions/Juanfe"/>
	<updated>2026-07-21T21:46:31Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.44.0</generator>
	<entry>
		<id>http://wiki.linuxmce.org/index.php?title=How_to_setup_Local_Authoritative_DNS&amp;diff=15515</id>
		<title>How to setup Local Authoritative DNS</title>
		<link rel="alternate" type="text/html" href="http://wiki.linuxmce.org/index.php?title=How_to_setup_Local_Authoritative_DNS&amp;diff=15515"/>
		<updated>2008-09-05T23:00:03Z</updated>

		<summary type="html">&lt;p&gt;Juanfe: /* Installation */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[category: Tutorials]]&lt;br /&gt;
=How to setup Local Authoritative DNS=&lt;br /&gt;
&lt;br /&gt;
I was wanting an authoritative name server for my local intranet.  I also wanted any dynamic IP&#039;s to be visible to the name server.  The name server included with linuxmce is configured as a recursive name server.  Here&#039;s the changes I did to configure my core&#039;s name server to be authoritative and support dynamic IPs.  Note, the machines on my intranet are private, i.e., not known to the outside world.&lt;br /&gt;
&lt;br /&gt;
  3 Feb 2008 - Developed and tested on LinuxMCE 0710 Beta 3 amd64.&lt;br /&gt;
&lt;br /&gt;
I named my intranet &amp;quot;wright.local&amp;quot;.  Using a &amp;quot;local&amp;quot; top level domain (TLD) is recommended for private intranets.  Some may prefer to use &amp;quot;lan&amp;quot;.  You do not want to use any of the standard TLDs like &amp;quot;com&amp;quot;, &amp;quot;net&amp;quot;, &amp;quot;org&amp;quot;,...&lt;br /&gt;
&lt;br /&gt;
I used the core&#039;s default intranet addresses, 192.168.80.0/24 with the core at 192.168.80.1.&lt;br /&gt;
&lt;br /&gt;
I&#039;ve attempted to verbosely document each config file. :)&lt;br /&gt;
&lt;br /&gt;
The directions for adapting the config files are included in the named.conf file.&lt;br /&gt;
&lt;br /&gt;
==Installation==&lt;br /&gt;
&lt;br /&gt;
If you want to try this, I would suggest building the config in new directories then swapping with the originals when you are ready (I had a little mess when my core hung and I had to restart with only half the configs ready) :)&lt;br /&gt;
&lt;br /&gt;
So start with creating two directories:&lt;br /&gt;
&lt;br /&gt;
  sudo mkdir /etc/bind.new&lt;br /&gt;
  sudo mkdir /etc/dhcp3.new&lt;br /&gt;
&lt;br /&gt;
Now copy the contents of the original directories:&lt;br /&gt;
&lt;br /&gt;
  sudo cp -arp /etc/bind/* /etc/bind.new&lt;br /&gt;
  sudo cp -arp /etc/dhcp3/* /etc/dhcp3.new&lt;br /&gt;
&lt;br /&gt;
Also create a new resolve.conf file:&lt;br /&gt;
&lt;br /&gt;
  sudo touch /etc/resolv.conf.new&lt;br /&gt;
&lt;br /&gt;
You will be creating or editing the following config files in these new directories:&lt;br /&gt;
&lt;br /&gt;
  /etc/bind.new/named.conf&lt;br /&gt;
  /etc/bind.new/named.conf.options&lt;br /&gt;
  /etc/bind.new/logging.conf&lt;br /&gt;
  /etc/bind.new/rndc.conf&lt;br /&gt;
  /etc/bind.new/rndc.key&lt;br /&gt;
  /etc/bind.new/db.wright.local.zone&lt;br /&gt;
  /etc/bind.new/db.wright.local.rev&lt;br /&gt;
  /etc/dhcp3.new/dhcpd.conf&lt;br /&gt;
  /etc/resolv.conf.new&lt;br /&gt;
&lt;br /&gt;
The full text of the files you will be editing is at the foot of this page. The original author named his network &amp;quot;wright&amp;quot;; you should replace all instances of &amp;quot;wright&amp;quot; with the name of your network.&lt;br /&gt;
&lt;br /&gt;
==Notes on Editing Files==&lt;br /&gt;
&lt;br /&gt;
===rndc.key and dhcpd.conf key values=== &lt;br /&gt;
&lt;br /&gt;
To create a key for use in rndc.key and dhcpd.conf:&lt;br /&gt;
&lt;br /&gt;
  sudo dnssec-keygen -a HMAC-MD5 -b 256 -n user rndc&lt;br /&gt;
&lt;br /&gt;
Now get the key from the private file:&lt;br /&gt;
&lt;br /&gt;
  sudo cat Krndc.*.private&lt;br /&gt;
  Private-key-format: v1.2&lt;br /&gt;
  Algorithm: 157 (HMAC_MD5)&lt;br /&gt;
  Key: 3+GnSWV5FKxcUu57k7QFxbpvv/xr4fXj2wBVGtdGifI=&lt;br /&gt;
  Bits: AAA=&lt;br /&gt;
&lt;br /&gt;
Now cut the key which is to the right of &amp;quot;Key: &amp;quot; and paste where needed (replace &amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot; with the key in the config files).  So an example using the above key would look like:&lt;br /&gt;
&lt;br /&gt;
  key &amp;quot;linuxmce-dhcp&amp;quot; {&lt;br /&gt;
        algorithm	hmac-md5;&lt;br /&gt;
        secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
  };&lt;br /&gt;
&lt;br /&gt;
becomes:&lt;br /&gt;
&lt;br /&gt;
  key &amp;quot;linuxmce-dhcp&amp;quot; {&lt;br /&gt;
        algorithm	hmac-md5;&lt;br /&gt;
        secret		&amp;quot;3+GnSWV5FKxcUu57k7QFxbpvv/xr4fXj2wBVGtdGifI=&amp;quot;;&lt;br /&gt;
  };&lt;br /&gt;
&lt;br /&gt;
===Check directory ownership===&lt;br /&gt;
Make the logging directory:&lt;br /&gt;
&lt;br /&gt;
  sudo mkdir /var/log/named&lt;br /&gt;
  sudo chown bind:bind /var/log/named&lt;br /&gt;
  sudo chmod 755 /var/log/named&lt;br /&gt;
&lt;br /&gt;
===Setting default domain===&lt;br /&gt;
You probably ought to check and change the defaultdomain:&lt;br /&gt;
&lt;br /&gt;
  domainname&lt;br /&gt;
&lt;br /&gt;
will probably show&lt;br /&gt;
&lt;br /&gt;
  pluto&lt;br /&gt;
&lt;br /&gt;
if so, then set it by:&lt;br /&gt;
  sudo domainname yourdomain.local&lt;br /&gt;
&lt;br /&gt;
where &amp;quot;yourdomain.local&amp;quot; is your domain.  :-)&lt;br /&gt;
&lt;br /&gt;
===File Permissions===&lt;br /&gt;
Change all the file permissions per instructions in named.conf:&lt;br /&gt;
&lt;br /&gt;
   File permissions:&lt;br /&gt;
  //    /etc/bind/named.conf   root:root   644&lt;br /&gt;
  //    /etc/bind/rndc.key     root:bind   640&lt;br /&gt;
  //    /etc/bind/rndc.conf    root:root   600&lt;br /&gt;
  //    /etc/resolv.conf       root:root   644&lt;br /&gt;
  //    /etc/bind              root:bind   775, chmod g+s =&amp;gt; drwxrwsr-x&lt;br /&gt;
  //    /etc/dhcp3             root:root   755&lt;br /&gt;
  //    /etc/dhcp3/dhcpd.conf  root:root   644&lt;br /&gt;
  //&lt;br /&gt;
&lt;br /&gt;
===Double check. Everything===&lt;br /&gt;
Double check everything.   Roll Eyes&lt;br /&gt;
&lt;br /&gt;
==Wrapping up==&lt;br /&gt;
When and if you are feeling lucky, rename the original directories and then rename the new directories to take their place:&lt;br /&gt;
&lt;br /&gt;
  sudo mv /etc/bind /etc/bind.original&lt;br /&gt;
  sudo mv /etc/bind.new /etc/bind&lt;br /&gt;
  sudo mv /etc/dhcp3 /etc/dhcp3.original&lt;br /&gt;
  sudo mv /etc/dhcp3.new /etc/dhcp3&lt;br /&gt;
  sudo mv /etc/resolve.conf /etc/resolve.conf.original&lt;br /&gt;
  sudo mv /etc/resolve.conf.new /etc/resolve.conf&lt;br /&gt;
&lt;br /&gt;
Finally restart the bind and dhcpd services:&lt;br /&gt;
&lt;br /&gt;
  sudo rndc reload&lt;br /&gt;
  sudo /etc/init.d/dhcp3-server restart&lt;br /&gt;
&lt;br /&gt;
Check the syslog for any errors:&lt;br /&gt;
&lt;br /&gt;
  grep named /var/log/syslog&lt;br /&gt;
  grep dhcpd /var/log/syslog&lt;br /&gt;
&lt;br /&gt;
==Config Files==&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/named.conf===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
// This is the primary configuration file for the BIND DNS server named.&lt;br /&gt;
//&lt;br /&gt;
// This configuration supports an authoritative local zone (wright.local on&lt;br /&gt;
// 192.168.80.0/24) and allows DHCP to update the local zone.  &lt;br /&gt;
// To customize to your setup:&lt;br /&gt;
// 1) replace &amp;quot;wright.local&amp;quot; with your internal domain name.&lt;br /&gt;
// 2) edit db.wright.local.zone and db.wright.local.rev and replace&lt;br /&gt;
//    my static names/addresses with your network&#039;s static names/addresses.&lt;br /&gt;
//    Make sure to increment the serial number of any file edited.  &lt;br /&gt;
//    Note, format of serial number is:  YYYYMMDDNN where YYYY is year, &lt;br /&gt;
//    MM is month, DD is day, NN is update number for that day (i.e., 01, &lt;br /&gt;
//    02, 03,...)&lt;br /&gt;
// 3) rename db.wright.local.zone to match your domain name.&lt;br /&gt;
// 4) rename db.wright.local.rev to match your domain name.&lt;br /&gt;
// 5) If you changed the internal network IP from the LinuxMCE default of&lt;br /&gt;
//    192.168.80.0/24, then replace &amp;quot;192.168.80&amp;quot; with your network&lt;br /&gt;
//    ip and replace it&#039;s reverse &amp;quot;80.168.192&amp;quot; wity your network ip&#039;s&lt;br /&gt;
//    reverse.&lt;br /&gt;
//&lt;br /&gt;
// Please read /usr/share/doc/bind9/README.Debian.gz for information on the &lt;br /&gt;
// structure of BIND configuration files in Debian, *BEFORE* you customize &lt;br /&gt;
// this configuration file.&lt;br /&gt;
//&lt;br /&gt;
// If you are just adding zones, please do that in /etc/bind/named.conf.local&lt;br /&gt;
//&lt;br /&gt;
// references:&lt;br /&gt;
// http://www.arda.homeunix.net/dnssetup.html&lt;br /&gt;
// http://www.madboa.com/geek/soho-bind/&lt;br /&gt;
//&lt;br /&gt;
// notes:&lt;br /&gt;
// 1) The following command should be ran about twice a year to keep&lt;br /&gt;
//    the root servers current:&lt;br /&gt;
//      dig @a.root-servers.net . ns &amp;gt; /etc/bin/db.root&lt;br /&gt;
//    Root name servers don’t change very often so updating this file more &lt;br /&gt;
//    than twice a year is probably overkill. Frequent updates also put undo &lt;br /&gt;
//    load on the root name servers; they have enough to do as it is.&lt;br /&gt;
//&lt;br /&gt;
// 2) File permissions:&lt;br /&gt;
//    /etc/bind/named.conf   root:root   644&lt;br /&gt;
//    /etc/bind/rndc.key     root:bind   640&lt;br /&gt;
//    /etc/bind/rndc.conf    root:root   600&lt;br /&gt;
//    /etc/resolv.conf       root:root   644&lt;br /&gt;
//    /etc/bind              root:bind   775, chmod g+s =&amp;gt; drwxrwsr-x&lt;br /&gt;
//    /etc/dhcp3             root:root   755&lt;br /&gt;
//    /etc/dhcp3/dhcpd.conf  root:root   644&lt;br /&gt;
//&lt;br /&gt;
// Manually Updating Zone Files&lt;br /&gt;
// 1. Use rndc to stop BIND.&lt;br /&gt;
//      sudo rndc stop&lt;br /&gt;
// 2. Remove any .jnl files from the zone file directory.&lt;br /&gt;
//      sudo rm /etc/bind/*.jnl&lt;br /&gt;
// 3. Edit the zone files as necessary. Make sure to increment the serial &lt;br /&gt;
//    number of any file edited.  Note, format of serial number is:&lt;br /&gt;
//    YYYYMMDDNN where YYYY is year, MM is month, DD is day, NN is update&lt;br /&gt;
//    number for that day (i.e., 01, 02, 03,...)&lt;br /&gt;
// 4. Start BIND using its startup script. &lt;br /&gt;
//      sudo /etc/init.d/bind9 start&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
// secret must be the same as in /etc/bind/rndc.conf&lt;br /&gt;
include &amp;quot;/etc/bind/rndc.key&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
// access control list used to limit queries to local net&lt;br /&gt;
acl &amp;quot;internal-net&amp;quot; { 192.168.80/24; 127.0.0.1; };&lt;br /&gt;
&lt;br /&gt;
controls {&lt;br /&gt;
    inet 127.0.0.1 allow { any; } keys { &amp;quot;rndc-key&amp;quot;; };&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
include &amp;quot;/etc/bind/named.conf.options&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
// The single dot (.) is the root of all DNS namespace, so&lt;br /&gt;
// this zone tells named where to start looking for any&lt;br /&gt;
// name on the Internet&lt;br /&gt;
zone &amp;quot;.&amp;quot; IN {&lt;br /&gt;
	type hint;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.root&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
// local intranet zones and reverse zones&lt;br /&gt;
// intranet is wright.local and 192.168.80.0/24&lt;br /&gt;
// the DHCP servers is on linuxmce-dhcp&lt;br /&gt;
// an optional second nameserver would be on linuxmce-ns2&lt;br /&gt;
	&lt;br /&gt;
zone &amp;quot;wright.local&amp;quot; IN {&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.wright.local.zone&amp;quot;;&lt;br /&gt;
	// both allow-update and update-policy can enable DHCP updates,&lt;br /&gt;
	// but update-policy allows more control over what kinds of &lt;br /&gt;
	// updates DHCP can perform on a zone.&lt;br /&gt;
	// allow-update { none; };&lt;br /&gt;
	update-policy { grant linuxmce-dhcp subdomain wright.local. A TXT; };&lt;br /&gt;
	// allow-transfer { key &amp;quot;linuxmce-ns2&amp;quot;; };&lt;br /&gt;
	// notify on zone transfers&lt;br /&gt;
	notify yes;&lt;br /&gt;
};&lt;br /&gt;
	&lt;br /&gt;
zone &amp;quot;80.168.192.in-addr.arpa&amp;quot; IN {&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.wright.local.rev&amp;quot;;&lt;br /&gt;
	// allow-update { none; };&lt;br /&gt;
	update-policy { grant linuxmce-dhcp subdomain 80.168.192.in-addr.arpa. PTR TXT; };&lt;br /&gt;
	// allow-transfer { key &amp;quot;linuxmce-ns2&amp;quot;; };&lt;br /&gt;
	notify yes;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
// be authoritative for the localhost forward and reverse zones, and for&lt;br /&gt;
// broadcast zones as per RFC 1912 (http://www.ietf.org/rfc/rfc1912.txt)&lt;br /&gt;
&lt;br /&gt;
// Where the localhost hostname is defined&lt;br /&gt;
zone &amp;quot;localhost&amp;quot; IN {&lt;br /&gt;
	// a master type means that this server needn&#039;t look&lt;br /&gt;
	// anywhere else for information; the localhost buck&lt;br /&gt;
	// stops here.&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.local&amp;quot;;&lt;br /&gt;
	// don&#039;t allow dynamic DNS clients to update info&lt;br /&gt;
	// about the localhost zone&lt;br /&gt;
	allow-update { none; };&lt;br /&gt;
};&lt;br /&gt;
	&lt;br /&gt;
// Where the 127.0.0.0 network is defined&lt;br /&gt;
zone &amp;quot;127.in-addr.arpa&amp;quot; IN {&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.127&amp;quot;;&lt;br /&gt;
	allow-update { none; };&lt;br /&gt;
};&lt;br /&gt;
	&lt;br /&gt;
zone &amp;quot;0.in-addr.arpa&amp;quot; IN {&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.0&amp;quot;;&lt;br /&gt;
	allow-update { none; };&lt;br /&gt;
};&lt;br /&gt;
	&lt;br /&gt;
zone &amp;quot;255.in-addr.arpa&amp;quot; IN {&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.255&amp;quot;;&lt;br /&gt;
	allow-update { none; };&lt;br /&gt;
};&lt;br /&gt;
	&lt;br /&gt;
&lt;br /&gt;
// Include logging config file&lt;br /&gt;
include &amp;quot;/etc/bind/logging.conf&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
// zone &amp;quot;com&amp;quot; { type delegation-only; };&lt;br /&gt;
// zone &amp;quot;net&amp;quot; { type delegation-only; };&lt;br /&gt;
&lt;br /&gt;
// From the release notes:&lt;br /&gt;
//  Because many of our users are uncomfortable receiving undelegated answers&lt;br /&gt;
//  from root or top level domains, other than a few for whom that behaviour&lt;br /&gt;
//  has been trusted and expected for quite some length of time, we have now&lt;br /&gt;
//  introduced the &amp;quot;root-delegations-only&amp;quot; feature which applies delegation-only&lt;br /&gt;
//  logic to all top level domains, and to the root domain.  An exception list&lt;br /&gt;
//  should be specified, including &amp;quot;MUSEUM&amp;quot; and &amp;quot;DE&amp;quot;, and any other top level&lt;br /&gt;
//  domains from whom undelegated responses are expected and trusted.&lt;br /&gt;
// root-delegation-only exclude { &amp;quot;DE&amp;quot;; &amp;quot;MUSEUM&amp;quot;; };&lt;br /&gt;
&lt;br /&gt;
include &amp;quot;/etc/bind/named.conf.local&amp;quot;;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/named.conf.options===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
options {&lt;br /&gt;
	// tell named where to find files mentioned below&lt;br /&gt;
	directory &amp;quot;/var/cache/bind&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
	// file that contains the process id when bind is running&lt;br /&gt;
	pid-file &amp;quot;/var/run/bind/run/named.pid&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
	// enable statistics&lt;br /&gt;
	statistics-file &amp;quot;/var/named/named.stats&amp;quot;;&lt;br /&gt;
	zone-statistics yes;&lt;br /&gt;
&lt;br /&gt;
	dump-file &amp;quot;/var/named/named.dump&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
	// If there is a firewall between you and nameservers you want&lt;br /&gt;
	// to talk to, you might need to uncomment the query-source&lt;br /&gt;
	// directive below.  Previous versions of BIND always asked&lt;br /&gt;
	// questions using port 53, but BIND 8.1 and later use an unprivileged&lt;br /&gt;
	// port by default.&lt;br /&gt;
	// query-source address * port 53;&lt;br /&gt;
&lt;br /&gt;
	// If your ISP provided one or more IP addresses for stable &lt;br /&gt;
	// nameservers, you probably want to use them as forwarders.  &lt;br /&gt;
	// Uncomment the following block, and insert the addresses replacing &lt;br /&gt;
	// the all-0&#039;s placeholder.&lt;br /&gt;
&lt;br /&gt;
	// The forwarders option tells BIND to not use iterative queries itself &lt;br /&gt;
	// for information it doesn’t already know about but to forward a &lt;br /&gt;
	// recursive query to the name servers specified instead.&lt;br /&gt;
	include &amp;quot;/etc/bind/named.conf.forwarders&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
	// conform to RFC1035&lt;br /&gt;
	auth-nxdomain no;&lt;br /&gt;
&lt;br /&gt;
	// on a multi-homed host, you might want to tell named&lt;br /&gt;
	// to listen for queries only on certain interfaces&lt;br /&gt;
	listen-on-v6 { any; };&lt;br /&gt;
	listen-on { &amp;quot;internal-net&amp;quot;; };&lt;br /&gt;
&lt;br /&gt;
	// to allow only specific hosts to use the DNS server:&lt;br /&gt;
	allow-query { &amp;quot;internal-net&amp;quot;; };&lt;br /&gt;
&lt;br /&gt;
	// sets BIND’s default behaviour to refuse all zone transfers. &lt;br /&gt;
	// Without setting this option, anyone can transfer any zone.&lt;br /&gt;
	allow-transfer { none; };&lt;br /&gt;
&lt;br /&gt;
	// do not generate notify messages for all zones on a restart.&lt;br /&gt;
	// override for authorative zones&lt;br /&gt;
	notify no;&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/logging.conf===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
logging {&lt;br /&gt;
&lt;br /&gt;
	channel default_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/default.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel general_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/general.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel database_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/database.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel security_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/security.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel config_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/config.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel resolver_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/resolver.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel xfer-in_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/xfer-in.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel xfer-out_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/xfer-out.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel notify_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/notify.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel client_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/client.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel unmatched_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/unmatched.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel queries_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/queries.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel network_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/network.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel update_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/update.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel dispatch_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/dispatch.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel dnssec_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/dnssec.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel lame-servers_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/lame-servers.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
	category lame-servers {&lt;br /&gt;
		lame-servers_file;&lt;br /&gt;
		};&lt;br /&gt;
	category dnssec {&lt;br /&gt;
		dnssec_file;&lt;br /&gt;
		};&lt;br /&gt;
	category dispatch {&lt;br /&gt;
		dispatch_file;&lt;br /&gt;
		};&lt;br /&gt;
	category update {&lt;br /&gt;
		update_file;&lt;br /&gt;
		};&lt;br /&gt;
	category network {&lt;br /&gt;
		network_file;&lt;br /&gt;
		};&lt;br /&gt;
	category queries {&lt;br /&gt;
		queries_file;&lt;br /&gt;
		};&lt;br /&gt;
	category unmatched {&lt;br /&gt;
		unmatched_file;&lt;br /&gt;
		};&lt;br /&gt;
	category client {&lt;br /&gt;
		client_file;&lt;br /&gt;
		};&lt;br /&gt;
	category notify {&lt;br /&gt;
		notify_file;&lt;br /&gt;
		};&lt;br /&gt;
	category xfer-out {&lt;br /&gt;
		xfer-out_file;&lt;br /&gt;
		};&lt;br /&gt;
	category xfer-in {&lt;br /&gt;
		xfer-in_file;&lt;br /&gt;
		};&lt;br /&gt;
	category resolver {&lt;br /&gt;
		resolver_file;&lt;br /&gt;
		};&lt;br /&gt;
	category config {&lt;br /&gt;
		config_file;&lt;br /&gt;
		};&lt;br /&gt;
	category security {&lt;br /&gt;
		security_file;&lt;br /&gt;
		};&lt;br /&gt;
	category database {&lt;br /&gt;
		database_file;&lt;br /&gt;
		};&lt;br /&gt;
	category general {&lt;br /&gt;
		general_file;&lt;br /&gt;
		};&lt;br /&gt;
	category default {&lt;br /&gt;
		default_file;&lt;br /&gt;
		};&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/rndc.conf===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
options {&lt;br /&gt;
	default-server  localhost;&lt;br /&gt;
	default-key     &amp;quot;rndc-key&amp;quot;;&lt;br /&gt;
	default-port 953;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
server localhost {&lt;br /&gt;
	key     &amp;quot;rndc-key&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
key &amp;quot;rndc-key&amp;quot; {&lt;br /&gt;
	algorithm       hmac-md5;&lt;br /&gt;
	secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/rndc.key===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
key &amp;quot;rndc-key&amp;quot; {&lt;br /&gt;
        algorithm	hmac-md5;&lt;br /&gt;
        secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
key &amp;quot;linuxmce-dhcp&amp;quot; {&lt;br /&gt;
        algorithm	hmac-md5;&lt;br /&gt;
        secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
key &amp;quot;linuxmce-ns2&amp;quot; {&lt;br /&gt;
        algorithm	hmac-md5;&lt;br /&gt;
        secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/db.wright.local.zone===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
;&lt;br /&gt;
; BIND data file for wright.local&lt;br /&gt;
; ref. http://www.redhat.com/docs/manuals/linux/RHL-9-Manual/ref-guide/s1-bind-zone.html&lt;br /&gt;
;&lt;br /&gt;
$TTL 86400 ; time to live : 86400s = 1 day&lt;br /&gt;
; Start Of Authority record, proclaims important authoritative information &lt;br /&gt;
; about a namespace to the nameserver.&lt;br /&gt;
@               IN SOA  dcerouter.wright.local        roy@wright.org (&lt;br /&gt;
                2008013101      ;serial (YYYYMMDDNN where N = 01,02,03,...)&lt;br /&gt;
                10800           ;refresh (3 hours)&lt;br /&gt;
                7200            ;retry (2 hours)&lt;br /&gt;
                36000000        ;expire (10,000 hours = 416 2/3 days)&lt;br /&gt;
                86400)          ;default minimum ttl&lt;br /&gt;
;&lt;br /&gt;
; NameServer record, which announces the authoritative nameservers for a particular zone.&lt;br /&gt;
;&lt;br /&gt;
                IN NS   dcerouter.wright.local.&lt;br /&gt;
;&lt;br /&gt;
; Address records specify an IP address to assign to a name&lt;br /&gt;
;&lt;br /&gt;
dcerouter       IN A            192.168.80.1&lt;br /&gt;
thenameofamachine     IN A            192.168.80.21&lt;br /&gt;
thenameofanothermachine  IN A		192.168.80.20&lt;br /&gt;
;&lt;br /&gt;
; Canonical name records, maps one name to another. &lt;br /&gt;
;&lt;br /&gt;
linuxmce        IN CNAME        dcerouter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/db.wright.local.rev===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
;&lt;br /&gt;
; BIND reverse data file for wright.local&lt;br /&gt;
; ref. http://www.redhat.com/docs/manuals/linux/RHL-9-Manual/ref-guide/s1-bind-zone.html&lt;br /&gt;
;&lt;br /&gt;
$ORIGIN 80.168.192.in-addr.arpa.&lt;br /&gt;
$TTL 86400 ; time to live : 86400s = 1 day&lt;br /&gt;
; Start Of Authority record, proclaims important authoritative information &lt;br /&gt;
; about a namespace to the nameserver.&lt;br /&gt;
@               IN SOA  dcerouter.wright.local        roy@wright.org (&lt;br /&gt;
                2008013101      ;serial (YYYYMMDDNN where N = 01,02,03,...)&lt;br /&gt;
                10800           ;refresh (3 hours)&lt;br /&gt;
                7200            ;retry (2 hours)&lt;br /&gt;
                36000000        ;expire (10,000 hours = 416 2/3 days)&lt;br /&gt;
                86400)          ;default minimum ttl&lt;br /&gt;
;&lt;br /&gt;
; NameServer record, which announces the authoritative nameservers for a particular zone.&lt;br /&gt;
;&lt;br /&gt;
                IN NS   dcerouter.wright.local.&lt;br /&gt;
;&lt;br /&gt;
; PTR — PoinTeR record, designed to point to another part of the namespace.&lt;br /&gt;
;&lt;br /&gt;
1               IN PTR  dcerouter.wright.local.&lt;br /&gt;
21              IN PTR  dad-kubuntu.wright.local.&lt;br /&gt;
20		IN PTR	royw-gentoo.wright.local.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/dhcp3/dhcpd.conf===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
option domain-name-servers 192.168.80.1;&lt;br /&gt;
authoritative;&lt;br /&gt;
&lt;br /&gt;
option routers 192.168.80.1;&lt;br /&gt;
option subnet-mask 255.255.255.0;&lt;br /&gt;
&lt;br /&gt;
# lease IPs for 1 day, maximum 1 week&lt;br /&gt;
default-lease-time 86400;&lt;br /&gt;
max-lease-time 604800;&lt;br /&gt;
&lt;br /&gt;
# dynamic DNS updates&lt;br /&gt;
ddns-updates on;&lt;br /&gt;
ddns-update-style interim;&lt;br /&gt;
ddns-domainname &amp;quot;wright.local.&amp;quot;;&lt;br /&gt;
ddns-rev-domainname &amp;quot;in-addr.arpa.&amp;quot;;&lt;br /&gt;
ddns-ttl 14400;&lt;br /&gt;
&lt;br /&gt;
# don&#039;t let clients modify their own A records&lt;br /&gt;
ignore client-updates;&lt;br /&gt;
&lt;br /&gt;
key &amp;quot;linuxmce-dhcp&amp;quot; {&lt;br /&gt;
	algorithm       hmac-md5;&lt;br /&gt;
	secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
zone wright.local {&lt;br /&gt;
	primary 192.168.80.1;&lt;br /&gt;
	key &amp;quot;linuxmce-dhcp&amp;quot;;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
zone 80.168.192.in-addr.arpa {&lt;br /&gt;
	primary 192.168.80.1;&lt;br /&gt;
	key &amp;quot;linuxmce-dhcp&amp;quot;;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
option space pxelinux;&lt;br /&gt;
option pxelinux.magic code 208 = string;&lt;br /&gt;
option pxelinux.configfile code 209 = text;&lt;br /&gt;
option pxelinux.pathprefix code 210 = text;&lt;br /&gt;
option pxelinux.reboottime code 211 = unsigned integer 32;&lt;br /&gt;
&lt;br /&gt;
subnet 192.168.80.0 netmask 255.255.255.0 {&lt;br /&gt;
	next-server 192.168.80.1;&lt;br /&gt;
	filename &amp;quot;/tftpboot/pxelinux.0&amp;quot;;&lt;br /&gt;
	option pxelinux.reboottime = 30;&lt;br /&gt;
&lt;br /&gt;
	option domain-name &amp;quot;wright.local&amp;quot;;&lt;br /&gt;
	option domain-name-servers 192.168.80.1;&lt;br /&gt;
	option routers 192.168.80.1;&lt;br /&gt;
&lt;br /&gt;
	default-lease-time 86400;&lt;br /&gt;
	max-lease-time 604800;&lt;br /&gt;
	pool {&lt;br /&gt;
		 allow unknown-clients;&lt;br /&gt;
		 range 192.168.80.129 192.168.80.254; &lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
# PXE booting machines&lt;br /&gt;
group {&lt;br /&gt;
	next-server 192.168.80.1;&lt;br /&gt;
	filename &amp;quot;/tftpboot/pxelinux.0&amp;quot;;&lt;br /&gt;
	option pxelinux.reboottime = 30;&lt;br /&gt;
&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
# regular machines&lt;br /&gt;
group {&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
# CORE (1) has bad mac address: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/resolv.conf===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
domain wright.local&lt;br /&gt;
nameserver localhost&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Juanfe</name></author>
	</entry>
	<entry>
		<id>http://wiki.linuxmce.org/index.php?title=How_to_setup_Local_Authoritative_DNS&amp;diff=15514</id>
		<title>How to setup Local Authoritative DNS</title>
		<link rel="alternate" type="text/html" href="http://wiki.linuxmce.org/index.php?title=How_to_setup_Local_Authoritative_DNS&amp;diff=15514"/>
		<updated>2008-09-05T22:37:35Z</updated>

		<summary type="html">&lt;p&gt;Juanfe: /* /etc/bind/db.wright.local.zone */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[category: Tutorials]]&lt;br /&gt;
=How to setup Local Authoritative DNS=&lt;br /&gt;
&lt;br /&gt;
I was wanting an authoritative name server for my local intranet.  I also wanted any dynamic IP&#039;s to be visible to the name server.  The name server included with linuxmce is configured as a recursive name server.  Here&#039;s the changes I did to configure my core&#039;s name server to be authoritative and support dynamic IPs.  Note, the machines on my intranet are private, i.e., not known to the outside world.&lt;br /&gt;
&lt;br /&gt;
  3 Feb 2008 - Developed and tested on LinuxMCE 0710 Beta 3 amd64.&lt;br /&gt;
&lt;br /&gt;
I named my intranet &amp;quot;wright.local&amp;quot;.  Using a &amp;quot;local&amp;quot; top level domain (TLD) is recommended for private intranets.  Some may prefer to use &amp;quot;lan&amp;quot;.  You do not want to use any of the standard TLDs like &amp;quot;com&amp;quot;, &amp;quot;net&amp;quot;, &amp;quot;org&amp;quot;,...&lt;br /&gt;
&lt;br /&gt;
I used the core&#039;s default intranet addresses, 192.168.80.0/24 with the core at 192.168.80.1.&lt;br /&gt;
&lt;br /&gt;
I&#039;ve attempted to verbosely document each config file. :)&lt;br /&gt;
&lt;br /&gt;
The directions for adapting the config files are included in the named.conf file.&lt;br /&gt;
&lt;br /&gt;
==Installation==&lt;br /&gt;
&lt;br /&gt;
If you want to try this, I would suggest building the config in new directories then swapping with the originals when you are ready (I had a little mess when my core hung and I had to restart with only half the configs ready) :)&lt;br /&gt;
&lt;br /&gt;
So start with creating two directories:&lt;br /&gt;
&lt;br /&gt;
  sudo mkdir /etc/bind.new&lt;br /&gt;
  sudo mkdir /etc/dhcp3.new&lt;br /&gt;
&lt;br /&gt;
Now copy the contents of the original directories:&lt;br /&gt;
&lt;br /&gt;
  sudo cp -arp /etc/bind/* /etc/bind.new&lt;br /&gt;
  sudo cp -arp /etc/dhcp3/* /etc/dhcp3.new&lt;br /&gt;
&lt;br /&gt;
Also create a new resolve.conf file:&lt;br /&gt;
&lt;br /&gt;
  sudo touch /etc/resolv.conf.new&lt;br /&gt;
&lt;br /&gt;
You will be creating or editing the following config files in these new directories:&lt;br /&gt;
&lt;br /&gt;
  /etc/bind.new/named.conf&lt;br /&gt;
  /etc/bind.new/named.conf.options&lt;br /&gt;
  /etc/bind.new/logging.conf&lt;br /&gt;
  /etc/bind.new/rndc.conf&lt;br /&gt;
  /etc/bind.new/rndc.key&lt;br /&gt;
  /etc/bind.new/db.wright.local.zone&lt;br /&gt;
  /etc/bind.new/db.wright.local.rev&lt;br /&gt;
  /etc/dhcp3.new/dhcpd.conf&lt;br /&gt;
  /etc/resolv.conf&lt;br /&gt;
&lt;br /&gt;
The full text of the files you will be editing is at the foot of this page. The original author named his network &amp;quot;wright&amp;quot;; you should replace all instances of &amp;quot;wright&amp;quot; with the name of your network.&lt;br /&gt;
&lt;br /&gt;
==Notes on Editing Files==&lt;br /&gt;
&lt;br /&gt;
===rndc.key and dhcpd.conf key values=== &lt;br /&gt;
&lt;br /&gt;
To create a key for use in rndc.key and dhcpd.conf:&lt;br /&gt;
&lt;br /&gt;
  sudo dnssec-keygen -a HMAC-MD5 -b 256 -n user rndc&lt;br /&gt;
&lt;br /&gt;
Now get the key from the private file:&lt;br /&gt;
&lt;br /&gt;
  sudo cat Krndc.*.private&lt;br /&gt;
  Private-key-format: v1.2&lt;br /&gt;
  Algorithm: 157 (HMAC_MD5)&lt;br /&gt;
  Key: 3+GnSWV5FKxcUu57k7QFxbpvv/xr4fXj2wBVGtdGifI=&lt;br /&gt;
  Bits: AAA=&lt;br /&gt;
&lt;br /&gt;
Now cut the key which is to the right of &amp;quot;Key: &amp;quot; and paste where needed (replace &amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot; with the key in the config files).  So an example using the above key would look like:&lt;br /&gt;
&lt;br /&gt;
  key &amp;quot;linuxmce-dhcp&amp;quot; {&lt;br /&gt;
        algorithm	hmac-md5;&lt;br /&gt;
        secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
  };&lt;br /&gt;
&lt;br /&gt;
becomes:&lt;br /&gt;
&lt;br /&gt;
  key &amp;quot;linuxmce-dhcp&amp;quot; {&lt;br /&gt;
        algorithm	hmac-md5;&lt;br /&gt;
        secret		&amp;quot;3+GnSWV5FKxcUu57k7QFxbpvv/xr4fXj2wBVGtdGifI=&amp;quot;;&lt;br /&gt;
  };&lt;br /&gt;
&lt;br /&gt;
===Check directory ownership===&lt;br /&gt;
Make the logging directory:&lt;br /&gt;
&lt;br /&gt;
  sudo mkdir /var/log/named&lt;br /&gt;
  sudo chown bind:bind /var/log/named&lt;br /&gt;
  sudo chmod 755 /var/log/named&lt;br /&gt;
&lt;br /&gt;
===Setting default domain===&lt;br /&gt;
You probably ought to check and change the defaultdomain:&lt;br /&gt;
&lt;br /&gt;
  domainname&lt;br /&gt;
&lt;br /&gt;
will probably show&lt;br /&gt;
&lt;br /&gt;
  pluto&lt;br /&gt;
&lt;br /&gt;
if so, then set it by:&lt;br /&gt;
  sudo domainname yourdomain.local&lt;br /&gt;
&lt;br /&gt;
where &amp;quot;yourdomain.local&amp;quot; is your domain.  :-)&lt;br /&gt;
&lt;br /&gt;
===File Permissions===&lt;br /&gt;
Change all the file permissions per instructions in named.conf:&lt;br /&gt;
&lt;br /&gt;
   File permissions:&lt;br /&gt;
  //    /etc/bind/named.conf   root:root   644&lt;br /&gt;
  //    /etc/bind/rndc.key     root:bind   640&lt;br /&gt;
  //    /etc/bind/rndc.conf    root:root   600&lt;br /&gt;
  //    /etc/resolv.conf       root:root   644&lt;br /&gt;
  //    /etc/bind              root:bind   775, chmod g+s =&amp;gt; drwxrwsr-x&lt;br /&gt;
  //    /etc/dhcp3             root:root   755&lt;br /&gt;
  //    /etc/dhcp3/dhcpd.conf  root:root   644&lt;br /&gt;
  //&lt;br /&gt;
&lt;br /&gt;
===Double check. Everything===&lt;br /&gt;
Double check everything.   Roll Eyes&lt;br /&gt;
&lt;br /&gt;
==Wrapping up==&lt;br /&gt;
When and if you are feeling lucky, rename the original directories and then rename the new directories to take their place:&lt;br /&gt;
&lt;br /&gt;
  sudo mv /etc/bind /etc/bind.original&lt;br /&gt;
  sudo mv /etc/bind.new /etc/bind&lt;br /&gt;
  sudo mv /etc/dhcp3 /etc/dhcp3.original&lt;br /&gt;
  sudo mv /etc/dhcp3.new /etc/dhcp3&lt;br /&gt;
  sudo mv /etc/resolve.conf /etc/resolve.conf.original&lt;br /&gt;
  sudo mv /etc/resolve.conf.new /etc/resolve.conf&lt;br /&gt;
&lt;br /&gt;
Finally restart the bind and dhcpd services:&lt;br /&gt;
&lt;br /&gt;
  sudo rndc reload&lt;br /&gt;
  sudo /etc/init.d/dhcp3-server restart&lt;br /&gt;
&lt;br /&gt;
Check the syslog for any errors:&lt;br /&gt;
&lt;br /&gt;
  grep named /var/log/syslog&lt;br /&gt;
  grep dhcpd /var/log/syslog&lt;br /&gt;
&lt;br /&gt;
==Config Files==&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/named.conf===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
// This is the primary configuration file for the BIND DNS server named.&lt;br /&gt;
//&lt;br /&gt;
// This configuration supports an authoritative local zone (wright.local on&lt;br /&gt;
// 192.168.80.0/24) and allows DHCP to update the local zone.  &lt;br /&gt;
// To customize to your setup:&lt;br /&gt;
// 1) replace &amp;quot;wright.local&amp;quot; with your internal domain name.&lt;br /&gt;
// 2) edit db.wright.local.zone and db.wright.local.rev and replace&lt;br /&gt;
//    my static names/addresses with your network&#039;s static names/addresses.&lt;br /&gt;
//    Make sure to increment the serial number of any file edited.  &lt;br /&gt;
//    Note, format of serial number is:  YYYYMMDDNN where YYYY is year, &lt;br /&gt;
//    MM is month, DD is day, NN is update number for that day (i.e., 01, &lt;br /&gt;
//    02, 03,...)&lt;br /&gt;
// 3) rename db.wright.local.zone to match your domain name.&lt;br /&gt;
// 4) rename db.wright.local.rev to match your domain name.&lt;br /&gt;
// 5) If you changed the internal network IP from the LinuxMCE default of&lt;br /&gt;
//    192.168.80.0/24, then replace &amp;quot;192.168.80&amp;quot; with your network&lt;br /&gt;
//    ip and replace it&#039;s reverse &amp;quot;80.168.192&amp;quot; wity your network ip&#039;s&lt;br /&gt;
//    reverse.&lt;br /&gt;
//&lt;br /&gt;
// Please read /usr/share/doc/bind9/README.Debian.gz for information on the &lt;br /&gt;
// structure of BIND configuration files in Debian, *BEFORE* you customize &lt;br /&gt;
// this configuration file.&lt;br /&gt;
//&lt;br /&gt;
// If you are just adding zones, please do that in /etc/bind/named.conf.local&lt;br /&gt;
//&lt;br /&gt;
// references:&lt;br /&gt;
// http://www.arda.homeunix.net/dnssetup.html&lt;br /&gt;
// http://www.madboa.com/geek/soho-bind/&lt;br /&gt;
//&lt;br /&gt;
// notes:&lt;br /&gt;
// 1) The following command should be ran about twice a year to keep&lt;br /&gt;
//    the root servers current:&lt;br /&gt;
//      dig @a.root-servers.net . ns &amp;gt; /etc/bin/db.root&lt;br /&gt;
//    Root name servers don’t change very often so updating this file more &lt;br /&gt;
//    than twice a year is probably overkill. Frequent updates also put undo &lt;br /&gt;
//    load on the root name servers; they have enough to do as it is.&lt;br /&gt;
//&lt;br /&gt;
// 2) File permissions:&lt;br /&gt;
//    /etc/bind/named.conf   root:root   644&lt;br /&gt;
//    /etc/bind/rndc.key     root:bind   640&lt;br /&gt;
//    /etc/bind/rndc.conf    root:root   600&lt;br /&gt;
//    /etc/resolv.conf       root:root   644&lt;br /&gt;
//    /etc/bind              root:bind   775, chmod g+s =&amp;gt; drwxrwsr-x&lt;br /&gt;
//    /etc/dhcp3             root:root   755&lt;br /&gt;
//    /etc/dhcp3/dhcpd.conf  root:root   644&lt;br /&gt;
//&lt;br /&gt;
// Manually Updating Zone Files&lt;br /&gt;
// 1. Use rndc to stop BIND.&lt;br /&gt;
//      sudo rndc stop&lt;br /&gt;
// 2. Remove any .jnl files from the zone file directory.&lt;br /&gt;
//      sudo rm /etc/bind/*.jnl&lt;br /&gt;
// 3. Edit the zone files as necessary. Make sure to increment the serial &lt;br /&gt;
//    number of any file edited.  Note, format of serial number is:&lt;br /&gt;
//    YYYYMMDDNN where YYYY is year, MM is month, DD is day, NN is update&lt;br /&gt;
//    number for that day (i.e., 01, 02, 03,...)&lt;br /&gt;
// 4. Start BIND using its startup script. &lt;br /&gt;
//      sudo /etc/init.d/bind9 start&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
// secret must be the same as in /etc/bind/rndc.conf&lt;br /&gt;
include &amp;quot;/etc/bind/rndc.key&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
// access control list used to limit queries to local net&lt;br /&gt;
acl &amp;quot;internal-net&amp;quot; { 192.168.80/24; 127.0.0.1; };&lt;br /&gt;
&lt;br /&gt;
controls {&lt;br /&gt;
    inet 127.0.0.1 allow { any; } keys { &amp;quot;rndc-key&amp;quot;; };&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
include &amp;quot;/etc/bind/named.conf.options&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
// The single dot (.) is the root of all DNS namespace, so&lt;br /&gt;
// this zone tells named where to start looking for any&lt;br /&gt;
// name on the Internet&lt;br /&gt;
zone &amp;quot;.&amp;quot; IN {&lt;br /&gt;
	type hint;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.root&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
// local intranet zones and reverse zones&lt;br /&gt;
// intranet is wright.local and 192.168.80.0/24&lt;br /&gt;
// the DHCP servers is on linuxmce-dhcp&lt;br /&gt;
// an optional second nameserver would be on linuxmce-ns2&lt;br /&gt;
	&lt;br /&gt;
zone &amp;quot;wright.local&amp;quot; IN {&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.wright.local.zone&amp;quot;;&lt;br /&gt;
	// both allow-update and update-policy can enable DHCP updates,&lt;br /&gt;
	// but update-policy allows more control over what kinds of &lt;br /&gt;
	// updates DHCP can perform on a zone.&lt;br /&gt;
	// allow-update { none; };&lt;br /&gt;
	update-policy { grant linuxmce-dhcp subdomain wright.local. A TXT; };&lt;br /&gt;
	// allow-transfer { key &amp;quot;linuxmce-ns2&amp;quot;; };&lt;br /&gt;
	// notify on zone transfers&lt;br /&gt;
	notify yes;&lt;br /&gt;
};&lt;br /&gt;
	&lt;br /&gt;
zone &amp;quot;80.168.192.in-addr.arpa&amp;quot; IN {&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.wright.local.rev&amp;quot;;&lt;br /&gt;
	// allow-update { none; };&lt;br /&gt;
	update-policy { grant linuxmce-dhcp subdomain 80.168.192.in-addr.arpa. PTR TXT; };&lt;br /&gt;
	// allow-transfer { key &amp;quot;linuxmce-ns2&amp;quot;; };&lt;br /&gt;
	notify yes;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
// be authoritative for the localhost forward and reverse zones, and for&lt;br /&gt;
// broadcast zones as per RFC 1912 (http://www.ietf.org/rfc/rfc1912.txt)&lt;br /&gt;
&lt;br /&gt;
// Where the localhost hostname is defined&lt;br /&gt;
zone &amp;quot;localhost&amp;quot; IN {&lt;br /&gt;
	// a master type means that this server needn&#039;t look&lt;br /&gt;
	// anywhere else for information; the localhost buck&lt;br /&gt;
	// stops here.&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.local&amp;quot;;&lt;br /&gt;
	// don&#039;t allow dynamic DNS clients to update info&lt;br /&gt;
	// about the localhost zone&lt;br /&gt;
	allow-update { none; };&lt;br /&gt;
};&lt;br /&gt;
	&lt;br /&gt;
// Where the 127.0.0.0 network is defined&lt;br /&gt;
zone &amp;quot;127.in-addr.arpa&amp;quot; IN {&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.127&amp;quot;;&lt;br /&gt;
	allow-update { none; };&lt;br /&gt;
};&lt;br /&gt;
	&lt;br /&gt;
zone &amp;quot;0.in-addr.arpa&amp;quot; IN {&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.0&amp;quot;;&lt;br /&gt;
	allow-update { none; };&lt;br /&gt;
};&lt;br /&gt;
	&lt;br /&gt;
zone &amp;quot;255.in-addr.arpa&amp;quot; IN {&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.255&amp;quot;;&lt;br /&gt;
	allow-update { none; };&lt;br /&gt;
};&lt;br /&gt;
	&lt;br /&gt;
&lt;br /&gt;
// Include logging config file&lt;br /&gt;
include &amp;quot;/etc/bind/logging.conf&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
// zone &amp;quot;com&amp;quot; { type delegation-only; };&lt;br /&gt;
// zone &amp;quot;net&amp;quot; { type delegation-only; };&lt;br /&gt;
&lt;br /&gt;
// From the release notes:&lt;br /&gt;
//  Because many of our users are uncomfortable receiving undelegated answers&lt;br /&gt;
//  from root or top level domains, other than a few for whom that behaviour&lt;br /&gt;
//  has been trusted and expected for quite some length of time, we have now&lt;br /&gt;
//  introduced the &amp;quot;root-delegations-only&amp;quot; feature which applies delegation-only&lt;br /&gt;
//  logic to all top level domains, and to the root domain.  An exception list&lt;br /&gt;
//  should be specified, including &amp;quot;MUSEUM&amp;quot; and &amp;quot;DE&amp;quot;, and any other top level&lt;br /&gt;
//  domains from whom undelegated responses are expected and trusted.&lt;br /&gt;
// root-delegation-only exclude { &amp;quot;DE&amp;quot;; &amp;quot;MUSEUM&amp;quot;; };&lt;br /&gt;
&lt;br /&gt;
include &amp;quot;/etc/bind/named.conf.local&amp;quot;;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/named.conf.options===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
options {&lt;br /&gt;
	// tell named where to find files mentioned below&lt;br /&gt;
	directory &amp;quot;/var/cache/bind&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
	// file that contains the process id when bind is running&lt;br /&gt;
	pid-file &amp;quot;/var/run/bind/run/named.pid&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
	// enable statistics&lt;br /&gt;
	statistics-file &amp;quot;/var/named/named.stats&amp;quot;;&lt;br /&gt;
	zone-statistics yes;&lt;br /&gt;
&lt;br /&gt;
	dump-file &amp;quot;/var/named/named.dump&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
	// If there is a firewall between you and nameservers you want&lt;br /&gt;
	// to talk to, you might need to uncomment the query-source&lt;br /&gt;
	// directive below.  Previous versions of BIND always asked&lt;br /&gt;
	// questions using port 53, but BIND 8.1 and later use an unprivileged&lt;br /&gt;
	// port by default.&lt;br /&gt;
	// query-source address * port 53;&lt;br /&gt;
&lt;br /&gt;
	// If your ISP provided one or more IP addresses for stable &lt;br /&gt;
	// nameservers, you probably want to use them as forwarders.  &lt;br /&gt;
	// Uncomment the following block, and insert the addresses replacing &lt;br /&gt;
	// the all-0&#039;s placeholder.&lt;br /&gt;
&lt;br /&gt;
	// The forwarders option tells BIND to not use iterative queries itself &lt;br /&gt;
	// for information it doesn’t already know about but to forward a &lt;br /&gt;
	// recursive query to the name servers specified instead.&lt;br /&gt;
	include &amp;quot;/etc/bind/named.conf.forwarders&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
	// conform to RFC1035&lt;br /&gt;
	auth-nxdomain no;&lt;br /&gt;
&lt;br /&gt;
	// on a multi-homed host, you might want to tell named&lt;br /&gt;
	// to listen for queries only on certain interfaces&lt;br /&gt;
	listen-on-v6 { any; };&lt;br /&gt;
	listen-on { &amp;quot;internal-net&amp;quot;; };&lt;br /&gt;
&lt;br /&gt;
	// to allow only specific hosts to use the DNS server:&lt;br /&gt;
	allow-query { &amp;quot;internal-net&amp;quot;; };&lt;br /&gt;
&lt;br /&gt;
	// sets BIND’s default behaviour to refuse all zone transfers. &lt;br /&gt;
	// Without setting this option, anyone can transfer any zone.&lt;br /&gt;
	allow-transfer { none; };&lt;br /&gt;
&lt;br /&gt;
	// do not generate notify messages for all zones on a restart.&lt;br /&gt;
	// override for authorative zones&lt;br /&gt;
	notify no;&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/logging.conf===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
logging {&lt;br /&gt;
&lt;br /&gt;
	channel default_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/default.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel general_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/general.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel database_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/database.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel security_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/security.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel config_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/config.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel resolver_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/resolver.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel xfer-in_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/xfer-in.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel xfer-out_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/xfer-out.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel notify_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/notify.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel client_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/client.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel unmatched_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/unmatched.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel queries_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/queries.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel network_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/network.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel update_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/update.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel dispatch_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/dispatch.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel dnssec_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/dnssec.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel lame-servers_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/lame-servers.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
	category lame-servers {&lt;br /&gt;
		lame-servers_file;&lt;br /&gt;
		};&lt;br /&gt;
	category dnssec {&lt;br /&gt;
		dnssec_file;&lt;br /&gt;
		};&lt;br /&gt;
	category dispatch {&lt;br /&gt;
		dispatch_file;&lt;br /&gt;
		};&lt;br /&gt;
	category update {&lt;br /&gt;
		update_file;&lt;br /&gt;
		};&lt;br /&gt;
	category network {&lt;br /&gt;
		network_file;&lt;br /&gt;
		};&lt;br /&gt;
	category queries {&lt;br /&gt;
		queries_file;&lt;br /&gt;
		};&lt;br /&gt;
	category unmatched {&lt;br /&gt;
		unmatched_file;&lt;br /&gt;
		};&lt;br /&gt;
	category client {&lt;br /&gt;
		client_file;&lt;br /&gt;
		};&lt;br /&gt;
	category notify {&lt;br /&gt;
		notify_file;&lt;br /&gt;
		};&lt;br /&gt;
	category xfer-out {&lt;br /&gt;
		xfer-out_file;&lt;br /&gt;
		};&lt;br /&gt;
	category xfer-in {&lt;br /&gt;
		xfer-in_file;&lt;br /&gt;
		};&lt;br /&gt;
	category resolver {&lt;br /&gt;
		resolver_file;&lt;br /&gt;
		};&lt;br /&gt;
	category config {&lt;br /&gt;
		config_file;&lt;br /&gt;
		};&lt;br /&gt;
	category security {&lt;br /&gt;
		security_file;&lt;br /&gt;
		};&lt;br /&gt;
	category database {&lt;br /&gt;
		database_file;&lt;br /&gt;
		};&lt;br /&gt;
	category general {&lt;br /&gt;
		general_file;&lt;br /&gt;
		};&lt;br /&gt;
	category default {&lt;br /&gt;
		default_file;&lt;br /&gt;
		};&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/rndc.conf===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
options {&lt;br /&gt;
	default-server  localhost;&lt;br /&gt;
	default-key     &amp;quot;rndc-key&amp;quot;;&lt;br /&gt;
	default-port 953;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
server localhost {&lt;br /&gt;
	key     &amp;quot;rndc-key&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
key &amp;quot;rndc-key&amp;quot; {&lt;br /&gt;
	algorithm       hmac-md5;&lt;br /&gt;
	secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/rndc.key===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
key &amp;quot;rndc-key&amp;quot; {&lt;br /&gt;
        algorithm	hmac-md5;&lt;br /&gt;
        secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
key &amp;quot;linuxmce-dhcp&amp;quot; {&lt;br /&gt;
        algorithm	hmac-md5;&lt;br /&gt;
        secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
key &amp;quot;linuxmce-ns2&amp;quot; {&lt;br /&gt;
        algorithm	hmac-md5;&lt;br /&gt;
        secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/db.wright.local.zone===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
;&lt;br /&gt;
; BIND data file for wright.local&lt;br /&gt;
; ref. http://www.redhat.com/docs/manuals/linux/RHL-9-Manual/ref-guide/s1-bind-zone.html&lt;br /&gt;
;&lt;br /&gt;
$TTL 86400 ; time to live : 86400s = 1 day&lt;br /&gt;
; Start Of Authority record, proclaims important authoritative information &lt;br /&gt;
; about a namespace to the nameserver.&lt;br /&gt;
@               IN SOA  dcerouter.wright.local        roy@wright.org (&lt;br /&gt;
                2008013101      ;serial (YYYYMMDDNN where N = 01,02,03,...)&lt;br /&gt;
                10800           ;refresh (3 hours)&lt;br /&gt;
                7200            ;retry (2 hours)&lt;br /&gt;
                36000000        ;expire (10,000 hours = 416 2/3 days)&lt;br /&gt;
                86400)          ;default minimum ttl&lt;br /&gt;
;&lt;br /&gt;
; NameServer record, which announces the authoritative nameservers for a particular zone.&lt;br /&gt;
;&lt;br /&gt;
                IN NS   dcerouter.wright.local.&lt;br /&gt;
;&lt;br /&gt;
; Address records specify an IP address to assign to a name&lt;br /&gt;
;&lt;br /&gt;
dcerouter       IN A            192.168.80.1&lt;br /&gt;
thenameofamachine     IN A            192.168.80.21&lt;br /&gt;
thenameofanothermachine  IN A		192.168.80.20&lt;br /&gt;
;&lt;br /&gt;
; Canonical name records, maps one name to another. &lt;br /&gt;
;&lt;br /&gt;
linuxmce        IN CNAME        dcerouter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/db.wright.local.rev===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
;&lt;br /&gt;
; BIND reverse data file for wright.local&lt;br /&gt;
; ref. http://www.redhat.com/docs/manuals/linux/RHL-9-Manual/ref-guide/s1-bind-zone.html&lt;br /&gt;
;&lt;br /&gt;
$ORIGIN 80.168.192.in-addr.arpa.&lt;br /&gt;
$TTL 86400 ; time to live : 86400s = 1 day&lt;br /&gt;
; Start Of Authority record, proclaims important authoritative information &lt;br /&gt;
; about a namespace to the nameserver.&lt;br /&gt;
@               IN SOA  dcerouter.wright.local        roy@wright.org (&lt;br /&gt;
                2008013101      ;serial (YYYYMMDDNN where N = 01,02,03,...)&lt;br /&gt;
                10800           ;refresh (3 hours)&lt;br /&gt;
                7200            ;retry (2 hours)&lt;br /&gt;
                36000000        ;expire (10,000 hours = 416 2/3 days)&lt;br /&gt;
                86400)          ;default minimum ttl&lt;br /&gt;
;&lt;br /&gt;
; NameServer record, which announces the authoritative nameservers for a particular zone.&lt;br /&gt;
;&lt;br /&gt;
                IN NS   dcerouter.wright.local.&lt;br /&gt;
;&lt;br /&gt;
; PTR — PoinTeR record, designed to point to another part of the namespace.&lt;br /&gt;
;&lt;br /&gt;
1               IN PTR  dcerouter.wright.local.&lt;br /&gt;
21              IN PTR  dad-kubuntu.wright.local.&lt;br /&gt;
20		IN PTR	royw-gentoo.wright.local.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/dhcp3/dhcpd.conf===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
option domain-name-servers 192.168.80.1;&lt;br /&gt;
authoritative;&lt;br /&gt;
&lt;br /&gt;
option routers 192.168.80.1;&lt;br /&gt;
option subnet-mask 255.255.255.0;&lt;br /&gt;
&lt;br /&gt;
# lease IPs for 1 day, maximum 1 week&lt;br /&gt;
default-lease-time 86400;&lt;br /&gt;
max-lease-time 604800;&lt;br /&gt;
&lt;br /&gt;
# dynamic DNS updates&lt;br /&gt;
ddns-updates on;&lt;br /&gt;
ddns-update-style interim;&lt;br /&gt;
ddns-domainname &amp;quot;wright.local.&amp;quot;;&lt;br /&gt;
ddns-rev-domainname &amp;quot;in-addr.arpa.&amp;quot;;&lt;br /&gt;
ddns-ttl 14400;&lt;br /&gt;
&lt;br /&gt;
# don&#039;t let clients modify their own A records&lt;br /&gt;
ignore client-updates;&lt;br /&gt;
&lt;br /&gt;
key &amp;quot;linuxmce-dhcp&amp;quot; {&lt;br /&gt;
	algorithm       hmac-md5;&lt;br /&gt;
	secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
zone wright.local {&lt;br /&gt;
	primary 192.168.80.1;&lt;br /&gt;
	key &amp;quot;linuxmce-dhcp&amp;quot;;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
zone 80.168.192.in-addr.arpa {&lt;br /&gt;
	primary 192.168.80.1;&lt;br /&gt;
	key &amp;quot;linuxmce-dhcp&amp;quot;;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
option space pxelinux;&lt;br /&gt;
option pxelinux.magic code 208 = string;&lt;br /&gt;
option pxelinux.configfile code 209 = text;&lt;br /&gt;
option pxelinux.pathprefix code 210 = text;&lt;br /&gt;
option pxelinux.reboottime code 211 = unsigned integer 32;&lt;br /&gt;
&lt;br /&gt;
subnet 192.168.80.0 netmask 255.255.255.0 {&lt;br /&gt;
	next-server 192.168.80.1;&lt;br /&gt;
	filename &amp;quot;/tftpboot/pxelinux.0&amp;quot;;&lt;br /&gt;
	option pxelinux.reboottime = 30;&lt;br /&gt;
&lt;br /&gt;
	option domain-name &amp;quot;wright.local&amp;quot;;&lt;br /&gt;
	option domain-name-servers 192.168.80.1;&lt;br /&gt;
	option routers 192.168.80.1;&lt;br /&gt;
&lt;br /&gt;
	default-lease-time 86400;&lt;br /&gt;
	max-lease-time 604800;&lt;br /&gt;
	pool {&lt;br /&gt;
		 allow unknown-clients;&lt;br /&gt;
		 range 192.168.80.129 192.168.80.254; &lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
# PXE booting machines&lt;br /&gt;
group {&lt;br /&gt;
	next-server 192.168.80.1;&lt;br /&gt;
	filename &amp;quot;/tftpboot/pxelinux.0&amp;quot;;&lt;br /&gt;
	option pxelinux.reboottime = 30;&lt;br /&gt;
&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
# regular machines&lt;br /&gt;
group {&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
# CORE (1) has bad mac address: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/resolv.conf===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
domain wright.local&lt;br /&gt;
nameserver localhost&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Juanfe</name></author>
	</entry>
	<entry>
		<id>http://wiki.linuxmce.org/index.php?title=How_to_setup_Local_Authoritative_DNS&amp;diff=15513</id>
		<title>How to setup Local Authoritative DNS</title>
		<link rel="alternate" type="text/html" href="http://wiki.linuxmce.org/index.php?title=How_to_setup_Local_Authoritative_DNS&amp;diff=15513"/>
		<updated>2008-09-05T22:30:51Z</updated>

		<summary type="html">&lt;p&gt;Juanfe: /* Check directory ownership */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[category: Tutorials]]&lt;br /&gt;
=How to setup Local Authoritative DNS=&lt;br /&gt;
&lt;br /&gt;
I was wanting an authoritative name server for my local intranet.  I also wanted any dynamic IP&#039;s to be visible to the name server.  The name server included with linuxmce is configured as a recursive name server.  Here&#039;s the changes I did to configure my core&#039;s name server to be authoritative and support dynamic IPs.  Note, the machines on my intranet are private, i.e., not known to the outside world.&lt;br /&gt;
&lt;br /&gt;
  3 Feb 2008 - Developed and tested on LinuxMCE 0710 Beta 3 amd64.&lt;br /&gt;
&lt;br /&gt;
I named my intranet &amp;quot;wright.local&amp;quot;.  Using a &amp;quot;local&amp;quot; top level domain (TLD) is recommended for private intranets.  Some may prefer to use &amp;quot;lan&amp;quot;.  You do not want to use any of the standard TLDs like &amp;quot;com&amp;quot;, &amp;quot;net&amp;quot;, &amp;quot;org&amp;quot;,...&lt;br /&gt;
&lt;br /&gt;
I used the core&#039;s default intranet addresses, 192.168.80.0/24 with the core at 192.168.80.1.&lt;br /&gt;
&lt;br /&gt;
I&#039;ve attempted to verbosely document each config file. :)&lt;br /&gt;
&lt;br /&gt;
The directions for adapting the config files are included in the named.conf file.&lt;br /&gt;
&lt;br /&gt;
==Installation==&lt;br /&gt;
&lt;br /&gt;
If you want to try this, I would suggest building the config in new directories then swapping with the originals when you are ready (I had a little mess when my core hung and I had to restart with only half the configs ready) :)&lt;br /&gt;
&lt;br /&gt;
So start with creating two directories:&lt;br /&gt;
&lt;br /&gt;
  sudo mkdir /etc/bind.new&lt;br /&gt;
  sudo mkdir /etc/dhcp3.new&lt;br /&gt;
&lt;br /&gt;
Now copy the contents of the original directories:&lt;br /&gt;
&lt;br /&gt;
  sudo cp -arp /etc/bind/* /etc/bind.new&lt;br /&gt;
  sudo cp -arp /etc/dhcp3/* /etc/dhcp3.new&lt;br /&gt;
&lt;br /&gt;
Also create a new resolve.conf file:&lt;br /&gt;
&lt;br /&gt;
  sudo touch /etc/resolv.conf.new&lt;br /&gt;
&lt;br /&gt;
You will be creating or editing the following config files in these new directories:&lt;br /&gt;
&lt;br /&gt;
  /etc/bind.new/named.conf&lt;br /&gt;
  /etc/bind.new/named.conf.options&lt;br /&gt;
  /etc/bind.new/logging.conf&lt;br /&gt;
  /etc/bind.new/rndc.conf&lt;br /&gt;
  /etc/bind.new/rndc.key&lt;br /&gt;
  /etc/bind.new/db.wright.local.zone&lt;br /&gt;
  /etc/bind.new/db.wright.local.rev&lt;br /&gt;
  /etc/dhcp3.new/dhcpd.conf&lt;br /&gt;
  /etc/resolv.conf&lt;br /&gt;
&lt;br /&gt;
The full text of the files you will be editing is at the foot of this page. The original author named his network &amp;quot;wright&amp;quot;; you should replace all instances of &amp;quot;wright&amp;quot; with the name of your network.&lt;br /&gt;
&lt;br /&gt;
==Notes on Editing Files==&lt;br /&gt;
&lt;br /&gt;
===rndc.key and dhcpd.conf key values=== &lt;br /&gt;
&lt;br /&gt;
To create a key for use in rndc.key and dhcpd.conf:&lt;br /&gt;
&lt;br /&gt;
  sudo dnssec-keygen -a HMAC-MD5 -b 256 -n user rndc&lt;br /&gt;
&lt;br /&gt;
Now get the key from the private file:&lt;br /&gt;
&lt;br /&gt;
  sudo cat Krndc.*.private&lt;br /&gt;
  Private-key-format: v1.2&lt;br /&gt;
  Algorithm: 157 (HMAC_MD5)&lt;br /&gt;
  Key: 3+GnSWV5FKxcUu57k7QFxbpvv/xr4fXj2wBVGtdGifI=&lt;br /&gt;
  Bits: AAA=&lt;br /&gt;
&lt;br /&gt;
Now cut the key which is to the right of &amp;quot;Key: &amp;quot; and paste where needed (replace &amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot; with the key in the config files).  So an example using the above key would look like:&lt;br /&gt;
&lt;br /&gt;
  key &amp;quot;linuxmce-dhcp&amp;quot; {&lt;br /&gt;
        algorithm	hmac-md5;&lt;br /&gt;
        secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
  };&lt;br /&gt;
&lt;br /&gt;
becomes:&lt;br /&gt;
&lt;br /&gt;
  key &amp;quot;linuxmce-dhcp&amp;quot; {&lt;br /&gt;
        algorithm	hmac-md5;&lt;br /&gt;
        secret		&amp;quot;3+GnSWV5FKxcUu57k7QFxbpvv/xr4fXj2wBVGtdGifI=&amp;quot;;&lt;br /&gt;
  };&lt;br /&gt;
&lt;br /&gt;
===Check directory ownership===&lt;br /&gt;
Make the logging directory:&lt;br /&gt;
&lt;br /&gt;
  sudo mkdir /var/log/named&lt;br /&gt;
  sudo chown bind:bind /var/log/named&lt;br /&gt;
  sudo chmod 755 /var/log/named&lt;br /&gt;
&lt;br /&gt;
===Setting default domain===&lt;br /&gt;
You probably ought to check and change the defaultdomain:&lt;br /&gt;
&lt;br /&gt;
  domainname&lt;br /&gt;
&lt;br /&gt;
will probably show&lt;br /&gt;
&lt;br /&gt;
  pluto&lt;br /&gt;
&lt;br /&gt;
if so, then set it by:&lt;br /&gt;
  sudo domainname yourdomain.local&lt;br /&gt;
&lt;br /&gt;
where &amp;quot;yourdomain.local&amp;quot; is your domain.  :-)&lt;br /&gt;
&lt;br /&gt;
===File Permissions===&lt;br /&gt;
Change all the file permissions per instructions in named.conf:&lt;br /&gt;
&lt;br /&gt;
   File permissions:&lt;br /&gt;
  //    /etc/bind/named.conf   root:root   644&lt;br /&gt;
  //    /etc/bind/rndc.key     root:bind   640&lt;br /&gt;
  //    /etc/bind/rndc.conf    root:root   600&lt;br /&gt;
  //    /etc/resolv.conf       root:root   644&lt;br /&gt;
  //    /etc/bind              root:bind   775, chmod g+s =&amp;gt; drwxrwsr-x&lt;br /&gt;
  //    /etc/dhcp3             root:root   755&lt;br /&gt;
  //    /etc/dhcp3/dhcpd.conf  root:root   644&lt;br /&gt;
  //&lt;br /&gt;
&lt;br /&gt;
===Double check. Everything===&lt;br /&gt;
Double check everything.   Roll Eyes&lt;br /&gt;
&lt;br /&gt;
==Wrapping up==&lt;br /&gt;
When and if you are feeling lucky, rename the original directories and then rename the new directories to take their place:&lt;br /&gt;
&lt;br /&gt;
  sudo mv /etc/bind /etc/bind.original&lt;br /&gt;
  sudo mv /etc/bind.new /etc/bind&lt;br /&gt;
  sudo mv /etc/dhcp3 /etc/dhcp3.original&lt;br /&gt;
  sudo mv /etc/dhcp3.new /etc/dhcp3&lt;br /&gt;
  sudo mv /etc/resolve.conf /etc/resolve.conf.original&lt;br /&gt;
  sudo mv /etc/resolve.conf.new /etc/resolve.conf&lt;br /&gt;
&lt;br /&gt;
Finally restart the bind and dhcpd services:&lt;br /&gt;
&lt;br /&gt;
  sudo rndc reload&lt;br /&gt;
  sudo /etc/init.d/dhcp3-server restart&lt;br /&gt;
&lt;br /&gt;
Check the syslog for any errors:&lt;br /&gt;
&lt;br /&gt;
  grep named /var/log/syslog&lt;br /&gt;
  grep dhcpd /var/log/syslog&lt;br /&gt;
&lt;br /&gt;
==Config Files==&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/named.conf===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
// This is the primary configuration file for the BIND DNS server named.&lt;br /&gt;
//&lt;br /&gt;
// This configuration supports an authoritative local zone (wright.local on&lt;br /&gt;
// 192.168.80.0/24) and allows DHCP to update the local zone.  &lt;br /&gt;
// To customize to your setup:&lt;br /&gt;
// 1) replace &amp;quot;wright.local&amp;quot; with your internal domain name.&lt;br /&gt;
// 2) edit db.wright.local.zone and db.wright.local.rev and replace&lt;br /&gt;
//    my static names/addresses with your network&#039;s static names/addresses.&lt;br /&gt;
//    Make sure to increment the serial number of any file edited.  &lt;br /&gt;
//    Note, format of serial number is:  YYYYMMDDNN where YYYY is year, &lt;br /&gt;
//    MM is month, DD is day, NN is update number for that day (i.e., 01, &lt;br /&gt;
//    02, 03,...)&lt;br /&gt;
// 3) rename db.wright.local.zone to match your domain name.&lt;br /&gt;
// 4) rename db.wright.local.rev to match your domain name.&lt;br /&gt;
// 5) If you changed the internal network IP from the LinuxMCE default of&lt;br /&gt;
//    192.168.80.0/24, then replace &amp;quot;192.168.80&amp;quot; with your network&lt;br /&gt;
//    ip and replace it&#039;s reverse &amp;quot;80.168.192&amp;quot; wity your network ip&#039;s&lt;br /&gt;
//    reverse.&lt;br /&gt;
//&lt;br /&gt;
// Please read /usr/share/doc/bind9/README.Debian.gz for information on the &lt;br /&gt;
// structure of BIND configuration files in Debian, *BEFORE* you customize &lt;br /&gt;
// this configuration file.&lt;br /&gt;
//&lt;br /&gt;
// If you are just adding zones, please do that in /etc/bind/named.conf.local&lt;br /&gt;
//&lt;br /&gt;
// references:&lt;br /&gt;
// http://www.arda.homeunix.net/dnssetup.html&lt;br /&gt;
// http://www.madboa.com/geek/soho-bind/&lt;br /&gt;
//&lt;br /&gt;
// notes:&lt;br /&gt;
// 1) The following command should be ran about twice a year to keep&lt;br /&gt;
//    the root servers current:&lt;br /&gt;
//      dig @a.root-servers.net . ns &amp;gt; /etc/bin/db.root&lt;br /&gt;
//    Root name servers don’t change very often so updating this file more &lt;br /&gt;
//    than twice a year is probably overkill. Frequent updates also put undo &lt;br /&gt;
//    load on the root name servers; they have enough to do as it is.&lt;br /&gt;
//&lt;br /&gt;
// 2) File permissions:&lt;br /&gt;
//    /etc/bind/named.conf   root:root   644&lt;br /&gt;
//    /etc/bind/rndc.key     root:bind   640&lt;br /&gt;
//    /etc/bind/rndc.conf    root:root   600&lt;br /&gt;
//    /etc/resolv.conf       root:root   644&lt;br /&gt;
//    /etc/bind              root:bind   775, chmod g+s =&amp;gt; drwxrwsr-x&lt;br /&gt;
//    /etc/dhcp3             root:root   755&lt;br /&gt;
//    /etc/dhcp3/dhcpd.conf  root:root   644&lt;br /&gt;
//&lt;br /&gt;
// Manually Updating Zone Files&lt;br /&gt;
// 1. Use rndc to stop BIND.&lt;br /&gt;
//      sudo rndc stop&lt;br /&gt;
// 2. Remove any .jnl files from the zone file directory.&lt;br /&gt;
//      sudo rm /etc/bind/*.jnl&lt;br /&gt;
// 3. Edit the zone files as necessary. Make sure to increment the serial &lt;br /&gt;
//    number of any file edited.  Note, format of serial number is:&lt;br /&gt;
//    YYYYMMDDNN where YYYY is year, MM is month, DD is day, NN is update&lt;br /&gt;
//    number for that day (i.e., 01, 02, 03,...)&lt;br /&gt;
// 4. Start BIND using its startup script. &lt;br /&gt;
//      sudo /etc/init.d/bind9 start&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
// secret must be the same as in /etc/bind/rndc.conf&lt;br /&gt;
include &amp;quot;/etc/bind/rndc.key&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
// access control list used to limit queries to local net&lt;br /&gt;
acl &amp;quot;internal-net&amp;quot; { 192.168.80/24; 127.0.0.1; };&lt;br /&gt;
&lt;br /&gt;
controls {&lt;br /&gt;
    inet 127.0.0.1 allow { any; } keys { &amp;quot;rndc-key&amp;quot;; };&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
include &amp;quot;/etc/bind/named.conf.options&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
// The single dot (.) is the root of all DNS namespace, so&lt;br /&gt;
// this zone tells named where to start looking for any&lt;br /&gt;
// name on the Internet&lt;br /&gt;
zone &amp;quot;.&amp;quot; IN {&lt;br /&gt;
	type hint;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.root&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
// local intranet zones and reverse zones&lt;br /&gt;
// intranet is wright.local and 192.168.80.0/24&lt;br /&gt;
// the DHCP servers is on linuxmce-dhcp&lt;br /&gt;
// an optional second nameserver would be on linuxmce-ns2&lt;br /&gt;
	&lt;br /&gt;
zone &amp;quot;wright.local&amp;quot; IN {&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.wright.local.zone&amp;quot;;&lt;br /&gt;
	// both allow-update and update-policy can enable DHCP updates,&lt;br /&gt;
	// but update-policy allows more control over what kinds of &lt;br /&gt;
	// updates DHCP can perform on a zone.&lt;br /&gt;
	// allow-update { none; };&lt;br /&gt;
	update-policy { grant linuxmce-dhcp subdomain wright.local. A TXT; };&lt;br /&gt;
	// allow-transfer { key &amp;quot;linuxmce-ns2&amp;quot;; };&lt;br /&gt;
	// notify on zone transfers&lt;br /&gt;
	notify yes;&lt;br /&gt;
};&lt;br /&gt;
	&lt;br /&gt;
zone &amp;quot;80.168.192.in-addr.arpa&amp;quot; IN {&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.wright.local.rev&amp;quot;;&lt;br /&gt;
	// allow-update { none; };&lt;br /&gt;
	update-policy { grant linuxmce-dhcp subdomain 80.168.192.in-addr.arpa. PTR TXT; };&lt;br /&gt;
	// allow-transfer { key &amp;quot;linuxmce-ns2&amp;quot;; };&lt;br /&gt;
	notify yes;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
// be authoritative for the localhost forward and reverse zones, and for&lt;br /&gt;
// broadcast zones as per RFC 1912 (http://www.ietf.org/rfc/rfc1912.txt)&lt;br /&gt;
&lt;br /&gt;
// Where the localhost hostname is defined&lt;br /&gt;
zone &amp;quot;localhost&amp;quot; IN {&lt;br /&gt;
	// a master type means that this server needn&#039;t look&lt;br /&gt;
	// anywhere else for information; the localhost buck&lt;br /&gt;
	// stops here.&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.local&amp;quot;;&lt;br /&gt;
	// don&#039;t allow dynamic DNS clients to update info&lt;br /&gt;
	// about the localhost zone&lt;br /&gt;
	allow-update { none; };&lt;br /&gt;
};&lt;br /&gt;
	&lt;br /&gt;
// Where the 127.0.0.0 network is defined&lt;br /&gt;
zone &amp;quot;127.in-addr.arpa&amp;quot; IN {&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.127&amp;quot;;&lt;br /&gt;
	allow-update { none; };&lt;br /&gt;
};&lt;br /&gt;
	&lt;br /&gt;
zone &amp;quot;0.in-addr.arpa&amp;quot; IN {&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.0&amp;quot;;&lt;br /&gt;
	allow-update { none; };&lt;br /&gt;
};&lt;br /&gt;
	&lt;br /&gt;
zone &amp;quot;255.in-addr.arpa&amp;quot; IN {&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.255&amp;quot;;&lt;br /&gt;
	allow-update { none; };&lt;br /&gt;
};&lt;br /&gt;
	&lt;br /&gt;
&lt;br /&gt;
// Include logging config file&lt;br /&gt;
include &amp;quot;/etc/bind/logging.conf&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
// zone &amp;quot;com&amp;quot; { type delegation-only; };&lt;br /&gt;
// zone &amp;quot;net&amp;quot; { type delegation-only; };&lt;br /&gt;
&lt;br /&gt;
// From the release notes:&lt;br /&gt;
//  Because many of our users are uncomfortable receiving undelegated answers&lt;br /&gt;
//  from root or top level domains, other than a few for whom that behaviour&lt;br /&gt;
//  has been trusted and expected for quite some length of time, we have now&lt;br /&gt;
//  introduced the &amp;quot;root-delegations-only&amp;quot; feature which applies delegation-only&lt;br /&gt;
//  logic to all top level domains, and to the root domain.  An exception list&lt;br /&gt;
//  should be specified, including &amp;quot;MUSEUM&amp;quot; and &amp;quot;DE&amp;quot;, and any other top level&lt;br /&gt;
//  domains from whom undelegated responses are expected and trusted.&lt;br /&gt;
// root-delegation-only exclude { &amp;quot;DE&amp;quot;; &amp;quot;MUSEUM&amp;quot;; };&lt;br /&gt;
&lt;br /&gt;
include &amp;quot;/etc/bind/named.conf.local&amp;quot;;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/named.conf.options===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
options {&lt;br /&gt;
	// tell named where to find files mentioned below&lt;br /&gt;
	directory &amp;quot;/var/cache/bind&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
	// file that contains the process id when bind is running&lt;br /&gt;
	pid-file &amp;quot;/var/run/bind/run/named.pid&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
	// enable statistics&lt;br /&gt;
	statistics-file &amp;quot;/var/named/named.stats&amp;quot;;&lt;br /&gt;
	zone-statistics yes;&lt;br /&gt;
&lt;br /&gt;
	dump-file &amp;quot;/var/named/named.dump&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
	// If there is a firewall between you and nameservers you want&lt;br /&gt;
	// to talk to, you might need to uncomment the query-source&lt;br /&gt;
	// directive below.  Previous versions of BIND always asked&lt;br /&gt;
	// questions using port 53, but BIND 8.1 and later use an unprivileged&lt;br /&gt;
	// port by default.&lt;br /&gt;
	// query-source address * port 53;&lt;br /&gt;
&lt;br /&gt;
	// If your ISP provided one or more IP addresses for stable &lt;br /&gt;
	// nameservers, you probably want to use them as forwarders.  &lt;br /&gt;
	// Uncomment the following block, and insert the addresses replacing &lt;br /&gt;
	// the all-0&#039;s placeholder.&lt;br /&gt;
&lt;br /&gt;
	// The forwarders option tells BIND to not use iterative queries itself &lt;br /&gt;
	// for information it doesn’t already know about but to forward a &lt;br /&gt;
	// recursive query to the name servers specified instead.&lt;br /&gt;
	include &amp;quot;/etc/bind/named.conf.forwarders&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
	// conform to RFC1035&lt;br /&gt;
	auth-nxdomain no;&lt;br /&gt;
&lt;br /&gt;
	// on a multi-homed host, you might want to tell named&lt;br /&gt;
	// to listen for queries only on certain interfaces&lt;br /&gt;
	listen-on-v6 { any; };&lt;br /&gt;
	listen-on { &amp;quot;internal-net&amp;quot;; };&lt;br /&gt;
&lt;br /&gt;
	// to allow only specific hosts to use the DNS server:&lt;br /&gt;
	allow-query { &amp;quot;internal-net&amp;quot;; };&lt;br /&gt;
&lt;br /&gt;
	// sets BIND’s default behaviour to refuse all zone transfers. &lt;br /&gt;
	// Without setting this option, anyone can transfer any zone.&lt;br /&gt;
	allow-transfer { none; };&lt;br /&gt;
&lt;br /&gt;
	// do not generate notify messages for all zones on a restart.&lt;br /&gt;
	// override for authorative zones&lt;br /&gt;
	notify no;&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/logging.conf===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
logging {&lt;br /&gt;
&lt;br /&gt;
	channel default_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/default.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel general_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/general.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel database_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/database.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel security_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/security.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel config_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/config.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel resolver_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/resolver.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel xfer-in_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/xfer-in.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel xfer-out_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/xfer-out.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel notify_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/notify.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel client_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/client.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel unmatched_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/unmatched.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel queries_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/queries.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel network_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/network.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel update_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/update.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel dispatch_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/dispatch.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel dnssec_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/dnssec.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel lame-servers_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/lame-servers.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
	category lame-servers {&lt;br /&gt;
		lame-servers_file;&lt;br /&gt;
		};&lt;br /&gt;
	category dnssec {&lt;br /&gt;
		dnssec_file;&lt;br /&gt;
		};&lt;br /&gt;
	category dispatch {&lt;br /&gt;
		dispatch_file;&lt;br /&gt;
		};&lt;br /&gt;
	category update {&lt;br /&gt;
		update_file;&lt;br /&gt;
		};&lt;br /&gt;
	category network {&lt;br /&gt;
		network_file;&lt;br /&gt;
		};&lt;br /&gt;
	category queries {&lt;br /&gt;
		queries_file;&lt;br /&gt;
		};&lt;br /&gt;
	category unmatched {&lt;br /&gt;
		unmatched_file;&lt;br /&gt;
		};&lt;br /&gt;
	category client {&lt;br /&gt;
		client_file;&lt;br /&gt;
		};&lt;br /&gt;
	category notify {&lt;br /&gt;
		notify_file;&lt;br /&gt;
		};&lt;br /&gt;
	category xfer-out {&lt;br /&gt;
		xfer-out_file;&lt;br /&gt;
		};&lt;br /&gt;
	category xfer-in {&lt;br /&gt;
		xfer-in_file;&lt;br /&gt;
		};&lt;br /&gt;
	category resolver {&lt;br /&gt;
		resolver_file;&lt;br /&gt;
		};&lt;br /&gt;
	category config {&lt;br /&gt;
		config_file;&lt;br /&gt;
		};&lt;br /&gt;
	category security {&lt;br /&gt;
		security_file;&lt;br /&gt;
		};&lt;br /&gt;
	category database {&lt;br /&gt;
		database_file;&lt;br /&gt;
		};&lt;br /&gt;
	category general {&lt;br /&gt;
		general_file;&lt;br /&gt;
		};&lt;br /&gt;
	category default {&lt;br /&gt;
		default_file;&lt;br /&gt;
		};&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/rndc.conf===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
options {&lt;br /&gt;
	default-server  localhost;&lt;br /&gt;
	default-key     &amp;quot;rndc-key&amp;quot;;&lt;br /&gt;
	default-port 953;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
server localhost {&lt;br /&gt;
	key     &amp;quot;rndc-key&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
key &amp;quot;rndc-key&amp;quot; {&lt;br /&gt;
	algorithm       hmac-md5;&lt;br /&gt;
	secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/rndc.key===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
key &amp;quot;rndc-key&amp;quot; {&lt;br /&gt;
        algorithm	hmac-md5;&lt;br /&gt;
        secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
key &amp;quot;linuxmce-dhcp&amp;quot; {&lt;br /&gt;
        algorithm	hmac-md5;&lt;br /&gt;
        secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
key &amp;quot;linuxmce-ns2&amp;quot; {&lt;br /&gt;
        algorithm	hmac-md5;&lt;br /&gt;
        secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/db.wright.local.zone===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
;&lt;br /&gt;
; BIND data file for wright.local&lt;br /&gt;
; ref. http://www.redhat.com/docs/manuals/linux/RHL-9-Manual/ref-guide/s1-bind-zone.html&lt;br /&gt;
;&lt;br /&gt;
$TTL 86400 ; time to live : 86400s = 1 day&lt;br /&gt;
; Start Of Authority record, proclaims important authoritative information &lt;br /&gt;
; about a namespace to the nameserver.&lt;br /&gt;
@               IN SOA  dcerouter.wright.local        roy@wright.org (&lt;br /&gt;
                2008013101      ;serial (YYYYMMDDNN where N = 01,02,03,...)&lt;br /&gt;
                10800           ;refresh (3 hours)&lt;br /&gt;
                7200            ;retry (2 hours)&lt;br /&gt;
                36000000        ;expire (10,000 hours = 416 2/3 days)&lt;br /&gt;
                86400)          ;default minimum ttl&lt;br /&gt;
;&lt;br /&gt;
; NameServer record, which announces the authoritative nameservers for a particular zone.&lt;br /&gt;
;&lt;br /&gt;
                IN NS   dcerouter.wright.local.&lt;br /&gt;
;&lt;br /&gt;
; Address records specify an IP address to assign to a name&lt;br /&gt;
;&lt;br /&gt;
dcerouter       IN A            192.168.80.1&lt;br /&gt;
dad-kubuntu     IN A            192.168.80.21&lt;br /&gt;
royw-gentoo	IN A		192.168.80.20&lt;br /&gt;
;&lt;br /&gt;
; Canonical name records, maps one name to another. &lt;br /&gt;
;&lt;br /&gt;
linuxmce        IN CNAME        dcerouter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/db.wright.local.rev===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
;&lt;br /&gt;
; BIND reverse data file for wright.local&lt;br /&gt;
; ref. http://www.redhat.com/docs/manuals/linux/RHL-9-Manual/ref-guide/s1-bind-zone.html&lt;br /&gt;
;&lt;br /&gt;
$ORIGIN 80.168.192.in-addr.arpa.&lt;br /&gt;
$TTL 86400 ; time to live : 86400s = 1 day&lt;br /&gt;
; Start Of Authority record, proclaims important authoritative information &lt;br /&gt;
; about a namespace to the nameserver.&lt;br /&gt;
@               IN SOA  dcerouter.wright.local        roy@wright.org (&lt;br /&gt;
                2008013101      ;serial (YYYYMMDDNN where N = 01,02,03,...)&lt;br /&gt;
                10800           ;refresh (3 hours)&lt;br /&gt;
                7200            ;retry (2 hours)&lt;br /&gt;
                36000000        ;expire (10,000 hours = 416 2/3 days)&lt;br /&gt;
                86400)          ;default minimum ttl&lt;br /&gt;
;&lt;br /&gt;
; NameServer record, which announces the authoritative nameservers for a particular zone.&lt;br /&gt;
;&lt;br /&gt;
                IN NS   dcerouter.wright.local.&lt;br /&gt;
;&lt;br /&gt;
; PTR — PoinTeR record, designed to point to another part of the namespace.&lt;br /&gt;
;&lt;br /&gt;
1               IN PTR  dcerouter.wright.local.&lt;br /&gt;
21              IN PTR  dad-kubuntu.wright.local.&lt;br /&gt;
20		IN PTR	royw-gentoo.wright.local.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/dhcp3/dhcpd.conf===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
option domain-name-servers 192.168.80.1;&lt;br /&gt;
authoritative;&lt;br /&gt;
&lt;br /&gt;
option routers 192.168.80.1;&lt;br /&gt;
option subnet-mask 255.255.255.0;&lt;br /&gt;
&lt;br /&gt;
# lease IPs for 1 day, maximum 1 week&lt;br /&gt;
default-lease-time 86400;&lt;br /&gt;
max-lease-time 604800;&lt;br /&gt;
&lt;br /&gt;
# dynamic DNS updates&lt;br /&gt;
ddns-updates on;&lt;br /&gt;
ddns-update-style interim;&lt;br /&gt;
ddns-domainname &amp;quot;wright.local.&amp;quot;;&lt;br /&gt;
ddns-rev-domainname &amp;quot;in-addr.arpa.&amp;quot;;&lt;br /&gt;
ddns-ttl 14400;&lt;br /&gt;
&lt;br /&gt;
# don&#039;t let clients modify their own A records&lt;br /&gt;
ignore client-updates;&lt;br /&gt;
&lt;br /&gt;
key &amp;quot;linuxmce-dhcp&amp;quot; {&lt;br /&gt;
	algorithm       hmac-md5;&lt;br /&gt;
	secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
zone wright.local {&lt;br /&gt;
	primary 192.168.80.1;&lt;br /&gt;
	key &amp;quot;linuxmce-dhcp&amp;quot;;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
zone 80.168.192.in-addr.arpa {&lt;br /&gt;
	primary 192.168.80.1;&lt;br /&gt;
	key &amp;quot;linuxmce-dhcp&amp;quot;;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
option space pxelinux;&lt;br /&gt;
option pxelinux.magic code 208 = string;&lt;br /&gt;
option pxelinux.configfile code 209 = text;&lt;br /&gt;
option pxelinux.pathprefix code 210 = text;&lt;br /&gt;
option pxelinux.reboottime code 211 = unsigned integer 32;&lt;br /&gt;
&lt;br /&gt;
subnet 192.168.80.0 netmask 255.255.255.0 {&lt;br /&gt;
	next-server 192.168.80.1;&lt;br /&gt;
	filename &amp;quot;/tftpboot/pxelinux.0&amp;quot;;&lt;br /&gt;
	option pxelinux.reboottime = 30;&lt;br /&gt;
&lt;br /&gt;
	option domain-name &amp;quot;wright.local&amp;quot;;&lt;br /&gt;
	option domain-name-servers 192.168.80.1;&lt;br /&gt;
	option routers 192.168.80.1;&lt;br /&gt;
&lt;br /&gt;
	default-lease-time 86400;&lt;br /&gt;
	max-lease-time 604800;&lt;br /&gt;
	pool {&lt;br /&gt;
		 allow unknown-clients;&lt;br /&gt;
		 range 192.168.80.129 192.168.80.254; &lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
# PXE booting machines&lt;br /&gt;
group {&lt;br /&gt;
	next-server 192.168.80.1;&lt;br /&gt;
	filename &amp;quot;/tftpboot/pxelinux.0&amp;quot;;&lt;br /&gt;
	option pxelinux.reboottime = 30;&lt;br /&gt;
&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
# regular machines&lt;br /&gt;
group {&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
# CORE (1) has bad mac address: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/resolv.conf===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
domain wright.local&lt;br /&gt;
nameserver localhost&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Juanfe</name></author>
	</entry>
	<entry>
		<id>http://wiki.linuxmce.org/index.php?title=How_to_setup_Local_Authoritative_DNS&amp;diff=15512</id>
		<title>How to setup Local Authoritative DNS</title>
		<link rel="alternate" type="text/html" href="http://wiki.linuxmce.org/index.php?title=How_to_setup_Local_Authoritative_DNS&amp;diff=15512"/>
		<updated>2008-09-05T22:30:15Z</updated>

		<summary type="html">&lt;p&gt;Juanfe: /* File Permissions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[category: Tutorials]]&lt;br /&gt;
=How to setup Local Authoritative DNS=&lt;br /&gt;
&lt;br /&gt;
I was wanting an authoritative name server for my local intranet.  I also wanted any dynamic IP&#039;s to be visible to the name server.  The name server included with linuxmce is configured as a recursive name server.  Here&#039;s the changes I did to configure my core&#039;s name server to be authoritative and support dynamic IPs.  Note, the machines on my intranet are private, i.e., not known to the outside world.&lt;br /&gt;
&lt;br /&gt;
  3 Feb 2008 - Developed and tested on LinuxMCE 0710 Beta 3 amd64.&lt;br /&gt;
&lt;br /&gt;
I named my intranet &amp;quot;wright.local&amp;quot;.  Using a &amp;quot;local&amp;quot; top level domain (TLD) is recommended for private intranets.  Some may prefer to use &amp;quot;lan&amp;quot;.  You do not want to use any of the standard TLDs like &amp;quot;com&amp;quot;, &amp;quot;net&amp;quot;, &amp;quot;org&amp;quot;,...&lt;br /&gt;
&lt;br /&gt;
I used the core&#039;s default intranet addresses, 192.168.80.0/24 with the core at 192.168.80.1.&lt;br /&gt;
&lt;br /&gt;
I&#039;ve attempted to verbosely document each config file. :)&lt;br /&gt;
&lt;br /&gt;
The directions for adapting the config files are included in the named.conf file.&lt;br /&gt;
&lt;br /&gt;
==Installation==&lt;br /&gt;
&lt;br /&gt;
If you want to try this, I would suggest building the config in new directories then swapping with the originals when you are ready (I had a little mess when my core hung and I had to restart with only half the configs ready) :)&lt;br /&gt;
&lt;br /&gt;
So start with creating two directories:&lt;br /&gt;
&lt;br /&gt;
  sudo mkdir /etc/bind.new&lt;br /&gt;
  sudo mkdir /etc/dhcp3.new&lt;br /&gt;
&lt;br /&gt;
Now copy the contents of the original directories:&lt;br /&gt;
&lt;br /&gt;
  sudo cp -arp /etc/bind/* /etc/bind.new&lt;br /&gt;
  sudo cp -arp /etc/dhcp3/* /etc/dhcp3.new&lt;br /&gt;
&lt;br /&gt;
Also create a new resolve.conf file:&lt;br /&gt;
&lt;br /&gt;
  sudo touch /etc/resolv.conf.new&lt;br /&gt;
&lt;br /&gt;
You will be creating or editing the following config files in these new directories:&lt;br /&gt;
&lt;br /&gt;
  /etc/bind.new/named.conf&lt;br /&gt;
  /etc/bind.new/named.conf.options&lt;br /&gt;
  /etc/bind.new/logging.conf&lt;br /&gt;
  /etc/bind.new/rndc.conf&lt;br /&gt;
  /etc/bind.new/rndc.key&lt;br /&gt;
  /etc/bind.new/db.wright.local.zone&lt;br /&gt;
  /etc/bind.new/db.wright.local.rev&lt;br /&gt;
  /etc/dhcp3.new/dhcpd.conf&lt;br /&gt;
  /etc/resolv.conf&lt;br /&gt;
&lt;br /&gt;
The full text of the files you will be editing is at the foot of this page. The original author named his network &amp;quot;wright&amp;quot;; you should replace all instances of &amp;quot;wright&amp;quot; with the name of your network.&lt;br /&gt;
&lt;br /&gt;
==Notes on Editing Files==&lt;br /&gt;
&lt;br /&gt;
===rndc.key and dhcpd.conf key values=== &lt;br /&gt;
&lt;br /&gt;
To create a key for use in rndc.key and dhcpd.conf:&lt;br /&gt;
&lt;br /&gt;
  sudo dnssec-keygen -a HMAC-MD5 -b 256 -n user rndc&lt;br /&gt;
&lt;br /&gt;
Now get the key from the private file:&lt;br /&gt;
&lt;br /&gt;
  sudo cat Krndc.*.private&lt;br /&gt;
  Private-key-format: v1.2&lt;br /&gt;
  Algorithm: 157 (HMAC_MD5)&lt;br /&gt;
  Key: 3+GnSWV5FKxcUu57k7QFxbpvv/xr4fXj2wBVGtdGifI=&lt;br /&gt;
  Bits: AAA=&lt;br /&gt;
&lt;br /&gt;
Now cut the key which is to the right of &amp;quot;Key: &amp;quot; and paste where needed (replace &amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot; with the key in the config files).  So an example using the above key would look like:&lt;br /&gt;
&lt;br /&gt;
  key &amp;quot;linuxmce-dhcp&amp;quot; {&lt;br /&gt;
        algorithm	hmac-md5;&lt;br /&gt;
        secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
  };&lt;br /&gt;
&lt;br /&gt;
becomes:&lt;br /&gt;
&lt;br /&gt;
  key &amp;quot;linuxmce-dhcp&amp;quot; {&lt;br /&gt;
        algorithm	hmac-md5;&lt;br /&gt;
        secret		&amp;quot;3+GnSWV5FKxcUu57k7QFxbpvv/xr4fXj2wBVGtdGifI=&amp;quot;;&lt;br /&gt;
  };&lt;br /&gt;
&lt;br /&gt;
===Check directory ownership===&lt;br /&gt;
Make the logging directory:&lt;br /&gt;
&lt;br /&gt;
  sudo mkdir /var/log/named&lt;br /&gt;
  sudo chown bind:bind /var/log/named&lt;br /&gt;
  sudo chmod 755 /var/log/named&lt;br /&gt;
&lt;br /&gt;
You probably ought to check and change the defaultdomain:&lt;br /&gt;
&lt;br /&gt;
  domainname&lt;br /&gt;
&lt;br /&gt;
will probably show&lt;br /&gt;
&lt;br /&gt;
  pluto&lt;br /&gt;
&lt;br /&gt;
if so, then set it by:&lt;br /&gt;
  sudo domainname yourdomain.local&lt;br /&gt;
&lt;br /&gt;
where &amp;quot;yourdomain.local&amp;quot; is your domain.  :-)&lt;br /&gt;
&lt;br /&gt;
===File Permissions===&lt;br /&gt;
Change all the file permissions per instructions in named.conf:&lt;br /&gt;
&lt;br /&gt;
   File permissions:&lt;br /&gt;
  //    /etc/bind/named.conf   root:root   644&lt;br /&gt;
  //    /etc/bind/rndc.key     root:bind   640&lt;br /&gt;
  //    /etc/bind/rndc.conf    root:root   600&lt;br /&gt;
  //    /etc/resolv.conf       root:root   644&lt;br /&gt;
  //    /etc/bind              root:bind   775, chmod g+s =&amp;gt; drwxrwsr-x&lt;br /&gt;
  //    /etc/dhcp3             root:root   755&lt;br /&gt;
  //    /etc/dhcp3/dhcpd.conf  root:root   644&lt;br /&gt;
  //&lt;br /&gt;
&lt;br /&gt;
===Double check. Everything===&lt;br /&gt;
Double check everything.   Roll Eyes&lt;br /&gt;
&lt;br /&gt;
==Wrapping up==&lt;br /&gt;
When and if you are feeling lucky, rename the original directories and then rename the new directories to take their place:&lt;br /&gt;
&lt;br /&gt;
  sudo mv /etc/bind /etc/bind.original&lt;br /&gt;
  sudo mv /etc/bind.new /etc/bind&lt;br /&gt;
  sudo mv /etc/dhcp3 /etc/dhcp3.original&lt;br /&gt;
  sudo mv /etc/dhcp3.new /etc/dhcp3&lt;br /&gt;
  sudo mv /etc/resolve.conf /etc/resolve.conf.original&lt;br /&gt;
  sudo mv /etc/resolve.conf.new /etc/resolve.conf&lt;br /&gt;
&lt;br /&gt;
Finally restart the bind and dhcpd services:&lt;br /&gt;
&lt;br /&gt;
  sudo rndc reload&lt;br /&gt;
  sudo /etc/init.d/dhcp3-server restart&lt;br /&gt;
&lt;br /&gt;
Check the syslog for any errors:&lt;br /&gt;
&lt;br /&gt;
  grep named /var/log/syslog&lt;br /&gt;
  grep dhcpd /var/log/syslog&lt;br /&gt;
&lt;br /&gt;
==Config Files==&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/named.conf===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
// This is the primary configuration file for the BIND DNS server named.&lt;br /&gt;
//&lt;br /&gt;
// This configuration supports an authoritative local zone (wright.local on&lt;br /&gt;
// 192.168.80.0/24) and allows DHCP to update the local zone.  &lt;br /&gt;
// To customize to your setup:&lt;br /&gt;
// 1) replace &amp;quot;wright.local&amp;quot; with your internal domain name.&lt;br /&gt;
// 2) edit db.wright.local.zone and db.wright.local.rev and replace&lt;br /&gt;
//    my static names/addresses with your network&#039;s static names/addresses.&lt;br /&gt;
//    Make sure to increment the serial number of any file edited.  &lt;br /&gt;
//    Note, format of serial number is:  YYYYMMDDNN where YYYY is year, &lt;br /&gt;
//    MM is month, DD is day, NN is update number for that day (i.e., 01, &lt;br /&gt;
//    02, 03,...)&lt;br /&gt;
// 3) rename db.wright.local.zone to match your domain name.&lt;br /&gt;
// 4) rename db.wright.local.rev to match your domain name.&lt;br /&gt;
// 5) If you changed the internal network IP from the LinuxMCE default of&lt;br /&gt;
//    192.168.80.0/24, then replace &amp;quot;192.168.80&amp;quot; with your network&lt;br /&gt;
//    ip and replace it&#039;s reverse &amp;quot;80.168.192&amp;quot; wity your network ip&#039;s&lt;br /&gt;
//    reverse.&lt;br /&gt;
//&lt;br /&gt;
// Please read /usr/share/doc/bind9/README.Debian.gz for information on the &lt;br /&gt;
// structure of BIND configuration files in Debian, *BEFORE* you customize &lt;br /&gt;
// this configuration file.&lt;br /&gt;
//&lt;br /&gt;
// If you are just adding zones, please do that in /etc/bind/named.conf.local&lt;br /&gt;
//&lt;br /&gt;
// references:&lt;br /&gt;
// http://www.arda.homeunix.net/dnssetup.html&lt;br /&gt;
// http://www.madboa.com/geek/soho-bind/&lt;br /&gt;
//&lt;br /&gt;
// notes:&lt;br /&gt;
// 1) The following command should be ran about twice a year to keep&lt;br /&gt;
//    the root servers current:&lt;br /&gt;
//      dig @a.root-servers.net . ns &amp;gt; /etc/bin/db.root&lt;br /&gt;
//    Root name servers don’t change very often so updating this file more &lt;br /&gt;
//    than twice a year is probably overkill. Frequent updates also put undo &lt;br /&gt;
//    load on the root name servers; they have enough to do as it is.&lt;br /&gt;
//&lt;br /&gt;
// 2) File permissions:&lt;br /&gt;
//    /etc/bind/named.conf   root:root   644&lt;br /&gt;
//    /etc/bind/rndc.key     root:bind   640&lt;br /&gt;
//    /etc/bind/rndc.conf    root:root   600&lt;br /&gt;
//    /etc/resolv.conf       root:root   644&lt;br /&gt;
//    /etc/bind              root:bind   775, chmod g+s =&amp;gt; drwxrwsr-x&lt;br /&gt;
//    /etc/dhcp3             root:root   755&lt;br /&gt;
//    /etc/dhcp3/dhcpd.conf  root:root   644&lt;br /&gt;
//&lt;br /&gt;
// Manually Updating Zone Files&lt;br /&gt;
// 1. Use rndc to stop BIND.&lt;br /&gt;
//      sudo rndc stop&lt;br /&gt;
// 2. Remove any .jnl files from the zone file directory.&lt;br /&gt;
//      sudo rm /etc/bind/*.jnl&lt;br /&gt;
// 3. Edit the zone files as necessary. Make sure to increment the serial &lt;br /&gt;
//    number of any file edited.  Note, format of serial number is:&lt;br /&gt;
//    YYYYMMDDNN where YYYY is year, MM is month, DD is day, NN is update&lt;br /&gt;
//    number for that day (i.e., 01, 02, 03,...)&lt;br /&gt;
// 4. Start BIND using its startup script. &lt;br /&gt;
//      sudo /etc/init.d/bind9 start&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
// secret must be the same as in /etc/bind/rndc.conf&lt;br /&gt;
include &amp;quot;/etc/bind/rndc.key&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
// access control list used to limit queries to local net&lt;br /&gt;
acl &amp;quot;internal-net&amp;quot; { 192.168.80/24; 127.0.0.1; };&lt;br /&gt;
&lt;br /&gt;
controls {&lt;br /&gt;
    inet 127.0.0.1 allow { any; } keys { &amp;quot;rndc-key&amp;quot;; };&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
include &amp;quot;/etc/bind/named.conf.options&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
// The single dot (.) is the root of all DNS namespace, so&lt;br /&gt;
// this zone tells named where to start looking for any&lt;br /&gt;
// name on the Internet&lt;br /&gt;
zone &amp;quot;.&amp;quot; IN {&lt;br /&gt;
	type hint;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.root&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
// local intranet zones and reverse zones&lt;br /&gt;
// intranet is wright.local and 192.168.80.0/24&lt;br /&gt;
// the DHCP servers is on linuxmce-dhcp&lt;br /&gt;
// an optional second nameserver would be on linuxmce-ns2&lt;br /&gt;
	&lt;br /&gt;
zone &amp;quot;wright.local&amp;quot; IN {&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.wright.local.zone&amp;quot;;&lt;br /&gt;
	// both allow-update and update-policy can enable DHCP updates,&lt;br /&gt;
	// but update-policy allows more control over what kinds of &lt;br /&gt;
	// updates DHCP can perform on a zone.&lt;br /&gt;
	// allow-update { none; };&lt;br /&gt;
	update-policy { grant linuxmce-dhcp subdomain wright.local. A TXT; };&lt;br /&gt;
	// allow-transfer { key &amp;quot;linuxmce-ns2&amp;quot;; };&lt;br /&gt;
	// notify on zone transfers&lt;br /&gt;
	notify yes;&lt;br /&gt;
};&lt;br /&gt;
	&lt;br /&gt;
zone &amp;quot;80.168.192.in-addr.arpa&amp;quot; IN {&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.wright.local.rev&amp;quot;;&lt;br /&gt;
	// allow-update { none; };&lt;br /&gt;
	update-policy { grant linuxmce-dhcp subdomain 80.168.192.in-addr.arpa. PTR TXT; };&lt;br /&gt;
	// allow-transfer { key &amp;quot;linuxmce-ns2&amp;quot;; };&lt;br /&gt;
	notify yes;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
// be authoritative for the localhost forward and reverse zones, and for&lt;br /&gt;
// broadcast zones as per RFC 1912 (http://www.ietf.org/rfc/rfc1912.txt)&lt;br /&gt;
&lt;br /&gt;
// Where the localhost hostname is defined&lt;br /&gt;
zone &amp;quot;localhost&amp;quot; IN {&lt;br /&gt;
	// a master type means that this server needn&#039;t look&lt;br /&gt;
	// anywhere else for information; the localhost buck&lt;br /&gt;
	// stops here.&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.local&amp;quot;;&lt;br /&gt;
	// don&#039;t allow dynamic DNS clients to update info&lt;br /&gt;
	// about the localhost zone&lt;br /&gt;
	allow-update { none; };&lt;br /&gt;
};&lt;br /&gt;
	&lt;br /&gt;
// Where the 127.0.0.0 network is defined&lt;br /&gt;
zone &amp;quot;127.in-addr.arpa&amp;quot; IN {&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.127&amp;quot;;&lt;br /&gt;
	allow-update { none; };&lt;br /&gt;
};&lt;br /&gt;
	&lt;br /&gt;
zone &amp;quot;0.in-addr.arpa&amp;quot; IN {&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.0&amp;quot;;&lt;br /&gt;
	allow-update { none; };&lt;br /&gt;
};&lt;br /&gt;
	&lt;br /&gt;
zone &amp;quot;255.in-addr.arpa&amp;quot; IN {&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.255&amp;quot;;&lt;br /&gt;
	allow-update { none; };&lt;br /&gt;
};&lt;br /&gt;
	&lt;br /&gt;
&lt;br /&gt;
// Include logging config file&lt;br /&gt;
include &amp;quot;/etc/bind/logging.conf&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
// zone &amp;quot;com&amp;quot; { type delegation-only; };&lt;br /&gt;
// zone &amp;quot;net&amp;quot; { type delegation-only; };&lt;br /&gt;
&lt;br /&gt;
// From the release notes:&lt;br /&gt;
//  Because many of our users are uncomfortable receiving undelegated answers&lt;br /&gt;
//  from root or top level domains, other than a few for whom that behaviour&lt;br /&gt;
//  has been trusted and expected for quite some length of time, we have now&lt;br /&gt;
//  introduced the &amp;quot;root-delegations-only&amp;quot; feature which applies delegation-only&lt;br /&gt;
//  logic to all top level domains, and to the root domain.  An exception list&lt;br /&gt;
//  should be specified, including &amp;quot;MUSEUM&amp;quot; and &amp;quot;DE&amp;quot;, and any other top level&lt;br /&gt;
//  domains from whom undelegated responses are expected and trusted.&lt;br /&gt;
// root-delegation-only exclude { &amp;quot;DE&amp;quot;; &amp;quot;MUSEUM&amp;quot;; };&lt;br /&gt;
&lt;br /&gt;
include &amp;quot;/etc/bind/named.conf.local&amp;quot;;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/named.conf.options===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
options {&lt;br /&gt;
	// tell named where to find files mentioned below&lt;br /&gt;
	directory &amp;quot;/var/cache/bind&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
	// file that contains the process id when bind is running&lt;br /&gt;
	pid-file &amp;quot;/var/run/bind/run/named.pid&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
	// enable statistics&lt;br /&gt;
	statistics-file &amp;quot;/var/named/named.stats&amp;quot;;&lt;br /&gt;
	zone-statistics yes;&lt;br /&gt;
&lt;br /&gt;
	dump-file &amp;quot;/var/named/named.dump&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
	// If there is a firewall between you and nameservers you want&lt;br /&gt;
	// to talk to, you might need to uncomment the query-source&lt;br /&gt;
	// directive below.  Previous versions of BIND always asked&lt;br /&gt;
	// questions using port 53, but BIND 8.1 and later use an unprivileged&lt;br /&gt;
	// port by default.&lt;br /&gt;
	// query-source address * port 53;&lt;br /&gt;
&lt;br /&gt;
	// If your ISP provided one or more IP addresses for stable &lt;br /&gt;
	// nameservers, you probably want to use them as forwarders.  &lt;br /&gt;
	// Uncomment the following block, and insert the addresses replacing &lt;br /&gt;
	// the all-0&#039;s placeholder.&lt;br /&gt;
&lt;br /&gt;
	// The forwarders option tells BIND to not use iterative queries itself &lt;br /&gt;
	// for information it doesn’t already know about but to forward a &lt;br /&gt;
	// recursive query to the name servers specified instead.&lt;br /&gt;
	include &amp;quot;/etc/bind/named.conf.forwarders&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
	// conform to RFC1035&lt;br /&gt;
	auth-nxdomain no;&lt;br /&gt;
&lt;br /&gt;
	// on a multi-homed host, you might want to tell named&lt;br /&gt;
	// to listen for queries only on certain interfaces&lt;br /&gt;
	listen-on-v6 { any; };&lt;br /&gt;
	listen-on { &amp;quot;internal-net&amp;quot;; };&lt;br /&gt;
&lt;br /&gt;
	// to allow only specific hosts to use the DNS server:&lt;br /&gt;
	allow-query { &amp;quot;internal-net&amp;quot;; };&lt;br /&gt;
&lt;br /&gt;
	// sets BIND’s default behaviour to refuse all zone transfers. &lt;br /&gt;
	// Without setting this option, anyone can transfer any zone.&lt;br /&gt;
	allow-transfer { none; };&lt;br /&gt;
&lt;br /&gt;
	// do not generate notify messages for all zones on a restart.&lt;br /&gt;
	// override for authorative zones&lt;br /&gt;
	notify no;&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/logging.conf===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
logging {&lt;br /&gt;
&lt;br /&gt;
	channel default_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/default.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel general_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/general.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel database_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/database.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel security_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/security.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel config_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/config.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel resolver_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/resolver.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel xfer-in_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/xfer-in.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel xfer-out_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/xfer-out.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel notify_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/notify.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel client_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/client.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel unmatched_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/unmatched.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel queries_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/queries.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel network_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/network.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel update_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/update.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel dispatch_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/dispatch.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel dnssec_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/dnssec.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel lame-servers_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/lame-servers.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
	category lame-servers {&lt;br /&gt;
		lame-servers_file;&lt;br /&gt;
		};&lt;br /&gt;
	category dnssec {&lt;br /&gt;
		dnssec_file;&lt;br /&gt;
		};&lt;br /&gt;
	category dispatch {&lt;br /&gt;
		dispatch_file;&lt;br /&gt;
		};&lt;br /&gt;
	category update {&lt;br /&gt;
		update_file;&lt;br /&gt;
		};&lt;br /&gt;
	category network {&lt;br /&gt;
		network_file;&lt;br /&gt;
		};&lt;br /&gt;
	category queries {&lt;br /&gt;
		queries_file;&lt;br /&gt;
		};&lt;br /&gt;
	category unmatched {&lt;br /&gt;
		unmatched_file;&lt;br /&gt;
		};&lt;br /&gt;
	category client {&lt;br /&gt;
		client_file;&lt;br /&gt;
		};&lt;br /&gt;
	category notify {&lt;br /&gt;
		notify_file;&lt;br /&gt;
		};&lt;br /&gt;
	category xfer-out {&lt;br /&gt;
		xfer-out_file;&lt;br /&gt;
		};&lt;br /&gt;
	category xfer-in {&lt;br /&gt;
		xfer-in_file;&lt;br /&gt;
		};&lt;br /&gt;
	category resolver {&lt;br /&gt;
		resolver_file;&lt;br /&gt;
		};&lt;br /&gt;
	category config {&lt;br /&gt;
		config_file;&lt;br /&gt;
		};&lt;br /&gt;
	category security {&lt;br /&gt;
		security_file;&lt;br /&gt;
		};&lt;br /&gt;
	category database {&lt;br /&gt;
		database_file;&lt;br /&gt;
		};&lt;br /&gt;
	category general {&lt;br /&gt;
		general_file;&lt;br /&gt;
		};&lt;br /&gt;
	category default {&lt;br /&gt;
		default_file;&lt;br /&gt;
		};&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/rndc.conf===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
options {&lt;br /&gt;
	default-server  localhost;&lt;br /&gt;
	default-key     &amp;quot;rndc-key&amp;quot;;&lt;br /&gt;
	default-port 953;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
server localhost {&lt;br /&gt;
	key     &amp;quot;rndc-key&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
key &amp;quot;rndc-key&amp;quot; {&lt;br /&gt;
	algorithm       hmac-md5;&lt;br /&gt;
	secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/rndc.key===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
key &amp;quot;rndc-key&amp;quot; {&lt;br /&gt;
        algorithm	hmac-md5;&lt;br /&gt;
        secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
key &amp;quot;linuxmce-dhcp&amp;quot; {&lt;br /&gt;
        algorithm	hmac-md5;&lt;br /&gt;
        secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
key &amp;quot;linuxmce-ns2&amp;quot; {&lt;br /&gt;
        algorithm	hmac-md5;&lt;br /&gt;
        secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/db.wright.local.zone===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
;&lt;br /&gt;
; BIND data file for wright.local&lt;br /&gt;
; ref. http://www.redhat.com/docs/manuals/linux/RHL-9-Manual/ref-guide/s1-bind-zone.html&lt;br /&gt;
;&lt;br /&gt;
$TTL 86400 ; time to live : 86400s = 1 day&lt;br /&gt;
; Start Of Authority record, proclaims important authoritative information &lt;br /&gt;
; about a namespace to the nameserver.&lt;br /&gt;
@               IN SOA  dcerouter.wright.local        roy@wright.org (&lt;br /&gt;
                2008013101      ;serial (YYYYMMDDNN where N = 01,02,03,...)&lt;br /&gt;
                10800           ;refresh (3 hours)&lt;br /&gt;
                7200            ;retry (2 hours)&lt;br /&gt;
                36000000        ;expire (10,000 hours = 416 2/3 days)&lt;br /&gt;
                86400)          ;default minimum ttl&lt;br /&gt;
;&lt;br /&gt;
; NameServer record, which announces the authoritative nameservers for a particular zone.&lt;br /&gt;
;&lt;br /&gt;
                IN NS   dcerouter.wright.local.&lt;br /&gt;
;&lt;br /&gt;
; Address records specify an IP address to assign to a name&lt;br /&gt;
;&lt;br /&gt;
dcerouter       IN A            192.168.80.1&lt;br /&gt;
dad-kubuntu     IN A            192.168.80.21&lt;br /&gt;
royw-gentoo	IN A		192.168.80.20&lt;br /&gt;
;&lt;br /&gt;
; Canonical name records, maps one name to another. &lt;br /&gt;
;&lt;br /&gt;
linuxmce        IN CNAME        dcerouter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/db.wright.local.rev===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
;&lt;br /&gt;
; BIND reverse data file for wright.local&lt;br /&gt;
; ref. http://www.redhat.com/docs/manuals/linux/RHL-9-Manual/ref-guide/s1-bind-zone.html&lt;br /&gt;
;&lt;br /&gt;
$ORIGIN 80.168.192.in-addr.arpa.&lt;br /&gt;
$TTL 86400 ; time to live : 86400s = 1 day&lt;br /&gt;
; Start Of Authority record, proclaims important authoritative information &lt;br /&gt;
; about a namespace to the nameserver.&lt;br /&gt;
@               IN SOA  dcerouter.wright.local        roy@wright.org (&lt;br /&gt;
                2008013101      ;serial (YYYYMMDDNN where N = 01,02,03,...)&lt;br /&gt;
                10800           ;refresh (3 hours)&lt;br /&gt;
                7200            ;retry (2 hours)&lt;br /&gt;
                36000000        ;expire (10,000 hours = 416 2/3 days)&lt;br /&gt;
                86400)          ;default minimum ttl&lt;br /&gt;
;&lt;br /&gt;
; NameServer record, which announces the authoritative nameservers for a particular zone.&lt;br /&gt;
;&lt;br /&gt;
                IN NS   dcerouter.wright.local.&lt;br /&gt;
;&lt;br /&gt;
; PTR — PoinTeR record, designed to point to another part of the namespace.&lt;br /&gt;
;&lt;br /&gt;
1               IN PTR  dcerouter.wright.local.&lt;br /&gt;
21              IN PTR  dad-kubuntu.wright.local.&lt;br /&gt;
20		IN PTR	royw-gentoo.wright.local.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/dhcp3/dhcpd.conf===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
option domain-name-servers 192.168.80.1;&lt;br /&gt;
authoritative;&lt;br /&gt;
&lt;br /&gt;
option routers 192.168.80.1;&lt;br /&gt;
option subnet-mask 255.255.255.0;&lt;br /&gt;
&lt;br /&gt;
# lease IPs for 1 day, maximum 1 week&lt;br /&gt;
default-lease-time 86400;&lt;br /&gt;
max-lease-time 604800;&lt;br /&gt;
&lt;br /&gt;
# dynamic DNS updates&lt;br /&gt;
ddns-updates on;&lt;br /&gt;
ddns-update-style interim;&lt;br /&gt;
ddns-domainname &amp;quot;wright.local.&amp;quot;;&lt;br /&gt;
ddns-rev-domainname &amp;quot;in-addr.arpa.&amp;quot;;&lt;br /&gt;
ddns-ttl 14400;&lt;br /&gt;
&lt;br /&gt;
# don&#039;t let clients modify their own A records&lt;br /&gt;
ignore client-updates;&lt;br /&gt;
&lt;br /&gt;
key &amp;quot;linuxmce-dhcp&amp;quot; {&lt;br /&gt;
	algorithm       hmac-md5;&lt;br /&gt;
	secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
zone wright.local {&lt;br /&gt;
	primary 192.168.80.1;&lt;br /&gt;
	key &amp;quot;linuxmce-dhcp&amp;quot;;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
zone 80.168.192.in-addr.arpa {&lt;br /&gt;
	primary 192.168.80.1;&lt;br /&gt;
	key &amp;quot;linuxmce-dhcp&amp;quot;;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
option space pxelinux;&lt;br /&gt;
option pxelinux.magic code 208 = string;&lt;br /&gt;
option pxelinux.configfile code 209 = text;&lt;br /&gt;
option pxelinux.pathprefix code 210 = text;&lt;br /&gt;
option pxelinux.reboottime code 211 = unsigned integer 32;&lt;br /&gt;
&lt;br /&gt;
subnet 192.168.80.0 netmask 255.255.255.0 {&lt;br /&gt;
	next-server 192.168.80.1;&lt;br /&gt;
	filename &amp;quot;/tftpboot/pxelinux.0&amp;quot;;&lt;br /&gt;
	option pxelinux.reboottime = 30;&lt;br /&gt;
&lt;br /&gt;
	option domain-name &amp;quot;wright.local&amp;quot;;&lt;br /&gt;
	option domain-name-servers 192.168.80.1;&lt;br /&gt;
	option routers 192.168.80.1;&lt;br /&gt;
&lt;br /&gt;
	default-lease-time 86400;&lt;br /&gt;
	max-lease-time 604800;&lt;br /&gt;
	pool {&lt;br /&gt;
		 allow unknown-clients;&lt;br /&gt;
		 range 192.168.80.129 192.168.80.254; &lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
# PXE booting machines&lt;br /&gt;
group {&lt;br /&gt;
	next-server 192.168.80.1;&lt;br /&gt;
	filename &amp;quot;/tftpboot/pxelinux.0&amp;quot;;&lt;br /&gt;
	option pxelinux.reboottime = 30;&lt;br /&gt;
&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
# regular machines&lt;br /&gt;
group {&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
# CORE (1) has bad mac address: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/resolv.conf===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
domain wright.local&lt;br /&gt;
nameserver localhost&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Juanfe</name></author>
	</entry>
	<entry>
		<id>http://wiki.linuxmce.org/index.php?title=How_to_setup_Local_Authoritative_DNS&amp;diff=15511</id>
		<title>How to setup Local Authoritative DNS</title>
		<link rel="alternate" type="text/html" href="http://wiki.linuxmce.org/index.php?title=How_to_setup_Local_Authoritative_DNS&amp;diff=15511"/>
		<updated>2008-09-05T22:29:01Z</updated>

		<summary type="html">&lt;p&gt;Juanfe: /* Installation */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[category: Tutorials]]&lt;br /&gt;
=How to setup Local Authoritative DNS=&lt;br /&gt;
&lt;br /&gt;
I was wanting an authoritative name server for my local intranet.  I also wanted any dynamic IP&#039;s to be visible to the name server.  The name server included with linuxmce is configured as a recursive name server.  Here&#039;s the changes I did to configure my core&#039;s name server to be authoritative and support dynamic IPs.  Note, the machines on my intranet are private, i.e., not known to the outside world.&lt;br /&gt;
&lt;br /&gt;
  3 Feb 2008 - Developed and tested on LinuxMCE 0710 Beta 3 amd64.&lt;br /&gt;
&lt;br /&gt;
I named my intranet &amp;quot;wright.local&amp;quot;.  Using a &amp;quot;local&amp;quot; top level domain (TLD) is recommended for private intranets.  Some may prefer to use &amp;quot;lan&amp;quot;.  You do not want to use any of the standard TLDs like &amp;quot;com&amp;quot;, &amp;quot;net&amp;quot;, &amp;quot;org&amp;quot;,...&lt;br /&gt;
&lt;br /&gt;
I used the core&#039;s default intranet addresses, 192.168.80.0/24 with the core at 192.168.80.1.&lt;br /&gt;
&lt;br /&gt;
I&#039;ve attempted to verbosely document each config file. :)&lt;br /&gt;
&lt;br /&gt;
The directions for adapting the config files are included in the named.conf file.&lt;br /&gt;
&lt;br /&gt;
==Installation==&lt;br /&gt;
&lt;br /&gt;
If you want to try this, I would suggest building the config in new directories then swapping with the originals when you are ready (I had a little mess when my core hung and I had to restart with only half the configs ready) :)&lt;br /&gt;
&lt;br /&gt;
So start with creating two directories:&lt;br /&gt;
&lt;br /&gt;
  sudo mkdir /etc/bind.new&lt;br /&gt;
  sudo mkdir /etc/dhcp3.new&lt;br /&gt;
&lt;br /&gt;
Now copy the contents of the original directories:&lt;br /&gt;
&lt;br /&gt;
  sudo cp -arp /etc/bind/* /etc/bind.new&lt;br /&gt;
  sudo cp -arp /etc/dhcp3/* /etc/dhcp3.new&lt;br /&gt;
&lt;br /&gt;
Also create a new resolve.conf file:&lt;br /&gt;
&lt;br /&gt;
  sudo touch /etc/resolv.conf.new&lt;br /&gt;
&lt;br /&gt;
You will be creating or editing the following config files in these new directories:&lt;br /&gt;
&lt;br /&gt;
  /etc/bind.new/named.conf&lt;br /&gt;
  /etc/bind.new/named.conf.options&lt;br /&gt;
  /etc/bind.new/logging.conf&lt;br /&gt;
  /etc/bind.new/rndc.conf&lt;br /&gt;
  /etc/bind.new/rndc.key&lt;br /&gt;
  /etc/bind.new/db.wright.local.zone&lt;br /&gt;
  /etc/bind.new/db.wright.local.rev&lt;br /&gt;
  /etc/dhcp3.new/dhcpd.conf&lt;br /&gt;
  /etc/resolv.conf&lt;br /&gt;
&lt;br /&gt;
The full text of the files you will be editing is at the foot of this page. The original author named his network &amp;quot;wright&amp;quot;; you should replace all instances of &amp;quot;wright&amp;quot; with the name of your network.&lt;br /&gt;
&lt;br /&gt;
==Notes on Editing Files==&lt;br /&gt;
&lt;br /&gt;
===rndc.key and dhcpd.conf key values=== &lt;br /&gt;
&lt;br /&gt;
To create a key for use in rndc.key and dhcpd.conf:&lt;br /&gt;
&lt;br /&gt;
  sudo dnssec-keygen -a HMAC-MD5 -b 256 -n user rndc&lt;br /&gt;
&lt;br /&gt;
Now get the key from the private file:&lt;br /&gt;
&lt;br /&gt;
  sudo cat Krndc.*.private&lt;br /&gt;
  Private-key-format: v1.2&lt;br /&gt;
  Algorithm: 157 (HMAC_MD5)&lt;br /&gt;
  Key: 3+GnSWV5FKxcUu57k7QFxbpvv/xr4fXj2wBVGtdGifI=&lt;br /&gt;
  Bits: AAA=&lt;br /&gt;
&lt;br /&gt;
Now cut the key which is to the right of &amp;quot;Key: &amp;quot; and paste where needed (replace &amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot; with the key in the config files).  So an example using the above key would look like:&lt;br /&gt;
&lt;br /&gt;
  key &amp;quot;linuxmce-dhcp&amp;quot; {&lt;br /&gt;
        algorithm	hmac-md5;&lt;br /&gt;
        secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
  };&lt;br /&gt;
&lt;br /&gt;
becomes:&lt;br /&gt;
&lt;br /&gt;
  key &amp;quot;linuxmce-dhcp&amp;quot; {&lt;br /&gt;
        algorithm	hmac-md5;&lt;br /&gt;
        secret		&amp;quot;3+GnSWV5FKxcUu57k7QFxbpvv/xr4fXj2wBVGtdGifI=&amp;quot;;&lt;br /&gt;
  };&lt;br /&gt;
&lt;br /&gt;
===Check directory ownership===&lt;br /&gt;
Make the logging directory:&lt;br /&gt;
&lt;br /&gt;
  sudo mkdir /var/log/named&lt;br /&gt;
  sudo chown bind:bind /var/log/named&lt;br /&gt;
  sudo chmod 755 /var/log/named&lt;br /&gt;
&lt;br /&gt;
You probably ought to check and change the defaultdomain:&lt;br /&gt;
&lt;br /&gt;
  domainname&lt;br /&gt;
&lt;br /&gt;
will probably show&lt;br /&gt;
&lt;br /&gt;
  pluto&lt;br /&gt;
&lt;br /&gt;
if so, then set it by:&lt;br /&gt;
  sudo domainname yourdomain.local&lt;br /&gt;
&lt;br /&gt;
where &amp;quot;yourdomain.local&amp;quot; is your domain.  :-)&lt;br /&gt;
&lt;br /&gt;
===File Permissions===&lt;br /&gt;
Change all the file permissions per instructions in named.conf. &lt;br /&gt;
&lt;br /&gt;
Double check everything.   Roll Eyes&lt;br /&gt;
&lt;br /&gt;
==Wrapping up==&lt;br /&gt;
When and if you are feeling lucky, rename the original directories and then rename the new directories to take their place:&lt;br /&gt;
&lt;br /&gt;
  sudo mv /etc/bind /etc/bind.original&lt;br /&gt;
  sudo mv /etc/bind.new /etc/bind&lt;br /&gt;
  sudo mv /etc/dhcp3 /etc/dhcp3.original&lt;br /&gt;
  sudo mv /etc/dhcp3.new /etc/dhcp3&lt;br /&gt;
  sudo mv /etc/resolve.conf /etc/resolve.conf.original&lt;br /&gt;
  sudo mv /etc/resolve.conf.new /etc/resolve.conf&lt;br /&gt;
&lt;br /&gt;
Finally restart the bind and dhcpd services:&lt;br /&gt;
&lt;br /&gt;
  sudo rndc reload&lt;br /&gt;
  sudo /etc/init.d/dhcp3-server restart&lt;br /&gt;
&lt;br /&gt;
Check the syslog for any errors:&lt;br /&gt;
&lt;br /&gt;
  grep named /var/log/syslog&lt;br /&gt;
  grep dhcpd /var/log/syslog&lt;br /&gt;
&lt;br /&gt;
==Config Files==&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/named.conf===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
// This is the primary configuration file for the BIND DNS server named.&lt;br /&gt;
//&lt;br /&gt;
// This configuration supports an authoritative local zone (wright.local on&lt;br /&gt;
// 192.168.80.0/24) and allows DHCP to update the local zone.  &lt;br /&gt;
// To customize to your setup:&lt;br /&gt;
// 1) replace &amp;quot;wright.local&amp;quot; with your internal domain name.&lt;br /&gt;
// 2) edit db.wright.local.zone and db.wright.local.rev and replace&lt;br /&gt;
//    my static names/addresses with your network&#039;s static names/addresses.&lt;br /&gt;
//    Make sure to increment the serial number of any file edited.  &lt;br /&gt;
//    Note, format of serial number is:  YYYYMMDDNN where YYYY is year, &lt;br /&gt;
//    MM is month, DD is day, NN is update number for that day (i.e., 01, &lt;br /&gt;
//    02, 03,...)&lt;br /&gt;
// 3) rename db.wright.local.zone to match your domain name.&lt;br /&gt;
// 4) rename db.wright.local.rev to match your domain name.&lt;br /&gt;
// 5) If you changed the internal network IP from the LinuxMCE default of&lt;br /&gt;
//    192.168.80.0/24, then replace &amp;quot;192.168.80&amp;quot; with your network&lt;br /&gt;
//    ip and replace it&#039;s reverse &amp;quot;80.168.192&amp;quot; wity your network ip&#039;s&lt;br /&gt;
//    reverse.&lt;br /&gt;
//&lt;br /&gt;
// Please read /usr/share/doc/bind9/README.Debian.gz for information on the &lt;br /&gt;
// structure of BIND configuration files in Debian, *BEFORE* you customize &lt;br /&gt;
// this configuration file.&lt;br /&gt;
//&lt;br /&gt;
// If you are just adding zones, please do that in /etc/bind/named.conf.local&lt;br /&gt;
//&lt;br /&gt;
// references:&lt;br /&gt;
// http://www.arda.homeunix.net/dnssetup.html&lt;br /&gt;
// http://www.madboa.com/geek/soho-bind/&lt;br /&gt;
//&lt;br /&gt;
// notes:&lt;br /&gt;
// 1) The following command should be ran about twice a year to keep&lt;br /&gt;
//    the root servers current:&lt;br /&gt;
//      dig @a.root-servers.net . ns &amp;gt; /etc/bin/db.root&lt;br /&gt;
//    Root name servers don’t change very often so updating this file more &lt;br /&gt;
//    than twice a year is probably overkill. Frequent updates also put undo &lt;br /&gt;
//    load on the root name servers; they have enough to do as it is.&lt;br /&gt;
//&lt;br /&gt;
// 2) File permissions:&lt;br /&gt;
//    /etc/bind/named.conf   root:root   644&lt;br /&gt;
//    /etc/bind/rndc.key     root:bind   640&lt;br /&gt;
//    /etc/bind/rndc.conf    root:root   600&lt;br /&gt;
//    /etc/resolv.conf       root:root   644&lt;br /&gt;
//    /etc/bind              root:bind   775, chmod g+s =&amp;gt; drwxrwsr-x&lt;br /&gt;
//    /etc/dhcp3             root:root   755&lt;br /&gt;
//    /etc/dhcp3/dhcpd.conf  root:root   644&lt;br /&gt;
//&lt;br /&gt;
// Manually Updating Zone Files&lt;br /&gt;
// 1. Use rndc to stop BIND.&lt;br /&gt;
//      sudo rndc stop&lt;br /&gt;
// 2. Remove any .jnl files from the zone file directory.&lt;br /&gt;
//      sudo rm /etc/bind/*.jnl&lt;br /&gt;
// 3. Edit the zone files as necessary. Make sure to increment the serial &lt;br /&gt;
//    number of any file edited.  Note, format of serial number is:&lt;br /&gt;
//    YYYYMMDDNN where YYYY is year, MM is month, DD is day, NN is update&lt;br /&gt;
//    number for that day (i.e., 01, 02, 03,...)&lt;br /&gt;
// 4. Start BIND using its startup script. &lt;br /&gt;
//      sudo /etc/init.d/bind9 start&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
// secret must be the same as in /etc/bind/rndc.conf&lt;br /&gt;
include &amp;quot;/etc/bind/rndc.key&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
// access control list used to limit queries to local net&lt;br /&gt;
acl &amp;quot;internal-net&amp;quot; { 192.168.80/24; 127.0.0.1; };&lt;br /&gt;
&lt;br /&gt;
controls {&lt;br /&gt;
    inet 127.0.0.1 allow { any; } keys { &amp;quot;rndc-key&amp;quot;; };&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
include &amp;quot;/etc/bind/named.conf.options&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
// The single dot (.) is the root of all DNS namespace, so&lt;br /&gt;
// this zone tells named where to start looking for any&lt;br /&gt;
// name on the Internet&lt;br /&gt;
zone &amp;quot;.&amp;quot; IN {&lt;br /&gt;
	type hint;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.root&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
// local intranet zones and reverse zones&lt;br /&gt;
// intranet is wright.local and 192.168.80.0/24&lt;br /&gt;
// the DHCP servers is on linuxmce-dhcp&lt;br /&gt;
// an optional second nameserver would be on linuxmce-ns2&lt;br /&gt;
	&lt;br /&gt;
zone &amp;quot;wright.local&amp;quot; IN {&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.wright.local.zone&amp;quot;;&lt;br /&gt;
	// both allow-update and update-policy can enable DHCP updates,&lt;br /&gt;
	// but update-policy allows more control over what kinds of &lt;br /&gt;
	// updates DHCP can perform on a zone.&lt;br /&gt;
	// allow-update { none; };&lt;br /&gt;
	update-policy { grant linuxmce-dhcp subdomain wright.local. A TXT; };&lt;br /&gt;
	// allow-transfer { key &amp;quot;linuxmce-ns2&amp;quot;; };&lt;br /&gt;
	// notify on zone transfers&lt;br /&gt;
	notify yes;&lt;br /&gt;
};&lt;br /&gt;
	&lt;br /&gt;
zone &amp;quot;80.168.192.in-addr.arpa&amp;quot; IN {&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.wright.local.rev&amp;quot;;&lt;br /&gt;
	// allow-update { none; };&lt;br /&gt;
	update-policy { grant linuxmce-dhcp subdomain 80.168.192.in-addr.arpa. PTR TXT; };&lt;br /&gt;
	// allow-transfer { key &amp;quot;linuxmce-ns2&amp;quot;; };&lt;br /&gt;
	notify yes;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
// be authoritative for the localhost forward and reverse zones, and for&lt;br /&gt;
// broadcast zones as per RFC 1912 (http://www.ietf.org/rfc/rfc1912.txt)&lt;br /&gt;
&lt;br /&gt;
// Where the localhost hostname is defined&lt;br /&gt;
zone &amp;quot;localhost&amp;quot; IN {&lt;br /&gt;
	// a master type means that this server needn&#039;t look&lt;br /&gt;
	// anywhere else for information; the localhost buck&lt;br /&gt;
	// stops here.&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.local&amp;quot;;&lt;br /&gt;
	// don&#039;t allow dynamic DNS clients to update info&lt;br /&gt;
	// about the localhost zone&lt;br /&gt;
	allow-update { none; };&lt;br /&gt;
};&lt;br /&gt;
	&lt;br /&gt;
// Where the 127.0.0.0 network is defined&lt;br /&gt;
zone &amp;quot;127.in-addr.arpa&amp;quot; IN {&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.127&amp;quot;;&lt;br /&gt;
	allow-update { none; };&lt;br /&gt;
};&lt;br /&gt;
	&lt;br /&gt;
zone &amp;quot;0.in-addr.arpa&amp;quot; IN {&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.0&amp;quot;;&lt;br /&gt;
	allow-update { none; };&lt;br /&gt;
};&lt;br /&gt;
	&lt;br /&gt;
zone &amp;quot;255.in-addr.arpa&amp;quot; IN {&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.255&amp;quot;;&lt;br /&gt;
	allow-update { none; };&lt;br /&gt;
};&lt;br /&gt;
	&lt;br /&gt;
&lt;br /&gt;
// Include logging config file&lt;br /&gt;
include &amp;quot;/etc/bind/logging.conf&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
// zone &amp;quot;com&amp;quot; { type delegation-only; };&lt;br /&gt;
// zone &amp;quot;net&amp;quot; { type delegation-only; };&lt;br /&gt;
&lt;br /&gt;
// From the release notes:&lt;br /&gt;
//  Because many of our users are uncomfortable receiving undelegated answers&lt;br /&gt;
//  from root or top level domains, other than a few for whom that behaviour&lt;br /&gt;
//  has been trusted and expected for quite some length of time, we have now&lt;br /&gt;
//  introduced the &amp;quot;root-delegations-only&amp;quot; feature which applies delegation-only&lt;br /&gt;
//  logic to all top level domains, and to the root domain.  An exception list&lt;br /&gt;
//  should be specified, including &amp;quot;MUSEUM&amp;quot; and &amp;quot;DE&amp;quot;, and any other top level&lt;br /&gt;
//  domains from whom undelegated responses are expected and trusted.&lt;br /&gt;
// root-delegation-only exclude { &amp;quot;DE&amp;quot;; &amp;quot;MUSEUM&amp;quot;; };&lt;br /&gt;
&lt;br /&gt;
include &amp;quot;/etc/bind/named.conf.local&amp;quot;;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/named.conf.options===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
options {&lt;br /&gt;
	// tell named where to find files mentioned below&lt;br /&gt;
	directory &amp;quot;/var/cache/bind&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
	// file that contains the process id when bind is running&lt;br /&gt;
	pid-file &amp;quot;/var/run/bind/run/named.pid&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
	// enable statistics&lt;br /&gt;
	statistics-file &amp;quot;/var/named/named.stats&amp;quot;;&lt;br /&gt;
	zone-statistics yes;&lt;br /&gt;
&lt;br /&gt;
	dump-file &amp;quot;/var/named/named.dump&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
	// If there is a firewall between you and nameservers you want&lt;br /&gt;
	// to talk to, you might need to uncomment the query-source&lt;br /&gt;
	// directive below.  Previous versions of BIND always asked&lt;br /&gt;
	// questions using port 53, but BIND 8.1 and later use an unprivileged&lt;br /&gt;
	// port by default.&lt;br /&gt;
	// query-source address * port 53;&lt;br /&gt;
&lt;br /&gt;
	// If your ISP provided one or more IP addresses for stable &lt;br /&gt;
	// nameservers, you probably want to use them as forwarders.  &lt;br /&gt;
	// Uncomment the following block, and insert the addresses replacing &lt;br /&gt;
	// the all-0&#039;s placeholder.&lt;br /&gt;
&lt;br /&gt;
	// The forwarders option tells BIND to not use iterative queries itself &lt;br /&gt;
	// for information it doesn’t already know about but to forward a &lt;br /&gt;
	// recursive query to the name servers specified instead.&lt;br /&gt;
	include &amp;quot;/etc/bind/named.conf.forwarders&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
	// conform to RFC1035&lt;br /&gt;
	auth-nxdomain no;&lt;br /&gt;
&lt;br /&gt;
	// on a multi-homed host, you might want to tell named&lt;br /&gt;
	// to listen for queries only on certain interfaces&lt;br /&gt;
	listen-on-v6 { any; };&lt;br /&gt;
	listen-on { &amp;quot;internal-net&amp;quot;; };&lt;br /&gt;
&lt;br /&gt;
	// to allow only specific hosts to use the DNS server:&lt;br /&gt;
	allow-query { &amp;quot;internal-net&amp;quot;; };&lt;br /&gt;
&lt;br /&gt;
	// sets BIND’s default behaviour to refuse all zone transfers. &lt;br /&gt;
	// Without setting this option, anyone can transfer any zone.&lt;br /&gt;
	allow-transfer { none; };&lt;br /&gt;
&lt;br /&gt;
	// do not generate notify messages for all zones on a restart.&lt;br /&gt;
	// override for authorative zones&lt;br /&gt;
	notify no;&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/logging.conf===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
logging {&lt;br /&gt;
&lt;br /&gt;
	channel default_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/default.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel general_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/general.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel database_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/database.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel security_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/security.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel config_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/config.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel resolver_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/resolver.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel xfer-in_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/xfer-in.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel xfer-out_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/xfer-out.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel notify_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/notify.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel client_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/client.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel unmatched_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/unmatched.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel queries_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/queries.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel network_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/network.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel update_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/update.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel dispatch_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/dispatch.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel dnssec_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/dnssec.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel lame-servers_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/lame-servers.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
	category lame-servers {&lt;br /&gt;
		lame-servers_file;&lt;br /&gt;
		};&lt;br /&gt;
	category dnssec {&lt;br /&gt;
		dnssec_file;&lt;br /&gt;
		};&lt;br /&gt;
	category dispatch {&lt;br /&gt;
		dispatch_file;&lt;br /&gt;
		};&lt;br /&gt;
	category update {&lt;br /&gt;
		update_file;&lt;br /&gt;
		};&lt;br /&gt;
	category network {&lt;br /&gt;
		network_file;&lt;br /&gt;
		};&lt;br /&gt;
	category queries {&lt;br /&gt;
		queries_file;&lt;br /&gt;
		};&lt;br /&gt;
	category unmatched {&lt;br /&gt;
		unmatched_file;&lt;br /&gt;
		};&lt;br /&gt;
	category client {&lt;br /&gt;
		client_file;&lt;br /&gt;
		};&lt;br /&gt;
	category notify {&lt;br /&gt;
		notify_file;&lt;br /&gt;
		};&lt;br /&gt;
	category xfer-out {&lt;br /&gt;
		xfer-out_file;&lt;br /&gt;
		};&lt;br /&gt;
	category xfer-in {&lt;br /&gt;
		xfer-in_file;&lt;br /&gt;
		};&lt;br /&gt;
	category resolver {&lt;br /&gt;
		resolver_file;&lt;br /&gt;
		};&lt;br /&gt;
	category config {&lt;br /&gt;
		config_file;&lt;br /&gt;
		};&lt;br /&gt;
	category security {&lt;br /&gt;
		security_file;&lt;br /&gt;
		};&lt;br /&gt;
	category database {&lt;br /&gt;
		database_file;&lt;br /&gt;
		};&lt;br /&gt;
	category general {&lt;br /&gt;
		general_file;&lt;br /&gt;
		};&lt;br /&gt;
	category default {&lt;br /&gt;
		default_file;&lt;br /&gt;
		};&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/rndc.conf===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
options {&lt;br /&gt;
	default-server  localhost;&lt;br /&gt;
	default-key     &amp;quot;rndc-key&amp;quot;;&lt;br /&gt;
	default-port 953;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
server localhost {&lt;br /&gt;
	key     &amp;quot;rndc-key&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
key &amp;quot;rndc-key&amp;quot; {&lt;br /&gt;
	algorithm       hmac-md5;&lt;br /&gt;
	secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/rndc.key===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
key &amp;quot;rndc-key&amp;quot; {&lt;br /&gt;
        algorithm	hmac-md5;&lt;br /&gt;
        secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
key &amp;quot;linuxmce-dhcp&amp;quot; {&lt;br /&gt;
        algorithm	hmac-md5;&lt;br /&gt;
        secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
key &amp;quot;linuxmce-ns2&amp;quot; {&lt;br /&gt;
        algorithm	hmac-md5;&lt;br /&gt;
        secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/db.wright.local.zone===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
;&lt;br /&gt;
; BIND data file for wright.local&lt;br /&gt;
; ref. http://www.redhat.com/docs/manuals/linux/RHL-9-Manual/ref-guide/s1-bind-zone.html&lt;br /&gt;
;&lt;br /&gt;
$TTL 86400 ; time to live : 86400s = 1 day&lt;br /&gt;
; Start Of Authority record, proclaims important authoritative information &lt;br /&gt;
; about a namespace to the nameserver.&lt;br /&gt;
@               IN SOA  dcerouter.wright.local        roy@wright.org (&lt;br /&gt;
                2008013101      ;serial (YYYYMMDDNN where N = 01,02,03,...)&lt;br /&gt;
                10800           ;refresh (3 hours)&lt;br /&gt;
                7200            ;retry (2 hours)&lt;br /&gt;
                36000000        ;expire (10,000 hours = 416 2/3 days)&lt;br /&gt;
                86400)          ;default minimum ttl&lt;br /&gt;
;&lt;br /&gt;
; NameServer record, which announces the authoritative nameservers for a particular zone.&lt;br /&gt;
;&lt;br /&gt;
                IN NS   dcerouter.wright.local.&lt;br /&gt;
;&lt;br /&gt;
; Address records specify an IP address to assign to a name&lt;br /&gt;
;&lt;br /&gt;
dcerouter       IN A            192.168.80.1&lt;br /&gt;
dad-kubuntu     IN A            192.168.80.21&lt;br /&gt;
royw-gentoo	IN A		192.168.80.20&lt;br /&gt;
;&lt;br /&gt;
; Canonical name records, maps one name to another. &lt;br /&gt;
;&lt;br /&gt;
linuxmce        IN CNAME        dcerouter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/db.wright.local.rev===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
;&lt;br /&gt;
; BIND reverse data file for wright.local&lt;br /&gt;
; ref. http://www.redhat.com/docs/manuals/linux/RHL-9-Manual/ref-guide/s1-bind-zone.html&lt;br /&gt;
;&lt;br /&gt;
$ORIGIN 80.168.192.in-addr.arpa.&lt;br /&gt;
$TTL 86400 ; time to live : 86400s = 1 day&lt;br /&gt;
; Start Of Authority record, proclaims important authoritative information &lt;br /&gt;
; about a namespace to the nameserver.&lt;br /&gt;
@               IN SOA  dcerouter.wright.local        roy@wright.org (&lt;br /&gt;
                2008013101      ;serial (YYYYMMDDNN where N = 01,02,03,...)&lt;br /&gt;
                10800           ;refresh (3 hours)&lt;br /&gt;
                7200            ;retry (2 hours)&lt;br /&gt;
                36000000        ;expire (10,000 hours = 416 2/3 days)&lt;br /&gt;
                86400)          ;default minimum ttl&lt;br /&gt;
;&lt;br /&gt;
; NameServer record, which announces the authoritative nameservers for a particular zone.&lt;br /&gt;
;&lt;br /&gt;
                IN NS   dcerouter.wright.local.&lt;br /&gt;
;&lt;br /&gt;
; PTR — PoinTeR record, designed to point to another part of the namespace.&lt;br /&gt;
;&lt;br /&gt;
1               IN PTR  dcerouter.wright.local.&lt;br /&gt;
21              IN PTR  dad-kubuntu.wright.local.&lt;br /&gt;
20		IN PTR	royw-gentoo.wright.local.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/dhcp3/dhcpd.conf===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
option domain-name-servers 192.168.80.1;&lt;br /&gt;
authoritative;&lt;br /&gt;
&lt;br /&gt;
option routers 192.168.80.1;&lt;br /&gt;
option subnet-mask 255.255.255.0;&lt;br /&gt;
&lt;br /&gt;
# lease IPs for 1 day, maximum 1 week&lt;br /&gt;
default-lease-time 86400;&lt;br /&gt;
max-lease-time 604800;&lt;br /&gt;
&lt;br /&gt;
# dynamic DNS updates&lt;br /&gt;
ddns-updates on;&lt;br /&gt;
ddns-update-style interim;&lt;br /&gt;
ddns-domainname &amp;quot;wright.local.&amp;quot;;&lt;br /&gt;
ddns-rev-domainname &amp;quot;in-addr.arpa.&amp;quot;;&lt;br /&gt;
ddns-ttl 14400;&lt;br /&gt;
&lt;br /&gt;
# don&#039;t let clients modify their own A records&lt;br /&gt;
ignore client-updates;&lt;br /&gt;
&lt;br /&gt;
key &amp;quot;linuxmce-dhcp&amp;quot; {&lt;br /&gt;
	algorithm       hmac-md5;&lt;br /&gt;
	secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
zone wright.local {&lt;br /&gt;
	primary 192.168.80.1;&lt;br /&gt;
	key &amp;quot;linuxmce-dhcp&amp;quot;;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
zone 80.168.192.in-addr.arpa {&lt;br /&gt;
	primary 192.168.80.1;&lt;br /&gt;
	key &amp;quot;linuxmce-dhcp&amp;quot;;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
option space pxelinux;&lt;br /&gt;
option pxelinux.magic code 208 = string;&lt;br /&gt;
option pxelinux.configfile code 209 = text;&lt;br /&gt;
option pxelinux.pathprefix code 210 = text;&lt;br /&gt;
option pxelinux.reboottime code 211 = unsigned integer 32;&lt;br /&gt;
&lt;br /&gt;
subnet 192.168.80.0 netmask 255.255.255.0 {&lt;br /&gt;
	next-server 192.168.80.1;&lt;br /&gt;
	filename &amp;quot;/tftpboot/pxelinux.0&amp;quot;;&lt;br /&gt;
	option pxelinux.reboottime = 30;&lt;br /&gt;
&lt;br /&gt;
	option domain-name &amp;quot;wright.local&amp;quot;;&lt;br /&gt;
	option domain-name-servers 192.168.80.1;&lt;br /&gt;
	option routers 192.168.80.1;&lt;br /&gt;
&lt;br /&gt;
	default-lease-time 86400;&lt;br /&gt;
	max-lease-time 604800;&lt;br /&gt;
	pool {&lt;br /&gt;
		 allow unknown-clients;&lt;br /&gt;
		 range 192.168.80.129 192.168.80.254; &lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
# PXE booting machines&lt;br /&gt;
group {&lt;br /&gt;
	next-server 192.168.80.1;&lt;br /&gt;
	filename &amp;quot;/tftpboot/pxelinux.0&amp;quot;;&lt;br /&gt;
	option pxelinux.reboottime = 30;&lt;br /&gt;
&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
# regular machines&lt;br /&gt;
group {&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
# CORE (1) has bad mac address: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/resolv.conf===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
domain wright.local&lt;br /&gt;
nameserver localhost&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Juanfe</name></author>
	</entry>
	<entry>
		<id>http://wiki.linuxmce.org/index.php?title=How_to_setup_Local_Authoritative_DNS&amp;diff=15510</id>
		<title>How to setup Local Authoritative DNS</title>
		<link rel="alternate" type="text/html" href="http://wiki.linuxmce.org/index.php?title=How_to_setup_Local_Authoritative_DNS&amp;diff=15510"/>
		<updated>2008-09-05T22:27:35Z</updated>

		<summary type="html">&lt;p&gt;Juanfe: /* After Editing Files */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[category: Tutorials]]&lt;br /&gt;
=How to setup Local Authoritative DNS=&lt;br /&gt;
&lt;br /&gt;
I was wanting an authoritative name server for my local intranet.  I also wanted any dynamic IP&#039;s to be visible to the name server.  The name server included with linuxmce is configured as a recursive name server.  Here&#039;s the changes I did to configure my core&#039;s name server to be authoritative and support dynamic IPs.  Note, the machines on my intranet are private, i.e., not known to the outside world.&lt;br /&gt;
&lt;br /&gt;
  3 Feb 2008 - Developed and tested on LinuxMCE 0710 Beta 3 amd64.&lt;br /&gt;
&lt;br /&gt;
I named my intranet &amp;quot;wright.local&amp;quot;.  Using a &amp;quot;local&amp;quot; top level domain (TLD) is recommended for private intranets.  Some may prefer to use &amp;quot;lan&amp;quot;.  You do not want to use any of the standard TLDs like &amp;quot;com&amp;quot;, &amp;quot;net&amp;quot;, &amp;quot;org&amp;quot;,...&lt;br /&gt;
&lt;br /&gt;
I used the core&#039;s default intranet addresses, 192.168.80.0/24 with the core at 192.168.80.1.&lt;br /&gt;
&lt;br /&gt;
I&#039;ve attempted to verbosely document each config file. :)&lt;br /&gt;
&lt;br /&gt;
The directions for adapting the config files are included in the named.conf file.&lt;br /&gt;
&lt;br /&gt;
==Installation==&lt;br /&gt;
&lt;br /&gt;
If you want to try this, I would suggest building the config in new directories then swapping with the originals when you are ready (I had a little mess when my core hung and I had to restart with only half the configs ready) :)&lt;br /&gt;
&lt;br /&gt;
So start with creating two directories:&lt;br /&gt;
&lt;br /&gt;
  sudo mkdir /etc/bind.new&lt;br /&gt;
  sudo mkdir /etc/dhcp3.new&lt;br /&gt;
&lt;br /&gt;
Now copy the contents of the original directories:&lt;br /&gt;
&lt;br /&gt;
  sudo cp -arp /etc/bind/* /etc/bind.new&lt;br /&gt;
  sudo cp -arp /etc/dhcp3/* /etc/dhcp3.new&lt;br /&gt;
&lt;br /&gt;
Also create a new resolve.conf file:&lt;br /&gt;
&lt;br /&gt;
  sudo touch /etc/resolv.conf.new&lt;br /&gt;
&lt;br /&gt;
You will be creating or editing the following config files in these new directories, as described below:&lt;br /&gt;
&lt;br /&gt;
  /etc/bind.new/named.conf&lt;br /&gt;
  /etc/bind.new/named.conf.options&lt;br /&gt;
  /etc/bind.new/logging.conf&lt;br /&gt;
  /etc/bind.new/rndc.conf&lt;br /&gt;
  /etc/bind.new/rndc.key&lt;br /&gt;
  /etc/bind.new/db.yournetworkname.local.zone&lt;br /&gt;
  /etc/bind.new/db.yournetworkname.local.rev&lt;br /&gt;
  /etc/dhcp3.new/dhcpd.conf&lt;br /&gt;
  /etc/resolv.conf&lt;br /&gt;
&lt;br /&gt;
==Notes on Editing Files==&lt;br /&gt;
&lt;br /&gt;
===rndc.key and dhcpd.conf key values=== &lt;br /&gt;
&lt;br /&gt;
To create a key for use in rndc.key and dhcpd.conf:&lt;br /&gt;
&lt;br /&gt;
  sudo dnssec-keygen -a HMAC-MD5 -b 256 -n user rndc&lt;br /&gt;
&lt;br /&gt;
Now get the key from the private file:&lt;br /&gt;
&lt;br /&gt;
  sudo cat Krndc.*.private&lt;br /&gt;
  Private-key-format: v1.2&lt;br /&gt;
  Algorithm: 157 (HMAC_MD5)&lt;br /&gt;
  Key: 3+GnSWV5FKxcUu57k7QFxbpvv/xr4fXj2wBVGtdGifI=&lt;br /&gt;
  Bits: AAA=&lt;br /&gt;
&lt;br /&gt;
Now cut the key which is to the right of &amp;quot;Key: &amp;quot; and paste where needed (replace &amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot; with the key in the config files).  So an example using the above key would look like:&lt;br /&gt;
&lt;br /&gt;
  key &amp;quot;linuxmce-dhcp&amp;quot; {&lt;br /&gt;
        algorithm	hmac-md5;&lt;br /&gt;
        secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
  };&lt;br /&gt;
&lt;br /&gt;
becomes:&lt;br /&gt;
&lt;br /&gt;
  key &amp;quot;linuxmce-dhcp&amp;quot; {&lt;br /&gt;
        algorithm	hmac-md5;&lt;br /&gt;
        secret		&amp;quot;3+GnSWV5FKxcUu57k7QFxbpvv/xr4fXj2wBVGtdGifI=&amp;quot;;&lt;br /&gt;
  };&lt;br /&gt;
&lt;br /&gt;
===Check directory ownership===&lt;br /&gt;
Make the logging directory:&lt;br /&gt;
&lt;br /&gt;
  sudo mkdir /var/log/named&lt;br /&gt;
  sudo chown bind:bind /var/log/named&lt;br /&gt;
  sudo chmod 755 /var/log/named&lt;br /&gt;
&lt;br /&gt;
You probably ought to check and change the defaultdomain:&lt;br /&gt;
&lt;br /&gt;
  domainname&lt;br /&gt;
&lt;br /&gt;
will probably show&lt;br /&gt;
&lt;br /&gt;
  pluto&lt;br /&gt;
&lt;br /&gt;
if so, then set it by:&lt;br /&gt;
  sudo domainname yourdomain.local&lt;br /&gt;
&lt;br /&gt;
where &amp;quot;yourdomain.local&amp;quot; is your domain.  :-)&lt;br /&gt;
&lt;br /&gt;
===File Permissions===&lt;br /&gt;
Change all the file permissions per instructions in named.conf. &lt;br /&gt;
&lt;br /&gt;
Double check everything.   Roll Eyes&lt;br /&gt;
&lt;br /&gt;
==Wrapping up==&lt;br /&gt;
When and if you are feeling lucky, rename the original directories and then rename the new directories to take their place:&lt;br /&gt;
&lt;br /&gt;
  sudo mv /etc/bind /etc/bind.original&lt;br /&gt;
  sudo mv /etc/bind.new /etc/bind&lt;br /&gt;
  sudo mv /etc/dhcp3 /etc/dhcp3.original&lt;br /&gt;
  sudo mv /etc/dhcp3.new /etc/dhcp3&lt;br /&gt;
  sudo mv /etc/resolve.conf /etc/resolve.conf.original&lt;br /&gt;
  sudo mv /etc/resolve.conf.new /etc/resolve.conf&lt;br /&gt;
&lt;br /&gt;
Finally restart the bind and dhcpd services:&lt;br /&gt;
&lt;br /&gt;
  sudo rndc reload&lt;br /&gt;
  sudo /etc/init.d/dhcp3-server restart&lt;br /&gt;
&lt;br /&gt;
Check the syslog for any errors:&lt;br /&gt;
&lt;br /&gt;
  grep named /var/log/syslog&lt;br /&gt;
  grep dhcpd /var/log/syslog&lt;br /&gt;
&lt;br /&gt;
==Config Files==&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/named.conf===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
// This is the primary configuration file for the BIND DNS server named.&lt;br /&gt;
//&lt;br /&gt;
// This configuration supports an authoritative local zone (wright.local on&lt;br /&gt;
// 192.168.80.0/24) and allows DHCP to update the local zone.  &lt;br /&gt;
// To customize to your setup:&lt;br /&gt;
// 1) replace &amp;quot;wright.local&amp;quot; with your internal domain name.&lt;br /&gt;
// 2) edit db.wright.local.zone and db.wright.local.rev and replace&lt;br /&gt;
//    my static names/addresses with your network&#039;s static names/addresses.&lt;br /&gt;
//    Make sure to increment the serial number of any file edited.  &lt;br /&gt;
//    Note, format of serial number is:  YYYYMMDDNN where YYYY is year, &lt;br /&gt;
//    MM is month, DD is day, NN is update number for that day (i.e., 01, &lt;br /&gt;
//    02, 03,...)&lt;br /&gt;
// 3) rename db.wright.local.zone to match your domain name.&lt;br /&gt;
// 4) rename db.wright.local.rev to match your domain name.&lt;br /&gt;
// 5) If you changed the internal network IP from the LinuxMCE default of&lt;br /&gt;
//    192.168.80.0/24, then replace &amp;quot;192.168.80&amp;quot; with your network&lt;br /&gt;
//    ip and replace it&#039;s reverse &amp;quot;80.168.192&amp;quot; wity your network ip&#039;s&lt;br /&gt;
//    reverse.&lt;br /&gt;
//&lt;br /&gt;
// Please read /usr/share/doc/bind9/README.Debian.gz for information on the &lt;br /&gt;
// structure of BIND configuration files in Debian, *BEFORE* you customize &lt;br /&gt;
// this configuration file.&lt;br /&gt;
//&lt;br /&gt;
// If you are just adding zones, please do that in /etc/bind/named.conf.local&lt;br /&gt;
//&lt;br /&gt;
// references:&lt;br /&gt;
// http://www.arda.homeunix.net/dnssetup.html&lt;br /&gt;
// http://www.madboa.com/geek/soho-bind/&lt;br /&gt;
//&lt;br /&gt;
// notes:&lt;br /&gt;
// 1) The following command should be ran about twice a year to keep&lt;br /&gt;
//    the root servers current:&lt;br /&gt;
//      dig @a.root-servers.net . ns &amp;gt; /etc/bin/db.root&lt;br /&gt;
//    Root name servers don’t change very often so updating this file more &lt;br /&gt;
//    than twice a year is probably overkill. Frequent updates also put undo &lt;br /&gt;
//    load on the root name servers; they have enough to do as it is.&lt;br /&gt;
//&lt;br /&gt;
// 2) File permissions:&lt;br /&gt;
//    /etc/bind/named.conf   root:root   644&lt;br /&gt;
//    /etc/bind/rndc.key     root:bind   640&lt;br /&gt;
//    /etc/bind/rndc.conf    root:root   600&lt;br /&gt;
//    /etc/resolv.conf       root:root   644&lt;br /&gt;
//    /etc/bind              root:bind   775, chmod g+s =&amp;gt; drwxrwsr-x&lt;br /&gt;
//    /etc/dhcp3             root:root   755&lt;br /&gt;
//    /etc/dhcp3/dhcpd.conf  root:root   644&lt;br /&gt;
//&lt;br /&gt;
// Manually Updating Zone Files&lt;br /&gt;
// 1. Use rndc to stop BIND.&lt;br /&gt;
//      sudo rndc stop&lt;br /&gt;
// 2. Remove any .jnl files from the zone file directory.&lt;br /&gt;
//      sudo rm /etc/bind/*.jnl&lt;br /&gt;
// 3. Edit the zone files as necessary. Make sure to increment the serial &lt;br /&gt;
//    number of any file edited.  Note, format of serial number is:&lt;br /&gt;
//    YYYYMMDDNN where YYYY is year, MM is month, DD is day, NN is update&lt;br /&gt;
//    number for that day (i.e., 01, 02, 03,...)&lt;br /&gt;
// 4. Start BIND using its startup script. &lt;br /&gt;
//      sudo /etc/init.d/bind9 start&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
// secret must be the same as in /etc/bind/rndc.conf&lt;br /&gt;
include &amp;quot;/etc/bind/rndc.key&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
// access control list used to limit queries to local net&lt;br /&gt;
acl &amp;quot;internal-net&amp;quot; { 192.168.80/24; 127.0.0.1; };&lt;br /&gt;
&lt;br /&gt;
controls {&lt;br /&gt;
    inet 127.0.0.1 allow { any; } keys { &amp;quot;rndc-key&amp;quot;; };&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
include &amp;quot;/etc/bind/named.conf.options&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
// The single dot (.) is the root of all DNS namespace, so&lt;br /&gt;
// this zone tells named where to start looking for any&lt;br /&gt;
// name on the Internet&lt;br /&gt;
zone &amp;quot;.&amp;quot; IN {&lt;br /&gt;
	type hint;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.root&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
// local intranet zones and reverse zones&lt;br /&gt;
// intranet is wright.local and 192.168.80.0/24&lt;br /&gt;
// the DHCP servers is on linuxmce-dhcp&lt;br /&gt;
// an optional second nameserver would be on linuxmce-ns2&lt;br /&gt;
	&lt;br /&gt;
zone &amp;quot;wright.local&amp;quot; IN {&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.wright.local.zone&amp;quot;;&lt;br /&gt;
	// both allow-update and update-policy can enable DHCP updates,&lt;br /&gt;
	// but update-policy allows more control over what kinds of &lt;br /&gt;
	// updates DHCP can perform on a zone.&lt;br /&gt;
	// allow-update { none; };&lt;br /&gt;
	update-policy { grant linuxmce-dhcp subdomain wright.local. A TXT; };&lt;br /&gt;
	// allow-transfer { key &amp;quot;linuxmce-ns2&amp;quot;; };&lt;br /&gt;
	// notify on zone transfers&lt;br /&gt;
	notify yes;&lt;br /&gt;
};&lt;br /&gt;
	&lt;br /&gt;
zone &amp;quot;80.168.192.in-addr.arpa&amp;quot; IN {&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.wright.local.rev&amp;quot;;&lt;br /&gt;
	// allow-update { none; };&lt;br /&gt;
	update-policy { grant linuxmce-dhcp subdomain 80.168.192.in-addr.arpa. PTR TXT; };&lt;br /&gt;
	// allow-transfer { key &amp;quot;linuxmce-ns2&amp;quot;; };&lt;br /&gt;
	notify yes;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
// be authoritative for the localhost forward and reverse zones, and for&lt;br /&gt;
// broadcast zones as per RFC 1912 (http://www.ietf.org/rfc/rfc1912.txt)&lt;br /&gt;
&lt;br /&gt;
// Where the localhost hostname is defined&lt;br /&gt;
zone &amp;quot;localhost&amp;quot; IN {&lt;br /&gt;
	// a master type means that this server needn&#039;t look&lt;br /&gt;
	// anywhere else for information; the localhost buck&lt;br /&gt;
	// stops here.&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.local&amp;quot;;&lt;br /&gt;
	// don&#039;t allow dynamic DNS clients to update info&lt;br /&gt;
	// about the localhost zone&lt;br /&gt;
	allow-update { none; };&lt;br /&gt;
};&lt;br /&gt;
	&lt;br /&gt;
// Where the 127.0.0.0 network is defined&lt;br /&gt;
zone &amp;quot;127.in-addr.arpa&amp;quot; IN {&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.127&amp;quot;;&lt;br /&gt;
	allow-update { none; };&lt;br /&gt;
};&lt;br /&gt;
	&lt;br /&gt;
zone &amp;quot;0.in-addr.arpa&amp;quot; IN {&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.0&amp;quot;;&lt;br /&gt;
	allow-update { none; };&lt;br /&gt;
};&lt;br /&gt;
	&lt;br /&gt;
zone &amp;quot;255.in-addr.arpa&amp;quot; IN {&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.255&amp;quot;;&lt;br /&gt;
	allow-update { none; };&lt;br /&gt;
};&lt;br /&gt;
	&lt;br /&gt;
&lt;br /&gt;
// Include logging config file&lt;br /&gt;
include &amp;quot;/etc/bind/logging.conf&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
// zone &amp;quot;com&amp;quot; { type delegation-only; };&lt;br /&gt;
// zone &amp;quot;net&amp;quot; { type delegation-only; };&lt;br /&gt;
&lt;br /&gt;
// From the release notes:&lt;br /&gt;
//  Because many of our users are uncomfortable receiving undelegated answers&lt;br /&gt;
//  from root or top level domains, other than a few for whom that behaviour&lt;br /&gt;
//  has been trusted and expected for quite some length of time, we have now&lt;br /&gt;
//  introduced the &amp;quot;root-delegations-only&amp;quot; feature which applies delegation-only&lt;br /&gt;
//  logic to all top level domains, and to the root domain.  An exception list&lt;br /&gt;
//  should be specified, including &amp;quot;MUSEUM&amp;quot; and &amp;quot;DE&amp;quot;, and any other top level&lt;br /&gt;
//  domains from whom undelegated responses are expected and trusted.&lt;br /&gt;
// root-delegation-only exclude { &amp;quot;DE&amp;quot;; &amp;quot;MUSEUM&amp;quot;; };&lt;br /&gt;
&lt;br /&gt;
include &amp;quot;/etc/bind/named.conf.local&amp;quot;;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/named.conf.options===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
options {&lt;br /&gt;
	// tell named where to find files mentioned below&lt;br /&gt;
	directory &amp;quot;/var/cache/bind&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
	// file that contains the process id when bind is running&lt;br /&gt;
	pid-file &amp;quot;/var/run/bind/run/named.pid&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
	// enable statistics&lt;br /&gt;
	statistics-file &amp;quot;/var/named/named.stats&amp;quot;;&lt;br /&gt;
	zone-statistics yes;&lt;br /&gt;
&lt;br /&gt;
	dump-file &amp;quot;/var/named/named.dump&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
	// If there is a firewall between you and nameservers you want&lt;br /&gt;
	// to talk to, you might need to uncomment the query-source&lt;br /&gt;
	// directive below.  Previous versions of BIND always asked&lt;br /&gt;
	// questions using port 53, but BIND 8.1 and later use an unprivileged&lt;br /&gt;
	// port by default.&lt;br /&gt;
	// query-source address * port 53;&lt;br /&gt;
&lt;br /&gt;
	// If your ISP provided one or more IP addresses for stable &lt;br /&gt;
	// nameservers, you probably want to use them as forwarders.  &lt;br /&gt;
	// Uncomment the following block, and insert the addresses replacing &lt;br /&gt;
	// the all-0&#039;s placeholder.&lt;br /&gt;
&lt;br /&gt;
	// The forwarders option tells BIND to not use iterative queries itself &lt;br /&gt;
	// for information it doesn’t already know about but to forward a &lt;br /&gt;
	// recursive query to the name servers specified instead.&lt;br /&gt;
	include &amp;quot;/etc/bind/named.conf.forwarders&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
	// conform to RFC1035&lt;br /&gt;
	auth-nxdomain no;&lt;br /&gt;
&lt;br /&gt;
	// on a multi-homed host, you might want to tell named&lt;br /&gt;
	// to listen for queries only on certain interfaces&lt;br /&gt;
	listen-on-v6 { any; };&lt;br /&gt;
	listen-on { &amp;quot;internal-net&amp;quot;; };&lt;br /&gt;
&lt;br /&gt;
	// to allow only specific hosts to use the DNS server:&lt;br /&gt;
	allow-query { &amp;quot;internal-net&amp;quot;; };&lt;br /&gt;
&lt;br /&gt;
	// sets BIND’s default behaviour to refuse all zone transfers. &lt;br /&gt;
	// Without setting this option, anyone can transfer any zone.&lt;br /&gt;
	allow-transfer { none; };&lt;br /&gt;
&lt;br /&gt;
	// do not generate notify messages for all zones on a restart.&lt;br /&gt;
	// override for authorative zones&lt;br /&gt;
	notify no;&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/logging.conf===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
logging {&lt;br /&gt;
&lt;br /&gt;
	channel default_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/default.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel general_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/general.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel database_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/database.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel security_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/security.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel config_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/config.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel resolver_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/resolver.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel xfer-in_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/xfer-in.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel xfer-out_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/xfer-out.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel notify_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/notify.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel client_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/client.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel unmatched_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/unmatched.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel queries_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/queries.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel network_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/network.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel update_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/update.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel dispatch_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/dispatch.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel dnssec_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/dnssec.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel lame-servers_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/lame-servers.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
	category lame-servers {&lt;br /&gt;
		lame-servers_file;&lt;br /&gt;
		};&lt;br /&gt;
	category dnssec {&lt;br /&gt;
		dnssec_file;&lt;br /&gt;
		};&lt;br /&gt;
	category dispatch {&lt;br /&gt;
		dispatch_file;&lt;br /&gt;
		};&lt;br /&gt;
	category update {&lt;br /&gt;
		update_file;&lt;br /&gt;
		};&lt;br /&gt;
	category network {&lt;br /&gt;
		network_file;&lt;br /&gt;
		};&lt;br /&gt;
	category queries {&lt;br /&gt;
		queries_file;&lt;br /&gt;
		};&lt;br /&gt;
	category unmatched {&lt;br /&gt;
		unmatched_file;&lt;br /&gt;
		};&lt;br /&gt;
	category client {&lt;br /&gt;
		client_file;&lt;br /&gt;
		};&lt;br /&gt;
	category notify {&lt;br /&gt;
		notify_file;&lt;br /&gt;
		};&lt;br /&gt;
	category xfer-out {&lt;br /&gt;
		xfer-out_file;&lt;br /&gt;
		};&lt;br /&gt;
	category xfer-in {&lt;br /&gt;
		xfer-in_file;&lt;br /&gt;
		};&lt;br /&gt;
	category resolver {&lt;br /&gt;
		resolver_file;&lt;br /&gt;
		};&lt;br /&gt;
	category config {&lt;br /&gt;
		config_file;&lt;br /&gt;
		};&lt;br /&gt;
	category security {&lt;br /&gt;
		security_file;&lt;br /&gt;
		};&lt;br /&gt;
	category database {&lt;br /&gt;
		database_file;&lt;br /&gt;
		};&lt;br /&gt;
	category general {&lt;br /&gt;
		general_file;&lt;br /&gt;
		};&lt;br /&gt;
	category default {&lt;br /&gt;
		default_file;&lt;br /&gt;
		};&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/rndc.conf===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
options {&lt;br /&gt;
	default-server  localhost;&lt;br /&gt;
	default-key     &amp;quot;rndc-key&amp;quot;;&lt;br /&gt;
	default-port 953;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
server localhost {&lt;br /&gt;
	key     &amp;quot;rndc-key&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
key &amp;quot;rndc-key&amp;quot; {&lt;br /&gt;
	algorithm       hmac-md5;&lt;br /&gt;
	secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/rndc.key===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
key &amp;quot;rndc-key&amp;quot; {&lt;br /&gt;
        algorithm	hmac-md5;&lt;br /&gt;
        secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
key &amp;quot;linuxmce-dhcp&amp;quot; {&lt;br /&gt;
        algorithm	hmac-md5;&lt;br /&gt;
        secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
key &amp;quot;linuxmce-ns2&amp;quot; {&lt;br /&gt;
        algorithm	hmac-md5;&lt;br /&gt;
        secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/db.wright.local.zone===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
;&lt;br /&gt;
; BIND data file for wright.local&lt;br /&gt;
; ref. http://www.redhat.com/docs/manuals/linux/RHL-9-Manual/ref-guide/s1-bind-zone.html&lt;br /&gt;
;&lt;br /&gt;
$TTL 86400 ; time to live : 86400s = 1 day&lt;br /&gt;
; Start Of Authority record, proclaims important authoritative information &lt;br /&gt;
; about a namespace to the nameserver.&lt;br /&gt;
@               IN SOA  dcerouter.wright.local        roy@wright.org (&lt;br /&gt;
                2008013101      ;serial (YYYYMMDDNN where N = 01,02,03,...)&lt;br /&gt;
                10800           ;refresh (3 hours)&lt;br /&gt;
                7200            ;retry (2 hours)&lt;br /&gt;
                36000000        ;expire (10,000 hours = 416 2/3 days)&lt;br /&gt;
                86400)          ;default minimum ttl&lt;br /&gt;
;&lt;br /&gt;
; NameServer record, which announces the authoritative nameservers for a particular zone.&lt;br /&gt;
;&lt;br /&gt;
                IN NS   dcerouter.wright.local.&lt;br /&gt;
;&lt;br /&gt;
; Address records specify an IP address to assign to a name&lt;br /&gt;
;&lt;br /&gt;
dcerouter       IN A            192.168.80.1&lt;br /&gt;
dad-kubuntu     IN A            192.168.80.21&lt;br /&gt;
royw-gentoo	IN A		192.168.80.20&lt;br /&gt;
;&lt;br /&gt;
; Canonical name records, maps one name to another. &lt;br /&gt;
;&lt;br /&gt;
linuxmce        IN CNAME        dcerouter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/db.wright.local.rev===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
;&lt;br /&gt;
; BIND reverse data file for wright.local&lt;br /&gt;
; ref. http://www.redhat.com/docs/manuals/linux/RHL-9-Manual/ref-guide/s1-bind-zone.html&lt;br /&gt;
;&lt;br /&gt;
$ORIGIN 80.168.192.in-addr.arpa.&lt;br /&gt;
$TTL 86400 ; time to live : 86400s = 1 day&lt;br /&gt;
; Start Of Authority record, proclaims important authoritative information &lt;br /&gt;
; about a namespace to the nameserver.&lt;br /&gt;
@               IN SOA  dcerouter.wright.local        roy@wright.org (&lt;br /&gt;
                2008013101      ;serial (YYYYMMDDNN where N = 01,02,03,...)&lt;br /&gt;
                10800           ;refresh (3 hours)&lt;br /&gt;
                7200            ;retry (2 hours)&lt;br /&gt;
                36000000        ;expire (10,000 hours = 416 2/3 days)&lt;br /&gt;
                86400)          ;default minimum ttl&lt;br /&gt;
;&lt;br /&gt;
; NameServer record, which announces the authoritative nameservers for a particular zone.&lt;br /&gt;
;&lt;br /&gt;
                IN NS   dcerouter.wright.local.&lt;br /&gt;
;&lt;br /&gt;
; PTR — PoinTeR record, designed to point to another part of the namespace.&lt;br /&gt;
;&lt;br /&gt;
1               IN PTR  dcerouter.wright.local.&lt;br /&gt;
21              IN PTR  dad-kubuntu.wright.local.&lt;br /&gt;
20		IN PTR	royw-gentoo.wright.local.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/dhcp3/dhcpd.conf===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
option domain-name-servers 192.168.80.1;&lt;br /&gt;
authoritative;&lt;br /&gt;
&lt;br /&gt;
option routers 192.168.80.1;&lt;br /&gt;
option subnet-mask 255.255.255.0;&lt;br /&gt;
&lt;br /&gt;
# lease IPs for 1 day, maximum 1 week&lt;br /&gt;
default-lease-time 86400;&lt;br /&gt;
max-lease-time 604800;&lt;br /&gt;
&lt;br /&gt;
# dynamic DNS updates&lt;br /&gt;
ddns-updates on;&lt;br /&gt;
ddns-update-style interim;&lt;br /&gt;
ddns-domainname &amp;quot;wright.local.&amp;quot;;&lt;br /&gt;
ddns-rev-domainname &amp;quot;in-addr.arpa.&amp;quot;;&lt;br /&gt;
ddns-ttl 14400;&lt;br /&gt;
&lt;br /&gt;
# don&#039;t let clients modify their own A records&lt;br /&gt;
ignore client-updates;&lt;br /&gt;
&lt;br /&gt;
key &amp;quot;linuxmce-dhcp&amp;quot; {&lt;br /&gt;
	algorithm       hmac-md5;&lt;br /&gt;
	secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
zone wright.local {&lt;br /&gt;
	primary 192.168.80.1;&lt;br /&gt;
	key &amp;quot;linuxmce-dhcp&amp;quot;;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
zone 80.168.192.in-addr.arpa {&lt;br /&gt;
	primary 192.168.80.1;&lt;br /&gt;
	key &amp;quot;linuxmce-dhcp&amp;quot;;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
option space pxelinux;&lt;br /&gt;
option pxelinux.magic code 208 = string;&lt;br /&gt;
option pxelinux.configfile code 209 = text;&lt;br /&gt;
option pxelinux.pathprefix code 210 = text;&lt;br /&gt;
option pxelinux.reboottime code 211 = unsigned integer 32;&lt;br /&gt;
&lt;br /&gt;
subnet 192.168.80.0 netmask 255.255.255.0 {&lt;br /&gt;
	next-server 192.168.80.1;&lt;br /&gt;
	filename &amp;quot;/tftpboot/pxelinux.0&amp;quot;;&lt;br /&gt;
	option pxelinux.reboottime = 30;&lt;br /&gt;
&lt;br /&gt;
	option domain-name &amp;quot;wright.local&amp;quot;;&lt;br /&gt;
	option domain-name-servers 192.168.80.1;&lt;br /&gt;
	option routers 192.168.80.1;&lt;br /&gt;
&lt;br /&gt;
	default-lease-time 86400;&lt;br /&gt;
	max-lease-time 604800;&lt;br /&gt;
	pool {&lt;br /&gt;
		 allow unknown-clients;&lt;br /&gt;
		 range 192.168.80.129 192.168.80.254; &lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
# PXE booting machines&lt;br /&gt;
group {&lt;br /&gt;
	next-server 192.168.80.1;&lt;br /&gt;
	filename &amp;quot;/tftpboot/pxelinux.0&amp;quot;;&lt;br /&gt;
	option pxelinux.reboottime = 30;&lt;br /&gt;
&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
# regular machines&lt;br /&gt;
group {&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
# CORE (1) has bad mac address: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/resolv.conf===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
domain wright.local&lt;br /&gt;
nameserver localhost&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Juanfe</name></author>
	</entry>
	<entry>
		<id>http://wiki.linuxmce.org/index.php?title=How_to_setup_Local_Authoritative_DNS&amp;diff=15509</id>
		<title>How to setup Local Authoritative DNS</title>
		<link rel="alternate" type="text/html" href="http://wiki.linuxmce.org/index.php?title=How_to_setup_Local_Authoritative_DNS&amp;diff=15509"/>
		<updated>2008-09-05T22:24:44Z</updated>

		<summary type="html">&lt;p&gt;Juanfe: /* Installation */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[category: Tutorials]]&lt;br /&gt;
=How to setup Local Authoritative DNS=&lt;br /&gt;
&lt;br /&gt;
I was wanting an authoritative name server for my local intranet.  I also wanted any dynamic IP&#039;s to be visible to the name server.  The name server included with linuxmce is configured as a recursive name server.  Here&#039;s the changes I did to configure my core&#039;s name server to be authoritative and support dynamic IPs.  Note, the machines on my intranet are private, i.e., not known to the outside world.&lt;br /&gt;
&lt;br /&gt;
  3 Feb 2008 - Developed and tested on LinuxMCE 0710 Beta 3 amd64.&lt;br /&gt;
&lt;br /&gt;
I named my intranet &amp;quot;wright.local&amp;quot;.  Using a &amp;quot;local&amp;quot; top level domain (TLD) is recommended for private intranets.  Some may prefer to use &amp;quot;lan&amp;quot;.  You do not want to use any of the standard TLDs like &amp;quot;com&amp;quot;, &amp;quot;net&amp;quot;, &amp;quot;org&amp;quot;,...&lt;br /&gt;
&lt;br /&gt;
I used the core&#039;s default intranet addresses, 192.168.80.0/24 with the core at 192.168.80.1.&lt;br /&gt;
&lt;br /&gt;
I&#039;ve attempted to verbosely document each config file. :)&lt;br /&gt;
&lt;br /&gt;
The directions for adapting the config files are included in the named.conf file.&lt;br /&gt;
&lt;br /&gt;
==Installation==&lt;br /&gt;
&lt;br /&gt;
If you want to try this, I would suggest building the config in new directories then swapping with the originals when you are ready (I had a little mess when my core hung and I had to restart with only half the configs ready) :)&lt;br /&gt;
&lt;br /&gt;
So start with creating two directories:&lt;br /&gt;
&lt;br /&gt;
  sudo mkdir /etc/bind.new&lt;br /&gt;
  sudo mkdir /etc/dhcp3.new&lt;br /&gt;
&lt;br /&gt;
Now copy the contents of the original directories:&lt;br /&gt;
&lt;br /&gt;
  sudo cp -arp /etc/bind/* /etc/bind.new&lt;br /&gt;
  sudo cp -arp /etc/dhcp3/* /etc/dhcp3.new&lt;br /&gt;
&lt;br /&gt;
Also create a new resolve.conf file:&lt;br /&gt;
&lt;br /&gt;
  sudo touch /etc/resolv.conf.new&lt;br /&gt;
&lt;br /&gt;
You will be creating or editing the following config files in these new directories, as described below:&lt;br /&gt;
&lt;br /&gt;
  /etc/bind.new/named.conf&lt;br /&gt;
  /etc/bind.new/named.conf.options&lt;br /&gt;
  /etc/bind.new/logging.conf&lt;br /&gt;
  /etc/bind.new/rndc.conf&lt;br /&gt;
  /etc/bind.new/rndc.key&lt;br /&gt;
  /etc/bind.new/db.yournetworkname.local.zone&lt;br /&gt;
  /etc/bind.new/db.yournetworkname.local.rev&lt;br /&gt;
  /etc/dhcp3.new/dhcpd.conf&lt;br /&gt;
  /etc/resolv.conf&lt;br /&gt;
&lt;br /&gt;
==After Editing Files==&lt;br /&gt;
&lt;br /&gt;
Make the logging directory:&lt;br /&gt;
&lt;br /&gt;
  sudo mkdir /var/log/named&lt;br /&gt;
  sudo chown bind:bind /var/log/named&lt;br /&gt;
  sudo chmod 755 /var/log/named&lt;br /&gt;
&lt;br /&gt;
You probably ought to check and change the defaultdomain:&lt;br /&gt;
&lt;br /&gt;
  domainname&lt;br /&gt;
&lt;br /&gt;
will probably show&lt;br /&gt;
&lt;br /&gt;
  pluto&lt;br /&gt;
&lt;br /&gt;
if so, then set it by:&lt;br /&gt;
  sudo domainname yourdomain.local&lt;br /&gt;
&lt;br /&gt;
where &amp;quot;yourdomain.local&amp;quot; is your domain.  :-)&lt;br /&gt;
&lt;br /&gt;
Change all the file permissions per instructions in named.conf. &lt;br /&gt;
&lt;br /&gt;
Double check everything.   Roll Eyes&lt;br /&gt;
&lt;br /&gt;
Then when you are feeling lucky, rename the original directories and then rename the new directories to take there place:&lt;br /&gt;
&lt;br /&gt;
  sudo mv /etc/bind /etc/bind.original&lt;br /&gt;
  sudo mv /etc/bind.new /etc/bind&lt;br /&gt;
  sudo mv /etc/dhcp3 /etc/dhcp3.original&lt;br /&gt;
  sudo mv /etc/dhcp3.new /etc/dhcp3&lt;br /&gt;
  sudo mv /etc/resolve.conf /etc/resolve.conf.original&lt;br /&gt;
  sudo mv /etc/resolve.conf.new /etc/resolve.conf&lt;br /&gt;
&lt;br /&gt;
Finally restart the bind and dhcpd services:&lt;br /&gt;
&lt;br /&gt;
  sudo rndc reload&lt;br /&gt;
  sudo /etc/init.d/dhcp3-server restart&lt;br /&gt;
&lt;br /&gt;
Check the syslog for any errors:&lt;br /&gt;
&lt;br /&gt;
  grep named /var/log/syslog&lt;br /&gt;
  grep dhcpd /var/log/syslog&lt;br /&gt;
&lt;br /&gt;
==Config Files==&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/named.conf===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
// This is the primary configuration file for the BIND DNS server named.&lt;br /&gt;
//&lt;br /&gt;
// This configuration supports an authoritative local zone (wright.local on&lt;br /&gt;
// 192.168.80.0/24) and allows DHCP to update the local zone.  &lt;br /&gt;
// To customize to your setup:&lt;br /&gt;
// 1) replace &amp;quot;wright.local&amp;quot; with your internal domain name.&lt;br /&gt;
// 2) edit db.wright.local.zone and db.wright.local.rev and replace&lt;br /&gt;
//    my static names/addresses with your network&#039;s static names/addresses.&lt;br /&gt;
//    Make sure to increment the serial number of any file edited.  &lt;br /&gt;
//    Note, format of serial number is:  YYYYMMDDNN where YYYY is year, &lt;br /&gt;
//    MM is month, DD is day, NN is update number for that day (i.e., 01, &lt;br /&gt;
//    02, 03,...)&lt;br /&gt;
// 3) rename db.wright.local.zone to match your domain name.&lt;br /&gt;
// 4) rename db.wright.local.rev to match your domain name.&lt;br /&gt;
// 5) If you changed the internal network IP from the LinuxMCE default of&lt;br /&gt;
//    192.168.80.0/24, then replace &amp;quot;192.168.80&amp;quot; with your network&lt;br /&gt;
//    ip and replace it&#039;s reverse &amp;quot;80.168.192&amp;quot; wity your network ip&#039;s&lt;br /&gt;
//    reverse.&lt;br /&gt;
//&lt;br /&gt;
// Please read /usr/share/doc/bind9/README.Debian.gz for information on the &lt;br /&gt;
// structure of BIND configuration files in Debian, *BEFORE* you customize &lt;br /&gt;
// this configuration file.&lt;br /&gt;
//&lt;br /&gt;
// If you are just adding zones, please do that in /etc/bind/named.conf.local&lt;br /&gt;
//&lt;br /&gt;
// references:&lt;br /&gt;
// http://www.arda.homeunix.net/dnssetup.html&lt;br /&gt;
// http://www.madboa.com/geek/soho-bind/&lt;br /&gt;
//&lt;br /&gt;
// notes:&lt;br /&gt;
// 1) The following command should be ran about twice a year to keep&lt;br /&gt;
//    the root servers current:&lt;br /&gt;
//      dig @a.root-servers.net . ns &amp;gt; /etc/bin/db.root&lt;br /&gt;
//    Root name servers don’t change very often so updating this file more &lt;br /&gt;
//    than twice a year is probably overkill. Frequent updates also put undo &lt;br /&gt;
//    load on the root name servers; they have enough to do as it is.&lt;br /&gt;
//&lt;br /&gt;
// 2) File permissions:&lt;br /&gt;
//    /etc/bind/named.conf   root:root   644&lt;br /&gt;
//    /etc/bind/rndc.key     root:bind   640&lt;br /&gt;
//    /etc/bind/rndc.conf    root:root   600&lt;br /&gt;
//    /etc/resolv.conf       root:root   644&lt;br /&gt;
//    /etc/bind              root:bind   775, chmod g+s =&amp;gt; drwxrwsr-x&lt;br /&gt;
//    /etc/dhcp3             root:root   755&lt;br /&gt;
//    /etc/dhcp3/dhcpd.conf  root:root   644&lt;br /&gt;
//&lt;br /&gt;
// Manually Updating Zone Files&lt;br /&gt;
// 1. Use rndc to stop BIND.&lt;br /&gt;
//      sudo rndc stop&lt;br /&gt;
// 2. Remove any .jnl files from the zone file directory.&lt;br /&gt;
//      sudo rm /etc/bind/*.jnl&lt;br /&gt;
// 3. Edit the zone files as necessary. Make sure to increment the serial &lt;br /&gt;
//    number of any file edited.  Note, format of serial number is:&lt;br /&gt;
//    YYYYMMDDNN where YYYY is year, MM is month, DD is day, NN is update&lt;br /&gt;
//    number for that day (i.e., 01, 02, 03,...)&lt;br /&gt;
// 4. Start BIND using its startup script. &lt;br /&gt;
//      sudo /etc/init.d/bind9 start&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
// secret must be the same as in /etc/bind/rndc.conf&lt;br /&gt;
include &amp;quot;/etc/bind/rndc.key&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
// access control list used to limit queries to local net&lt;br /&gt;
acl &amp;quot;internal-net&amp;quot; { 192.168.80/24; 127.0.0.1; };&lt;br /&gt;
&lt;br /&gt;
controls {&lt;br /&gt;
    inet 127.0.0.1 allow { any; } keys { &amp;quot;rndc-key&amp;quot;; };&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
include &amp;quot;/etc/bind/named.conf.options&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
// The single dot (.) is the root of all DNS namespace, so&lt;br /&gt;
// this zone tells named where to start looking for any&lt;br /&gt;
// name on the Internet&lt;br /&gt;
zone &amp;quot;.&amp;quot; IN {&lt;br /&gt;
	type hint;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.root&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
// local intranet zones and reverse zones&lt;br /&gt;
// intranet is wright.local and 192.168.80.0/24&lt;br /&gt;
// the DHCP servers is on linuxmce-dhcp&lt;br /&gt;
// an optional second nameserver would be on linuxmce-ns2&lt;br /&gt;
	&lt;br /&gt;
zone &amp;quot;wright.local&amp;quot; IN {&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.wright.local.zone&amp;quot;;&lt;br /&gt;
	// both allow-update and update-policy can enable DHCP updates,&lt;br /&gt;
	// but update-policy allows more control over what kinds of &lt;br /&gt;
	// updates DHCP can perform on a zone.&lt;br /&gt;
	// allow-update { none; };&lt;br /&gt;
	update-policy { grant linuxmce-dhcp subdomain wright.local. A TXT; };&lt;br /&gt;
	// allow-transfer { key &amp;quot;linuxmce-ns2&amp;quot;; };&lt;br /&gt;
	// notify on zone transfers&lt;br /&gt;
	notify yes;&lt;br /&gt;
};&lt;br /&gt;
	&lt;br /&gt;
zone &amp;quot;80.168.192.in-addr.arpa&amp;quot; IN {&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.wright.local.rev&amp;quot;;&lt;br /&gt;
	// allow-update { none; };&lt;br /&gt;
	update-policy { grant linuxmce-dhcp subdomain 80.168.192.in-addr.arpa. PTR TXT; };&lt;br /&gt;
	// allow-transfer { key &amp;quot;linuxmce-ns2&amp;quot;; };&lt;br /&gt;
	notify yes;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
// be authoritative for the localhost forward and reverse zones, and for&lt;br /&gt;
// broadcast zones as per RFC 1912 (http://www.ietf.org/rfc/rfc1912.txt)&lt;br /&gt;
&lt;br /&gt;
// Where the localhost hostname is defined&lt;br /&gt;
zone &amp;quot;localhost&amp;quot; IN {&lt;br /&gt;
	// a master type means that this server needn&#039;t look&lt;br /&gt;
	// anywhere else for information; the localhost buck&lt;br /&gt;
	// stops here.&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.local&amp;quot;;&lt;br /&gt;
	// don&#039;t allow dynamic DNS clients to update info&lt;br /&gt;
	// about the localhost zone&lt;br /&gt;
	allow-update { none; };&lt;br /&gt;
};&lt;br /&gt;
	&lt;br /&gt;
// Where the 127.0.0.0 network is defined&lt;br /&gt;
zone &amp;quot;127.in-addr.arpa&amp;quot; IN {&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.127&amp;quot;;&lt;br /&gt;
	allow-update { none; };&lt;br /&gt;
};&lt;br /&gt;
	&lt;br /&gt;
zone &amp;quot;0.in-addr.arpa&amp;quot; IN {&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.0&amp;quot;;&lt;br /&gt;
	allow-update { none; };&lt;br /&gt;
};&lt;br /&gt;
	&lt;br /&gt;
zone &amp;quot;255.in-addr.arpa&amp;quot; IN {&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.255&amp;quot;;&lt;br /&gt;
	allow-update { none; };&lt;br /&gt;
};&lt;br /&gt;
	&lt;br /&gt;
&lt;br /&gt;
// Include logging config file&lt;br /&gt;
include &amp;quot;/etc/bind/logging.conf&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
// zone &amp;quot;com&amp;quot; { type delegation-only; };&lt;br /&gt;
// zone &amp;quot;net&amp;quot; { type delegation-only; };&lt;br /&gt;
&lt;br /&gt;
// From the release notes:&lt;br /&gt;
//  Because many of our users are uncomfortable receiving undelegated answers&lt;br /&gt;
//  from root or top level domains, other than a few for whom that behaviour&lt;br /&gt;
//  has been trusted and expected for quite some length of time, we have now&lt;br /&gt;
//  introduced the &amp;quot;root-delegations-only&amp;quot; feature which applies delegation-only&lt;br /&gt;
//  logic to all top level domains, and to the root domain.  An exception list&lt;br /&gt;
//  should be specified, including &amp;quot;MUSEUM&amp;quot; and &amp;quot;DE&amp;quot;, and any other top level&lt;br /&gt;
//  domains from whom undelegated responses are expected and trusted.&lt;br /&gt;
// root-delegation-only exclude { &amp;quot;DE&amp;quot;; &amp;quot;MUSEUM&amp;quot;; };&lt;br /&gt;
&lt;br /&gt;
include &amp;quot;/etc/bind/named.conf.local&amp;quot;;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/named.conf.options===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
options {&lt;br /&gt;
	// tell named where to find files mentioned below&lt;br /&gt;
	directory &amp;quot;/var/cache/bind&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
	// file that contains the process id when bind is running&lt;br /&gt;
	pid-file &amp;quot;/var/run/bind/run/named.pid&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
	// enable statistics&lt;br /&gt;
	statistics-file &amp;quot;/var/named/named.stats&amp;quot;;&lt;br /&gt;
	zone-statistics yes;&lt;br /&gt;
&lt;br /&gt;
	dump-file &amp;quot;/var/named/named.dump&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
	// If there is a firewall between you and nameservers you want&lt;br /&gt;
	// to talk to, you might need to uncomment the query-source&lt;br /&gt;
	// directive below.  Previous versions of BIND always asked&lt;br /&gt;
	// questions using port 53, but BIND 8.1 and later use an unprivileged&lt;br /&gt;
	// port by default.&lt;br /&gt;
	// query-source address * port 53;&lt;br /&gt;
&lt;br /&gt;
	// If your ISP provided one or more IP addresses for stable &lt;br /&gt;
	// nameservers, you probably want to use them as forwarders.  &lt;br /&gt;
	// Uncomment the following block, and insert the addresses replacing &lt;br /&gt;
	// the all-0&#039;s placeholder.&lt;br /&gt;
&lt;br /&gt;
	// The forwarders option tells BIND to not use iterative queries itself &lt;br /&gt;
	// for information it doesn’t already know about but to forward a &lt;br /&gt;
	// recursive query to the name servers specified instead.&lt;br /&gt;
	include &amp;quot;/etc/bind/named.conf.forwarders&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
	// conform to RFC1035&lt;br /&gt;
	auth-nxdomain no;&lt;br /&gt;
&lt;br /&gt;
	// on a multi-homed host, you might want to tell named&lt;br /&gt;
	// to listen for queries only on certain interfaces&lt;br /&gt;
	listen-on-v6 { any; };&lt;br /&gt;
	listen-on { &amp;quot;internal-net&amp;quot;; };&lt;br /&gt;
&lt;br /&gt;
	// to allow only specific hosts to use the DNS server:&lt;br /&gt;
	allow-query { &amp;quot;internal-net&amp;quot;; };&lt;br /&gt;
&lt;br /&gt;
	// sets BIND’s default behaviour to refuse all zone transfers. &lt;br /&gt;
	// Without setting this option, anyone can transfer any zone.&lt;br /&gt;
	allow-transfer { none; };&lt;br /&gt;
&lt;br /&gt;
	// do not generate notify messages for all zones on a restart.&lt;br /&gt;
	// override for authorative zones&lt;br /&gt;
	notify no;&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/logging.conf===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
logging {&lt;br /&gt;
&lt;br /&gt;
	channel default_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/default.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel general_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/general.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel database_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/database.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel security_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/security.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel config_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/config.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel resolver_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/resolver.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel xfer-in_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/xfer-in.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel xfer-out_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/xfer-out.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel notify_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/notify.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel client_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/client.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel unmatched_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/unmatched.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel queries_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/queries.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel network_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/network.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel update_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/update.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel dispatch_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/dispatch.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel dnssec_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/dnssec.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel lame-servers_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/lame-servers.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
	category lame-servers {&lt;br /&gt;
		lame-servers_file;&lt;br /&gt;
		};&lt;br /&gt;
	category dnssec {&lt;br /&gt;
		dnssec_file;&lt;br /&gt;
		};&lt;br /&gt;
	category dispatch {&lt;br /&gt;
		dispatch_file;&lt;br /&gt;
		};&lt;br /&gt;
	category update {&lt;br /&gt;
		update_file;&lt;br /&gt;
		};&lt;br /&gt;
	category network {&lt;br /&gt;
		network_file;&lt;br /&gt;
		};&lt;br /&gt;
	category queries {&lt;br /&gt;
		queries_file;&lt;br /&gt;
		};&lt;br /&gt;
	category unmatched {&lt;br /&gt;
		unmatched_file;&lt;br /&gt;
		};&lt;br /&gt;
	category client {&lt;br /&gt;
		client_file;&lt;br /&gt;
		};&lt;br /&gt;
	category notify {&lt;br /&gt;
		notify_file;&lt;br /&gt;
		};&lt;br /&gt;
	category xfer-out {&lt;br /&gt;
		xfer-out_file;&lt;br /&gt;
		};&lt;br /&gt;
	category xfer-in {&lt;br /&gt;
		xfer-in_file;&lt;br /&gt;
		};&lt;br /&gt;
	category resolver {&lt;br /&gt;
		resolver_file;&lt;br /&gt;
		};&lt;br /&gt;
	category config {&lt;br /&gt;
		config_file;&lt;br /&gt;
		};&lt;br /&gt;
	category security {&lt;br /&gt;
		security_file;&lt;br /&gt;
		};&lt;br /&gt;
	category database {&lt;br /&gt;
		database_file;&lt;br /&gt;
		};&lt;br /&gt;
	category general {&lt;br /&gt;
		general_file;&lt;br /&gt;
		};&lt;br /&gt;
	category default {&lt;br /&gt;
		default_file;&lt;br /&gt;
		};&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/rndc.conf===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
options {&lt;br /&gt;
	default-server  localhost;&lt;br /&gt;
	default-key     &amp;quot;rndc-key&amp;quot;;&lt;br /&gt;
	default-port 953;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
server localhost {&lt;br /&gt;
	key     &amp;quot;rndc-key&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
key &amp;quot;rndc-key&amp;quot; {&lt;br /&gt;
	algorithm       hmac-md5;&lt;br /&gt;
	secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/rndc.key===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
key &amp;quot;rndc-key&amp;quot; {&lt;br /&gt;
        algorithm	hmac-md5;&lt;br /&gt;
        secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
key &amp;quot;linuxmce-dhcp&amp;quot; {&lt;br /&gt;
        algorithm	hmac-md5;&lt;br /&gt;
        secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
key &amp;quot;linuxmce-ns2&amp;quot; {&lt;br /&gt;
        algorithm	hmac-md5;&lt;br /&gt;
        secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/db.wright.local.zone===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
;&lt;br /&gt;
; BIND data file for wright.local&lt;br /&gt;
; ref. http://www.redhat.com/docs/manuals/linux/RHL-9-Manual/ref-guide/s1-bind-zone.html&lt;br /&gt;
;&lt;br /&gt;
$TTL 86400 ; time to live : 86400s = 1 day&lt;br /&gt;
; Start Of Authority record, proclaims important authoritative information &lt;br /&gt;
; about a namespace to the nameserver.&lt;br /&gt;
@               IN SOA  dcerouter.wright.local        roy@wright.org (&lt;br /&gt;
                2008013101      ;serial (YYYYMMDDNN where N = 01,02,03,...)&lt;br /&gt;
                10800           ;refresh (3 hours)&lt;br /&gt;
                7200            ;retry (2 hours)&lt;br /&gt;
                36000000        ;expire (10,000 hours = 416 2/3 days)&lt;br /&gt;
                86400)          ;default minimum ttl&lt;br /&gt;
;&lt;br /&gt;
; NameServer record, which announces the authoritative nameservers for a particular zone.&lt;br /&gt;
;&lt;br /&gt;
                IN NS   dcerouter.wright.local.&lt;br /&gt;
;&lt;br /&gt;
; Address records specify an IP address to assign to a name&lt;br /&gt;
;&lt;br /&gt;
dcerouter       IN A            192.168.80.1&lt;br /&gt;
dad-kubuntu     IN A            192.168.80.21&lt;br /&gt;
royw-gentoo	IN A		192.168.80.20&lt;br /&gt;
;&lt;br /&gt;
; Canonical name records, maps one name to another. &lt;br /&gt;
;&lt;br /&gt;
linuxmce        IN CNAME        dcerouter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/db.wright.local.rev===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
;&lt;br /&gt;
; BIND reverse data file for wright.local&lt;br /&gt;
; ref. http://www.redhat.com/docs/manuals/linux/RHL-9-Manual/ref-guide/s1-bind-zone.html&lt;br /&gt;
;&lt;br /&gt;
$ORIGIN 80.168.192.in-addr.arpa.&lt;br /&gt;
$TTL 86400 ; time to live : 86400s = 1 day&lt;br /&gt;
; Start Of Authority record, proclaims important authoritative information &lt;br /&gt;
; about a namespace to the nameserver.&lt;br /&gt;
@               IN SOA  dcerouter.wright.local        roy@wright.org (&lt;br /&gt;
                2008013101      ;serial (YYYYMMDDNN where N = 01,02,03,...)&lt;br /&gt;
                10800           ;refresh (3 hours)&lt;br /&gt;
                7200            ;retry (2 hours)&lt;br /&gt;
                36000000        ;expire (10,000 hours = 416 2/3 days)&lt;br /&gt;
                86400)          ;default minimum ttl&lt;br /&gt;
;&lt;br /&gt;
; NameServer record, which announces the authoritative nameservers for a particular zone.&lt;br /&gt;
;&lt;br /&gt;
                IN NS   dcerouter.wright.local.&lt;br /&gt;
;&lt;br /&gt;
; PTR — PoinTeR record, designed to point to another part of the namespace.&lt;br /&gt;
;&lt;br /&gt;
1               IN PTR  dcerouter.wright.local.&lt;br /&gt;
21              IN PTR  dad-kubuntu.wright.local.&lt;br /&gt;
20		IN PTR	royw-gentoo.wright.local.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/dhcp3/dhcpd.conf===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
option domain-name-servers 192.168.80.1;&lt;br /&gt;
authoritative;&lt;br /&gt;
&lt;br /&gt;
option routers 192.168.80.1;&lt;br /&gt;
option subnet-mask 255.255.255.0;&lt;br /&gt;
&lt;br /&gt;
# lease IPs for 1 day, maximum 1 week&lt;br /&gt;
default-lease-time 86400;&lt;br /&gt;
max-lease-time 604800;&lt;br /&gt;
&lt;br /&gt;
# dynamic DNS updates&lt;br /&gt;
ddns-updates on;&lt;br /&gt;
ddns-update-style interim;&lt;br /&gt;
ddns-domainname &amp;quot;wright.local.&amp;quot;;&lt;br /&gt;
ddns-rev-domainname &amp;quot;in-addr.arpa.&amp;quot;;&lt;br /&gt;
ddns-ttl 14400;&lt;br /&gt;
&lt;br /&gt;
# don&#039;t let clients modify their own A records&lt;br /&gt;
ignore client-updates;&lt;br /&gt;
&lt;br /&gt;
key &amp;quot;linuxmce-dhcp&amp;quot; {&lt;br /&gt;
	algorithm       hmac-md5;&lt;br /&gt;
	secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
zone wright.local {&lt;br /&gt;
	primary 192.168.80.1;&lt;br /&gt;
	key &amp;quot;linuxmce-dhcp&amp;quot;;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
zone 80.168.192.in-addr.arpa {&lt;br /&gt;
	primary 192.168.80.1;&lt;br /&gt;
	key &amp;quot;linuxmce-dhcp&amp;quot;;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
option space pxelinux;&lt;br /&gt;
option pxelinux.magic code 208 = string;&lt;br /&gt;
option pxelinux.configfile code 209 = text;&lt;br /&gt;
option pxelinux.pathprefix code 210 = text;&lt;br /&gt;
option pxelinux.reboottime code 211 = unsigned integer 32;&lt;br /&gt;
&lt;br /&gt;
subnet 192.168.80.0 netmask 255.255.255.0 {&lt;br /&gt;
	next-server 192.168.80.1;&lt;br /&gt;
	filename &amp;quot;/tftpboot/pxelinux.0&amp;quot;;&lt;br /&gt;
	option pxelinux.reboottime = 30;&lt;br /&gt;
&lt;br /&gt;
	option domain-name &amp;quot;wright.local&amp;quot;;&lt;br /&gt;
	option domain-name-servers 192.168.80.1;&lt;br /&gt;
	option routers 192.168.80.1;&lt;br /&gt;
&lt;br /&gt;
	default-lease-time 86400;&lt;br /&gt;
	max-lease-time 604800;&lt;br /&gt;
	pool {&lt;br /&gt;
		 allow unknown-clients;&lt;br /&gt;
		 range 192.168.80.129 192.168.80.254; &lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
# PXE booting machines&lt;br /&gt;
group {&lt;br /&gt;
	next-server 192.168.80.1;&lt;br /&gt;
	filename &amp;quot;/tftpboot/pxelinux.0&amp;quot;;&lt;br /&gt;
	option pxelinux.reboottime = 30;&lt;br /&gt;
&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
# regular machines&lt;br /&gt;
group {&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
# CORE (1) has bad mac address: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/resolv.conf===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
domain wright.local&lt;br /&gt;
nameserver localhost&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Juanfe</name></author>
	</entry>
	<entry>
		<id>http://wiki.linuxmce.org/index.php?title=How_to_setup_Local_Authoritative_DNS&amp;diff=15508</id>
		<title>How to setup Local Authoritative DNS</title>
		<link rel="alternate" type="text/html" href="http://wiki.linuxmce.org/index.php?title=How_to_setup_Local_Authoritative_DNS&amp;diff=15508"/>
		<updated>2008-09-05T22:20:38Z</updated>

		<summary type="html">&lt;p&gt;Juanfe: /* Installation */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[category: Tutorials]]&lt;br /&gt;
=How to setup Local Authoritative DNS=&lt;br /&gt;
&lt;br /&gt;
I was wanting an authoritative name server for my local intranet.  I also wanted any dynamic IP&#039;s to be visible to the name server.  The name server included with linuxmce is configured as a recursive name server.  Here&#039;s the changes I did to configure my core&#039;s name server to be authoritative and support dynamic IPs.  Note, the machines on my intranet are private, i.e., not known to the outside world.&lt;br /&gt;
&lt;br /&gt;
  3 Feb 2008 - Developed and tested on LinuxMCE 0710 Beta 3 amd64.&lt;br /&gt;
&lt;br /&gt;
I named my intranet &amp;quot;wright.local&amp;quot;.  Using a &amp;quot;local&amp;quot; top level domain (TLD) is recommended for private intranets.  Some may prefer to use &amp;quot;lan&amp;quot;.  You do not want to use any of the standard TLDs like &amp;quot;com&amp;quot;, &amp;quot;net&amp;quot;, &amp;quot;org&amp;quot;,...&lt;br /&gt;
&lt;br /&gt;
I used the core&#039;s default intranet addresses, 192.168.80.0/24 with the core at 192.168.80.1.&lt;br /&gt;
&lt;br /&gt;
I&#039;ve attempted to verbosely document each config file. :)&lt;br /&gt;
&lt;br /&gt;
The directions for adapting the config files are included in the named.conf file.&lt;br /&gt;
&lt;br /&gt;
==Installation==&lt;br /&gt;
&lt;br /&gt;
If you want to try this, I would suggest building the config in new directories then swapping with the originals when you are ready (I had a little mess when my core hung and I had to restart with only half the configs ready) :)&lt;br /&gt;
&lt;br /&gt;
So start with creating two directories:&lt;br /&gt;
&lt;br /&gt;
  sudo mkdir /etc/bind.new&lt;br /&gt;
  sudo mkdir /etc/dhcp3.new&lt;br /&gt;
&lt;br /&gt;
Now copy the contents of the original directories:&lt;br /&gt;
&lt;br /&gt;
  sudo cp -arp /etc/bind/* /etc/bind.new&lt;br /&gt;
  sudo cp -arp /etc/dhcp3/* /etc/dhcp3.new&lt;br /&gt;
&lt;br /&gt;
Also create a new resolve.conf file:&lt;br /&gt;
&lt;br /&gt;
  sudo touch /etc/resolv.conf.new&lt;br /&gt;
&lt;br /&gt;
Then add/change the following config files as described below:&lt;br /&gt;
&lt;br /&gt;
  /etc/bind/named.conf&lt;br /&gt;
&lt;br /&gt;
To create a key for use in rndc.key and dhcpd.conf:&lt;br /&gt;
&lt;br /&gt;
  sudo dnssec-keygen -a HMAC-MD5 -b 256 -n user rndc&lt;br /&gt;
&lt;br /&gt;
Now get the key from the private file:&lt;br /&gt;
&lt;br /&gt;
  sudo cat Krndc.*.private&lt;br /&gt;
  Private-key-format: v1.2&lt;br /&gt;
  Algorithm: 157 (HMAC_MD5)&lt;br /&gt;
  Key: 3+GnSWV5FKxcUu57k7QFxbpvv/xr4fXj2wBVGtdGifI=&lt;br /&gt;
  Bits: AAA=&lt;br /&gt;
&lt;br /&gt;
Now cut the key which is to the right of &amp;quot;Key: &amp;quot; and paste where needed (replace &amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot; with the key in the config files).  So an example using the above key would look like:&lt;br /&gt;
&lt;br /&gt;
  key &amp;quot;linuxmce-dhcp&amp;quot; {&lt;br /&gt;
        algorithm	hmac-md5;&lt;br /&gt;
        secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
  };&lt;br /&gt;
&lt;br /&gt;
becomes:&lt;br /&gt;
&lt;br /&gt;
  key &amp;quot;linuxmce-dhcp&amp;quot; {&lt;br /&gt;
        algorithm	hmac-md5;&lt;br /&gt;
        secret		&amp;quot;3+GnSWV5FKxcUu57k7QFxbpvv/xr4fXj2wBVGtdGifI=&amp;quot;;&lt;br /&gt;
  };&lt;br /&gt;
&lt;br /&gt;
Make the logging directory:&lt;br /&gt;
&lt;br /&gt;
  sudo mkdir /var/log/named&lt;br /&gt;
  sudo chown bind:bind /var/log/named&lt;br /&gt;
  sudo chmod 755 /var/log/named&lt;br /&gt;
&lt;br /&gt;
You probably ought to check and change the defaultdomain:&lt;br /&gt;
&lt;br /&gt;
  domainname&lt;br /&gt;
&lt;br /&gt;
will probably show&lt;br /&gt;
&lt;br /&gt;
  pluto&lt;br /&gt;
&lt;br /&gt;
if so, then set it by:&lt;br /&gt;
  sudo domainname yourdomain.local&lt;br /&gt;
&lt;br /&gt;
where &amp;quot;yourdomain.local&amp;quot; is your domain.  :-)&lt;br /&gt;
&lt;br /&gt;
Change all the file permissions per instructions in named.conf. &lt;br /&gt;
&lt;br /&gt;
Double check everything.   Roll Eyes&lt;br /&gt;
&lt;br /&gt;
Then when you are feeling lucky, rename the original directories and then rename the new directories to take there place:&lt;br /&gt;
&lt;br /&gt;
  sudo mv /etc/bind /etc/bind.original&lt;br /&gt;
  sudo mv /etc/bind.new /etc/bind&lt;br /&gt;
  sudo mv /etc/dhcp3 /etc/dhcp3.original&lt;br /&gt;
  sudo mv /etc/dhcp3.new /etc/dhcp3&lt;br /&gt;
  sudo mv /etc/resolve.conf /etc/resolve.conf.original&lt;br /&gt;
  sudo mv /etc/resolve.conf.new /etc/resolve.conf&lt;br /&gt;
&lt;br /&gt;
Finally restart the bind and dhcpd services:&lt;br /&gt;
&lt;br /&gt;
  sudo rndc reload&lt;br /&gt;
  sudo /etc/init.d/dhcp3-server restart&lt;br /&gt;
&lt;br /&gt;
Check the syslog for any errors:&lt;br /&gt;
&lt;br /&gt;
  grep named /var/log/syslog&lt;br /&gt;
  grep dhcpd /var/log/syslog&lt;br /&gt;
&lt;br /&gt;
==Config Files==&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/named.conf===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
// This is the primary configuration file for the BIND DNS server named.&lt;br /&gt;
//&lt;br /&gt;
// This configuration supports an authoritative local zone (wright.local on&lt;br /&gt;
// 192.168.80.0/24) and allows DHCP to update the local zone.  &lt;br /&gt;
// To customize to your setup:&lt;br /&gt;
// 1) replace &amp;quot;wright.local&amp;quot; with your internal domain name.&lt;br /&gt;
// 2) edit db.wright.local.zone and db.wright.local.rev and replace&lt;br /&gt;
//    my static names/addresses with your network&#039;s static names/addresses.&lt;br /&gt;
//    Make sure to increment the serial number of any file edited.  &lt;br /&gt;
//    Note, format of serial number is:  YYYYMMDDNN where YYYY is year, &lt;br /&gt;
//    MM is month, DD is day, NN is update number for that day (i.e., 01, &lt;br /&gt;
//    02, 03,...)&lt;br /&gt;
// 3) rename db.wright.local.zone to match your domain name.&lt;br /&gt;
// 4) rename db.wright.local.rev to match your domain name.&lt;br /&gt;
// 5) If you changed the internal network IP from the LinuxMCE default of&lt;br /&gt;
//    192.168.80.0/24, then replace &amp;quot;192.168.80&amp;quot; with your network&lt;br /&gt;
//    ip and replace it&#039;s reverse &amp;quot;80.168.192&amp;quot; wity your network ip&#039;s&lt;br /&gt;
//    reverse.&lt;br /&gt;
//&lt;br /&gt;
// Please read /usr/share/doc/bind9/README.Debian.gz for information on the &lt;br /&gt;
// structure of BIND configuration files in Debian, *BEFORE* you customize &lt;br /&gt;
// this configuration file.&lt;br /&gt;
//&lt;br /&gt;
// If you are just adding zones, please do that in /etc/bind/named.conf.local&lt;br /&gt;
//&lt;br /&gt;
// references:&lt;br /&gt;
// http://www.arda.homeunix.net/dnssetup.html&lt;br /&gt;
// http://www.madboa.com/geek/soho-bind/&lt;br /&gt;
//&lt;br /&gt;
// notes:&lt;br /&gt;
// 1) The following command should be ran about twice a year to keep&lt;br /&gt;
//    the root servers current:&lt;br /&gt;
//      dig @a.root-servers.net . ns &amp;gt; /etc/bin/db.root&lt;br /&gt;
//    Root name servers don’t change very often so updating this file more &lt;br /&gt;
//    than twice a year is probably overkill. Frequent updates also put undo &lt;br /&gt;
//    load on the root name servers; they have enough to do as it is.&lt;br /&gt;
//&lt;br /&gt;
// 2) File permissions:&lt;br /&gt;
//    /etc/bind/named.conf   root:root   644&lt;br /&gt;
//    /etc/bind/rndc.key     root:bind   640&lt;br /&gt;
//    /etc/bind/rndc.conf    root:root   600&lt;br /&gt;
//    /etc/resolv.conf       root:root   644&lt;br /&gt;
//    /etc/bind              root:bind   775, chmod g+s =&amp;gt; drwxrwsr-x&lt;br /&gt;
//    /etc/dhcp3             root:root   755&lt;br /&gt;
//    /etc/dhcp3/dhcpd.conf  root:root   644&lt;br /&gt;
//&lt;br /&gt;
// Manually Updating Zone Files&lt;br /&gt;
// 1. Use rndc to stop BIND.&lt;br /&gt;
//      sudo rndc stop&lt;br /&gt;
// 2. Remove any .jnl files from the zone file directory.&lt;br /&gt;
//      sudo rm /etc/bind/*.jnl&lt;br /&gt;
// 3. Edit the zone files as necessary. Make sure to increment the serial &lt;br /&gt;
//    number of any file edited.  Note, format of serial number is:&lt;br /&gt;
//    YYYYMMDDNN where YYYY is year, MM is month, DD is day, NN is update&lt;br /&gt;
//    number for that day (i.e., 01, 02, 03,...)&lt;br /&gt;
// 4. Start BIND using its startup script. &lt;br /&gt;
//      sudo /etc/init.d/bind9 start&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
// secret must be the same as in /etc/bind/rndc.conf&lt;br /&gt;
include &amp;quot;/etc/bind/rndc.key&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
// access control list used to limit queries to local net&lt;br /&gt;
acl &amp;quot;internal-net&amp;quot; { 192.168.80/24; 127.0.0.1; };&lt;br /&gt;
&lt;br /&gt;
controls {&lt;br /&gt;
    inet 127.0.0.1 allow { any; } keys { &amp;quot;rndc-key&amp;quot;; };&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
include &amp;quot;/etc/bind/named.conf.options&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
// The single dot (.) is the root of all DNS namespace, so&lt;br /&gt;
// this zone tells named where to start looking for any&lt;br /&gt;
// name on the Internet&lt;br /&gt;
zone &amp;quot;.&amp;quot; IN {&lt;br /&gt;
	type hint;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.root&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
// local intranet zones and reverse zones&lt;br /&gt;
// intranet is wright.local and 192.168.80.0/24&lt;br /&gt;
// the DHCP servers is on linuxmce-dhcp&lt;br /&gt;
// an optional second nameserver would be on linuxmce-ns2&lt;br /&gt;
	&lt;br /&gt;
zone &amp;quot;wright.local&amp;quot; IN {&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.wright.local.zone&amp;quot;;&lt;br /&gt;
	// both allow-update and update-policy can enable DHCP updates,&lt;br /&gt;
	// but update-policy allows more control over what kinds of &lt;br /&gt;
	// updates DHCP can perform on a zone.&lt;br /&gt;
	// allow-update { none; };&lt;br /&gt;
	update-policy { grant linuxmce-dhcp subdomain wright.local. A TXT; };&lt;br /&gt;
	// allow-transfer { key &amp;quot;linuxmce-ns2&amp;quot;; };&lt;br /&gt;
	// notify on zone transfers&lt;br /&gt;
	notify yes;&lt;br /&gt;
};&lt;br /&gt;
	&lt;br /&gt;
zone &amp;quot;80.168.192.in-addr.arpa&amp;quot; IN {&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.wright.local.rev&amp;quot;;&lt;br /&gt;
	// allow-update { none; };&lt;br /&gt;
	update-policy { grant linuxmce-dhcp subdomain 80.168.192.in-addr.arpa. PTR TXT; };&lt;br /&gt;
	// allow-transfer { key &amp;quot;linuxmce-ns2&amp;quot;; };&lt;br /&gt;
	notify yes;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
// be authoritative for the localhost forward and reverse zones, and for&lt;br /&gt;
// broadcast zones as per RFC 1912 (http://www.ietf.org/rfc/rfc1912.txt)&lt;br /&gt;
&lt;br /&gt;
// Where the localhost hostname is defined&lt;br /&gt;
zone &amp;quot;localhost&amp;quot; IN {&lt;br /&gt;
	// a master type means that this server needn&#039;t look&lt;br /&gt;
	// anywhere else for information; the localhost buck&lt;br /&gt;
	// stops here.&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.local&amp;quot;;&lt;br /&gt;
	// don&#039;t allow dynamic DNS clients to update info&lt;br /&gt;
	// about the localhost zone&lt;br /&gt;
	allow-update { none; };&lt;br /&gt;
};&lt;br /&gt;
	&lt;br /&gt;
// Where the 127.0.0.0 network is defined&lt;br /&gt;
zone &amp;quot;127.in-addr.arpa&amp;quot; IN {&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.127&amp;quot;;&lt;br /&gt;
	allow-update { none; };&lt;br /&gt;
};&lt;br /&gt;
	&lt;br /&gt;
zone &amp;quot;0.in-addr.arpa&amp;quot; IN {&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.0&amp;quot;;&lt;br /&gt;
	allow-update { none; };&lt;br /&gt;
};&lt;br /&gt;
	&lt;br /&gt;
zone &amp;quot;255.in-addr.arpa&amp;quot; IN {&lt;br /&gt;
	type master;&lt;br /&gt;
	file &amp;quot;/etc/bind/db.255&amp;quot;;&lt;br /&gt;
	allow-update { none; };&lt;br /&gt;
};&lt;br /&gt;
	&lt;br /&gt;
&lt;br /&gt;
// Include logging config file&lt;br /&gt;
include &amp;quot;/etc/bind/logging.conf&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
// zone &amp;quot;com&amp;quot; { type delegation-only; };&lt;br /&gt;
// zone &amp;quot;net&amp;quot; { type delegation-only; };&lt;br /&gt;
&lt;br /&gt;
// From the release notes:&lt;br /&gt;
//  Because many of our users are uncomfortable receiving undelegated answers&lt;br /&gt;
//  from root or top level domains, other than a few for whom that behaviour&lt;br /&gt;
//  has been trusted and expected for quite some length of time, we have now&lt;br /&gt;
//  introduced the &amp;quot;root-delegations-only&amp;quot; feature which applies delegation-only&lt;br /&gt;
//  logic to all top level domains, and to the root domain.  An exception list&lt;br /&gt;
//  should be specified, including &amp;quot;MUSEUM&amp;quot; and &amp;quot;DE&amp;quot;, and any other top level&lt;br /&gt;
//  domains from whom undelegated responses are expected and trusted.&lt;br /&gt;
// root-delegation-only exclude { &amp;quot;DE&amp;quot;; &amp;quot;MUSEUM&amp;quot;; };&lt;br /&gt;
&lt;br /&gt;
include &amp;quot;/etc/bind/named.conf.local&amp;quot;;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/named.conf.options===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
options {&lt;br /&gt;
	// tell named where to find files mentioned below&lt;br /&gt;
	directory &amp;quot;/var/cache/bind&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
	// file that contains the process id when bind is running&lt;br /&gt;
	pid-file &amp;quot;/var/run/bind/run/named.pid&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
	// enable statistics&lt;br /&gt;
	statistics-file &amp;quot;/var/named/named.stats&amp;quot;;&lt;br /&gt;
	zone-statistics yes;&lt;br /&gt;
&lt;br /&gt;
	dump-file &amp;quot;/var/named/named.dump&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
	// If there is a firewall between you and nameservers you want&lt;br /&gt;
	// to talk to, you might need to uncomment the query-source&lt;br /&gt;
	// directive below.  Previous versions of BIND always asked&lt;br /&gt;
	// questions using port 53, but BIND 8.1 and later use an unprivileged&lt;br /&gt;
	// port by default.&lt;br /&gt;
	// query-source address * port 53;&lt;br /&gt;
&lt;br /&gt;
	// If your ISP provided one or more IP addresses for stable &lt;br /&gt;
	// nameservers, you probably want to use them as forwarders.  &lt;br /&gt;
	// Uncomment the following block, and insert the addresses replacing &lt;br /&gt;
	// the all-0&#039;s placeholder.&lt;br /&gt;
&lt;br /&gt;
	// The forwarders option tells BIND to not use iterative queries itself &lt;br /&gt;
	// for information it doesn’t already know about but to forward a &lt;br /&gt;
	// recursive query to the name servers specified instead.&lt;br /&gt;
	include &amp;quot;/etc/bind/named.conf.forwarders&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
	// conform to RFC1035&lt;br /&gt;
	auth-nxdomain no;&lt;br /&gt;
&lt;br /&gt;
	// on a multi-homed host, you might want to tell named&lt;br /&gt;
	// to listen for queries only on certain interfaces&lt;br /&gt;
	listen-on-v6 { any; };&lt;br /&gt;
	listen-on { &amp;quot;internal-net&amp;quot;; };&lt;br /&gt;
&lt;br /&gt;
	// to allow only specific hosts to use the DNS server:&lt;br /&gt;
	allow-query { &amp;quot;internal-net&amp;quot;; };&lt;br /&gt;
&lt;br /&gt;
	// sets BIND’s default behaviour to refuse all zone transfers. &lt;br /&gt;
	// Without setting this option, anyone can transfer any zone.&lt;br /&gt;
	allow-transfer { none; };&lt;br /&gt;
&lt;br /&gt;
	// do not generate notify messages for all zones on a restart.&lt;br /&gt;
	// override for authorative zones&lt;br /&gt;
	notify no;&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/logging.conf===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
logging {&lt;br /&gt;
&lt;br /&gt;
	channel default_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/default.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel general_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/general.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel database_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/database.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel security_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/security.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel config_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/config.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel resolver_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/resolver.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel xfer-in_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/xfer-in.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel xfer-out_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/xfer-out.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel notify_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/notify.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel client_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/client.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel unmatched_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/unmatched.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel queries_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/queries.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel network_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/network.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel update_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/update.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel dispatch_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/dispatch.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel dnssec_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/dnssec.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
	channel lame-servers_file {&lt;br /&gt;
		file &amp;quot;/var/log/named/lame-servers.log&amp;quot; versions 3 size 5m;&lt;br /&gt;
		severity dynamic;&lt;br /&gt;
		print-time yes;&lt;br /&gt;
		};&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
	category lame-servers {&lt;br /&gt;
		lame-servers_file;&lt;br /&gt;
		};&lt;br /&gt;
	category dnssec {&lt;br /&gt;
		dnssec_file;&lt;br /&gt;
		};&lt;br /&gt;
	category dispatch {&lt;br /&gt;
		dispatch_file;&lt;br /&gt;
		};&lt;br /&gt;
	category update {&lt;br /&gt;
		update_file;&lt;br /&gt;
		};&lt;br /&gt;
	category network {&lt;br /&gt;
		network_file;&lt;br /&gt;
		};&lt;br /&gt;
	category queries {&lt;br /&gt;
		queries_file;&lt;br /&gt;
		};&lt;br /&gt;
	category unmatched {&lt;br /&gt;
		unmatched_file;&lt;br /&gt;
		};&lt;br /&gt;
	category client {&lt;br /&gt;
		client_file;&lt;br /&gt;
		};&lt;br /&gt;
	category notify {&lt;br /&gt;
		notify_file;&lt;br /&gt;
		};&lt;br /&gt;
	category xfer-out {&lt;br /&gt;
		xfer-out_file;&lt;br /&gt;
		};&lt;br /&gt;
	category xfer-in {&lt;br /&gt;
		xfer-in_file;&lt;br /&gt;
		};&lt;br /&gt;
	category resolver {&lt;br /&gt;
		resolver_file;&lt;br /&gt;
		};&lt;br /&gt;
	category config {&lt;br /&gt;
		config_file;&lt;br /&gt;
		};&lt;br /&gt;
	category security {&lt;br /&gt;
		security_file;&lt;br /&gt;
		};&lt;br /&gt;
	category database {&lt;br /&gt;
		database_file;&lt;br /&gt;
		};&lt;br /&gt;
	category general {&lt;br /&gt;
		general_file;&lt;br /&gt;
		};&lt;br /&gt;
	category default {&lt;br /&gt;
		default_file;&lt;br /&gt;
		};&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/rndc.conf===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
options {&lt;br /&gt;
	default-server  localhost;&lt;br /&gt;
	default-key     &amp;quot;rndc-key&amp;quot;;&lt;br /&gt;
	default-port 953;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
server localhost {&lt;br /&gt;
	key     &amp;quot;rndc-key&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
key &amp;quot;rndc-key&amp;quot; {&lt;br /&gt;
	algorithm       hmac-md5;&lt;br /&gt;
	secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/rndc.key===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
key &amp;quot;rndc-key&amp;quot; {&lt;br /&gt;
        algorithm	hmac-md5;&lt;br /&gt;
        secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
key &amp;quot;linuxmce-dhcp&amp;quot; {&lt;br /&gt;
        algorithm	hmac-md5;&lt;br /&gt;
        secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
key &amp;quot;linuxmce-ns2&amp;quot; {&lt;br /&gt;
        algorithm	hmac-md5;&lt;br /&gt;
        secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/db.wright.local.zone===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
;&lt;br /&gt;
; BIND data file for wright.local&lt;br /&gt;
; ref. http://www.redhat.com/docs/manuals/linux/RHL-9-Manual/ref-guide/s1-bind-zone.html&lt;br /&gt;
;&lt;br /&gt;
$TTL 86400 ; time to live : 86400s = 1 day&lt;br /&gt;
; Start Of Authority record, proclaims important authoritative information &lt;br /&gt;
; about a namespace to the nameserver.&lt;br /&gt;
@               IN SOA  dcerouter.wright.local        roy@wright.org (&lt;br /&gt;
                2008013101      ;serial (YYYYMMDDNN where N = 01,02,03,...)&lt;br /&gt;
                10800           ;refresh (3 hours)&lt;br /&gt;
                7200            ;retry (2 hours)&lt;br /&gt;
                36000000        ;expire (10,000 hours = 416 2/3 days)&lt;br /&gt;
                86400)          ;default minimum ttl&lt;br /&gt;
;&lt;br /&gt;
; NameServer record, which announces the authoritative nameservers for a particular zone.&lt;br /&gt;
;&lt;br /&gt;
                IN NS   dcerouter.wright.local.&lt;br /&gt;
;&lt;br /&gt;
; Address records specify an IP address to assign to a name&lt;br /&gt;
;&lt;br /&gt;
dcerouter       IN A            192.168.80.1&lt;br /&gt;
dad-kubuntu     IN A            192.168.80.21&lt;br /&gt;
royw-gentoo	IN A		192.168.80.20&lt;br /&gt;
;&lt;br /&gt;
; Canonical name records, maps one name to another. &lt;br /&gt;
;&lt;br /&gt;
linuxmce        IN CNAME        dcerouter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/bind/db.wright.local.rev===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
;&lt;br /&gt;
; BIND reverse data file for wright.local&lt;br /&gt;
; ref. http://www.redhat.com/docs/manuals/linux/RHL-9-Manual/ref-guide/s1-bind-zone.html&lt;br /&gt;
;&lt;br /&gt;
$ORIGIN 80.168.192.in-addr.arpa.&lt;br /&gt;
$TTL 86400 ; time to live : 86400s = 1 day&lt;br /&gt;
; Start Of Authority record, proclaims important authoritative information &lt;br /&gt;
; about a namespace to the nameserver.&lt;br /&gt;
@               IN SOA  dcerouter.wright.local        roy@wright.org (&lt;br /&gt;
                2008013101      ;serial (YYYYMMDDNN where N = 01,02,03,...)&lt;br /&gt;
                10800           ;refresh (3 hours)&lt;br /&gt;
                7200            ;retry (2 hours)&lt;br /&gt;
                36000000        ;expire (10,000 hours = 416 2/3 days)&lt;br /&gt;
                86400)          ;default minimum ttl&lt;br /&gt;
;&lt;br /&gt;
; NameServer record, which announces the authoritative nameservers for a particular zone.&lt;br /&gt;
;&lt;br /&gt;
                IN NS   dcerouter.wright.local.&lt;br /&gt;
;&lt;br /&gt;
; PTR — PoinTeR record, designed to point to another part of the namespace.&lt;br /&gt;
;&lt;br /&gt;
1               IN PTR  dcerouter.wright.local.&lt;br /&gt;
21              IN PTR  dad-kubuntu.wright.local.&lt;br /&gt;
20		IN PTR	royw-gentoo.wright.local.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/dhcp3/dhcpd.conf===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
option domain-name-servers 192.168.80.1;&lt;br /&gt;
authoritative;&lt;br /&gt;
&lt;br /&gt;
option routers 192.168.80.1;&lt;br /&gt;
option subnet-mask 255.255.255.0;&lt;br /&gt;
&lt;br /&gt;
# lease IPs for 1 day, maximum 1 week&lt;br /&gt;
default-lease-time 86400;&lt;br /&gt;
max-lease-time 604800;&lt;br /&gt;
&lt;br /&gt;
# dynamic DNS updates&lt;br /&gt;
ddns-updates on;&lt;br /&gt;
ddns-update-style interim;&lt;br /&gt;
ddns-domainname &amp;quot;wright.local.&amp;quot;;&lt;br /&gt;
ddns-rev-domainname &amp;quot;in-addr.arpa.&amp;quot;;&lt;br /&gt;
ddns-ttl 14400;&lt;br /&gt;
&lt;br /&gt;
# don&#039;t let clients modify their own A records&lt;br /&gt;
ignore client-updates;&lt;br /&gt;
&lt;br /&gt;
key &amp;quot;linuxmce-dhcp&amp;quot; {&lt;br /&gt;
	algorithm       hmac-md5;&lt;br /&gt;
	secret		&amp;quot;&amp;lt;paste your key here&amp;gt;&amp;quot;;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
zone wright.local {&lt;br /&gt;
	primary 192.168.80.1;&lt;br /&gt;
	key &amp;quot;linuxmce-dhcp&amp;quot;;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
zone 80.168.192.in-addr.arpa {&lt;br /&gt;
	primary 192.168.80.1;&lt;br /&gt;
	key &amp;quot;linuxmce-dhcp&amp;quot;;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
option space pxelinux;&lt;br /&gt;
option pxelinux.magic code 208 = string;&lt;br /&gt;
option pxelinux.configfile code 209 = text;&lt;br /&gt;
option pxelinux.pathprefix code 210 = text;&lt;br /&gt;
option pxelinux.reboottime code 211 = unsigned integer 32;&lt;br /&gt;
&lt;br /&gt;
subnet 192.168.80.0 netmask 255.255.255.0 {&lt;br /&gt;
	next-server 192.168.80.1;&lt;br /&gt;
	filename &amp;quot;/tftpboot/pxelinux.0&amp;quot;;&lt;br /&gt;
	option pxelinux.reboottime = 30;&lt;br /&gt;
&lt;br /&gt;
	option domain-name &amp;quot;wright.local&amp;quot;;&lt;br /&gt;
	option domain-name-servers 192.168.80.1;&lt;br /&gt;
	option routers 192.168.80.1;&lt;br /&gt;
&lt;br /&gt;
	default-lease-time 86400;&lt;br /&gt;
	max-lease-time 604800;&lt;br /&gt;
	pool {&lt;br /&gt;
		 allow unknown-clients;&lt;br /&gt;
		 range 192.168.80.129 192.168.80.254; &lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
# PXE booting machines&lt;br /&gt;
group {&lt;br /&gt;
	next-server 192.168.80.1;&lt;br /&gt;
	filename &amp;quot;/tftpboot/pxelinux.0&amp;quot;;&lt;br /&gt;
	option pxelinux.reboottime = 30;&lt;br /&gt;
&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
# regular machines&lt;br /&gt;
group {&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
# CORE (1) has bad mac address: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===/etc/resolv.conf===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
domain wright.local&lt;br /&gt;
nameserver localhost&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Juanfe</name></author>
	</entry>
	<entry>
		<id>http://wiki.linuxmce.org/index.php?title=SMB_/_Samba_NAS_Configurations&amp;diff=15506</id>
		<title>SMB / Samba NAS Configurations</title>
		<link rel="alternate" type="text/html" href="http://wiki.linuxmce.org/index.php?title=SMB_/_Samba_NAS_Configurations&amp;diff=15506"/>
		<updated>2008-09-05T22:09:24Z</updated>

		<summary type="html">&lt;p&gt;Juanfe: /* Adding fileserver on the external network */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Category: Tutorials]]&lt;br /&gt;
&lt;br /&gt;
[[How to setup Samba with two workgroups?]]&lt;br /&gt;
[[How to setup Samba to follow symbolic links?]]&lt;br /&gt;
&lt;br /&gt;
Problem: we have shares for each users. if I want to access it from Windows, I have to enter password. if I don&#039;t this on first access, windows won&#039;t ask my anymore to enter password and just denies access. How can I force windows, to reenter password for share ???&lt;br /&gt;
&lt;br /&gt;
If your samba password doesn&#039;t work then run this on core to update your samba password:&lt;br /&gt;
 sudo smbpasswd pluto_USER&lt;br /&gt;
where USER is your username. For instance to change john&#039;s password run sudo smbpasswd pluto_john&lt;br /&gt;
&lt;br /&gt;
== Adding fileserver on the external network ==&lt;br /&gt;
The external network does not get scanned for Samba servers. You can easily add a new server by going into the web admin&lt;br /&gt;
* Click Show Device Tree&lt;br /&gt;
* Click CORE&lt;br /&gt;
* On the right hand side, click Create Child Device&lt;br /&gt;
* Click Pick Device Template&lt;br /&gt;
* In the popup select Manufacturer-&amp;gt;Generic and Device Category-&amp;gt;File Server from the drop down menus; you can also enter device template ID 1837 in the &amp;quot;Do you know the ID of the device template?&amp;quot; field&lt;br /&gt;
* Now, it is important to fill out 2 fields&lt;br /&gt;
** The IP address&lt;br /&gt;
** &#039;&#039;&#039;and&#039;&#039;&#039; the MAC address&lt;br /&gt;
* The username and password are only needed if the file server requires them.&lt;br /&gt;
* There is currently a bug in the webadmin which causes this file server to not be scanned for shares.&lt;br /&gt;
=== Scanning For Shares ===&lt;br /&gt;
The good thing about LinuxMCE is, that LinuxMCE routinely scans the internal network for servers, and if found, scans those servers for shares to be mounted and spidered for media. To initiate the scan for shares manually (because of a manually added server) do the following&lt;br /&gt;
* Open a terminal&lt;br /&gt;
* Execute&lt;br /&gt;
 /usr/pluto/bin/Configure_1837.sh -d &amp;lt;device-id&amp;gt; -i &#039;&amp;lt;ip-address&amp;gt;&#039; -m &#039;&amp;lt;mac-address&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
This will execute the scan for new shares. The shares will be presented to you on any orbiter.&lt;/div&gt;</summary>
		<author><name>Juanfe</name></author>
	</entry>
	<entry>
		<id>http://wiki.linuxmce.org/index.php?title=LinuxMCE_System_Update&amp;diff=15475</id>
		<title>LinuxMCE System Update</title>
		<link rel="alternate" type="text/html" href="http://wiki.linuxmce.org/index.php?title=LinuxMCE_System_Update&amp;diff=15475"/>
		<updated>2008-09-03T21:18:31Z</updated>

		<summary type="html">&lt;p&gt;Juanfe: /* This information seems to be outdated. At least in 0710b3 there are no such files. */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{NeedsToBeFixed}}&lt;br /&gt;
== General Info ==&lt;br /&gt;
&#039;&#039;&#039;Package:&#039;&#039;&#039; pluto-update-system&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Directory:&#039;&#039;&#039; src/PlutoUpdateSystem&lt;br /&gt;
&lt;br /&gt;
== File Details ==&lt;br /&gt;
&lt;br /&gt;
= This information seems to be outdated. At least in 0710b3 there are no such files. =&lt;br /&gt;
&lt;br /&gt;
LinuxMCE live updating system is taking care of by 4 shell scripts:&lt;br /&gt;
&lt;br /&gt;
;DownloadUpdates.sh: This script is runned by cron and downloads all the needed deb packages for doing an dist-upgrade on the Core and all of it&#039;s MDs. Also this script calls the NotifyUpdates.sh script to notify the user that the updates are available and he shoule reboot certain machine so they can be installed. This script runs only on the Core.&lt;br /&gt;
&lt;br /&gt;
;ApplyUpdates.sh: This is a startup script and is runned by the /etc/init.d/fastboot/rcS.d system initialization script before any of the LinuxMCE services get started. It checks if DownloadUpdates has downloaded all the needed packages and if so, it trigers a dist-updagrade. If a new kernel is one of the updated packages he also takes care of rebooting the system after all the updates are installed. This script is run by Core and all the Diskless MDs.&lt;br /&gt;
&lt;br /&gt;
;NotifyUpdates.sh: Notifies the user via orbiters that updates are available and that certain machines should do a reboot so they can update. It takes the  &#039;&#039;PK_Device&#039;&#039; of the machine that needs to reboot as a parameter.&lt;br /&gt;
&lt;br /&gt;
;ForceUpdates.sh: Force system update. It kill all instances of already run DownloadUpdates.sh and ForceUpdates.sh, display notification message about reboot on all Orbiters and send a command to the Core to reboot it and start process of system update.&lt;br /&gt;
[[Category: LinuxMCEBashScripts]]&lt;br /&gt;
&lt;br /&gt;
== How to upgrade manually ==&lt;br /&gt;
&lt;br /&gt;
--[[User:Totallymaxed|Totallymaxed]] 08:14, 2 March 2008 (PST)&lt;br /&gt;
I would suggest the following procedure for forcing the download of updates under 0704;&lt;br /&gt;
&lt;br /&gt;
Go to the /usr/pluto/bin directory&lt;br /&gt;
&lt;br /&gt;
run the following script;&lt;br /&gt;
&lt;br /&gt;
  sudo ./LMCEUpdate_DownloadXml.sh &amp;lt;return&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This will take some time while the update archives are downloaded... so be patient! Once the updates are downloaded you should be asked whether you want to apply the update in the Orbiter - click &amp;quot;Yes&amp;quot; to apply updates and thats it.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Quoting [http://plutohome.com/wiki/index.php/User:Nite_man nite_man] from forum :&lt;br /&gt;
&lt;br /&gt;
You can do upgrade manually. Go to the /usr/pluto/bin and run one by one two scripts: &lt;br /&gt;
&lt;br /&gt;
 &lt;br /&gt;
 ./DownloadUpdates.sh &lt;br /&gt;
&lt;br /&gt;
and &lt;br /&gt;
&lt;br /&gt;
 ./ApplyUpdates.sh  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The first one will download all updated packages and the second one will apply changes to the LinuxMCE installation. &lt;br /&gt;
&lt;br /&gt;
Note: you should wain until DownloadUpdates.sh finish. Also, you can ignore some warnings which may be generated by this script (you can see the log /var/log/pluto/DownloadUpdates.log)&lt;br /&gt;
&lt;br /&gt;
Another way to perform system update is use the Orbiter:&lt;br /&gt;
&lt;br /&gt;
   More --&amp;gt; Advanced Options --&amp;gt; Force Upgrade Now&lt;br /&gt;
&lt;br /&gt;
It forces reboot your core and starts upgrade.&lt;/div&gt;</summary>
		<author><name>Juanfe</name></author>
	</entry>
	<entry>
		<id>http://wiki.linuxmce.org/index.php?title=Java_Mobile_Orbiter&amp;diff=15292</id>
		<title>Java Mobile Orbiter</title>
		<link rel="alternate" type="text/html" href="http://wiki.linuxmce.org/index.php?title=Java_Mobile_Orbiter&amp;diff=15292"/>
		<updated>2008-08-16T21:09:33Z</updated>

		<summary type="html">&lt;p&gt;Juanfe: /* Install the application on the phone */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Category: Hardware]]&lt;br /&gt;
[[Category: Phones]]&lt;br /&gt;
[[Category: Orbiters]]&lt;br /&gt;
&lt;br /&gt;
[[Image:N73-Javamo.jpg|thumb|200px|JavaMO on the Nokia N73]]&lt;br /&gt;
[[Image:Javamo p1 ui1.jpg|thumb|200px|UI1 with touchscreen on the P1]]&lt;br /&gt;
[[Image:Javamo-e65-ui1.jpg|thumb|200px|UI1 on the Nokia E65]]&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
The JavaMO is a lightweight [[Mobile_Orbiter|Mobile Orbiter]] client. It receives rendered pictures from the [[Bluetooth_Dongle|Bluetooth dongle]] [[Orbiter]] and sends keystrokes and pointer events back. The protocol used over Bluetooth is [[BD_-_Bidirectional_command_processor|BD]].&lt;br /&gt;
&lt;br /&gt;
JavaMO is under active development. An alpha version can be found on the charonmedia svn tree or on http://vt100.at/javamo/.&lt;br /&gt;
= Changelog =&lt;br /&gt;
* 0.0.2 - Touchscreen support, fix unhandled exception on dcerouter reload&lt;br /&gt;
* 0.0.1 - Proof of concept, basic functionality&lt;br /&gt;
&lt;br /&gt;
= Installation =&lt;br /&gt;
== Phone ==&lt;br /&gt;
For most phones you need the jad and the jar file. Copy both to the phone and select the jad from the file or application manager.&lt;br /&gt;
== Core/MD ==&lt;br /&gt;
You have to exchange the libBDCommon.so with the provided one on all 0710 cores or MD&#039;s with a Bluetooth_Dongle. Download the replacement libBDCommon.so from http://vt100.at/javamo/ . In /usr/pluto/lib rename libBDCommon.so to libBDCommon.so.old, then copy the new version you downloaded into this directory and reboot.&lt;br /&gt;
== LMCE Plug and Play detection ==&lt;br /&gt;
When LMCE asks you for the type of phone select &amp;quot;Symbian S60&amp;quot;. The application push will fail. Thats ok. Just answer no to the question if LMCE should resend it.&lt;br /&gt;
== Screen Size, UI Variant ==&lt;br /&gt;
Go to the Orbiter in the pluto-admin web interface (select Orbiters in the Wizard on the left)&lt;br /&gt;
Adapt the PK_UI, PK_Size and resolution values to match your phones display. If you have no touchscreen on the phone stick with symbian for PK_UI, otherwise choose the normal variant.&lt;br /&gt;
&lt;br /&gt;
= See also =&lt;br /&gt;
[[Mobile_Orbiter|Mobile Orbiter]]&lt;br /&gt;
&lt;br /&gt;
[[LinuxMCE_Orbiter_Symbian_Programmer%27s_Guide|LinuxMCE Orbiter Symbian Programmer&#039;s Guide]]&lt;br /&gt;
&lt;br /&gt;
= Links =&lt;br /&gt;
[http://forum.linuxmce.org/index.php?topic=2893 Forum thread re JavaMO]&lt;br /&gt;
&lt;br /&gt;
= JavaMO development guide =&lt;br /&gt;
== Preparations ==&lt;br /&gt;
=== Checkout ===&lt;br /&gt;
Checkout the source from the charonmedia.org svn tree:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
svn co http://svn.charonmedia.org/svn/home/hari/javamo&lt;br /&gt;
cd javamo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Installing Java ===&lt;br /&gt;
First we install the Java SDK. I used version 6 update 6. Download it from the sun download center: http://java.sun.com/javase/downloads/index.jsp&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
chmod +x ./jdk-6u6-linux-i586.bin&lt;br /&gt;
./jdk-6u6-linux-i586.bin&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
That gives us the directory &amp;quot;jdk1.6.0_06&amp;quot;. &lt;br /&gt;
&lt;br /&gt;
Now install the wireless toolkit version 2.5.2: http://java.sun.com/products/sjwtoolkit/download.html&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./sun_java_wireless_toolkit-2_5_2-linux.bin&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Specify the _full_ path to the &amp;quot;jdk1.6.0_06/bin&amp;quot; directory (this example assumes javamo was checked out to &amp;quot;/home/hari/src/javamo&amp;quot;):&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Enter a path to the Java 2 SDK: /home/hari/src/javamo/jdk1.6.0_06/bin&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
After the installation you should have the following subdirectories in the javamo directory:&lt;br /&gt;
* jdk1.6.0_06&lt;br /&gt;
* WTK2.5.2&lt;br /&gt;
&lt;br /&gt;
== Building the application ==&lt;br /&gt;
just run &amp;quot;make&amp;quot;:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
make&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
You will find the &amp;quot;JavaMO.jad&amp;quot; and &amp;quot;JavaMO.jar&amp;quot; file in the &amp;quot;output&amp;quot; directory if the compile succeeds.&lt;br /&gt;
== Install the application on the phone ==&lt;br /&gt;
That strongly depends on the type of phone and sometimes your mobile carrier. &lt;br /&gt;
&lt;br /&gt;
===Nokia Symbian devices===&lt;br /&gt;
For Nokia Symbian Series with a memory card you can use the &amp;quot;install&amp;quot; target in the &amp;quot;Makefile&amp;quot;. Just adapt the Bluetooth address of the phone in the &amp;quot;Makefile&amp;quot; and run:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
make install&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Then go to the file browser on the phone, switch to the memory card and select the &amp;quot;JavaMO.jad&amp;quot; file. Make sure you have enabled the installation of unsigned applications in the application manager.&lt;br /&gt;
&lt;br /&gt;
===Developers in the United States===&lt;br /&gt;
If you are developing in the United States, the process to install JavaMO on your phone depends heavily on the operator you have for your mobile.&lt;br /&gt;
&lt;br /&gt;
If you have a Sprint or Nextel phone, you can install the MIDlet over the air using [http://developer.sprint.com/site/global/develop/upload_your_content/p_upload_your_content.jsp | Sprint ADP&#039;s OTA content uploader].  &lt;br /&gt;
&lt;br /&gt;
On a Nextel phone, you can also install it using a cable downloading the [https://developer.motorola.com/docstools/idenjal/| iDEN Java Application Loader]. There are mechanisms for cable-loading an application onto a variety of Sprint CDMA phones, but these vary greatly in their reliability/ease of access.&lt;br /&gt;
&lt;br /&gt;
If you are working with a Verizon phone, you will need to have a BREW developer license and toolkit to load an application onto the device. Chances are you don&#039;t have this.&lt;br /&gt;
&lt;br /&gt;
If you are working with an AT&amp;amp;T or T-Mobile GSM phone, you should put the JAD and JAR files in a publicly accessible web server, then point the web browser of your phone to the JAD file -- it should begin the download automatically.&lt;br /&gt;
&lt;br /&gt;
== Building the documentation ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
make javadoc&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Direct your browser to the file &amp;quot;doc/index.html&amp;quot;&lt;br /&gt;
== On device debugging with a Nokia N and E series phone and Linux ==&lt;br /&gt;
To get the output from the application running on the phone on a computer screen, do the following:&lt;br /&gt;
* Register with Nokia and get the Symbian SDK&lt;br /&gt;
* Transfer the &amp;quot;EcmtAgent_MIDP.SIS&amp;quot; application on the phone and run it, uses bluetooth per default&lt;br /&gt;
* Go to system - application manager on the phone and install the &amp;quot;RedMIDlet.jar&amp;quot; (shows &amp;quot;not installed&amp;quot;)&lt;br /&gt;
* Go to the application folder and run the &amp;quot;Sdt.out.redir&amp;quot; application&lt;br /&gt;
* do a &amp;quot;sdptool browse&amp;quot; on your notebook with a supported bluetooth dongle (hci device must be up) to find out the rfcomm port. You should see something like this:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Service Name: EcmtAgent&lt;br /&gt;
Service Description: Bluetooth bearer for EcmtAgent&lt;br /&gt;
Service RecHandle: 0x10043&lt;br /&gt;
Service Class ID List:&lt;br /&gt;
  &amp;quot;Serial Port&amp;quot; (0x1101)&lt;br /&gt;
Protocol Descriptor List:&lt;br /&gt;
  &amp;quot;L2CAP&amp;quot; (0x0100)&lt;br /&gt;
    PSM: 3&lt;br /&gt;
  &amp;quot;RFCOMM&amp;quot; (0x0003)&lt;br /&gt;
    Channel: 3&lt;br /&gt;
Language Base Attr List:&lt;br /&gt;
  code_ISO639: 0x656e&lt;br /&gt;
  encoding:    0x6a&lt;br /&gt;
  base_offset: 0x100&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* run a command like the following after substitution of the Bluetooth address and the rfcomm channel:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
while $a; do rfcomm release /dev/rfcomm0 ; rfcomm bind /dev/rfcomm0 00:17:C4:C3:36:24 3 ; cat /dev/rfcomm0 ; done&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Example output (process list, system info and the javamo console output):&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
0x000004380x10204578CPU 191985135 1 DRIVES C 46539776 23182336;D 5629952 5627904;E 2030960640 30343168;Z 20971520 0; RAM 5627904 46137344 20971520 APPLICATIONS JavaMO 692 -1 -1 -1 2654876;EiksrvBackdrop 97 -1 -1 -1 106830749;Menü 163 -1 -1 -1 5559722;EcmtAgent 601 -1 -1 -1 1263824;Standby-Modus 150 -1 -1 -1 16982482;Sdt.out_redir 648 -1 -1 -1 243194;Telefon 146 -1 -1 -1 11353271;Protokoll 394 -1 -1 -1 1592987;Kontakte 330 -1 -1 -1 1927398;MultimediaList 161 -1 -1 -1 510864;SysAp 122 -1 -1 -1 4535278; 77 -1 -1 -1 9002;Anykey 148 -1 -1 -1 290618;blinkingled 240 -1 -1 -1 266265;Player 266 -1 -1 -1 331695;Autolock 238 -1 -1 -1 103759;Galerie 310 -1 -1 -1 1241149;screensaver 154 -1 -1 -1 16530914;akncapserver 97 -1 -1 -1 106830749;btnotifappserver 108 -1 -1 -1 684661;Securitynotifierappserver 106 -1 -1 -1 311309;VolumePopup 266 -1 -1 -1 331695;MPlayerInfoPopup 266 -1 -1 -1 331695;VolumePopup 150 -1 -1 -1 16982482;CTSecDlgAppServer 110 -1 -1 -1 63354;SyncMLNotifierAppServer 114 -1 -1 -1 59234;cconndlgappserver 116 -1 -1 -1 62744;locnotifierappserver 104 -1 -1 -1 63476;0x000000780x1020456c&lt;br /&gt;
ReceiveLong: long result: 102&lt;br /&gt;
Got BD_CP_SHOW_IMAGE&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
== Java J2ME simulator with real bluetooth hardware access over bluez ==&lt;br /&gt;
* Get the mpowerplayer SDK: http://mpowerplayer.com/?cat=6&lt;br /&gt;
* Install it&lt;br /&gt;
* Either buy (http://www.avetana-gmbh.de) or compile (http://sourceforge.net/projects/avetanabt/) the avetana bluetooth stack&lt;br /&gt;
* put the &amp;quot;AvetanaBluetooth.jar&amp;quot; file in the mpp-sdk top level directory&lt;br /&gt;
* adapt the path to the mpp installation in the javamo Makefile&lt;br /&gt;
* run &amp;quot;make bluezsim&amp;quot; to run JavaMO in the sim with bluez access over JSR082&lt;br /&gt;
&lt;br /&gt;
= Phone Specifics =&lt;br /&gt;
== Nokia E61 ==&lt;br /&gt;
The Nokia E61 has a full keyboard. To select the numbers you have to &#039;&#039;&#039;hold&#039;&#039;&#039; down the blue function key, and press the number together with it.&lt;/div&gt;</summary>
		<author><name>Juanfe</name></author>
	</entry>
	<entry>
		<id>http://wiki.linuxmce.org/index.php?title=Java_Mobile_Orbiter&amp;diff=15166</id>
		<title>Java Mobile Orbiter</title>
		<link rel="alternate" type="text/html" href="http://wiki.linuxmce.org/index.php?title=Java_Mobile_Orbiter&amp;diff=15166"/>
		<updated>2008-08-01T15:57:20Z</updated>

		<summary type="html">&lt;p&gt;Juanfe: /* Install the application on the phone */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Category: Hardware]]&lt;br /&gt;
[[Category: Phones]]&lt;br /&gt;
[[Category: Orbiters]]&lt;br /&gt;
&lt;br /&gt;
[[Image:N73-Javamo.jpg|thumb|200px|JavaMO on the Nokia N73]]&lt;br /&gt;
[[Image:Javamo p1 ui1.jpg|thumb|200px|UI1 with touchscreen on the P1]]&lt;br /&gt;
[[Image:Javamo-e65-ui1.jpg|thumb|200px|UI1 on the Nokia E65]]&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
The JavaMO is a lightweight [[Mobile_Orbiter|Mobile Orbiter]] client. It receives rendered pictures from the [[Bluetooth_Dongle|Bluetooth dongle]] [[Orbiter]] and sends keystrokes and pointer events back. The protocol used over Bluetooth is [[BD_-_Bidirectional_command_processor|BD]].&lt;br /&gt;
&lt;br /&gt;
JavaMO is under active development. An alpha version can be found on the charonmedia svn tree or on http://vt100.at/javamo/.&lt;br /&gt;
= Changelog =&lt;br /&gt;
* 0.0.2 - Touchscreen support, fix unhandled exception on dcerouter reload&lt;br /&gt;
* 0.0.1 - Proof of concept, basic functionality&lt;br /&gt;
&lt;br /&gt;
= Installation =&lt;br /&gt;
== Phone ==&lt;br /&gt;
For most phones you need the jad and the jar file. Copy both to the phone and select the jad from the file or application manager.&lt;br /&gt;
== Core/MD ==&lt;br /&gt;
You have to exchange the libBDCommon.so with the provided one on all 0710 cores or MD&#039;s with a Bluetooth_Dongle. Download the replacement libBDCommon.so from http://vt100.at/javamo/ . In /usr/pluto/lib rename libBDCommon.so to libBDCommon.so.old, then copy the new version you downloaded into this directory and reboot.&lt;br /&gt;
== LMCE Plug and Play detection ==&lt;br /&gt;
When LMCE asks you for the type of phone select &amp;quot;Symbian S60&amp;quot;. The application push will fail. Thats ok. Just answer no to the question if LMCE should resend it.&lt;br /&gt;
== Screen Size, UI Variant ==&lt;br /&gt;
Go to the Orbiter in the pluto-admin web interface (select Orbiters in the Wizard on the left)&lt;br /&gt;
Adapt the PK_UI, PK_Size and resolution values to match your phones display. If you have no touchscreen on the phone stick with symbian for PK_UI, otherwise choose the normal variant.&lt;br /&gt;
&lt;br /&gt;
= See also =&lt;br /&gt;
[[Mobile_Orbiter|Mobile Orbiter]]&lt;br /&gt;
&lt;br /&gt;
[[LinuxMCE_Orbiter_Symbian_Programmer%27s_Guide|LinuxMCE Orbiter Symbian Programmer&#039;s Guide]]&lt;br /&gt;
&lt;br /&gt;
= Links =&lt;br /&gt;
[http://forum.linuxmce.org/index.php?topic=2893 Forum thread re JavaMO]&lt;br /&gt;
&lt;br /&gt;
= JavaMO development guide =&lt;br /&gt;
== Preparations ==&lt;br /&gt;
=== Checkout ===&lt;br /&gt;
Checkout the source from the charonmedia.org svn tree:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
svn co http://svn.charonmedia.org/svn/home/hari/javamo&lt;br /&gt;
cd javamo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Installing Java ===&lt;br /&gt;
First we install the Java SDK. I used version 6 update 6. Download it from the sun download center: http://java.sun.com/javase/downloads/index.jsp&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
chmod +x ./jdk-6u6-linux-i586.bin&lt;br /&gt;
./jdk-6u6-linux-i586.bin&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
That gives us the directory &amp;quot;jdk1.6.0_06&amp;quot;. &lt;br /&gt;
&lt;br /&gt;
Now install the wireless toolkit version 2.5.2: http://java.sun.com/products/sjwtoolkit/download.html&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./sun_java_wireless_toolkit-2_5_2-linux.bin&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Specify the _full_ path to the &amp;quot;jdk1.6.0_06/bin&amp;quot; directory (this example assumes javamo was checked out to &amp;quot;/home/hari/src/javamo&amp;quot;):&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Enter a path to the Java 2 SDK: /home/hari/src/javamo/jdk1.6.0_06/bin&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
After the installation you should have the following subdirectories in the javamo directory:&lt;br /&gt;
* jdk1.6.0_06&lt;br /&gt;
* WTK2.5.2&lt;br /&gt;
&lt;br /&gt;
== Building the application ==&lt;br /&gt;
just run &amp;quot;make&amp;quot;:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
make&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
You will find the &amp;quot;JavaMO.jad&amp;quot; and &amp;quot;JavaMO.jar&amp;quot; file in the &amp;quot;output&amp;quot; directory if the compile succeeds.&lt;br /&gt;
== Install the application on the phone ==&lt;br /&gt;
That strongly depends on the type of phone. For Nokia Symbian Series with a memory card you can use the &amp;quot;install&amp;quot; target in the &amp;quot;Makefile&amp;quot;. Just adapt the Bluetooth address of the phone in the &amp;quot;Makefile&amp;quot; and run:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
make install&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Then go to the file browser on the phone, switch to the memory card and select the &amp;quot;JavaMO.jad&amp;quot; file. Make sure you have enabled the installation of unsigned applications in the application manager.&lt;br /&gt;
&lt;br /&gt;
===Developers in the United States===&lt;br /&gt;
This depends strongly on the operator you have on your mobile.&lt;br /&gt;
&lt;br /&gt;
If you are developing in the United States and have a Sprint or Nextel phone, you can install the MIDlet over the air using [http://developer.sprint.com/site/global/develop/upload_your_content/p_upload_your_content.jsp | Sprint ADP&#039;s OTA content uploader].  &lt;br /&gt;
&lt;br /&gt;
On a Nextel phone, you can also install it using a cable downloading the [https://developer.motorola.com/docstools/idenjal/| iDEN Java Application Loader]. There are mechanisms for cable-loading an application onto a variety of Sprint CDMA phones, but these vary greatly in their reliability/ease of access.&lt;br /&gt;
&lt;br /&gt;
If you are working with a Verizon phone, you will need to have a BREW developer license and toolkit to load an application onto the device. Chances are you don&#039;t have this.&lt;br /&gt;
&lt;br /&gt;
If you are working with an AT&amp;amp;T or T-Mobile GSM phone, you should put the JAD and JAR files in a publicly accessible web server, then point the web browser of your phone to the JAD file -- it should begin the download automatically.&lt;br /&gt;
&lt;br /&gt;
== Building the documentation ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
make javadoc&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Direct your browser to the file &amp;quot;doc/index.html&amp;quot;&lt;br /&gt;
== On device debugging with a Nokia N and E series phone and Linux ==&lt;br /&gt;
To get the output from the application running on the phone on a computer screen, do the following:&lt;br /&gt;
* Register with Nokia and get the Symbian SDK&lt;br /&gt;
* Transfer the &amp;quot;EcmtAgent_MIDP.SIS&amp;quot; application on the phone and run it, uses bluetooth per default&lt;br /&gt;
* Go to system - application manager on the phone and install the &amp;quot;RedMIDlet.jar&amp;quot; (shows &amp;quot;not installed&amp;quot;)&lt;br /&gt;
* Go to the application folder and run the &amp;quot;Sdt.out.redir&amp;quot; application&lt;br /&gt;
* do a &amp;quot;sdptool browse&amp;quot; on your notebook with a supported bluetooth dongle (hci device must be up) to find out the rfcomm port. You should see something like this:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Service Name: EcmtAgent&lt;br /&gt;
Service Description: Bluetooth bearer for EcmtAgent&lt;br /&gt;
Service RecHandle: 0x10043&lt;br /&gt;
Service Class ID List:&lt;br /&gt;
  &amp;quot;Serial Port&amp;quot; (0x1101)&lt;br /&gt;
Protocol Descriptor List:&lt;br /&gt;
  &amp;quot;L2CAP&amp;quot; (0x0100)&lt;br /&gt;
    PSM: 3&lt;br /&gt;
  &amp;quot;RFCOMM&amp;quot; (0x0003)&lt;br /&gt;
    Channel: 3&lt;br /&gt;
Language Base Attr List:&lt;br /&gt;
  code_ISO639: 0x656e&lt;br /&gt;
  encoding:    0x6a&lt;br /&gt;
  base_offset: 0x100&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* run a command like the following after substitution of the Bluetooth address and the rfcomm channel:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
while $a; do rfcomm release /dev/rfcomm0 ; rfcomm bind /dev/rfcomm0 00:17:C4:C3:36:24 3 ; cat /dev/rfcomm0 ; done&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Example output (process list, system info and the javamo console output):&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
0x000004380x10204578CPU 191985135 1 DRIVES C 46539776 23182336;D 5629952 5627904;E 2030960640 30343168;Z 20971520 0; RAM 5627904 46137344 20971520 APPLICATIONS JavaMO 692 -1 -1 -1 2654876;EiksrvBackdrop 97 -1 -1 -1 106830749;Menü 163 -1 -1 -1 5559722;EcmtAgent 601 -1 -1 -1 1263824;Standby-Modus 150 -1 -1 -1 16982482;Sdt.out_redir 648 -1 -1 -1 243194;Telefon 146 -1 -1 -1 11353271;Protokoll 394 -1 -1 -1 1592987;Kontakte 330 -1 -1 -1 1927398;MultimediaList 161 -1 -1 -1 510864;SysAp 122 -1 -1 -1 4535278; 77 -1 -1 -1 9002;Anykey 148 -1 -1 -1 290618;blinkingled 240 -1 -1 -1 266265;Player 266 -1 -1 -1 331695;Autolock 238 -1 -1 -1 103759;Galerie 310 -1 -1 -1 1241149;screensaver 154 -1 -1 -1 16530914;akncapserver 97 -1 -1 -1 106830749;btnotifappserver 108 -1 -1 -1 684661;Securitynotifierappserver 106 -1 -1 -1 311309;VolumePopup 266 -1 -1 -1 331695;MPlayerInfoPopup 266 -1 -1 -1 331695;VolumePopup 150 -1 -1 -1 16982482;CTSecDlgAppServer 110 -1 -1 -1 63354;SyncMLNotifierAppServer 114 -1 -1 -1 59234;cconndlgappserver 116 -1 -1 -1 62744;locnotifierappserver 104 -1 -1 -1 63476;0x000000780x1020456c&lt;br /&gt;
ReceiveLong: long result: 102&lt;br /&gt;
Got BD_CP_SHOW_IMAGE&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
== Java J2ME simulator with real bluetooth hardware access over bluez ==&lt;br /&gt;
* Get the mpowerplayer SDK: http://mpowerplayer.com/?cat=6&lt;br /&gt;
* Install it&lt;br /&gt;
* Either buy (http://www.avetana-gmbh.de) or compile (http://sourceforge.net/projects/avetanabt/) the avetana bluetooth stack&lt;br /&gt;
* put the &amp;quot;AvetanaBluetooth.jar&amp;quot; file in the mpp-sdk top level directory&lt;br /&gt;
* adapt the path to the mpp installation in the javamo Makefile&lt;br /&gt;
* run &amp;quot;make bluezsim&amp;quot; to run JavaMO in the sim with bluez access over JSR082&lt;br /&gt;
&lt;br /&gt;
= Phone Specifics =&lt;br /&gt;
== Nokia E61 ==&lt;br /&gt;
The Nokia E61 has a full keyboard. To select the numbers you have to &#039;&#039;&#039;hold&#039;&#039;&#039; down the blue function key, and press the number together with it.&lt;/div&gt;</summary>
		<author><name>Juanfe</name></author>
	</entry>
	<entry>
		<id>http://wiki.linuxmce.org/index.php?title=Developers_Guide&amp;diff=15164</id>
		<title>Developers Guide</title>
		<link rel="alternate" type="text/html" href="http://wiki.linuxmce.org/index.php?title=Developers_Guide&amp;diff=15164"/>
		<updated>2008-08-01T15:28:34Z</updated>

		<summary type="html">&lt;p&gt;Juanfe: /* 9.3.1 HADesigner */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Category: Programmer&#039;s Guide]]&lt;br /&gt;
&lt;br /&gt;
{| align=&amp;quot;right&amp;quot;&lt;br /&gt;
  | __TOC__&lt;br /&gt;
  |}&lt;br /&gt;
LinuxMCE developer’s guide&lt;br /&gt;
Document version 1.0&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==1. Architecture==&lt;br /&gt;
&lt;br /&gt;
LinuxMCE uses a modular architecture. The heart of LinuxMCE, the &#039;main application&#039; DCERouter is nothing but a general-purpose message router. It has absolutely no code relating to any of LinuxMCE’s functionality--it just relays messages between &amp;quot;Devices&amp;quot;. The functionality of LinuxMCE is entirely in separate programs (aka &amp;quot;Devices&amp;quot;) which all run independently and communicate with each other by passing messages through DCERouter over sockets. &lt;br /&gt;
&lt;br /&gt;
[[Image:LMCE_Architecture_mini.jpg|frame|none|LinuxMCE architecture – the devices]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The plug-in’s are also devices, but instead of running as separate binaries, they run as dynamic libraries in DCERouter’s memory space.&lt;br /&gt;
A LinuxMCE system can have one or more Media Directors (MD’s). Also, a Core machine can have also the functionality of a Media Director. We call it a Hybrid:&lt;br /&gt;
&lt;br /&gt;
[[Image:LMCE_Architecture_-_the_machines.jpg|frame|none|Linux MCE architecture – the machines]]&lt;br /&gt;
&lt;br /&gt;
==2. DCE== &lt;br /&gt;
&lt;br /&gt;
DCE (Data, Commands and Events) is a lightweight network protocol allowing any device to access its configuration (ie data) from a central database, send + receive commands, and fire + respond to events.&lt;br /&gt;
&lt;br /&gt;
The DCE protocol can be implemented with any device that supports standard networking. LinuxMCE provides a DCE library written in Ansi C++ that implements the protocol on any socket-compatible operating system, and has been tested on Linux and Windows. Porting to other languages should not be a big task. Because the messaging is socket-based, any device, regardless of operating system or language, can be used with any other device.&lt;br /&gt;
&lt;br /&gt;
In each installation there is also one DCE Router, through which all messages are routed. An &amp;quot;installation&amp;quot; is a group of devices treated as a unit, and normally corresponds to a physical residence.&lt;br /&gt;
&lt;br /&gt;
The DCE Router is itself quite simple. It just opens a port for incoming connections. When a device connects, the device sends its unique ID, or Mac Address. The DCE Router does a lookup in a database, and returns that device&#039;s data (configuration). DCERouter also sends back a list of all the other devices in the installation with basic information including the commands they know how to implement. The DCE Device then opens a minimum of 2 socket connections to the router. One is for incoming messages (usually commands) from the router, another for outgoing messages (usually events) to it. The DCE Library, which implements the protocol for DCE Devices and the DCE Router, will also open a 3rd socket connection so that it has 2 outgoing sockets: 1 dedicated for sending events and the other for sending other types of messages, like requests and commands to other devices.&lt;br /&gt;
&lt;br /&gt;
All messages go through the router. The devices do not communicate directly to each other. The message will contain information such as the destination device, the type of message, the message id and any number of optional parameters. The router does nothing with the message but forward it to the destination device or devices if the message is being sent to more than one. The DCE library, from which DCE Devices and the DCE Router are derived, knows how to receive incoming messages of the type command and route them to a message handler in the DCE Device. &lt;br /&gt;
&lt;br /&gt;
Another important library is PlutoUtils. It has cross-platform wrapper classes to handle file, strings, processes, threads synchronization, database utils, etc.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==3. DCERouter==&lt;br /&gt;
&lt;br /&gt;
When a DCE Device connects, DCERouter gives it its configuration data and is responsible for receiving and forwarding any messages to and from the devices that connect to it. The most common types of messages are commands and events. All communication goes through DCE Router. If a doorbell device fires an event that the button was pushed, that event goes to DCERouter, which will forward it whatever plug-in has indicated it wants to handle that type of event. If the plug-in then wants to send a command to the media player, this command goes first to the DCE Router, which will then forward it to the media player. The DCE Devices never communicate with each other directly--everything goes through DCE Router. Devices can create their own types of messages specific to them--not just commands and events. For example, a DVD player may send a message that contains a screen capture, or a TV program may send a stream of messages with streaming video. To DCE Router it makes no difference. Messages just have sources and destinations, and DCE Router does not care what type of message it is.&lt;br /&gt;
&lt;br /&gt;
DCERouter also allows you to Message Interceptors. This means a device or plug-in can say that it wants to pre-process all messages that meet a certain criteria. For example, a security plug-in may want to see all events relating to security.&lt;br /&gt;
Plug-in’s are DCE Devices that run within the DCERouter&#039;s memory space. They are DCE Devices just like any other and they are created like any other DCE Device. The code is the same, it&#039;s just a compilation option whether the device is built as a normal DCE Device, which runs in its own memory space and communicates with DCERouter over a socket, or if it&#039;s a plug-in which gets loaded into DCERouter&#039;s memory space. Plug-in’s have the ability to get pointers to the in-memory instance of the other plug-ins so they can share memory and call each others methods.&lt;br /&gt;
&lt;br /&gt;
See below a simplified class diagram for DCERouter:&lt;br /&gt;
[[Image:DCERouter.jpg|frame|none|Simplified class diagram for the DCE router]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==4. The binary communication protocol==&lt;br /&gt;
&lt;br /&gt;
===4.1 Introduction===&lt;br /&gt;
A device can create a command connection and one or more event connections to the router. &lt;br /&gt;
*The command connection is used as an incoming connection and device will use it to receive message from the router (commands). &lt;br /&gt;
*An event connection is used by the device as an outgoing connection to notify the router about events or the deliver commands to other devices. &lt;br /&gt;
The DCERouter process is listening on 3450 port. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===4.2. How to create an event connection===&lt;br /&gt;
Here is how the handshake is made for an event connection: &lt;br /&gt;
&lt;br /&gt;
&amp;gt;&amp;gt; Device sends: &lt;br /&gt;
EVENT &amp;lt;my_device_id&amp;gt; &#039;\n&#039; &lt;br /&gt;
&lt;br /&gt;
&amp;lt;&amp;lt; The router will respond with : &lt;br /&gt;
OK &amp;lt;my_device_id&amp;gt; IP=&amp;lt;device_ip_address&amp;gt; &#039;\n&#039; &lt;br /&gt;
&lt;br /&gt;
&amp;gt;&amp;gt; To send a message, the device will send : &lt;br /&gt;
MESSAGE &amp;lt;size_of_binary_message&amp;gt; &#039;\n&#039; &lt;br /&gt;
&lt;br /&gt;
and then:&lt;br /&gt;
&amp;lt;serialized_binary_message&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===4.3 How to serialize data===&lt;br /&gt;
DCE uses SerializeClass to serialize/deserialize data. &lt;br /&gt;
The sources can be found here : src/SerializeClass/Serialize.h/cpp. &lt;br /&gt;
The deserialize the data, the deserializing module must know the way the data was serialized like this: &lt;br /&gt;
* 4 bytes, unsigned long&lt;br /&gt;
* 1 byte, unsigned char &lt;br /&gt;
&lt;br /&gt;
Primitives: &lt;br /&gt;
* 8 bytes, unsigned int64 &lt;br /&gt;
* 8 bytes, int64 &lt;br /&gt;
* 4 bytes, unsigned long &lt;br /&gt;
* 4 bytes, unsigned short &lt;br /&gt;
* 1 byte, unsigned char &lt;br /&gt;
* 1 byte, char &lt;br /&gt;
* 4 byte, long &lt;br /&gt;
* 4 bytes, float &lt;br /&gt;
* 8 bytes, double &lt;br /&gt;
* 2 bytes, short&lt;br /&gt;
&lt;br /&gt;
Complex types: &lt;br /&gt;
&lt;br /&gt;
#string &lt;br /&gt;
#*STR_LENGTH bytes, the array with chars &lt;br /&gt;
#*1 byte, &#039;/0&#039; (value 0x00) &lt;br /&gt;
#:&lt;br /&gt;
#block of data &lt;br /&gt;
#*BLOCK_LENGTH bytes, the array with bytes &lt;br /&gt;
#:&lt;br /&gt;
#vector of strings &lt;br /&gt;
#*VECT_LENGTH bytes, the number of strings from vector &lt;br /&gt;
#*string 0 &lt;br /&gt;
#*string 1 &lt;br /&gt;
#*... &lt;br /&gt;
#*string VECT_LENGTH - 1 &lt;br /&gt;
&lt;br /&gt;
Other complex types serialized (see SerializeClass.cpp for details) : &lt;br /&gt;
* map&amp;lt;int,string&amp;gt; &lt;br /&gt;
* map&amp;lt;u_int64_t,string&amp;gt; &lt;br /&gt;
* map&amp;lt;int,int&amp;gt; &lt;br /&gt;
* map&amp;lt;string,string&amp;gt; &lt;br /&gt;
* vector&amp;lt;int&amp;gt; &lt;br /&gt;
* vector&amp;lt; pair&amp;lt;int,int&amp;gt; &amp;gt; &lt;br /&gt;
* map&amp;lt;string, pair&amp;lt;int,int&amp;gt; &amp;gt; &lt;br /&gt;
&lt;br /&gt;
SerializeClass also allowed you to serialize/deserialize custom objects. Examples: &lt;br /&gt;
* PlutoColor &lt;br /&gt;
* PlutoPoint &lt;br /&gt;
* PlutoSize &lt;br /&gt;
* PlutoRectangle &lt;br /&gt;
* PlutoDataBlock&lt;br /&gt;
&lt;br /&gt;
===4.4 How to serialize a message===&lt;br /&gt;
&lt;br /&gt;
The class used by DCE is Message class from src/DCE/Message.h/cpp unit. &lt;br /&gt;
&lt;br /&gt;
This is how the raw data looks like into a binary message: &lt;br /&gt;
&lt;br /&gt;
* long, value must be 1234 (magic number) &lt;br /&gt;
* long, &amp;lt;device_from_id&amp;gt; &lt;br /&gt;
* long, &amp;lt;device_to_id&amp;gt; &lt;br /&gt;
* long, &amp;lt;device_group_to_id&amp;gt; &lt;br /&gt;
* long, &amp;lt;message_id&amp;gt; &lt;br /&gt;
* long, &amp;lt;message_priority&amp;gt; &lt;br /&gt;
* long, &amp;lt;message_type&amp;gt; &lt;br /&gt;
* long, &amp;lt;device_category_to&amp;gt; &lt;br /&gt;
* long, &amp;lt;device_template_to&amp;gt; &lt;br /&gt;
* unsigned char, &amp;lt;include_children&amp;gt; &lt;br /&gt;
* long, &amp;lt;message_broadcast_level&amp;gt; &lt;br /&gt;
* long, &amp;lt;message_retry&amp;gt; &lt;br /&gt;
* unsigned char, &amp;lt;relative_to_sender&amp;gt; &lt;br /&gt;
* long, &amp;lt;expected_response&amp;gt; &lt;br /&gt;
* string, &amp;lt;device_list_to&amp;gt; &lt;br /&gt;
* unsigned long, &amp;lt;number_of_string_parameters&amp;gt; &lt;br /&gt;
**	foreach &amp;lt;string_parameter&amp;gt; &lt;br /&gt;
***	long, &amp;lt;string_parameter_id&amp;gt; &lt;br /&gt;
***     string, &amp;lt;string_parameter_value&amp;gt; &lt;br /&gt;
**	end_foreach &lt;br /&gt;
* unsigned long, &amp;lt;number_of_data_parameters&amp;gt; &lt;br /&gt;
**	foreach &amp;lt;data_parameter&amp;gt; &lt;br /&gt;
***	long, &amp;lt;data_parameter_id&amp;gt; &lt;br /&gt;
***	unsigned long, &amp;lt;data_parameter_length&amp;gt; &lt;br /&gt;
***	array of bytes, &amp;lt;data_parameter_value&amp;gt; &lt;br /&gt;
**      end_foreach &lt;br /&gt;
* unsigned long, &amp;lt;number_of_extra_messages&amp;gt; &lt;br /&gt;
**	foreach &amp;lt;extra_message&amp;gt; &lt;br /&gt;
***	unsigned long, &amp;lt;serialized_extra_message_length&amp;gt; &lt;br /&gt;
***	array of bytes, &amp;lt;serialized_extra_message_value&amp;gt; &lt;br /&gt;
**	end_foreach &lt;br /&gt;
* unsigned long, must be 6789 &lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Enums:&#039;&#039;&#039; &lt;br /&gt;
* enum eBroadcastLevel { BL_None=0, BL_DirectSiblings=1, BL_SameComputer=2, BL_SameRoom=3, BL_SameHouse=4, BL_AllHouses=5 }; &lt;br /&gt;
* enum eRetry { MR_None=0, MR_Retry=1, MR_Persist=2 }; &lt;br /&gt;
* enum eExpectedResponse { ER_None=0, ER_ReplyMessage, ER_ReplyString, ER_DeliveryConfirmation }; &lt;br /&gt;
* message types: enum { MESSAGETYPE_COMMAND=1, MESSAGETYPE_EVENT=2, MESSAGETYPE_DATAPARM_CHANGE=3, MESSAGETYPE_REPLY=4, MESSAGETYPE_DATAPARM_REQUEST=5, MESSAGETYPE_LOG=6, MESSAGETYPE_SYSCOMMAND=7, MESSAGETYPE_REGISTER_INTERCEPTOR=8, MESSAGETYPE_MESSAGE_INTERCEPTED=9, MESSAGETYPE_EXEC_COMMAND_GROUP=10, MESSAGETYPE_START_PING=11, MESSAGETYPE_STOP_PING=12, MESSAGETYPE_PURGE_INTERCEPTORS=13, MESSAGETYPE_PENDING_TASKS=14 }; &lt;br /&gt;
* message priority : enum { PRIORITY_LOW=0, PRIORITY_NORMAL=1, PRIORITY_HIGH=2, PRIORITY_URGENT=3 }; &lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Important notes:&#039;&#039;&#039; &lt;br /&gt;
* when sending to device template, set &amp;lt;device_template_to&amp;gt; to desired device template and also &amp;lt;device_to_id&amp;gt; to -2000 (DEVICEID_MASTERDEVICE) &lt;br /&gt;
* when sending to device category, set &amp;lt;device_category_to&amp;gt; to desired device category and also &amp;lt;device_to_id&amp;gt; to -2001 (DEVICEID_CATEGORY) &lt;br /&gt;
* when sending to a list with devices, set &amp;lt;device_list_to&amp;gt; to comma delimited list with devices and also &amp;lt;device_to_id&amp;gt; to -2002 (DEVICEID_LIST). &lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Example:&#039;&#039;&#039; &lt;br /&gt;
Here is the pseudocode to send the &amp;quot;on&amp;quot; command to a light switch. &lt;br /&gt;
We&#039;ll assume that the your device has #id 250 and the light switch has device #id 100 &lt;br /&gt;
&lt;br /&gt;
*MyDevice.Connect(router_ip, 3450 /*port*/)&lt;br /&gt;
*MyDevice.SendData(&amp;quot;EVENT 250\n&amp;quot;) &lt;br /&gt;
*MyDevice.ReceiveData() //until you&#039;ll get a &#039;\n&#039; ; you should receive: &amp;quot;OK 250 IP=&amp;lt;device_ip_address&amp;gt; &#039;\n&#039;; &lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;next: creating a message&#039;&#039;&#039; &lt;br /&gt;
let&#039;s say MyData is an array of bytes &lt;br /&gt;
*SerializeLong(MyData, 1234) //magic number &lt;br /&gt;
*SerializeLong(MyData, 250) //my id &lt;br /&gt;
*SerializeLong(MyData, 100) //the light switch &lt;br /&gt;
*SerializeLong(MyData, 0) //not used now &lt;br /&gt;
*SerializeLong(MyData, 192) //message id of command &#039;on&#039; &lt;br /&gt;
*SerializeLong(MyData, 1) //normal priority &lt;br /&gt;
*SerializeLong(MyData, 1) //message type : command &lt;br /&gt;
*SerializeLong(MyData, 0) //not used now &lt;br /&gt;
*SerializeLong(MyData, 0) //not used now &lt;br /&gt;
*SerializeUnsignedChar(MyData, 0) //not including children &lt;br /&gt;
*SerializeLong(MyData, 0) //broadcast level : none &lt;br /&gt;
*SerializeLong(MyData, 0) //don&#039;t retry &lt;br /&gt;
*SerializeUnsignedChar(MyData, 0) //relative to sender false &lt;br /&gt;
*SerializeLong(MyData, 3) //delivery confirmation &lt;br /&gt;
*SerializeString(MyData, &amp;quot;&amp;quot;) //device list to empty &lt;br /&gt;
*SerializeUnsignedLong(MyData, 2) //2 parameters &lt;br /&gt;
*SerializeLong(MyData, 98) //parameter type #98 &lt;br /&gt;
*SerializeString(MyData, &amp;quot;&amp;quot;) //empty value &lt;br /&gt;
*SerializeLong(MyData, 97) //parameter type #97 &lt;br /&gt;
*SerializeString(MyData, &amp;quot;&amp;quot;) //empty value &lt;br /&gt;
*SerializeUnsignedLong(MyData, 0) //no binary parameters &lt;br /&gt;
*SerializeUnsignedLong(MyData, 0) //no extra messages &lt;br /&gt;
*SerializeUnsignedLong(6789) //magic number &lt;br /&gt;
&lt;br /&gt;
*MyDevice.SendData(&amp;quot;MESSAGE &amp;quot; + MyData.length() + &#039;\n&#039;) &lt;br /&gt;
*MyDevice.SendData(MyData) &lt;br /&gt;
*MyDevice.ReceiveData() //until you&#039;ll get a &#039;\n&#039; ; you should receive: &amp;quot;OK&amp;quot; or an error message &lt;br /&gt;
&lt;br /&gt;
*MyDevice.CloseConnection();&lt;br /&gt;
&lt;br /&gt;
===4.5 How to serialize data-grids ===&lt;br /&gt;
&#039;&#039;&#039;Complex objects:&#039;&#039;&#039; &lt;br /&gt;
# DataGridCellSerializableData &lt;br /&gt;
#* unsigned long, &amp;lt;sizeof(DataGridCellSerializableData)&amp;gt; &lt;br /&gt;
#* unsigned long, &amp;lt;graphic_length&amp;gt; &lt;br /&gt;
#* unsigned long, &amp;lt;message_length&amp;gt; &lt;br /&gt;
#* unsigned long, &amp;lt;text_length&amp;gt; &lt;br /&gt;
#* unsigned long, &amp;lt;value_length&amp;gt; &lt;br /&gt;
#* unsigned long, &amp;lt;image_path_length&amp;gt; &lt;br /&gt;
#* unsigned long, &amp;lt;number_of_attributes_length&amp;gt; &lt;br /&gt;
#* unsigned long, &amp;lt;attributes_length&amp;gt; &lt;br /&gt;
#* int, &amp;lt;alternate_color&amp;gt; &lt;br /&gt;
#* unsigned long, &amp;lt;graphic_format&amp;gt; &lt;br /&gt;
#* unsigned char, &amp;lt;selectable&amp;gt; &lt;br /&gt;
#* int, &amp;lt;style_detail&amp;gt; &lt;br /&gt;
#* int, &amp;lt;col_span&amp;gt; &lt;br /&gt;
#* int, &amp;lt;row_span&amp;gt; &lt;br /&gt;
#* unsigned char, &amp;lt;dont_fire_grid_event&amp;gt; &lt;br /&gt;
#:&lt;br /&gt;
#:Enums: &lt;br /&gt;
#* enum eGraphicFormat { GR_UNKNOWN=0, GR_JPG=1, GR_GIF=2, GR_TIF=3, GR_PNG=4, GR_MNG=5, GR_BMP=6, GR_OCG=7, GR_PFG=8 }; &lt;br /&gt;
#:&lt;br /&gt;
# DataGridCell &lt;br /&gt;
#* DataGridCellSerializableData, &amp;lt;datagrid_cell_serializable_data&amp;gt; &lt;br /&gt;
#* array of chars, &amp;lt;text&amp;gt; &lt;br /&gt;
#* array of chars, &amp;lt;value&amp;gt; &lt;br /&gt;
#* array of bytes, &amp;lt;graphic_data&amp;gt; &lt;br /&gt;
#* array of bytes, &amp;lt;message_data&amp;gt; &lt;br /&gt;
#* array of chars, &amp;lt;image_path&amp;gt; &lt;br /&gt;
#*:&lt;br /&gt;
#**	foreach &amp;lt;cell_attribute&amp;gt; &lt;br /&gt;
#***	array of chars ended with &#039;\0&#039; , &amp;lt;cell_attribute_name&amp;gt; &lt;br /&gt;
#***	array of chars ended with &#039;\0&#039;, &amp;lt;cell_attribute_value&amp;gt; &lt;br /&gt;
#**	end_foreach &lt;br /&gt;
#:&lt;br /&gt;
#DataGridTableSerializableData &lt;br /&gt;
#* int, &amp;lt;total_number_of_columns&amp;gt; &lt;br /&gt;
#* int, &amp;lt;total_number_of_rows&amp;gt; &lt;br /&gt;
#* unsigned char, &amp;lt;keep_row_header&amp;gt; &lt;br /&gt;
#* unsigned char, &amp;lt;keep_column_header&amp;gt; &lt;br /&gt;
#* int, &amp;lt;column_count&amp;gt; &lt;br /&gt;
#* int, &amp;lt;row_count&amp;gt; &lt;br /&gt;
#* int, &amp;lt;starting_column&amp;gt; &lt;br /&gt;
#* int, &amp;lt;starting_row&amp;gt; &lt;br /&gt;
#* int, &amp;lt;cell_count&amp;gt; &lt;br /&gt;
#:&lt;br /&gt;
#DataGridTableCellIndex &lt;br /&gt;
#* unsigned int, &amp;lt;column_row_type&amp;gt; &lt;br /&gt;
#* unsigned int, &amp;lt;size&amp;gt; &lt;br /&gt;
#:&lt;br /&gt;
#DataGridTable &lt;br /&gt;
#* unsigned long, &amp;lt;sizeof(DataGridTableSerializableData)&amp;gt; &lt;br /&gt;
#* array of DataGridTableCellIndex, &amp;lt;col * row * sizeof(DataGridTableCellIndex)&amp;gt; &lt;br /&gt;
#* array of DataGridCell, &amp;lt;col * row * serialized DataGridCell&amp;gt; &lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
Additional step: lzo compression/decompression &lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; can be disabled if compiled with DISABLE_LZO_DATAGRID &lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
==5. The devices==&lt;br /&gt;
&lt;br /&gt;
Each device has associated an interface, which we call device template. A device template is a set of commands to be implemented, events which can be fired by the device and device data (persistent information for device).&lt;br /&gt;
To create device templates and modify them, go to LinuxMCE Web Admin -&amp;gt; Advanced -&amp;gt; Configuration -&amp;gt; Device Templates.&lt;br /&gt;
To generate the C++ code for the device implementing a device template interface, you must use DCEGen tool, specifying the database ip address and the device template number.&lt;br /&gt;
Here is the simplified class diagram for one of the devices (App_Server):&lt;br /&gt;
&lt;br /&gt;
[[Image:App_Server.jpg|frame|none|Simplified class diagram for a DCE device]]&lt;br /&gt;
&lt;br /&gt;
The classes App_Server_Event, App_Server_Command and App_Server_Data are generated using DCEGen tool. The base classes for them are implemented in DCE Library.&lt;br /&gt;
&lt;br /&gt;
==6. App_Server device==&lt;br /&gt;
&lt;br /&gt;
App_Server device is present by default on all LinuxMCE machines. It spawns/kills applications, handles volume of sound on that machine, restarts/halts the device.&lt;br /&gt;
&lt;br /&gt;
# Implemented commands:&lt;br /&gt;
#*CMD_Spawn_Application - Spawns an application&lt;br /&gt;
#*CMD_Kill_Application - Kills an application&lt;br /&gt;
#*CMD_Application_Is_Running - Checks if the given application is running.&lt;br /&gt;
#*CMD_Halt_Device - Halts or reboots this device&lt;br /&gt;
#*CMD_Vol_Up - Increases the volume 1%&lt;br /&gt;
#*CMD_Vol_Down - Decreases the volume 1%&lt;br /&gt;
#*CMD_Set_Volume - Sets the volume to a specific level between 0-100&lt;br /&gt;
#*CMD_Mute - Toggles mute/unmute&lt;br /&gt;
#: &lt;br /&gt;
#: &lt;br /&gt;
#It doesn’t fire any events.&lt;br /&gt;
#: &lt;br /&gt;
#: &lt;br /&gt;
#It has the following device data:&lt;br /&gt;
#*Discrete Volume&lt;br /&gt;
#*Volume Level&lt;br /&gt;
&lt;br /&gt;
==7. Photo_Screen_Saver device==&lt;br /&gt;
&lt;br /&gt;
The photo screen saver (PSS) displays pictures when there is no video playing, even if you just happen to be listening to music. By default, the photos come from Flickr and are downloaded regularly to local drive.&lt;br /&gt;
&lt;br /&gt;
PSS is a OpenGL application and it slides pictures and fades them between transitions. &lt;br /&gt;
&lt;br /&gt;
1. Implemented commands&lt;br /&gt;
&lt;br /&gt;
The list with pictures is taken by sending a command to Orbiter Plugin : CMD_Get_Screen_Saver_Files which has an output parameter Filename. The filenames are delimited by a ‘\n’ character.&lt;br /&gt;
&lt;br /&gt;
The PSS animations are started/stopped using CMD_On/CMD_Off commands. To force PSS reload the list with pictures from Orbiter Plugin, CMD_Reload is used.&lt;br /&gt;
&lt;br /&gt;
When PSS starts, it should check every 10 minutes if there are any pictures downloaded and ready to be displayed. If there are pictures to display it should display them on CMD_On command and refresh the list with pictures every 24 hours.&lt;br /&gt;
&lt;br /&gt;
2. It doesn’t fire any events&lt;br /&gt;
&lt;br /&gt;
3. Device data:&lt;br /&gt;
* ZoomTime - Value in miliseconds that a zoom effect will take &lt;br /&gt;
* FadeTime - value in miliseconds that a fade effect will take &lt;br /&gt;
* Name - The window name to activate&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==8. Media Player device==&lt;br /&gt;
&lt;br /&gt;
Currently there are two Media Players in LinuxMCE, the primary Xine_Player and &lt;br /&gt;
secondary MPlayer_Player.&lt;br /&gt;
First one is based one the Xine engine (http://xinehq.de) and supports the &lt;br /&gt;
following formats:&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;File formats (System layer / media types)supported:&#039;&#039;&#039;&lt;br /&gt;
**direct DVD playback (of unlocked/unencrypted DVDs, see below)&lt;br /&gt;
** Video CD&lt;br /&gt;
** Audio CD&lt;br /&gt;
** mpeg program streams (.mpg, .mpeg)&lt;br /&gt;
** mpeg transport streams (.ts)&lt;br /&gt;
** ogg (.ogg, .ogm)&lt;br /&gt;
** avi (.avi)&lt;br /&gt;
** asf (.asf, .wmv, .wma)&lt;br /&gt;
** quicktime (.mov, .mp4)&lt;br /&gt;
** mpeg-video (.mpv, .m2v)&lt;br /&gt;
** mpeg-audio (.mp2, .mp3)&lt;br /&gt;
** Sega Saturn FILM (.cpk)&lt;br /&gt;
** Id Software RoQ (.roq)&lt;br /&gt;
** wav (.wav)&lt;br /&gt;
** Autodesk FLIC (.fli)&lt;br /&gt;
** real (.rm, .ra, .ram)&lt;br /&gt;
** raw dv (.dv)&lt;br /&gt;
** network graphics format (.png, .mng)&lt;br /&gt;
** Creative Voice (.voc)&lt;br /&gt;
** Sun/NeXT SND/AU (.snd, .au)&lt;br /&gt;
** Wing Commander III (.mve)&lt;br /&gt;
** Westwood Studios files (.vqa, .aud)&lt;br /&gt;
** Electronic Arts WVE (.wve)&lt;br /&gt;
** AIFF (.aif, .aiff)&lt;br /&gt;
** YUV4MPEG2 (.y4m)&lt;br /&gt;
** SMJPEG (.mjpg)&lt;br /&gt;
** raw AC3 (.ac3)&lt;br /&gt;
** Dialogic VOX (.vox)&lt;br /&gt;
** TechnoTrend PVA (.pva)&lt;br /&gt;
** Playstation STR (.str)&lt;br /&gt;
** Nullsoft Video (.nsv)&lt;br /&gt;
** 4X Technologies (.4xm)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Video codecs supported:&#039;&#039;&#039;&lt;br /&gt;
** mpeg 1/2&lt;br /&gt;
** mpeg 4 (aka OpenDivX)&lt;br /&gt;
** ms mpeg 4&lt;br /&gt;
** divx 3/4/5&lt;br /&gt;
** windows media video 7 &amp;amp; 8&lt;br /&gt;
** motion jpeg&lt;br /&gt;
** Cinepak&lt;br /&gt;
** DV&lt;br /&gt;
** ms video 1 (msvc)&lt;br /&gt;
** ms rle&lt;br /&gt;
** Sorenson SVQ1/SVQ3 (often used in Quicktime trailers)&lt;br /&gt;
** creative yuv (cyuv)&lt;br /&gt;
** roq video&lt;br /&gt;
** QT RLE, SMC, RPZA&lt;br /&gt;
** theora&lt;br /&gt;
** via external binary/win32 codecs (not included in xine):&lt;br /&gt;
** Indeo 3.1-5.0&lt;br /&gt;
** Window Media Video 8,9&lt;br /&gt;
** On2 VP3.1&lt;br /&gt;
** I263&lt;br /&gt;
** Real Media 2.0, 3.0, 4.0&lt;br /&gt;
* currently unsupported/untested Formats:&lt;br /&gt;
** 3ivx&lt;br /&gt;
** h263 (aka Real Video 1.0)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Audio codecs&#039;&#039;&#039;&lt;br /&gt;
** mpeg audio (layer 1,2,3)&lt;br /&gt;
** a/52 (aka ac3, dolby digital)&lt;br /&gt;
** aac (used in .mp4 files)&lt;br /&gt;
** dts (via external decoder)&lt;br /&gt;
** vorbis&lt;br /&gt;
** pcm&lt;br /&gt;
** adpcm (MS/IMA/DVI/Dialogic)&lt;br /&gt;
** mu-law and A-law&lt;br /&gt;
** roq dpcm&lt;br /&gt;
** Real Media dnet audio&lt;br /&gt;
** Real Media 28.8 audio&lt;br /&gt;
** DivX audio (WMA)&lt;br /&gt;
** GSM 6.10&lt;br /&gt;
** FLAC&lt;br /&gt;
** NSF (NES sound format)&lt;br /&gt;
** Speex&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The MPlayer_Player is used as the fallback player for the formats Xine doesn&#039;t &lt;br /&gt;
support/supports not well and currently is used for playing HD-DVD/Bluray &lt;br /&gt;
video files and disks.&lt;br /&gt;
&lt;br /&gt;
A media player device plays all kind of media: audio and video, stored media or from cd/dvd/hd/bluray drivers, etc.&lt;br /&gt;
&lt;br /&gt;
1. Implemented commands&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Keyboard input:&#039;&#039;&#039; &lt;br /&gt;
** CMD_EnterGo - Select the currently highlighted menu item&lt;br /&gt;
** CMD_Move_Up, CMD_Move_Down, CMD_Move_Left, CMD_Move_Right - Move the highlighter&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Media Player Commands&#039;&#039;&#039;&lt;br /&gt;
** CMD_Pause - Pause the media&lt;br /&gt;
** CMD_Play - Play the media&lt;br /&gt;
** CMD_Skip_Back_ChannelTrack_Lower - Lower the channel, track, station, etc. by 1.  Same as Jump to Pos in Playlist with value -1 for a smart media player&lt;br /&gt;
** CMD_Skip_Fwd_ChannelTrack_Greater - Raise  the channel, track, station, etc. by 1.  Same as Jump to Pos in Playlist with value +1 for a smart media player&lt;br /&gt;
** CMD_Stop - Stop the media&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Menu Navigation&#039;&#039;&#039;&lt;br /&gt;
** CMD_EnterGo - Select the currently highlighted menu item&lt;br /&gt;
** CMD_Move_Up, CMD_Move_Down, CMD_Move_Left, CMD_Move_Right - Move the highlighter&lt;br /&gt;
** CMD_Get_Video_Frame - Gets the current video frame from the media player.&lt;br /&gt;
** CMD_Goto_Media_Menu - Goto to the current media Root Menu.&lt;br /&gt;
** CMD_Navigate_Next - Nagivate to the next possible navigable area. (The actual outcome depends on the specifc device)&lt;br /&gt;
** CMD_Navigate_Prev - Nagivate the previous possible navigable area. (The actual outcome depends on the specific device).&lt;br /&gt;
** CMD_Simulate_Mouse_Click - Simlate a mouse click at a certain position on the screen&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Smart DVD commands&#039;&#039;&#039;&lt;br /&gt;
** CMD_Angle – Go to an angle&lt;br /&gt;
** CMD_Audio_Track – Go to an audio track&lt;br /&gt;
** Subtitle – Go to a subtitle&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Smart Media Player&#039;&#039;&#039;&lt;br /&gt;
** CMD_Change_Playback_Speed – Will make the playback to FF with a configurable amount of speed.&lt;br /&gt;
** CMD_Guide - Show guide information.  For a dvd this may be the menu, just like the menu command&lt;br /&gt;
** CMD_Jump_Position_In_Playlist - Jump to a specific position in the playlist, or a track, or a chapter.  Smart media players should also understand the skip fwd/skip back (which non-DCE media players use) to be the same thing as a jump +1 or -1&lt;br /&gt;
** CMD_Jump_To_Position_In_Stream - Jump to a position in the stream, specified in seconds.&lt;br /&gt;
** CMD_Menu - Show a menu associated with this media&lt;br /&gt;
** CMD_Pause_Media - This will stop a media that is currently played. This method should be paired with the &amp;quot;Restart Media&amp;quot; and used when the playback will be stopped and restarted on the same display device.&lt;br /&gt;
** CMD_Play_Media - This command will instruct a Media Player to play a media stream identified by a media descriptor created by the &amp;quot;Create Media&amp;quot; command.&lt;br /&gt;
** CMD_Report_Playback_Position - This will report the playback position of the current stream.&lt;br /&gt;
** CMD_Restart_Media - This will restart a media was paused with the above command&lt;br /&gt;
** CMD_Set_Aspect_Ratio - Force aspect ratio&lt;br /&gt;
** CMD_Set_Media_ID - Set Media ID - information about media stream&lt;br /&gt;
** CMD_Set_Media_Position - Jump to a certain media position&lt;br /&gt;
** CMD_SetZoom - Sets zoom level, relative, absolute or &#039;auto&#039;&lt;br /&gt;
** CMD_Simulate_Keypress - Send a key to the device&#039;s OSD, or simulate keypresses on the device&#039;s panel&lt;br /&gt;
** CMD_Start_Streaming - Like play media, but it means the destination device is not the same as the source&lt;br /&gt;
** CMD_Stop_Media - This will instruct the media player to stop the playback of a media started with the &amp;quot;Play Media&amp;quot; Command&lt;br /&gt;
** CMD_Update_Object_Image - Display an image on the media player&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
2. &#039;&#039;&#039;It fires the following events&#039;&#039;&#039;&lt;br /&gt;
* EVENT_Menu_Onscreen - A DVD Menu appeared on screen&lt;br /&gt;
* EVENT_Playblack_Completed - Fired when the playback of a stream has completed.&lt;br /&gt;
* EVENT_Playback_Info_Changed – Playback info changed&lt;br /&gt;
* EVENT_Playback_Started – Media has start playing&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
3. &#039;&#039;&#039;Device data:&#039;&#039;&#039;&lt;br /&gt;
* Name - The name of the window for this app&lt;br /&gt;
* Hardware acceleration - driver used&lt;br /&gt;
* Deinterlacing Mode - Movie deinterlacing filter status&lt;br /&gt;
* Port – Time code notification every second&lt;br /&gt;
* Zoom Level – default zoom level&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;NOTE:&#039;&#039;&#039; A deviation from design, the media player must bind on a port specified in the device data and report the time code every one second. Any device like an Orbiter could connect to that port and read the time code. Here is the format used for time code:&lt;br /&gt;
Speed,CurrentTime,TotalTime,StreamID,Title,Chapter,MediaType,MediaID,Filename (comma delimited).&lt;br /&gt;
&lt;br /&gt;
==9. Orbiter==&lt;br /&gt;
&lt;br /&gt;
===9.1 Introduction===&lt;br /&gt;
&lt;br /&gt;
The Orbiter is really a device just like any other. The main class, Orbiter, is a normal DCE command implementation. However, the Orbiter class was written so that it has no platform-specific functions, such as graphics and sound. It handles the basic logic, and calls pure virtual functions that derived classes must implement to handle the platform-specific commands. Most of the code and virtually all of the logic is contained in the base classes. Therefore, it is a fairly easy task to make a new version of Orbiter for a platform other than SDL, perhaps one that uses Windows SDK calls, or another image library.&lt;br /&gt;
&lt;br /&gt;
Right now there are implementations of Orbiter using SDL. PocketFrog and OpenGL engines. Orbiter runs on different operation systems like Linux, Windows, Windows CE, Window Mobile, Symbian60. There also implementation for web orbiter (running into a browser) or for a Cisco hard phones (using XML services).&lt;br /&gt;
&lt;br /&gt;
===9.2 Architecture===&lt;br /&gt;
&lt;br /&gt;
[[Image:architecture.jpg|frame|none|Orbiter application architecture]]&lt;br /&gt;
&lt;br /&gt;
The present diagram shows how the Orbiter application architecture looks like. Depending on the Graphic Engine and the platform, the only modules dependent on them are “Renderers – engine specific” and “Orbiter - platform specific”. &lt;br /&gt;
&lt;br /&gt;
====9.2.1. The renderers====&lt;br /&gt;
&lt;br /&gt;
There are two kinds of renders:&lt;br /&gt;
* orbiter renderers&lt;br /&gt;
* object renderers&lt;br /&gt;
&lt;br /&gt;
The orbiter renderers (derived from OrbiterRenderer class) handle the graphic primitives, having pure virtual methods for operations like this:&lt;br /&gt;
* RenderText&lt;br /&gt;
* SolidRectangle&lt;br /&gt;
* HollowRectangle&lt;br /&gt;
* DrawLine&lt;br /&gt;
* FloodFill&lt;br /&gt;
* RenderGraphic&lt;br /&gt;
* ReplaceColorInRectangle&lt;br /&gt;
* etc.&lt;br /&gt;
&lt;br /&gt;
and applications flow :&lt;br /&gt;
* event loop&lt;br /&gt;
* configure&lt;br /&gt;
* destroy&lt;br /&gt;
* on quit&lt;br /&gt;
* on reload&lt;br /&gt;
&lt;br /&gt;
However, OrbiterRenderer is not an interface. It also has implemented the logic needed for: &lt;br /&gt;
* render screen action&lt;br /&gt;
* show a progress bar&lt;br /&gt;
* highlighting / un-highlighting objects&lt;br /&gt;
* render shortcuts&lt;br /&gt;
* show / hide popup’s&lt;br /&gt;
* redraw objects&lt;br /&gt;
* refresh screen&lt;br /&gt;
* render object asynchronously&lt;br /&gt;
* object on screen / off screen actions&lt;br /&gt;
* background image loading&lt;br /&gt;
* drawing an arrow&lt;br /&gt;
&lt;br /&gt;
Here is the class diagram for derived OrbiterRenderer‘s:&lt;br /&gt;
&lt;br /&gt;
[[Image:orbiterrenderer.jpg|frame|none|OrbiterRenderer class diagram]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Also, there are renderer classes of complex objects like button, data grid, edit box, etc. The base classes for them are : ObjectRenderer, DataGridRenderer. Each renderer is attached to an object like DesignObj_Orbiter, DesignObj_DataGrid. &lt;br /&gt;
&lt;br /&gt;
Here is the class diagram for OpenGL implementation:&lt;br /&gt;
&lt;br /&gt;
[[Image:openGLimplementation.jpg|frame|none|OpenGL implementation]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The screens are actually trees of objects. The characteristics of the objects are set using the Designer application and stored in the database, then serialized by OrbiterGen and then deserialized by Orbiter. &lt;br /&gt;
OrbiterGen scales and pre-renders the screens. Also, OrbiterGen embeds in the serialized data info about the actions to be executed when an object is loaded, activated, unloaded, etc.&lt;br /&gt;
&lt;br /&gt;
====9.2.2. Orbiter – platform specific====&lt;br /&gt;
&lt;br /&gt;
Orbiter also has to take care of the input events like mouse click, keyboard events, etc. For example, Orbiter_Win32 is derived from Orbiter class and takes care of enabling the auto-update mechanism. &lt;br /&gt;
Platform specific are the external dialogs with progress bar and prompt user, or the way the composite or masks are used (see OrbiterRenderer_Linux, OrbiterLinux, OrbiterRenderer_SDL_Win32&lt;br /&gt;
&lt;br /&gt;
The Linux version uses XRecord extension to intercept events. The Windows versions use PocketFrog engine’s event loop or SDL event loop.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
====9.2.3. Cache image manager====&lt;br /&gt;
&lt;br /&gt;
This module is mainly used by remote orbiters, non-OSD orbiters. Because these orbiters don’t have access to core’s file system, all the graphic files are obtained by network connection and it might be slow. So instead of requesting same image over and over, the image is cached on the local drivers. The collection of images cached are associated with a timestamp (the generation date for the screens). If the user decides to regenerate the screens, the timestamp is changed and the cache is purged and the images are requested, on demand, again from the server.&lt;br /&gt;
&lt;br /&gt;
====9.2.4. Self update module====&lt;br /&gt;
&lt;br /&gt;
The “Self update” module is also used for non-OSD orbiters. Once a new version of the Orbiter XP/CE is available, a new binary data is stored on core’s filesystem. When an non-OSD orbiter starts, compares the md5sum of the current binary with the one from the server. If it’s different, the UpdateBinary is spawned, Orbiter exits and UpdateBinary requests the new binary from server, it downloads it, replaces the old binary and restart Orbiter.&lt;br /&gt;
&lt;br /&gt;
====9.2.5. Simulator====&lt;br /&gt;
&lt;br /&gt;
The simulator is responsible for generating mouse and keyboard events used for stress testing. It also stores some configuration settings.&lt;br /&gt;
&lt;br /&gt;
====9.2.6. Graphic objects====&lt;br /&gt;
&lt;br /&gt;
They are all derived from PlutoGraphic class and store info about the filename, width, height, the block of data and its length, graphic format and graphic management. The operations required are related to loading graphics from a file or a block of data, clearing the data stored, initializations, etc.&lt;br /&gt;
In the derived classes like PocketFrogGraphic, SDLGraphic, OpenGLGraphic, specific info are stored like the Surface for PocketFrong, SDL_Surface for SDL and the texture for OpenGL.&lt;br /&gt;
&lt;br /&gt;
====9.2.7. Orbiter logic module====&lt;br /&gt;
&lt;br /&gt;
Just like any other device, Orbiter is derived from a {Device_name}_Command class, the wrapper class generated by DCEGen to allow the device communicate with the router. However, Orbiter is also derived from OrbiterData and IRReceiverBase.&lt;br /&gt;
&lt;br /&gt;
[[Image:orbiterlogicclassdiagram.jpg|frame|none|Orbiter logic – class diagram]]&lt;br /&gt;
&lt;br /&gt;
 &lt;br /&gt;
OrbiterData helps Orbiter deserialize the data needed for its graphic objects, data serialized by OrbiterGen. IRReceiverBase is the base class for all IR receiver devices and it translates IR codes into actions, base on the current screen type and remote layout.&lt;br /&gt;
&lt;br /&gt;
====9.2.7. Mouse handlers====&lt;br /&gt;
&lt;br /&gt;
The goal of handlers is the interpret mouse movements and perform specific actions depending on current screen type. This is one of the main features add in UI2 version.&lt;br /&gt;
&lt;br /&gt;
See below the class diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image:mousehandlers.jpg|frame|none|Mouse handlers – class diagram]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Note that the mouse handlers are not available for UI1 version of Orbiter.&lt;br /&gt;
&lt;br /&gt;
MouseIterator and MouseGovernor limit the mouse movements the only one move per x ms to prevent extreme numbers of messages burdening the system.&lt;br /&gt;
MouseBehaviour handles special mouse behavior, such as locking axis’s, ramping and acceleration.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
====9.2.7. HID interface====&lt;br /&gt;
&lt;br /&gt;
This module gets events from the Gyration remote. See below the class diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image:HIDinterface.jpg|frame|none|HID interface – class diagram]]&lt;br /&gt;
&lt;br /&gt;
===9.3 Skinning and User Interface===&lt;br /&gt;
&lt;br /&gt;
====9.3.1 HADesigner====&lt;br /&gt;
The graphics, layout and display for the screens rendered in different Orbiter interfaces for the different UI versions are generated and manipulated using a Windows UI management tool called [[HADesigner_User&#039;s_manual|HADesigner]]. &lt;br /&gt;
&lt;br /&gt;
The following series of screencasts describes the use of the HADesigner tool and the process of generating a brand new UI for a specific plugin for all different variations of the Orbiter UI versions.&lt;br /&gt;
&lt;br /&gt;
Before proceeding, follow the [[Installing_HADesigner | installation instructions for HADesigner]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
# [http://www.localeconcept.com/HADesigner-Screencasts/01-basic_hadesigner_fundamentals.html Basic Designer Fundamentals]&lt;br /&gt;
# [http://www.localeconcept.com/HADesigner-Screencasts/ogg/02_designobj_basics_1.ogg Design Object Basics]&lt;br /&gt;
# [http://www.localeconcept.com/HADesigner-Screencasts/ogg/03_ui2_popup_part_1.ogg UI2 Popup Part I]&lt;br /&gt;
# [http://www.localeconcept.com/HADesigner-Screencasts/ogg/04_ui2_popup_part_2.ogg UI2 Popup Part II]&lt;br /&gt;
# [http://www.localeconcept.com/HADesigner-Screencasts/ogg/05_UI1_Orbiter.ogg UI1 Orbiter]&lt;br /&gt;
# [http://www.localeconcept.com/HADesigner-Screencasts/ogg/06_UI1_Full_Screen_OSD.ogg UI1 Full Screen OSD]&lt;br /&gt;
# [http://www.localeconcept.com/HADesigner-Screencasts/ogg/07_UI1_Full_Screen_OSD_2.ogg UI1 Full Screen OSD Part II]&lt;br /&gt;
# [http://www.localeconcept.com/HADesigner-Screencasts/ogg/08_UI1_PDA.ogg UI1 PDA]&lt;br /&gt;
# [http://www.localeconcept.com/HADesigner-Screencasts/ogg/09_Mobile_Remote.ogg Mobile Remote]&lt;br /&gt;
# [http://www.localeconcept.com/HADesigner-Screencasts/ogg/10_cisco_7970_orbiter.ogg Cisco 7970 Orbiter]&lt;br /&gt;
# [http://www.localeconcept.com/HADesigner-Screencasts/ogg/11_Monitor_mode.ogg Monitor Mode]&lt;br /&gt;
&lt;br /&gt;
The Basic skin, included with LinuxMCE, should really not be modified, since it is used extensively by LinuxMCE and Pluto and is known to work.&lt;br /&gt;
&lt;br /&gt;
====9.3.2 UI Design and process====&lt;br /&gt;
The following series of screencasts walks through the design considerations involved in creating a brand new skin for LinuxMCE.&lt;br /&gt;
&lt;br /&gt;
# [http://www.localeconcept.com/Skin-Screencasts/01_introduction_and_aesthetic.ogg Introduction and Aesthetic considerations]&lt;br /&gt;
# [http://www.localeconcept.com/Skin-Screencasts/02_main_menu_first_pass.ogg First Pass at the Main Menu]&lt;br /&gt;
# [http://www.localeconcept.com/Skin-Screencasts/03_main_menu_notes_and_corrections.ogg Main Menu Notes and Corrections]&lt;br /&gt;
# [http://www.localeconcept.com/Skin-Screencasts/04_the_floorplan_buttons.ogg The Floorplan Buttons]&lt;/div&gt;</summary>
		<author><name>Juanfe</name></author>
	</entry>
	<entry>
		<id>http://wiki.linuxmce.org/index.php?title=Designer_User%27s_manual&amp;diff=15163</id>
		<title>Designer User&#039;s manual</title>
		<link rel="alternate" type="text/html" href="http://wiki.linuxmce.org/index.php?title=Designer_User%27s_manual&amp;diff=15163"/>
		<updated>2008-08-01T15:25:38Z</updated>

		<summary type="html">&lt;p&gt;Juanfe: Designer User&amp;#039;s manual moved to HADesigner User&amp;#039;s manual: More descriptive of the function&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;#REDIRECT [[HADesigner User&#039;s manual]]&lt;/div&gt;</summary>
		<author><name>Juanfe</name></author>
	</entry>
	<entry>
		<id>http://wiki.linuxmce.org/index.php?title=HADesigner_User%27s_manual&amp;diff=15162</id>
		<title>HADesigner User&#039;s manual</title>
		<link rel="alternate" type="text/html" href="http://wiki.linuxmce.org/index.php?title=HADesigner_User%27s_manual&amp;diff=15162"/>
		<updated>2008-08-01T15:25:38Z</updated>

		<summary type="html">&lt;p&gt;Juanfe: Designer User&amp;#039;s manual moved to HADesigner User&amp;#039;s manual: More descriptive of the function&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Here is a link to the Orbiter Design Program (HADesigner) documentation.&lt;br /&gt;
&lt;br /&gt;
* [http://www.localeconcept.com/pub/HADesigner/HADesigner_user_manual.pdf  HADesigner Manual]&lt;br /&gt;
&lt;br /&gt;
[[Category: Programmer&#039;s Guide]]&lt;/div&gt;</summary>
		<author><name>Juanfe</name></author>
	</entry>
	<entry>
		<id>http://wiki.linuxmce.org/index.php?title=Developers_Guide&amp;diff=15148</id>
		<title>Developers Guide</title>
		<link rel="alternate" type="text/html" href="http://wiki.linuxmce.org/index.php?title=Developers_Guide&amp;diff=15148"/>
		<updated>2008-07-31T15:52:57Z</updated>

		<summary type="html">&lt;p&gt;Juanfe: /* 9.3.1 HADesigner */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Category: Programmer&#039;s Guide]]&lt;br /&gt;
&lt;br /&gt;
{| align=&amp;quot;right&amp;quot;&lt;br /&gt;
  | __TOC__&lt;br /&gt;
  |}&lt;br /&gt;
LinuxMCE developer’s guide&lt;br /&gt;
Document version 1.0&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==1. Architecture==&lt;br /&gt;
&lt;br /&gt;
LinuxMCE uses a modular architecture. The heart of LinuxMCE, the &#039;main application&#039; DCERouter is nothing but a general-purpose message router. It has absolutely no code relating to any of LinuxMCE’s functionality--it just relays messages between &amp;quot;Devices&amp;quot;. The functionality of LinuxMCE is entirely in separate programs (aka &amp;quot;Devices&amp;quot;) which all run independently and communicate with each other by passing messages through DCERouter over sockets. &lt;br /&gt;
&lt;br /&gt;
[[Image:LMCE_Architecture_mini.jpg|frame|none|LinuxMCE architecture – the devices]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The plug-in’s are also devices, but instead of running as separate binaries, they run as dynamic libraries in DCERouter’s memory space.&lt;br /&gt;
A LinuxMCE system can have one or more Media Directors (MD’s). Also, a Core machine can have also the functionality of a Media Director. We call it a Hybrid:&lt;br /&gt;
&lt;br /&gt;
[[Image:LMCE_Architecture_-_the_machines.jpg|frame|none|Linux MCE architecture – the machines]]&lt;br /&gt;
&lt;br /&gt;
==2. DCE== &lt;br /&gt;
&lt;br /&gt;
DCE (Data, Commands and Events) is a lightweight network protocol allowing any device to access its configuration (ie data) from a central database, send + receive commands, and fire + respond to events.&lt;br /&gt;
&lt;br /&gt;
The DCE protocol can be implemented with any device that supports standard networking. LinuxMCE provides a DCE library written in Ansi C++ that implements the protocol on any socket-compatible operating system, and has been tested on Linux and Windows. Porting to other languages should not be a big task. Because the messaging is socket-based, any device, regardless of operating system or language, can be used with any other device.&lt;br /&gt;
&lt;br /&gt;
In each installation there is also one DCE Router, through which all messages are routed. An &amp;quot;installation&amp;quot; is a group of devices treated as a unit, and normally corresponds to a physical residence.&lt;br /&gt;
&lt;br /&gt;
The DCE Router is itself quite simple. It just opens a port for incoming connections. When a device connects, the device sends its unique ID, or Mac Address. The DCE Router does a lookup in a database, and returns that device&#039;s data (configuration). DCERouter also sends back a list of all the other devices in the installation with basic information including the commands they know how to implement. The DCE Device then opens a minimum of 2 socket connections to the router. One is for incoming messages (usually commands) from the router, another for outgoing messages (usually events) to it. The DCE Library, which implements the protocol for DCE Devices and the DCE Router, will also open a 3rd socket connection so that it has 2 outgoing sockets: 1 dedicated for sending events and the other for sending other types of messages, like requests and commands to other devices.&lt;br /&gt;
&lt;br /&gt;
All messages go through the router. The devices do not communicate directly to each other. The message will contain information such as the destination device, the type of message, the message id and any number of optional parameters. The router does nothing with the message but forward it to the destination device or devices if the message is being sent to more than one. The DCE library, from which DCE Devices and the DCE Router are derived, knows how to receive incoming messages of the type command and route them to a message handler in the DCE Device. &lt;br /&gt;
&lt;br /&gt;
Another important library is PlutoUtils. It has cross-platform wrapper classes to handle file, strings, processes, threads synchronization, database utils, etc.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==3. DCERouter==&lt;br /&gt;
&lt;br /&gt;
When a DCE Device connects, DCERouter gives it its configuration data and is responsible for receiving and forwarding any messages to and from the devices that connect to it. The most common types of messages are commands and events. All communication goes through DCE Router. If a doorbell device fires an event that the button was pushed, that event goes to DCERouter, which will forward it whatever plug-in has indicated it wants to handle that type of event. If the plug-in then wants to send a command to the media player, this command goes first to the DCE Router, which will then forward it to the media player. The DCE Devices never communicate with each other directly--everything goes through DCE Router. Devices can create their own types of messages specific to them--not just commands and events. For example, a DVD player may send a message that contains a screen capture, or a TV program may send a stream of messages with streaming video. To DCE Router it makes no difference. Messages just have sources and destinations, and DCE Router does not care what type of message it is.&lt;br /&gt;
&lt;br /&gt;
DCERouter also allows you to Message Interceptors. This means a device or plug-in can say that it wants to pre-process all messages that meet a certain criteria. For example, a security plug-in may want to see all events relating to security.&lt;br /&gt;
Plug-in’s are DCE Devices that run within the DCERouter&#039;s memory space. They are DCE Devices just like any other and they are created like any other DCE Device. The code is the same, it&#039;s just a compilation option whether the device is built as a normal DCE Device, which runs in its own memory space and communicates with DCERouter over a socket, or if it&#039;s a plug-in which gets loaded into DCERouter&#039;s memory space. Plug-in’s have the ability to get pointers to the in-memory instance of the other plug-ins so they can share memory and call each others methods.&lt;br /&gt;
&lt;br /&gt;
See below a simplified class diagram for DCERouter:&lt;br /&gt;
[[Image:DCERouter.jpg|frame|none|Simplified class diagram for the DCE router]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==4. The binary communication protocol==&lt;br /&gt;
&lt;br /&gt;
===4.1 Introduction===&lt;br /&gt;
A device can create a command connection and one or more event connections to the router. &lt;br /&gt;
*The command connection is used as an incoming connection and device will use it to receive message from the router (commands). &lt;br /&gt;
*An event connection is used by the device as an outgoing connection to notify the router about events or the deliver commands to other devices. &lt;br /&gt;
The DCERouter process is listening on 3450 port. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===4.2. How to create an event connection===&lt;br /&gt;
Here is how the handshake is made for an event connection: &lt;br /&gt;
&lt;br /&gt;
&amp;gt;&amp;gt; Device sends: &lt;br /&gt;
EVENT &amp;lt;my_device_id&amp;gt; &#039;\n&#039; &lt;br /&gt;
&lt;br /&gt;
&amp;lt;&amp;lt; The router will respond with : &lt;br /&gt;
OK &amp;lt;my_device_id&amp;gt; IP=&amp;lt;device_ip_address&amp;gt; &#039;\n&#039; &lt;br /&gt;
&lt;br /&gt;
&amp;gt;&amp;gt; To send a message, the device will send : &lt;br /&gt;
MESSAGE &amp;lt;size_of_binary_message&amp;gt; &#039;\n&#039; &lt;br /&gt;
&lt;br /&gt;
and then:&lt;br /&gt;
&amp;lt;serialized_binary_message&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===4.3 How to serialize data===&lt;br /&gt;
DCE uses SerializeClass to serialize/deserialize data. &lt;br /&gt;
The sources can be found here : src/SerializeClass/Serialize.h/cpp. &lt;br /&gt;
The deserialize the data, the deserializing module must know the way the data was serialized like this: &lt;br /&gt;
* 4 bytes, unsigned long&lt;br /&gt;
* 1 byte, unsigned char &lt;br /&gt;
&lt;br /&gt;
Primitives: &lt;br /&gt;
* 8 bytes, unsigned int64 &lt;br /&gt;
* 8 bytes, int64 &lt;br /&gt;
* 4 bytes, unsigned long &lt;br /&gt;
* 4 bytes, unsigned short &lt;br /&gt;
* 1 byte, unsigned char &lt;br /&gt;
* 1 byte, char &lt;br /&gt;
* 4 byte, long &lt;br /&gt;
* 4 bytes, float &lt;br /&gt;
* 8 bytes, double &lt;br /&gt;
* 2 bytes, short&lt;br /&gt;
&lt;br /&gt;
Complex types: &lt;br /&gt;
&lt;br /&gt;
#string &lt;br /&gt;
#*STR_LENGTH bytes, the array with chars &lt;br /&gt;
#*1 byte, &#039;/0&#039; (value 0x00) &lt;br /&gt;
#:&lt;br /&gt;
#block of data &lt;br /&gt;
#*BLOCK_LENGTH bytes, the array with bytes &lt;br /&gt;
#:&lt;br /&gt;
#vector of strings &lt;br /&gt;
#*VECT_LENGTH bytes, the number of strings from vector &lt;br /&gt;
#*string 0 &lt;br /&gt;
#*string 1 &lt;br /&gt;
#*... &lt;br /&gt;
#*string VECT_LENGTH - 1 &lt;br /&gt;
&lt;br /&gt;
Other complex types serialized (see SerializeClass.cpp for details) : &lt;br /&gt;
* map&amp;lt;int,string&amp;gt; &lt;br /&gt;
* map&amp;lt;u_int64_t,string&amp;gt; &lt;br /&gt;
* map&amp;lt;int,int&amp;gt; &lt;br /&gt;
* map&amp;lt;string,string&amp;gt; &lt;br /&gt;
* vector&amp;lt;int&amp;gt; &lt;br /&gt;
* vector&amp;lt; pair&amp;lt;int,int&amp;gt; &amp;gt; &lt;br /&gt;
* map&amp;lt;string, pair&amp;lt;int,int&amp;gt; &amp;gt; &lt;br /&gt;
&lt;br /&gt;
SerializeClass also allowed you to serialize/deserialize custom objects. Examples: &lt;br /&gt;
* PlutoColor &lt;br /&gt;
* PlutoPoint &lt;br /&gt;
* PlutoSize &lt;br /&gt;
* PlutoRectangle &lt;br /&gt;
* PlutoDataBlock&lt;br /&gt;
&lt;br /&gt;
===4.4 How to serialize a message===&lt;br /&gt;
&lt;br /&gt;
The class used by DCE is Message class from src/DCE/Message.h/cpp unit. &lt;br /&gt;
&lt;br /&gt;
This is how the raw data looks like into a binary message: &lt;br /&gt;
&lt;br /&gt;
* long, value must be 1234 (magic number) &lt;br /&gt;
* long, &amp;lt;device_from_id&amp;gt; &lt;br /&gt;
* long, &amp;lt;device_to_id&amp;gt; &lt;br /&gt;
* long, &amp;lt;device_group_to_id&amp;gt; &lt;br /&gt;
* long, &amp;lt;message_id&amp;gt; &lt;br /&gt;
* long, &amp;lt;message_priority&amp;gt; &lt;br /&gt;
* long, &amp;lt;message_type&amp;gt; &lt;br /&gt;
* long, &amp;lt;device_category_to&amp;gt; &lt;br /&gt;
* long, &amp;lt;device_template_to&amp;gt; &lt;br /&gt;
* unsigned char, &amp;lt;include_children&amp;gt; &lt;br /&gt;
* long, &amp;lt;message_broadcast_level&amp;gt; &lt;br /&gt;
* long, &amp;lt;message_retry&amp;gt; &lt;br /&gt;
* unsigned char, &amp;lt;relative_to_sender&amp;gt; &lt;br /&gt;
* long, &amp;lt;expected_response&amp;gt; &lt;br /&gt;
* string, &amp;lt;device_list_to&amp;gt; &lt;br /&gt;
* unsigned long, &amp;lt;number_of_string_parameters&amp;gt; &lt;br /&gt;
**	foreach &amp;lt;string_parameter&amp;gt; &lt;br /&gt;
***	long, &amp;lt;string_parameter_id&amp;gt; &lt;br /&gt;
***     string, &amp;lt;string_parameter_value&amp;gt; &lt;br /&gt;
**	end_foreach &lt;br /&gt;
* unsigned long, &amp;lt;number_of_data_parameters&amp;gt; &lt;br /&gt;
**	foreach &amp;lt;data_parameter&amp;gt; &lt;br /&gt;
***	long, &amp;lt;data_parameter_id&amp;gt; &lt;br /&gt;
***	unsigned long, &amp;lt;data_parameter_length&amp;gt; &lt;br /&gt;
***	array of bytes, &amp;lt;data_parameter_value&amp;gt; &lt;br /&gt;
**      end_foreach &lt;br /&gt;
* unsigned long, &amp;lt;number_of_extra_messages&amp;gt; &lt;br /&gt;
**	foreach &amp;lt;extra_message&amp;gt; &lt;br /&gt;
***	unsigned long, &amp;lt;serialized_extra_message_length&amp;gt; &lt;br /&gt;
***	array of bytes, &amp;lt;serialized_extra_message_value&amp;gt; &lt;br /&gt;
**	end_foreach &lt;br /&gt;
* unsigned long, must be 6789 &lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Enums:&#039;&#039;&#039; &lt;br /&gt;
* enum eBroadcastLevel { BL_None=0, BL_DirectSiblings=1, BL_SameComputer=2, BL_SameRoom=3, BL_SameHouse=4, BL_AllHouses=5 }; &lt;br /&gt;
* enum eRetry { MR_None=0, MR_Retry=1, MR_Persist=2 }; &lt;br /&gt;
* enum eExpectedResponse { ER_None=0, ER_ReplyMessage, ER_ReplyString, ER_DeliveryConfirmation }; &lt;br /&gt;
* message types: enum { MESSAGETYPE_COMMAND=1, MESSAGETYPE_EVENT=2, MESSAGETYPE_DATAPARM_CHANGE=3, MESSAGETYPE_REPLY=4, MESSAGETYPE_DATAPARM_REQUEST=5, MESSAGETYPE_LOG=6, MESSAGETYPE_SYSCOMMAND=7, MESSAGETYPE_REGISTER_INTERCEPTOR=8, MESSAGETYPE_MESSAGE_INTERCEPTED=9, MESSAGETYPE_EXEC_COMMAND_GROUP=10, MESSAGETYPE_START_PING=11, MESSAGETYPE_STOP_PING=12, MESSAGETYPE_PURGE_INTERCEPTORS=13, MESSAGETYPE_PENDING_TASKS=14 }; &lt;br /&gt;
* message priority : enum { PRIORITY_LOW=0, PRIORITY_NORMAL=1, PRIORITY_HIGH=2, PRIORITY_URGENT=3 }; &lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Important notes:&#039;&#039;&#039; &lt;br /&gt;
* when sending to device template, set &amp;lt;device_template_to&amp;gt; to desired device template and also &amp;lt;device_to_id&amp;gt; to -2000 (DEVICEID_MASTERDEVICE) &lt;br /&gt;
* when sending to device category, set &amp;lt;device_category_to&amp;gt; to desired device category and also &amp;lt;device_to_id&amp;gt; to -2001 (DEVICEID_CATEGORY) &lt;br /&gt;
* when sending to a list with devices, set &amp;lt;device_list_to&amp;gt; to comma delimited list with devices and also &amp;lt;device_to_id&amp;gt; to -2002 (DEVICEID_LIST). &lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Example:&#039;&#039;&#039; &lt;br /&gt;
Here is the pseudocode to send the &amp;quot;on&amp;quot; command to a light switch. &lt;br /&gt;
We&#039;ll assume that the your device has #id 250 and the light switch has device #id 100 &lt;br /&gt;
&lt;br /&gt;
*MyDevice.Connect(router_ip, 3450 /*port*/)&lt;br /&gt;
*MyDevice.SendData(&amp;quot;EVENT 250\n&amp;quot;) &lt;br /&gt;
*MyDevice.ReceiveData() //until you&#039;ll get a &#039;\n&#039; ; you should receive: &amp;quot;OK 250 IP=&amp;lt;device_ip_address&amp;gt; &#039;\n&#039;; &lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;next: creating a message&#039;&#039;&#039; &lt;br /&gt;
let&#039;s say MyData is an array of bytes &lt;br /&gt;
*SerializeLong(MyData, 1234) //magic number &lt;br /&gt;
*SerializeLong(MyData, 250) //my id &lt;br /&gt;
*SerializeLong(MyData, 100) //the light switch &lt;br /&gt;
*SerializeLong(MyData, 0) //not used now &lt;br /&gt;
*SerializeLong(MyData, 192) //message id of command &#039;on&#039; &lt;br /&gt;
*SerializeLong(MyData, 1) //normal priority &lt;br /&gt;
*SerializeLong(MyData, 1) //message type : command &lt;br /&gt;
*SerializeLong(MyData, 0) //not used now &lt;br /&gt;
*SerializeLong(MyData, 0) //not used now &lt;br /&gt;
*SerializeUnsignedChar(MyData, 0) //not including children &lt;br /&gt;
*SerializeLong(MyData, 0) //broadcast level : none &lt;br /&gt;
*SerializeLong(MyData, 0) //don&#039;t retry &lt;br /&gt;
*SerializeUnsignedChar(MyData, 0) //relative to sender false &lt;br /&gt;
*SerializeLong(MyData, 3) //delivery confirmation &lt;br /&gt;
*SerializeString(MyData, &amp;quot;&amp;quot;) //device list to empty &lt;br /&gt;
*SerializeUnsignedLong(MyData, 2) //2 parameters &lt;br /&gt;
*SerializeLong(MyData, 98) //parameter type #98 &lt;br /&gt;
*SerializeString(MyData, &amp;quot;&amp;quot;) //empty value &lt;br /&gt;
*SerializeLong(MyData, 97) //parameter type #97 &lt;br /&gt;
*SerializeString(MyData, &amp;quot;&amp;quot;) //empty value &lt;br /&gt;
*SerializeUnsignedLong(MyData, 0) //no binary parameters &lt;br /&gt;
*SerializeUnsignedLong(MyData, 0) //no extra messages &lt;br /&gt;
*SerializeUnsignedLong(6789) //magic number &lt;br /&gt;
&lt;br /&gt;
*MyDevice.SendData(&amp;quot;MESSAGE &amp;quot; + MyData.length() + &#039;\n&#039;) &lt;br /&gt;
*MyDevice.SendData(MyData) &lt;br /&gt;
*MyDevice.ReceiveData() //until you&#039;ll get a &#039;\n&#039; ; you should receive: &amp;quot;OK&amp;quot; or an error message &lt;br /&gt;
&lt;br /&gt;
*MyDevice.CloseConnection();&lt;br /&gt;
&lt;br /&gt;
===4.5 How to serialize data-grids ===&lt;br /&gt;
&#039;&#039;&#039;Complex objects:&#039;&#039;&#039; &lt;br /&gt;
# DataGridCellSerializableData &lt;br /&gt;
#* unsigned long, &amp;lt;sizeof(DataGridCellSerializableData)&amp;gt; &lt;br /&gt;
#* unsigned long, &amp;lt;graphic_length&amp;gt; &lt;br /&gt;
#* unsigned long, &amp;lt;message_length&amp;gt; &lt;br /&gt;
#* unsigned long, &amp;lt;text_length&amp;gt; &lt;br /&gt;
#* unsigned long, &amp;lt;value_length&amp;gt; &lt;br /&gt;
#* unsigned long, &amp;lt;image_path_length&amp;gt; &lt;br /&gt;
#* unsigned long, &amp;lt;number_of_attributes_length&amp;gt; &lt;br /&gt;
#* unsigned long, &amp;lt;attributes_length&amp;gt; &lt;br /&gt;
#* int, &amp;lt;alternate_color&amp;gt; &lt;br /&gt;
#* unsigned long, &amp;lt;graphic_format&amp;gt; &lt;br /&gt;
#* unsigned char, &amp;lt;selectable&amp;gt; &lt;br /&gt;
#* int, &amp;lt;style_detail&amp;gt; &lt;br /&gt;
#* int, &amp;lt;col_span&amp;gt; &lt;br /&gt;
#* int, &amp;lt;row_span&amp;gt; &lt;br /&gt;
#* unsigned char, &amp;lt;dont_fire_grid_event&amp;gt; &lt;br /&gt;
#:&lt;br /&gt;
#:Enums: &lt;br /&gt;
#* enum eGraphicFormat { GR_UNKNOWN=0, GR_JPG=1, GR_GIF=2, GR_TIF=3, GR_PNG=4, GR_MNG=5, GR_BMP=6, GR_OCG=7, GR_PFG=8 }; &lt;br /&gt;
#:&lt;br /&gt;
# DataGridCell &lt;br /&gt;
#* DataGridCellSerializableData, &amp;lt;datagrid_cell_serializable_data&amp;gt; &lt;br /&gt;
#* array of chars, &amp;lt;text&amp;gt; &lt;br /&gt;
#* array of chars, &amp;lt;value&amp;gt; &lt;br /&gt;
#* array of bytes, &amp;lt;graphic_data&amp;gt; &lt;br /&gt;
#* array of bytes, &amp;lt;message_data&amp;gt; &lt;br /&gt;
#* array of chars, &amp;lt;image_path&amp;gt; &lt;br /&gt;
#*:&lt;br /&gt;
#**	foreach &amp;lt;cell_attribute&amp;gt; &lt;br /&gt;
#***	array of chars ended with &#039;\0&#039; , &amp;lt;cell_attribute_name&amp;gt; &lt;br /&gt;
#***	array of chars ended with &#039;\0&#039;, &amp;lt;cell_attribute_value&amp;gt; &lt;br /&gt;
#**	end_foreach &lt;br /&gt;
#:&lt;br /&gt;
#DataGridTableSerializableData &lt;br /&gt;
#* int, &amp;lt;total_number_of_columns&amp;gt; &lt;br /&gt;
#* int, &amp;lt;total_number_of_rows&amp;gt; &lt;br /&gt;
#* unsigned char, &amp;lt;keep_row_header&amp;gt; &lt;br /&gt;
#* unsigned char, &amp;lt;keep_column_header&amp;gt; &lt;br /&gt;
#* int, &amp;lt;column_count&amp;gt; &lt;br /&gt;
#* int, &amp;lt;row_count&amp;gt; &lt;br /&gt;
#* int, &amp;lt;starting_column&amp;gt; &lt;br /&gt;
#* int, &amp;lt;starting_row&amp;gt; &lt;br /&gt;
#* int, &amp;lt;cell_count&amp;gt; &lt;br /&gt;
#:&lt;br /&gt;
#DataGridTableCellIndex &lt;br /&gt;
#* unsigned int, &amp;lt;column_row_type&amp;gt; &lt;br /&gt;
#* unsigned int, &amp;lt;size&amp;gt; &lt;br /&gt;
#:&lt;br /&gt;
#DataGridTable &lt;br /&gt;
#* unsigned long, &amp;lt;sizeof(DataGridTableSerializableData)&amp;gt; &lt;br /&gt;
#* array of DataGridTableCellIndex, &amp;lt;col * row * sizeof(DataGridTableCellIndex)&amp;gt; &lt;br /&gt;
#* array of DataGridCell, &amp;lt;col * row * serialized DataGridCell&amp;gt; &lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
Additional step: lzo compression/decompression &lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; can be disabled if compiled with DISABLE_LZO_DATAGRID &lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
==5. The devices==&lt;br /&gt;
&lt;br /&gt;
Each device has associated an interface, which we call device template. A device template is a set of commands to be implemented, events which can be fired by the device and device data (persistent information for device).&lt;br /&gt;
To create device templates and modify them, go to LinuxMCE Web Admin -&amp;gt; Advanced -&amp;gt; Configuration -&amp;gt; Device Templates.&lt;br /&gt;
To generate the C++ code for the device implementing a device template interface, you must use DCEGen tool, specifying the database ip address and the device template number.&lt;br /&gt;
Here is the simplified class diagram for one of the devices (App_Server):&lt;br /&gt;
&lt;br /&gt;
[[Image:App_Server.jpg|frame|none|Simplified class diagram for a DCE device]]&lt;br /&gt;
&lt;br /&gt;
The classes App_Server_Event, App_Server_Command and App_Server_Data are generated using DCEGen tool. The base classes for them are implemented in DCE Library.&lt;br /&gt;
&lt;br /&gt;
==6. App_Server device==&lt;br /&gt;
&lt;br /&gt;
App_Server device is present by default on all LinuxMCE machines. It spawns/kills applications, handles volume of sound on that machine, restarts/halts the device.&lt;br /&gt;
&lt;br /&gt;
# Implemented commands:&lt;br /&gt;
#*CMD_Spawn_Application - Spawns an application&lt;br /&gt;
#*CMD_Kill_Application - Kills an application&lt;br /&gt;
#*CMD_Application_Is_Running - Checks if the given application is running.&lt;br /&gt;
#*CMD_Halt_Device - Halts or reboots this device&lt;br /&gt;
#*CMD_Vol_Up - Increases the volume 1%&lt;br /&gt;
#*CMD_Vol_Down - Decreases the volume 1%&lt;br /&gt;
#*CMD_Set_Volume - Sets the volume to a specific level between 0-100&lt;br /&gt;
#*CMD_Mute - Toggles mute/unmute&lt;br /&gt;
#: &lt;br /&gt;
#: &lt;br /&gt;
#It doesn’t fire any events.&lt;br /&gt;
#: &lt;br /&gt;
#: &lt;br /&gt;
#It has the following device data:&lt;br /&gt;
#*Discrete Volume&lt;br /&gt;
#*Volume Level&lt;br /&gt;
&lt;br /&gt;
==7. Photo_Screen_Saver device==&lt;br /&gt;
&lt;br /&gt;
The photo screen saver (PSS) displays pictures when there is no video playing, even if you just happen to be listening to music. By default, the photos come from Flickr and are downloaded regularly to local drive.&lt;br /&gt;
&lt;br /&gt;
PSS is a OpenGL application and it slides pictures and fades them between transitions. &lt;br /&gt;
&lt;br /&gt;
1. Implemented commands&lt;br /&gt;
&lt;br /&gt;
The list with pictures is taken by sending a command to Orbiter Plugin : CMD_Get_Screen_Saver_Files which has an output parameter Filename. The filenames are delimited by a ‘\n’ character.&lt;br /&gt;
&lt;br /&gt;
The PSS animations are started/stopped using CMD_On/CMD_Off commands. To force PSS reload the list with pictures from Orbiter Plugin, CMD_Reload is used.&lt;br /&gt;
&lt;br /&gt;
When PSS starts, it should check every 10 minutes if there are any pictures downloaded and ready to be displayed. If there are pictures to display it should display them on CMD_On command and refresh the list with pictures every 24 hours.&lt;br /&gt;
&lt;br /&gt;
2. It doesn’t fire any events&lt;br /&gt;
&lt;br /&gt;
3. Device data:&lt;br /&gt;
* ZoomTime - Value in miliseconds that a zoom effect will take &lt;br /&gt;
* FadeTime - value in miliseconds that a fade effect will take &lt;br /&gt;
* Name - The window name to activate&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==8. Media Player device==&lt;br /&gt;
&lt;br /&gt;
Currently there are two Media Players in LinuxMCE, the primary Xine_Player and &lt;br /&gt;
secondary MPlayer_Player.&lt;br /&gt;
First one is based one the Xine engine (http://xinehq.de) and supports the &lt;br /&gt;
following formats:&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;File formats (System layer / media types)supported:&#039;&#039;&#039;&lt;br /&gt;
**direct DVD playback (of unlocked/unencrypted DVDs, see below)&lt;br /&gt;
** Video CD&lt;br /&gt;
** Audio CD&lt;br /&gt;
** mpeg program streams (.mpg, .mpeg)&lt;br /&gt;
** mpeg transport streams (.ts)&lt;br /&gt;
** ogg (.ogg, .ogm)&lt;br /&gt;
** avi (.avi)&lt;br /&gt;
** asf (.asf, .wmv, .wma)&lt;br /&gt;
** quicktime (.mov, .mp4)&lt;br /&gt;
** mpeg-video (.mpv, .m2v)&lt;br /&gt;
** mpeg-audio (.mp2, .mp3)&lt;br /&gt;
** Sega Saturn FILM (.cpk)&lt;br /&gt;
** Id Software RoQ (.roq)&lt;br /&gt;
** wav (.wav)&lt;br /&gt;
** Autodesk FLIC (.fli)&lt;br /&gt;
** real (.rm, .ra, .ram)&lt;br /&gt;
** raw dv (.dv)&lt;br /&gt;
** network graphics format (.png, .mng)&lt;br /&gt;
** Creative Voice (.voc)&lt;br /&gt;
** Sun/NeXT SND/AU (.snd, .au)&lt;br /&gt;
** Wing Commander III (.mve)&lt;br /&gt;
** Westwood Studios files (.vqa, .aud)&lt;br /&gt;
** Electronic Arts WVE (.wve)&lt;br /&gt;
** AIFF (.aif, .aiff)&lt;br /&gt;
** YUV4MPEG2 (.y4m)&lt;br /&gt;
** SMJPEG (.mjpg)&lt;br /&gt;
** raw AC3 (.ac3)&lt;br /&gt;
** Dialogic VOX (.vox)&lt;br /&gt;
** TechnoTrend PVA (.pva)&lt;br /&gt;
** Playstation STR (.str)&lt;br /&gt;
** Nullsoft Video (.nsv)&lt;br /&gt;
** 4X Technologies (.4xm)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Video codecs supported:&#039;&#039;&#039;&lt;br /&gt;
** mpeg 1/2&lt;br /&gt;
** mpeg 4 (aka OpenDivX)&lt;br /&gt;
** ms mpeg 4&lt;br /&gt;
** divx 3/4/5&lt;br /&gt;
** windows media video 7 &amp;amp; 8&lt;br /&gt;
** motion jpeg&lt;br /&gt;
** Cinepak&lt;br /&gt;
** DV&lt;br /&gt;
** ms video 1 (msvc)&lt;br /&gt;
** ms rle&lt;br /&gt;
** Sorenson SVQ1/SVQ3 (often used in Quicktime trailers)&lt;br /&gt;
** creative yuv (cyuv)&lt;br /&gt;
** roq video&lt;br /&gt;
** QT RLE, SMC, RPZA&lt;br /&gt;
** theora&lt;br /&gt;
** via external binary/win32 codecs (not included in xine):&lt;br /&gt;
** Indeo 3.1-5.0&lt;br /&gt;
** Window Media Video 8,9&lt;br /&gt;
** On2 VP3.1&lt;br /&gt;
** I263&lt;br /&gt;
** Real Media 2.0, 3.0, 4.0&lt;br /&gt;
* currently unsupported/untested Formats:&lt;br /&gt;
** 3ivx&lt;br /&gt;
** h263 (aka Real Video 1.0)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Audio codecs&#039;&#039;&#039;&lt;br /&gt;
** mpeg audio (layer 1,2,3)&lt;br /&gt;
** a/52 (aka ac3, dolby digital)&lt;br /&gt;
** aac (used in .mp4 files)&lt;br /&gt;
** dts (via external decoder)&lt;br /&gt;
** vorbis&lt;br /&gt;
** pcm&lt;br /&gt;
** adpcm (MS/IMA/DVI/Dialogic)&lt;br /&gt;
** mu-law and A-law&lt;br /&gt;
** roq dpcm&lt;br /&gt;
** Real Media dnet audio&lt;br /&gt;
** Real Media 28.8 audio&lt;br /&gt;
** DivX audio (WMA)&lt;br /&gt;
** GSM 6.10&lt;br /&gt;
** FLAC&lt;br /&gt;
** NSF (NES sound format)&lt;br /&gt;
** Speex&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The MPlayer_Player is used as the fallback player for the formats Xine doesn&#039;t &lt;br /&gt;
support/supports not well and currently is used for playing HD-DVD/Bluray &lt;br /&gt;
video files and disks.&lt;br /&gt;
&lt;br /&gt;
A media player device plays all kind of media: audio and video, stored media or from cd/dvd/hd/bluray drivers, etc.&lt;br /&gt;
&lt;br /&gt;
1. Implemented commands&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Keyboard input:&#039;&#039;&#039; &lt;br /&gt;
** CMD_EnterGo - Select the currently highlighted menu item&lt;br /&gt;
** CMD_Move_Up, CMD_Move_Down, CMD_Move_Left, CMD_Move_Right - Move the highlighter&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Media Player Commands&#039;&#039;&#039;&lt;br /&gt;
** CMD_Pause - Pause the media&lt;br /&gt;
** CMD_Play - Play the media&lt;br /&gt;
** CMD_Skip_Back_ChannelTrack_Lower - Lower the channel, track, station, etc. by 1.  Same as Jump to Pos in Playlist with value -1 for a smart media player&lt;br /&gt;
** CMD_Skip_Fwd_ChannelTrack_Greater - Raise  the channel, track, station, etc. by 1.  Same as Jump to Pos in Playlist with value +1 for a smart media player&lt;br /&gt;
** CMD_Stop - Stop the media&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Menu Navigation&#039;&#039;&#039;&lt;br /&gt;
** CMD_EnterGo - Select the currently highlighted menu item&lt;br /&gt;
** CMD_Move_Up, CMD_Move_Down, CMD_Move_Left, CMD_Move_Right - Move the highlighter&lt;br /&gt;
** CMD_Get_Video_Frame - Gets the current video frame from the media player.&lt;br /&gt;
** CMD_Goto_Media_Menu - Goto to the current media Root Menu.&lt;br /&gt;
** CMD_Navigate_Next - Nagivate to the next possible navigable area. (The actual outcome depends on the specifc device)&lt;br /&gt;
** CMD_Navigate_Prev - Nagivate the previous possible navigable area. (The actual outcome depends on the specific device).&lt;br /&gt;
** CMD_Simulate_Mouse_Click - Simlate a mouse click at a certain position on the screen&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Smart DVD commands&#039;&#039;&#039;&lt;br /&gt;
** CMD_Angle – Go to an angle&lt;br /&gt;
** CMD_Audio_Track – Go to an audio track&lt;br /&gt;
** Subtitle – Go to a subtitle&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Smart Media Player&#039;&#039;&#039;&lt;br /&gt;
** CMD_Change_Playback_Speed – Will make the playback to FF with a configurable amount of speed.&lt;br /&gt;
** CMD_Guide - Show guide information.  For a dvd this may be the menu, just like the menu command&lt;br /&gt;
** CMD_Jump_Position_In_Playlist - Jump to a specific position in the playlist, or a track, or a chapter.  Smart media players should also understand the skip fwd/skip back (which non-DCE media players use) to be the same thing as a jump +1 or -1&lt;br /&gt;
** CMD_Jump_To_Position_In_Stream - Jump to a position in the stream, specified in seconds.&lt;br /&gt;
** CMD_Menu - Show a menu associated with this media&lt;br /&gt;
** CMD_Pause_Media - This will stop a media that is currently played. This method should be paired with the &amp;quot;Restart Media&amp;quot; and used when the playback will be stopped and restarted on the same display device.&lt;br /&gt;
** CMD_Play_Media - This command will instruct a Media Player to play a media stream identified by a media descriptor created by the &amp;quot;Create Media&amp;quot; command.&lt;br /&gt;
** CMD_Report_Playback_Position - This will report the playback position of the current stream.&lt;br /&gt;
** CMD_Restart_Media - This will restart a media was paused with the above command&lt;br /&gt;
** CMD_Set_Aspect_Ratio - Force aspect ratio&lt;br /&gt;
** CMD_Set_Media_ID - Set Media ID - information about media stream&lt;br /&gt;
** CMD_Set_Media_Position - Jump to a certain media position&lt;br /&gt;
** CMD_SetZoom - Sets zoom level, relative, absolute or &#039;auto&#039;&lt;br /&gt;
** CMD_Simulate_Keypress - Send a key to the device&#039;s OSD, or simulate keypresses on the device&#039;s panel&lt;br /&gt;
** CMD_Start_Streaming - Like play media, but it means the destination device is not the same as the source&lt;br /&gt;
** CMD_Stop_Media - This will instruct the media player to stop the playback of a media started with the &amp;quot;Play Media&amp;quot; Command&lt;br /&gt;
** CMD_Update_Object_Image - Display an image on the media player&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
2. &#039;&#039;&#039;It fires the following events&#039;&#039;&#039;&lt;br /&gt;
* EVENT_Menu_Onscreen - A DVD Menu appeared on screen&lt;br /&gt;
* EVENT_Playblack_Completed - Fired when the playback of a stream has completed.&lt;br /&gt;
* EVENT_Playback_Info_Changed – Playback info changed&lt;br /&gt;
* EVENT_Playback_Started – Media has start playing&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
3. &#039;&#039;&#039;Device data:&#039;&#039;&#039;&lt;br /&gt;
* Name - The name of the window for this app&lt;br /&gt;
* Hardware acceleration - driver used&lt;br /&gt;
* Deinterlacing Mode - Movie deinterlacing filter status&lt;br /&gt;
* Port – Time code notification every second&lt;br /&gt;
* Zoom Level – default zoom level&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;NOTE:&#039;&#039;&#039; A deviation from design, the media player must bind on a port specified in the device data and report the time code every one second. Any device like an Orbiter could connect to that port and read the time code. Here is the format used for time code:&lt;br /&gt;
Speed,CurrentTime,TotalTime,StreamID,Title,Chapter,MediaType,MediaID,Filename (comma delimited).&lt;br /&gt;
&lt;br /&gt;
==9. Orbiter==&lt;br /&gt;
&lt;br /&gt;
===9.1 Introduction===&lt;br /&gt;
&lt;br /&gt;
The Orbiter is really a device just like any other. The main class, Orbiter, is a normal DCE command implementation. However, the Orbiter class was written so that it has no platform-specific functions, such as graphics and sound. It handles the basic logic, and calls pure virtual functions that derived classes must implement to handle the platform-specific commands. Most of the code and virtually all of the logic is contained in the base classes. Therefore, it is a fairly easy task to make a new version of Orbiter for a platform other than SDL, perhaps one that uses Windows SDK calls, or another image library.&lt;br /&gt;
&lt;br /&gt;
Right now there are implementations of Orbiter using SDL. PocketFrog and OpenGL engines. Orbiter runs on different operation systems like Linux, Windows, Windows CE, Window Mobile, Symbian60. There also implementation for web orbiter (running into a browser) or for a Cisco hard phones (using XML services).&lt;br /&gt;
&lt;br /&gt;
===9.2 Architecture===&lt;br /&gt;
&lt;br /&gt;
[[Image:architecture.jpg|frame|none|Orbiter application architecture]]&lt;br /&gt;
&lt;br /&gt;
The present diagram shows how the Orbiter application architecture looks like. Depending on the Graphic Engine and the platform, the only modules dependent on them are “Renderers – engine specific” and “Orbiter - platform specific”. &lt;br /&gt;
&lt;br /&gt;
====9.2.1. The renderers====&lt;br /&gt;
&lt;br /&gt;
There are two kinds of renders:&lt;br /&gt;
* orbiter renderers&lt;br /&gt;
* object renderers&lt;br /&gt;
&lt;br /&gt;
The orbiter renderers (derived from OrbiterRenderer class) handle the graphic primitives, having pure virtual methods for operations like this:&lt;br /&gt;
* RenderText&lt;br /&gt;
* SolidRectangle&lt;br /&gt;
* HollowRectangle&lt;br /&gt;
* DrawLine&lt;br /&gt;
* FloodFill&lt;br /&gt;
* RenderGraphic&lt;br /&gt;
* ReplaceColorInRectangle&lt;br /&gt;
* etc.&lt;br /&gt;
&lt;br /&gt;
and applications flow :&lt;br /&gt;
* event loop&lt;br /&gt;
* configure&lt;br /&gt;
* destroy&lt;br /&gt;
* on quit&lt;br /&gt;
* on reload&lt;br /&gt;
&lt;br /&gt;
However, OrbiterRenderer is not an interface. It also has implemented the logic needed for: &lt;br /&gt;
* render screen action&lt;br /&gt;
* show a progress bar&lt;br /&gt;
* highlighting / un-highlighting objects&lt;br /&gt;
* render shortcuts&lt;br /&gt;
* show / hide popup’s&lt;br /&gt;
* redraw objects&lt;br /&gt;
* refresh screen&lt;br /&gt;
* render object asynchronously&lt;br /&gt;
* object on screen / off screen actions&lt;br /&gt;
* background image loading&lt;br /&gt;
* drawing an arrow&lt;br /&gt;
&lt;br /&gt;
Here is the class diagram for derived OrbiterRenderer‘s:&lt;br /&gt;
&lt;br /&gt;
[[Image:orbiterrenderer.jpg|frame|none|OrbiterRenderer class diagram]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Also, there are renderer classes of complex objects like button, data grid, edit box, etc. The base classes for them are : ObjectRenderer, DataGridRenderer. Each renderer is attached to an object like DesignObj_Orbiter, DesignObj_DataGrid. &lt;br /&gt;
&lt;br /&gt;
Here is the class diagram for OpenGL implementation:&lt;br /&gt;
&lt;br /&gt;
[[Image:openGLimplementation.jpg|frame|none|OpenGL implementation]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The screens are actually trees of objects. The characteristics of the objects are set using the Designer application and stored in the database, then serialized by OrbiterGen and then deserialized by Orbiter. &lt;br /&gt;
OrbiterGen scales and pre-renders the screens. Also, OrbiterGen embeds in the serialized data info about the actions to be executed when an object is loaded, activated, unloaded, etc.&lt;br /&gt;
&lt;br /&gt;
====9.2.2. Orbiter – platform specific====&lt;br /&gt;
&lt;br /&gt;
Orbiter also has to take care of the input events like mouse click, keyboard events, etc. For example, Orbiter_Win32 is derived from Orbiter class and takes care of enabling the auto-update mechanism. &lt;br /&gt;
Platform specific are the external dialogs with progress bar and prompt user, or the way the composite or masks are used (see OrbiterRenderer_Linux, OrbiterLinux, OrbiterRenderer_SDL_Win32&lt;br /&gt;
&lt;br /&gt;
The Linux version uses XRecord extension to intercept events. The Windows versions use PocketFrog engine’s event loop or SDL event loop.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
====9.2.3. Cache image manager====&lt;br /&gt;
&lt;br /&gt;
This module is mainly used by remote orbiters, non-OSD orbiters. Because these orbiters don’t have access to core’s file system, all the graphic files are obtained by network connection and it might be slow. So instead of requesting same image over and over, the image is cached on the local drivers. The collection of images cached are associated with a timestamp (the generation date for the screens). If the user decides to regenerate the screens, the timestamp is changed and the cache is purged and the images are requested, on demand, again from the server.&lt;br /&gt;
&lt;br /&gt;
====9.2.4. Self update module====&lt;br /&gt;
&lt;br /&gt;
The “Self update” module is also used for non-OSD orbiters. Once a new version of the Orbiter XP/CE is available, a new binary data is stored on core’s filesystem. When an non-OSD orbiter starts, compares the md5sum of the current binary with the one from the server. If it’s different, the UpdateBinary is spawned, Orbiter exits and UpdateBinary requests the new binary from server, it downloads it, replaces the old binary and restart Orbiter.&lt;br /&gt;
&lt;br /&gt;
====9.2.5. Simulator====&lt;br /&gt;
&lt;br /&gt;
The simulator is responsible for generating mouse and keyboard events used for stress testing. It also stores some configuration settings.&lt;br /&gt;
&lt;br /&gt;
====9.2.6. Graphic objects====&lt;br /&gt;
&lt;br /&gt;
They are all derived from PlutoGraphic class and store info about the filename, width, height, the block of data and its length, graphic format and graphic management. The operations required are related to loading graphics from a file or a block of data, clearing the data stored, initializations, etc.&lt;br /&gt;
In the derived classes like PocketFrogGraphic, SDLGraphic, OpenGLGraphic, specific info are stored like the Surface for PocketFrong, SDL_Surface for SDL and the texture for OpenGL.&lt;br /&gt;
&lt;br /&gt;
====9.2.7. Orbiter logic module====&lt;br /&gt;
&lt;br /&gt;
Just like any other device, Orbiter is derived from a {Device_name}_Command class, the wrapper class generated by DCEGen to allow the device communicate with the router. However, Orbiter is also derived from OrbiterData and IRReceiverBase.&lt;br /&gt;
&lt;br /&gt;
[[Image:orbiterlogicclassdiagram.jpg|frame|none|Orbiter logic – class diagram]]&lt;br /&gt;
&lt;br /&gt;
 &lt;br /&gt;
OrbiterData helps Orbiter deserialize the data needed for its graphic objects, data serialized by OrbiterGen. IRReceiverBase is the base class for all IR receiver devices and it translates IR codes into actions, base on the current screen type and remote layout.&lt;br /&gt;
&lt;br /&gt;
====9.2.7. Mouse handlers====&lt;br /&gt;
&lt;br /&gt;
The goal of handlers is the interpret mouse movements and perform specific actions depending on current screen type. This is one of the main features add in UI2 version.&lt;br /&gt;
&lt;br /&gt;
See below the class diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image:mousehandlers.jpg|frame|none|Mouse handlers – class diagram]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Note that the mouse handlers are not available for UI1 version of Orbiter.&lt;br /&gt;
&lt;br /&gt;
MouseIterator and MouseGovernor limit the mouse movements the only one move per x ms to prevent extreme numbers of messages burdening the system.&lt;br /&gt;
MouseBehaviour handles special mouse behavior, such as locking axis’s, ramping and acceleration.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
====9.2.7. HID interface====&lt;br /&gt;
&lt;br /&gt;
This module gets events from the Gyration remote. See below the class diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image:HIDinterface.jpg|frame|none|HID interface – class diagram]]&lt;br /&gt;
&lt;br /&gt;
===9.3 Skinning and User Interface===&lt;br /&gt;
&lt;br /&gt;
====9.3.1 HADesigner====&lt;br /&gt;
The graphics, layout and display for the screens rendered in different Orbiter interfaces for the different UI versions are generated and manipulated using a Windows UI management tool called [http://wiki.linuxmce.org/index.php/Installing_HADesigner HADesigner].&lt;br /&gt;
&lt;br /&gt;
The following series of screencasts describes the use of the HADesigner tool and the process of generating a brand new UI for a specific plugin for all different variations of the Orbiter UI versions.&lt;br /&gt;
&lt;br /&gt;
# [http://www.localeconcept.com/HADesigner-Screencasts/01-basic_hadesigner_fundamentals.html Basic Designer Fundamentals]&lt;br /&gt;
# [http://www.localeconcept.com/HADesigner-Screencasts/ogg/02_designobj_basics_1.ogg Design Object Basics]&lt;br /&gt;
# [http://www.localeconcept.com/HADesigner-Screencasts/ogg/03_ui2_popup_part_1.ogg UI2 Popup Part I]&lt;br /&gt;
# [http://www.localeconcept.com/HADesigner-Screencasts/ogg/04_ui2_popup_part_2.ogg UI2 Popup Part II]&lt;br /&gt;
# [http://www.localeconcept.com/HADesigner-Screencasts/ogg/05_UI1_Orbiter.ogg UI1 Orbiter]&lt;br /&gt;
# [http://www.localeconcept.com/HADesigner-Screencasts/ogg/06_UI1_Full_Screen_OSD.ogg UI1 Full Screen OSD]&lt;br /&gt;
# [http://www.localeconcept.com/HADesigner-Screencasts/ogg/07_UI1_Full_Screen_OSD_2.ogg UI1 Full Screen OSD Part II]&lt;br /&gt;
# [http://www.localeconcept.com/HADesigner-Screencasts/ogg/08_UI1_PDA.ogg UI1 PDA]&lt;br /&gt;
# [http://www.localeconcept.com/HADesigner-Screencasts/ogg/09_Mobile_Remote.ogg Mobile Remote]&lt;br /&gt;
# [http://www.localeconcept.com/HADesigner-Screencasts/ogg/10_cisco_7970_orbiter.ogg Cisco 7970 Orbiter]&lt;br /&gt;
# [http://www.localeconcept.com/HADesigner-Screencasts/ogg/11_Monitor_mode.ogg Monitor Mode]&lt;br /&gt;
&lt;br /&gt;
The Basic skin, included with LinuxMCE, should really not be modified, since it is used extensively by LinuxMCE and Pluto and is known to work.&lt;br /&gt;
&lt;br /&gt;
====9.3.2 UI Design and process====&lt;br /&gt;
The following series of screencasts walks through the design considerations involved in creating a brand new skin for LinuxMCE.&lt;br /&gt;
&lt;br /&gt;
# [http://www.localeconcept.com/Skin-Screencasts/01_introduction_and_aesthetic.ogg Introduction and Aesthetic considerations]&lt;br /&gt;
# [http://www.localeconcept.com/Skin-Screencasts/02_main_menu_first_pass.ogg First Pass at the Main Menu]&lt;br /&gt;
# [http://www.localeconcept.com/Skin-Screencasts/03_main_menu_notes_and_corrections.ogg Main Menu Notes and Corrections]&lt;br /&gt;
# [http://www.localeconcept.com/Skin-Screencasts/04_the_floorplan_buttons.ogg The Floorplan Buttons]&lt;/div&gt;</summary>
		<author><name>Juanfe</name></author>
	</entry>
	<entry>
		<id>http://wiki.linuxmce.org/index.php?title=Developers_Guide&amp;diff=15147</id>
		<title>Developers Guide</title>
		<link rel="alternate" type="text/html" href="http://wiki.linuxmce.org/index.php?title=Developers_Guide&amp;diff=15147"/>
		<updated>2008-07-31T15:51:25Z</updated>

		<summary type="html">&lt;p&gt;Juanfe: /* 9.3 Skinning and User Interface */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Category: Programmer&#039;s Guide]]&lt;br /&gt;
&lt;br /&gt;
{| align=&amp;quot;right&amp;quot;&lt;br /&gt;
  | __TOC__&lt;br /&gt;
  |}&lt;br /&gt;
LinuxMCE developer’s guide&lt;br /&gt;
Document version 1.0&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==1. Architecture==&lt;br /&gt;
&lt;br /&gt;
LinuxMCE uses a modular architecture. The heart of LinuxMCE, the &#039;main application&#039; DCERouter is nothing but a general-purpose message router. It has absolutely no code relating to any of LinuxMCE’s functionality--it just relays messages between &amp;quot;Devices&amp;quot;. The functionality of LinuxMCE is entirely in separate programs (aka &amp;quot;Devices&amp;quot;) which all run independently and communicate with each other by passing messages through DCERouter over sockets. &lt;br /&gt;
&lt;br /&gt;
[[Image:LMCE_Architecture_mini.jpg|frame|none|LinuxMCE architecture – the devices]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The plug-in’s are also devices, but instead of running as separate binaries, they run as dynamic libraries in DCERouter’s memory space.&lt;br /&gt;
A LinuxMCE system can have one or more Media Directors (MD’s). Also, a Core machine can have also the functionality of a Media Director. We call it a Hybrid:&lt;br /&gt;
&lt;br /&gt;
[[Image:LMCE_Architecture_-_the_machines.jpg|frame|none|Linux MCE architecture – the machines]]&lt;br /&gt;
&lt;br /&gt;
==2. DCE== &lt;br /&gt;
&lt;br /&gt;
DCE (Data, Commands and Events) is a lightweight network protocol allowing any device to access its configuration (ie data) from a central database, send + receive commands, and fire + respond to events.&lt;br /&gt;
&lt;br /&gt;
The DCE protocol can be implemented with any device that supports standard networking. LinuxMCE provides a DCE library written in Ansi C++ that implements the protocol on any socket-compatible operating system, and has been tested on Linux and Windows. Porting to other languages should not be a big task. Because the messaging is socket-based, any device, regardless of operating system or language, can be used with any other device.&lt;br /&gt;
&lt;br /&gt;
In each installation there is also one DCE Router, through which all messages are routed. An &amp;quot;installation&amp;quot; is a group of devices treated as a unit, and normally corresponds to a physical residence.&lt;br /&gt;
&lt;br /&gt;
The DCE Router is itself quite simple. It just opens a port for incoming connections. When a device connects, the device sends its unique ID, or Mac Address. The DCE Router does a lookup in a database, and returns that device&#039;s data (configuration). DCERouter also sends back a list of all the other devices in the installation with basic information including the commands they know how to implement. The DCE Device then opens a minimum of 2 socket connections to the router. One is for incoming messages (usually commands) from the router, another for outgoing messages (usually events) to it. The DCE Library, which implements the protocol for DCE Devices and the DCE Router, will also open a 3rd socket connection so that it has 2 outgoing sockets: 1 dedicated for sending events and the other for sending other types of messages, like requests and commands to other devices.&lt;br /&gt;
&lt;br /&gt;
All messages go through the router. The devices do not communicate directly to each other. The message will contain information such as the destination device, the type of message, the message id and any number of optional parameters. The router does nothing with the message but forward it to the destination device or devices if the message is being sent to more than one. The DCE library, from which DCE Devices and the DCE Router are derived, knows how to receive incoming messages of the type command and route them to a message handler in the DCE Device. &lt;br /&gt;
&lt;br /&gt;
Another important library is PlutoUtils. It has cross-platform wrapper classes to handle file, strings, processes, threads synchronization, database utils, etc.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==3. DCERouter==&lt;br /&gt;
&lt;br /&gt;
When a DCE Device connects, DCERouter gives it its configuration data and is responsible for receiving and forwarding any messages to and from the devices that connect to it. The most common types of messages are commands and events. All communication goes through DCE Router. If a doorbell device fires an event that the button was pushed, that event goes to DCERouter, which will forward it whatever plug-in has indicated it wants to handle that type of event. If the plug-in then wants to send a command to the media player, this command goes first to the DCE Router, which will then forward it to the media player. The DCE Devices never communicate with each other directly--everything goes through DCE Router. Devices can create their own types of messages specific to them--not just commands and events. For example, a DVD player may send a message that contains a screen capture, or a TV program may send a stream of messages with streaming video. To DCE Router it makes no difference. Messages just have sources and destinations, and DCE Router does not care what type of message it is.&lt;br /&gt;
&lt;br /&gt;
DCERouter also allows you to Message Interceptors. This means a device or plug-in can say that it wants to pre-process all messages that meet a certain criteria. For example, a security plug-in may want to see all events relating to security.&lt;br /&gt;
Plug-in’s are DCE Devices that run within the DCERouter&#039;s memory space. They are DCE Devices just like any other and they are created like any other DCE Device. The code is the same, it&#039;s just a compilation option whether the device is built as a normal DCE Device, which runs in its own memory space and communicates with DCERouter over a socket, or if it&#039;s a plug-in which gets loaded into DCERouter&#039;s memory space. Plug-in’s have the ability to get pointers to the in-memory instance of the other plug-ins so they can share memory and call each others methods.&lt;br /&gt;
&lt;br /&gt;
See below a simplified class diagram for DCERouter:&lt;br /&gt;
[[Image:DCERouter.jpg|frame|none|Simplified class diagram for the DCE router]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==4. The binary communication protocol==&lt;br /&gt;
&lt;br /&gt;
===4.1 Introduction===&lt;br /&gt;
A device can create a command connection and one or more event connections to the router. &lt;br /&gt;
*The command connection is used as an incoming connection and device will use it to receive message from the router (commands). &lt;br /&gt;
*An event connection is used by the device as an outgoing connection to notify the router about events or the deliver commands to other devices. &lt;br /&gt;
The DCERouter process is listening on 3450 port. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===4.2. How to create an event connection===&lt;br /&gt;
Here is how the handshake is made for an event connection: &lt;br /&gt;
&lt;br /&gt;
&amp;gt;&amp;gt; Device sends: &lt;br /&gt;
EVENT &amp;lt;my_device_id&amp;gt; &#039;\n&#039; &lt;br /&gt;
&lt;br /&gt;
&amp;lt;&amp;lt; The router will respond with : &lt;br /&gt;
OK &amp;lt;my_device_id&amp;gt; IP=&amp;lt;device_ip_address&amp;gt; &#039;\n&#039; &lt;br /&gt;
&lt;br /&gt;
&amp;gt;&amp;gt; To send a message, the device will send : &lt;br /&gt;
MESSAGE &amp;lt;size_of_binary_message&amp;gt; &#039;\n&#039; &lt;br /&gt;
&lt;br /&gt;
and then:&lt;br /&gt;
&amp;lt;serialized_binary_message&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===4.3 How to serialize data===&lt;br /&gt;
DCE uses SerializeClass to serialize/deserialize data. &lt;br /&gt;
The sources can be found here : src/SerializeClass/Serialize.h/cpp. &lt;br /&gt;
The deserialize the data, the deserializing module must know the way the data was serialized like this: &lt;br /&gt;
* 4 bytes, unsigned long&lt;br /&gt;
* 1 byte, unsigned char &lt;br /&gt;
&lt;br /&gt;
Primitives: &lt;br /&gt;
* 8 bytes, unsigned int64 &lt;br /&gt;
* 8 bytes, int64 &lt;br /&gt;
* 4 bytes, unsigned long &lt;br /&gt;
* 4 bytes, unsigned short &lt;br /&gt;
* 1 byte, unsigned char &lt;br /&gt;
* 1 byte, char &lt;br /&gt;
* 4 byte, long &lt;br /&gt;
* 4 bytes, float &lt;br /&gt;
* 8 bytes, double &lt;br /&gt;
* 2 bytes, short&lt;br /&gt;
&lt;br /&gt;
Complex types: &lt;br /&gt;
&lt;br /&gt;
#string &lt;br /&gt;
#*STR_LENGTH bytes, the array with chars &lt;br /&gt;
#*1 byte, &#039;/0&#039; (value 0x00) &lt;br /&gt;
#:&lt;br /&gt;
#block of data &lt;br /&gt;
#*BLOCK_LENGTH bytes, the array with bytes &lt;br /&gt;
#:&lt;br /&gt;
#vector of strings &lt;br /&gt;
#*VECT_LENGTH bytes, the number of strings from vector &lt;br /&gt;
#*string 0 &lt;br /&gt;
#*string 1 &lt;br /&gt;
#*... &lt;br /&gt;
#*string VECT_LENGTH - 1 &lt;br /&gt;
&lt;br /&gt;
Other complex types serialized (see SerializeClass.cpp for details) : &lt;br /&gt;
* map&amp;lt;int,string&amp;gt; &lt;br /&gt;
* map&amp;lt;u_int64_t,string&amp;gt; &lt;br /&gt;
* map&amp;lt;int,int&amp;gt; &lt;br /&gt;
* map&amp;lt;string,string&amp;gt; &lt;br /&gt;
* vector&amp;lt;int&amp;gt; &lt;br /&gt;
* vector&amp;lt; pair&amp;lt;int,int&amp;gt; &amp;gt; &lt;br /&gt;
* map&amp;lt;string, pair&amp;lt;int,int&amp;gt; &amp;gt; &lt;br /&gt;
&lt;br /&gt;
SerializeClass also allowed you to serialize/deserialize custom objects. Examples: &lt;br /&gt;
* PlutoColor &lt;br /&gt;
* PlutoPoint &lt;br /&gt;
* PlutoSize &lt;br /&gt;
* PlutoRectangle &lt;br /&gt;
* PlutoDataBlock&lt;br /&gt;
&lt;br /&gt;
===4.4 How to serialize a message===&lt;br /&gt;
&lt;br /&gt;
The class used by DCE is Message class from src/DCE/Message.h/cpp unit. &lt;br /&gt;
&lt;br /&gt;
This is how the raw data looks like into a binary message: &lt;br /&gt;
&lt;br /&gt;
* long, value must be 1234 (magic number) &lt;br /&gt;
* long, &amp;lt;device_from_id&amp;gt; &lt;br /&gt;
* long, &amp;lt;device_to_id&amp;gt; &lt;br /&gt;
* long, &amp;lt;device_group_to_id&amp;gt; &lt;br /&gt;
* long, &amp;lt;message_id&amp;gt; &lt;br /&gt;
* long, &amp;lt;message_priority&amp;gt; &lt;br /&gt;
* long, &amp;lt;message_type&amp;gt; &lt;br /&gt;
* long, &amp;lt;device_category_to&amp;gt; &lt;br /&gt;
* long, &amp;lt;device_template_to&amp;gt; &lt;br /&gt;
* unsigned char, &amp;lt;include_children&amp;gt; &lt;br /&gt;
* long, &amp;lt;message_broadcast_level&amp;gt; &lt;br /&gt;
* long, &amp;lt;message_retry&amp;gt; &lt;br /&gt;
* unsigned char, &amp;lt;relative_to_sender&amp;gt; &lt;br /&gt;
* long, &amp;lt;expected_response&amp;gt; &lt;br /&gt;
* string, &amp;lt;device_list_to&amp;gt; &lt;br /&gt;
* unsigned long, &amp;lt;number_of_string_parameters&amp;gt; &lt;br /&gt;
**	foreach &amp;lt;string_parameter&amp;gt; &lt;br /&gt;
***	long, &amp;lt;string_parameter_id&amp;gt; &lt;br /&gt;
***     string, &amp;lt;string_parameter_value&amp;gt; &lt;br /&gt;
**	end_foreach &lt;br /&gt;
* unsigned long, &amp;lt;number_of_data_parameters&amp;gt; &lt;br /&gt;
**	foreach &amp;lt;data_parameter&amp;gt; &lt;br /&gt;
***	long, &amp;lt;data_parameter_id&amp;gt; &lt;br /&gt;
***	unsigned long, &amp;lt;data_parameter_length&amp;gt; &lt;br /&gt;
***	array of bytes, &amp;lt;data_parameter_value&amp;gt; &lt;br /&gt;
**      end_foreach &lt;br /&gt;
* unsigned long, &amp;lt;number_of_extra_messages&amp;gt; &lt;br /&gt;
**	foreach &amp;lt;extra_message&amp;gt; &lt;br /&gt;
***	unsigned long, &amp;lt;serialized_extra_message_length&amp;gt; &lt;br /&gt;
***	array of bytes, &amp;lt;serialized_extra_message_value&amp;gt; &lt;br /&gt;
**	end_foreach &lt;br /&gt;
* unsigned long, must be 6789 &lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Enums:&#039;&#039;&#039; &lt;br /&gt;
* enum eBroadcastLevel { BL_None=0, BL_DirectSiblings=1, BL_SameComputer=2, BL_SameRoom=3, BL_SameHouse=4, BL_AllHouses=5 }; &lt;br /&gt;
* enum eRetry { MR_None=0, MR_Retry=1, MR_Persist=2 }; &lt;br /&gt;
* enum eExpectedResponse { ER_None=0, ER_ReplyMessage, ER_ReplyString, ER_DeliveryConfirmation }; &lt;br /&gt;
* message types: enum { MESSAGETYPE_COMMAND=1, MESSAGETYPE_EVENT=2, MESSAGETYPE_DATAPARM_CHANGE=3, MESSAGETYPE_REPLY=4, MESSAGETYPE_DATAPARM_REQUEST=5, MESSAGETYPE_LOG=6, MESSAGETYPE_SYSCOMMAND=7, MESSAGETYPE_REGISTER_INTERCEPTOR=8, MESSAGETYPE_MESSAGE_INTERCEPTED=9, MESSAGETYPE_EXEC_COMMAND_GROUP=10, MESSAGETYPE_START_PING=11, MESSAGETYPE_STOP_PING=12, MESSAGETYPE_PURGE_INTERCEPTORS=13, MESSAGETYPE_PENDING_TASKS=14 }; &lt;br /&gt;
* message priority : enum { PRIORITY_LOW=0, PRIORITY_NORMAL=1, PRIORITY_HIGH=2, PRIORITY_URGENT=3 }; &lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Important notes:&#039;&#039;&#039; &lt;br /&gt;
* when sending to device template, set &amp;lt;device_template_to&amp;gt; to desired device template and also &amp;lt;device_to_id&amp;gt; to -2000 (DEVICEID_MASTERDEVICE) &lt;br /&gt;
* when sending to device category, set &amp;lt;device_category_to&amp;gt; to desired device category and also &amp;lt;device_to_id&amp;gt; to -2001 (DEVICEID_CATEGORY) &lt;br /&gt;
* when sending to a list with devices, set &amp;lt;device_list_to&amp;gt; to comma delimited list with devices and also &amp;lt;device_to_id&amp;gt; to -2002 (DEVICEID_LIST). &lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Example:&#039;&#039;&#039; &lt;br /&gt;
Here is the pseudocode to send the &amp;quot;on&amp;quot; command to a light switch. &lt;br /&gt;
We&#039;ll assume that the your device has #id 250 and the light switch has device #id 100 &lt;br /&gt;
&lt;br /&gt;
*MyDevice.Connect(router_ip, 3450 /*port*/)&lt;br /&gt;
*MyDevice.SendData(&amp;quot;EVENT 250\n&amp;quot;) &lt;br /&gt;
*MyDevice.ReceiveData() //until you&#039;ll get a &#039;\n&#039; ; you should receive: &amp;quot;OK 250 IP=&amp;lt;device_ip_address&amp;gt; &#039;\n&#039;; &lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;next: creating a message&#039;&#039;&#039; &lt;br /&gt;
let&#039;s say MyData is an array of bytes &lt;br /&gt;
*SerializeLong(MyData, 1234) //magic number &lt;br /&gt;
*SerializeLong(MyData, 250) //my id &lt;br /&gt;
*SerializeLong(MyData, 100) //the light switch &lt;br /&gt;
*SerializeLong(MyData, 0) //not used now &lt;br /&gt;
*SerializeLong(MyData, 192) //message id of command &#039;on&#039; &lt;br /&gt;
*SerializeLong(MyData, 1) //normal priority &lt;br /&gt;
*SerializeLong(MyData, 1) //message type : command &lt;br /&gt;
*SerializeLong(MyData, 0) //not used now &lt;br /&gt;
*SerializeLong(MyData, 0) //not used now &lt;br /&gt;
*SerializeUnsignedChar(MyData, 0) //not including children &lt;br /&gt;
*SerializeLong(MyData, 0) //broadcast level : none &lt;br /&gt;
*SerializeLong(MyData, 0) //don&#039;t retry &lt;br /&gt;
*SerializeUnsignedChar(MyData, 0) //relative to sender false &lt;br /&gt;
*SerializeLong(MyData, 3) //delivery confirmation &lt;br /&gt;
*SerializeString(MyData, &amp;quot;&amp;quot;) //device list to empty &lt;br /&gt;
*SerializeUnsignedLong(MyData, 2) //2 parameters &lt;br /&gt;
*SerializeLong(MyData, 98) //parameter type #98 &lt;br /&gt;
*SerializeString(MyData, &amp;quot;&amp;quot;) //empty value &lt;br /&gt;
*SerializeLong(MyData, 97) //parameter type #97 &lt;br /&gt;
*SerializeString(MyData, &amp;quot;&amp;quot;) //empty value &lt;br /&gt;
*SerializeUnsignedLong(MyData, 0) //no binary parameters &lt;br /&gt;
*SerializeUnsignedLong(MyData, 0) //no extra messages &lt;br /&gt;
*SerializeUnsignedLong(6789) //magic number &lt;br /&gt;
&lt;br /&gt;
*MyDevice.SendData(&amp;quot;MESSAGE &amp;quot; + MyData.length() + &#039;\n&#039;) &lt;br /&gt;
*MyDevice.SendData(MyData) &lt;br /&gt;
*MyDevice.ReceiveData() //until you&#039;ll get a &#039;\n&#039; ; you should receive: &amp;quot;OK&amp;quot; or an error message &lt;br /&gt;
&lt;br /&gt;
*MyDevice.CloseConnection();&lt;br /&gt;
&lt;br /&gt;
===4.5 How to serialize data-grids ===&lt;br /&gt;
&#039;&#039;&#039;Complex objects:&#039;&#039;&#039; &lt;br /&gt;
# DataGridCellSerializableData &lt;br /&gt;
#* unsigned long, &amp;lt;sizeof(DataGridCellSerializableData)&amp;gt; &lt;br /&gt;
#* unsigned long, &amp;lt;graphic_length&amp;gt; &lt;br /&gt;
#* unsigned long, &amp;lt;message_length&amp;gt; &lt;br /&gt;
#* unsigned long, &amp;lt;text_length&amp;gt; &lt;br /&gt;
#* unsigned long, &amp;lt;value_length&amp;gt; &lt;br /&gt;
#* unsigned long, &amp;lt;image_path_length&amp;gt; &lt;br /&gt;
#* unsigned long, &amp;lt;number_of_attributes_length&amp;gt; &lt;br /&gt;
#* unsigned long, &amp;lt;attributes_length&amp;gt; &lt;br /&gt;
#* int, &amp;lt;alternate_color&amp;gt; &lt;br /&gt;
#* unsigned long, &amp;lt;graphic_format&amp;gt; &lt;br /&gt;
#* unsigned char, &amp;lt;selectable&amp;gt; &lt;br /&gt;
#* int, &amp;lt;style_detail&amp;gt; &lt;br /&gt;
#* int, &amp;lt;col_span&amp;gt; &lt;br /&gt;
#* int, &amp;lt;row_span&amp;gt; &lt;br /&gt;
#* unsigned char, &amp;lt;dont_fire_grid_event&amp;gt; &lt;br /&gt;
#:&lt;br /&gt;
#:Enums: &lt;br /&gt;
#* enum eGraphicFormat { GR_UNKNOWN=0, GR_JPG=1, GR_GIF=2, GR_TIF=3, GR_PNG=4, GR_MNG=5, GR_BMP=6, GR_OCG=7, GR_PFG=8 }; &lt;br /&gt;
#:&lt;br /&gt;
# DataGridCell &lt;br /&gt;
#* DataGridCellSerializableData, &amp;lt;datagrid_cell_serializable_data&amp;gt; &lt;br /&gt;
#* array of chars, &amp;lt;text&amp;gt; &lt;br /&gt;
#* array of chars, &amp;lt;value&amp;gt; &lt;br /&gt;
#* array of bytes, &amp;lt;graphic_data&amp;gt; &lt;br /&gt;
#* array of bytes, &amp;lt;message_data&amp;gt; &lt;br /&gt;
#* array of chars, &amp;lt;image_path&amp;gt; &lt;br /&gt;
#*:&lt;br /&gt;
#**	foreach &amp;lt;cell_attribute&amp;gt; &lt;br /&gt;
#***	array of chars ended with &#039;\0&#039; , &amp;lt;cell_attribute_name&amp;gt; &lt;br /&gt;
#***	array of chars ended with &#039;\0&#039;, &amp;lt;cell_attribute_value&amp;gt; &lt;br /&gt;
#**	end_foreach &lt;br /&gt;
#:&lt;br /&gt;
#DataGridTableSerializableData &lt;br /&gt;
#* int, &amp;lt;total_number_of_columns&amp;gt; &lt;br /&gt;
#* int, &amp;lt;total_number_of_rows&amp;gt; &lt;br /&gt;
#* unsigned char, &amp;lt;keep_row_header&amp;gt; &lt;br /&gt;
#* unsigned char, &amp;lt;keep_column_header&amp;gt; &lt;br /&gt;
#* int, &amp;lt;column_count&amp;gt; &lt;br /&gt;
#* int, &amp;lt;row_count&amp;gt; &lt;br /&gt;
#* int, &amp;lt;starting_column&amp;gt; &lt;br /&gt;
#* int, &amp;lt;starting_row&amp;gt; &lt;br /&gt;
#* int, &amp;lt;cell_count&amp;gt; &lt;br /&gt;
#:&lt;br /&gt;
#DataGridTableCellIndex &lt;br /&gt;
#* unsigned int, &amp;lt;column_row_type&amp;gt; &lt;br /&gt;
#* unsigned int, &amp;lt;size&amp;gt; &lt;br /&gt;
#:&lt;br /&gt;
#DataGridTable &lt;br /&gt;
#* unsigned long, &amp;lt;sizeof(DataGridTableSerializableData)&amp;gt; &lt;br /&gt;
#* array of DataGridTableCellIndex, &amp;lt;col * row * sizeof(DataGridTableCellIndex)&amp;gt; &lt;br /&gt;
#* array of DataGridCell, &amp;lt;col * row * serialized DataGridCell&amp;gt; &lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
Additional step: lzo compression/decompression &lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; can be disabled if compiled with DISABLE_LZO_DATAGRID &lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
==5. The devices==&lt;br /&gt;
&lt;br /&gt;
Each device has associated an interface, which we call device template. A device template is a set of commands to be implemented, events which can be fired by the device and device data (persistent information for device).&lt;br /&gt;
To create device templates and modify them, go to LinuxMCE Web Admin -&amp;gt; Advanced -&amp;gt; Configuration -&amp;gt; Device Templates.&lt;br /&gt;
To generate the C++ code for the device implementing a device template interface, you must use DCEGen tool, specifying the database ip address and the device template number.&lt;br /&gt;
Here is the simplified class diagram for one of the devices (App_Server):&lt;br /&gt;
&lt;br /&gt;
[[Image:App_Server.jpg|frame|none|Simplified class diagram for a DCE device]]&lt;br /&gt;
&lt;br /&gt;
The classes App_Server_Event, App_Server_Command and App_Server_Data are generated using DCEGen tool. The base classes for them are implemented in DCE Library.&lt;br /&gt;
&lt;br /&gt;
==6. App_Server device==&lt;br /&gt;
&lt;br /&gt;
App_Server device is present by default on all LinuxMCE machines. It spawns/kills applications, handles volume of sound on that machine, restarts/halts the device.&lt;br /&gt;
&lt;br /&gt;
# Implemented commands:&lt;br /&gt;
#*CMD_Spawn_Application - Spawns an application&lt;br /&gt;
#*CMD_Kill_Application - Kills an application&lt;br /&gt;
#*CMD_Application_Is_Running - Checks if the given application is running.&lt;br /&gt;
#*CMD_Halt_Device - Halts or reboots this device&lt;br /&gt;
#*CMD_Vol_Up - Increases the volume 1%&lt;br /&gt;
#*CMD_Vol_Down - Decreases the volume 1%&lt;br /&gt;
#*CMD_Set_Volume - Sets the volume to a specific level between 0-100&lt;br /&gt;
#*CMD_Mute - Toggles mute/unmute&lt;br /&gt;
#: &lt;br /&gt;
#: &lt;br /&gt;
#It doesn’t fire any events.&lt;br /&gt;
#: &lt;br /&gt;
#: &lt;br /&gt;
#It has the following device data:&lt;br /&gt;
#*Discrete Volume&lt;br /&gt;
#*Volume Level&lt;br /&gt;
&lt;br /&gt;
==7. Photo_Screen_Saver device==&lt;br /&gt;
&lt;br /&gt;
The photo screen saver (PSS) displays pictures when there is no video playing, even if you just happen to be listening to music. By default, the photos come from Flickr and are downloaded regularly to local drive.&lt;br /&gt;
&lt;br /&gt;
PSS is a OpenGL application and it slides pictures and fades them between transitions. &lt;br /&gt;
&lt;br /&gt;
1. Implemented commands&lt;br /&gt;
&lt;br /&gt;
The list with pictures is taken by sending a command to Orbiter Plugin : CMD_Get_Screen_Saver_Files which has an output parameter Filename. The filenames are delimited by a ‘\n’ character.&lt;br /&gt;
&lt;br /&gt;
The PSS animations are started/stopped using CMD_On/CMD_Off commands. To force PSS reload the list with pictures from Orbiter Plugin, CMD_Reload is used.&lt;br /&gt;
&lt;br /&gt;
When PSS starts, it should check every 10 minutes if there are any pictures downloaded and ready to be displayed. If there are pictures to display it should display them on CMD_On command and refresh the list with pictures every 24 hours.&lt;br /&gt;
&lt;br /&gt;
2. It doesn’t fire any events&lt;br /&gt;
&lt;br /&gt;
3. Device data:&lt;br /&gt;
* ZoomTime - Value in miliseconds that a zoom effect will take &lt;br /&gt;
* FadeTime - value in miliseconds that a fade effect will take &lt;br /&gt;
* Name - The window name to activate&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==8. Media Player device==&lt;br /&gt;
&lt;br /&gt;
Currently there are two Media Players in LinuxMCE, the primary Xine_Player and &lt;br /&gt;
secondary MPlayer_Player.&lt;br /&gt;
First one is based one the Xine engine (http://xinehq.de) and supports the &lt;br /&gt;
following formats:&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;File formats (System layer / media types)supported:&#039;&#039;&#039;&lt;br /&gt;
**direct DVD playback (of unlocked/unencrypted DVDs, see below)&lt;br /&gt;
** Video CD&lt;br /&gt;
** Audio CD&lt;br /&gt;
** mpeg program streams (.mpg, .mpeg)&lt;br /&gt;
** mpeg transport streams (.ts)&lt;br /&gt;
** ogg (.ogg, .ogm)&lt;br /&gt;
** avi (.avi)&lt;br /&gt;
** asf (.asf, .wmv, .wma)&lt;br /&gt;
** quicktime (.mov, .mp4)&lt;br /&gt;
** mpeg-video (.mpv, .m2v)&lt;br /&gt;
** mpeg-audio (.mp2, .mp3)&lt;br /&gt;
** Sega Saturn FILM (.cpk)&lt;br /&gt;
** Id Software RoQ (.roq)&lt;br /&gt;
** wav (.wav)&lt;br /&gt;
** Autodesk FLIC (.fli)&lt;br /&gt;
** real (.rm, .ra, .ram)&lt;br /&gt;
** raw dv (.dv)&lt;br /&gt;
** network graphics format (.png, .mng)&lt;br /&gt;
** Creative Voice (.voc)&lt;br /&gt;
** Sun/NeXT SND/AU (.snd, .au)&lt;br /&gt;
** Wing Commander III (.mve)&lt;br /&gt;
** Westwood Studios files (.vqa, .aud)&lt;br /&gt;
** Electronic Arts WVE (.wve)&lt;br /&gt;
** AIFF (.aif, .aiff)&lt;br /&gt;
** YUV4MPEG2 (.y4m)&lt;br /&gt;
** SMJPEG (.mjpg)&lt;br /&gt;
** raw AC3 (.ac3)&lt;br /&gt;
** Dialogic VOX (.vox)&lt;br /&gt;
** TechnoTrend PVA (.pva)&lt;br /&gt;
** Playstation STR (.str)&lt;br /&gt;
** Nullsoft Video (.nsv)&lt;br /&gt;
** 4X Technologies (.4xm)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Video codecs supported:&#039;&#039;&#039;&lt;br /&gt;
** mpeg 1/2&lt;br /&gt;
** mpeg 4 (aka OpenDivX)&lt;br /&gt;
** ms mpeg 4&lt;br /&gt;
** divx 3/4/5&lt;br /&gt;
** windows media video 7 &amp;amp; 8&lt;br /&gt;
** motion jpeg&lt;br /&gt;
** Cinepak&lt;br /&gt;
** DV&lt;br /&gt;
** ms video 1 (msvc)&lt;br /&gt;
** ms rle&lt;br /&gt;
** Sorenson SVQ1/SVQ3 (often used in Quicktime trailers)&lt;br /&gt;
** creative yuv (cyuv)&lt;br /&gt;
** roq video&lt;br /&gt;
** QT RLE, SMC, RPZA&lt;br /&gt;
** theora&lt;br /&gt;
** via external binary/win32 codecs (not included in xine):&lt;br /&gt;
** Indeo 3.1-5.0&lt;br /&gt;
** Window Media Video 8,9&lt;br /&gt;
** On2 VP3.1&lt;br /&gt;
** I263&lt;br /&gt;
** Real Media 2.0, 3.0, 4.0&lt;br /&gt;
* currently unsupported/untested Formats:&lt;br /&gt;
** 3ivx&lt;br /&gt;
** h263 (aka Real Video 1.0)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Audio codecs&#039;&#039;&#039;&lt;br /&gt;
** mpeg audio (layer 1,2,3)&lt;br /&gt;
** a/52 (aka ac3, dolby digital)&lt;br /&gt;
** aac (used in .mp4 files)&lt;br /&gt;
** dts (via external decoder)&lt;br /&gt;
** vorbis&lt;br /&gt;
** pcm&lt;br /&gt;
** adpcm (MS/IMA/DVI/Dialogic)&lt;br /&gt;
** mu-law and A-law&lt;br /&gt;
** roq dpcm&lt;br /&gt;
** Real Media dnet audio&lt;br /&gt;
** Real Media 28.8 audio&lt;br /&gt;
** DivX audio (WMA)&lt;br /&gt;
** GSM 6.10&lt;br /&gt;
** FLAC&lt;br /&gt;
** NSF (NES sound format)&lt;br /&gt;
** Speex&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The MPlayer_Player is used as the fallback player for the formats Xine doesn&#039;t &lt;br /&gt;
support/supports not well and currently is used for playing HD-DVD/Bluray &lt;br /&gt;
video files and disks.&lt;br /&gt;
&lt;br /&gt;
A media player device plays all kind of media: audio and video, stored media or from cd/dvd/hd/bluray drivers, etc.&lt;br /&gt;
&lt;br /&gt;
1. Implemented commands&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Keyboard input:&#039;&#039;&#039; &lt;br /&gt;
** CMD_EnterGo - Select the currently highlighted menu item&lt;br /&gt;
** CMD_Move_Up, CMD_Move_Down, CMD_Move_Left, CMD_Move_Right - Move the highlighter&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Media Player Commands&#039;&#039;&#039;&lt;br /&gt;
** CMD_Pause - Pause the media&lt;br /&gt;
** CMD_Play - Play the media&lt;br /&gt;
** CMD_Skip_Back_ChannelTrack_Lower - Lower the channel, track, station, etc. by 1.  Same as Jump to Pos in Playlist with value -1 for a smart media player&lt;br /&gt;
** CMD_Skip_Fwd_ChannelTrack_Greater - Raise  the channel, track, station, etc. by 1.  Same as Jump to Pos in Playlist with value +1 for a smart media player&lt;br /&gt;
** CMD_Stop - Stop the media&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Menu Navigation&#039;&#039;&#039;&lt;br /&gt;
** CMD_EnterGo - Select the currently highlighted menu item&lt;br /&gt;
** CMD_Move_Up, CMD_Move_Down, CMD_Move_Left, CMD_Move_Right - Move the highlighter&lt;br /&gt;
** CMD_Get_Video_Frame - Gets the current video frame from the media player.&lt;br /&gt;
** CMD_Goto_Media_Menu - Goto to the current media Root Menu.&lt;br /&gt;
** CMD_Navigate_Next - Nagivate to the next possible navigable area. (The actual outcome depends on the specifc device)&lt;br /&gt;
** CMD_Navigate_Prev - Nagivate the previous possible navigable area. (The actual outcome depends on the specific device).&lt;br /&gt;
** CMD_Simulate_Mouse_Click - Simlate a mouse click at a certain position on the screen&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Smart DVD commands&#039;&#039;&#039;&lt;br /&gt;
** CMD_Angle – Go to an angle&lt;br /&gt;
** CMD_Audio_Track – Go to an audio track&lt;br /&gt;
** Subtitle – Go to a subtitle&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Smart Media Player&#039;&#039;&#039;&lt;br /&gt;
** CMD_Change_Playback_Speed – Will make the playback to FF with a configurable amount of speed.&lt;br /&gt;
** CMD_Guide - Show guide information.  For a dvd this may be the menu, just like the menu command&lt;br /&gt;
** CMD_Jump_Position_In_Playlist - Jump to a specific position in the playlist, or a track, or a chapter.  Smart media players should also understand the skip fwd/skip back (which non-DCE media players use) to be the same thing as a jump +1 or -1&lt;br /&gt;
** CMD_Jump_To_Position_In_Stream - Jump to a position in the stream, specified in seconds.&lt;br /&gt;
** CMD_Menu - Show a menu associated with this media&lt;br /&gt;
** CMD_Pause_Media - This will stop a media that is currently played. This method should be paired with the &amp;quot;Restart Media&amp;quot; and used when the playback will be stopped and restarted on the same display device.&lt;br /&gt;
** CMD_Play_Media - This command will instruct a Media Player to play a media stream identified by a media descriptor created by the &amp;quot;Create Media&amp;quot; command.&lt;br /&gt;
** CMD_Report_Playback_Position - This will report the playback position of the current stream.&lt;br /&gt;
** CMD_Restart_Media - This will restart a media was paused with the above command&lt;br /&gt;
** CMD_Set_Aspect_Ratio - Force aspect ratio&lt;br /&gt;
** CMD_Set_Media_ID - Set Media ID - information about media stream&lt;br /&gt;
** CMD_Set_Media_Position - Jump to a certain media position&lt;br /&gt;
** CMD_SetZoom - Sets zoom level, relative, absolute or &#039;auto&#039;&lt;br /&gt;
** CMD_Simulate_Keypress - Send a key to the device&#039;s OSD, or simulate keypresses on the device&#039;s panel&lt;br /&gt;
** CMD_Start_Streaming - Like play media, but it means the destination device is not the same as the source&lt;br /&gt;
** CMD_Stop_Media - This will instruct the media player to stop the playback of a media started with the &amp;quot;Play Media&amp;quot; Command&lt;br /&gt;
** CMD_Update_Object_Image - Display an image on the media player&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
2. &#039;&#039;&#039;It fires the following events&#039;&#039;&#039;&lt;br /&gt;
* EVENT_Menu_Onscreen - A DVD Menu appeared on screen&lt;br /&gt;
* EVENT_Playblack_Completed - Fired when the playback of a stream has completed.&lt;br /&gt;
* EVENT_Playback_Info_Changed – Playback info changed&lt;br /&gt;
* EVENT_Playback_Started – Media has start playing&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
3. &#039;&#039;&#039;Device data:&#039;&#039;&#039;&lt;br /&gt;
* Name - The name of the window for this app&lt;br /&gt;
* Hardware acceleration - driver used&lt;br /&gt;
* Deinterlacing Mode - Movie deinterlacing filter status&lt;br /&gt;
* Port – Time code notification every second&lt;br /&gt;
* Zoom Level – default zoom level&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;NOTE:&#039;&#039;&#039; A deviation from design, the media player must bind on a port specified in the device data and report the time code every one second. Any device like an Orbiter could connect to that port and read the time code. Here is the format used for time code:&lt;br /&gt;
Speed,CurrentTime,TotalTime,StreamID,Title,Chapter,MediaType,MediaID,Filename (comma delimited).&lt;br /&gt;
&lt;br /&gt;
==9. Orbiter==&lt;br /&gt;
&lt;br /&gt;
===9.1 Introduction===&lt;br /&gt;
&lt;br /&gt;
The Orbiter is really a device just like any other. The main class, Orbiter, is a normal DCE command implementation. However, the Orbiter class was written so that it has no platform-specific functions, such as graphics and sound. It handles the basic logic, and calls pure virtual functions that derived classes must implement to handle the platform-specific commands. Most of the code and virtually all of the logic is contained in the base classes. Therefore, it is a fairly easy task to make a new version of Orbiter for a platform other than SDL, perhaps one that uses Windows SDK calls, or another image library.&lt;br /&gt;
&lt;br /&gt;
Right now there are implementations of Orbiter using SDL. PocketFrog and OpenGL engines. Orbiter runs on different operation systems like Linux, Windows, Windows CE, Window Mobile, Symbian60. There also implementation for web orbiter (running into a browser) or for a Cisco hard phones (using XML services).&lt;br /&gt;
&lt;br /&gt;
===9.2 Architecture===&lt;br /&gt;
&lt;br /&gt;
[[Image:architecture.jpg|frame|none|Orbiter application architecture]]&lt;br /&gt;
&lt;br /&gt;
The present diagram shows how the Orbiter application architecture looks like. Depending on the Graphic Engine and the platform, the only modules dependent on them are “Renderers – engine specific” and “Orbiter - platform specific”. &lt;br /&gt;
&lt;br /&gt;
====9.2.1. The renderers====&lt;br /&gt;
&lt;br /&gt;
There are two kinds of renders:&lt;br /&gt;
* orbiter renderers&lt;br /&gt;
* object renderers&lt;br /&gt;
&lt;br /&gt;
The orbiter renderers (derived from OrbiterRenderer class) handle the graphic primitives, having pure virtual methods for operations like this:&lt;br /&gt;
* RenderText&lt;br /&gt;
* SolidRectangle&lt;br /&gt;
* HollowRectangle&lt;br /&gt;
* DrawLine&lt;br /&gt;
* FloodFill&lt;br /&gt;
* RenderGraphic&lt;br /&gt;
* ReplaceColorInRectangle&lt;br /&gt;
* etc.&lt;br /&gt;
&lt;br /&gt;
and applications flow :&lt;br /&gt;
* event loop&lt;br /&gt;
* configure&lt;br /&gt;
* destroy&lt;br /&gt;
* on quit&lt;br /&gt;
* on reload&lt;br /&gt;
&lt;br /&gt;
However, OrbiterRenderer is not an interface. It also has implemented the logic needed for: &lt;br /&gt;
* render screen action&lt;br /&gt;
* show a progress bar&lt;br /&gt;
* highlighting / un-highlighting objects&lt;br /&gt;
* render shortcuts&lt;br /&gt;
* show / hide popup’s&lt;br /&gt;
* redraw objects&lt;br /&gt;
* refresh screen&lt;br /&gt;
* render object asynchronously&lt;br /&gt;
* object on screen / off screen actions&lt;br /&gt;
* background image loading&lt;br /&gt;
* drawing an arrow&lt;br /&gt;
&lt;br /&gt;
Here is the class diagram for derived OrbiterRenderer‘s:&lt;br /&gt;
&lt;br /&gt;
[[Image:orbiterrenderer.jpg|frame|none|OrbiterRenderer class diagram]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Also, there are renderer classes of complex objects like button, data grid, edit box, etc. The base classes for them are : ObjectRenderer, DataGridRenderer. Each renderer is attached to an object like DesignObj_Orbiter, DesignObj_DataGrid. &lt;br /&gt;
&lt;br /&gt;
Here is the class diagram for OpenGL implementation:&lt;br /&gt;
&lt;br /&gt;
[[Image:openGLimplementation.jpg|frame|none|OpenGL implementation]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The screens are actually trees of objects. The characteristics of the objects are set using the Designer application and stored in the database, then serialized by OrbiterGen and then deserialized by Orbiter. &lt;br /&gt;
OrbiterGen scales and pre-renders the screens. Also, OrbiterGen embeds in the serialized data info about the actions to be executed when an object is loaded, activated, unloaded, etc.&lt;br /&gt;
&lt;br /&gt;
====9.2.2. Orbiter – platform specific====&lt;br /&gt;
&lt;br /&gt;
Orbiter also has to take care of the input events like mouse click, keyboard events, etc. For example, Orbiter_Win32 is derived from Orbiter class and takes care of enabling the auto-update mechanism. &lt;br /&gt;
Platform specific are the external dialogs with progress bar and prompt user, or the way the composite or masks are used (see OrbiterRenderer_Linux, OrbiterLinux, OrbiterRenderer_SDL_Win32&lt;br /&gt;
&lt;br /&gt;
The Linux version uses XRecord extension to intercept events. The Windows versions use PocketFrog engine’s event loop or SDL event loop.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
====9.2.3. Cache image manager====&lt;br /&gt;
&lt;br /&gt;
This module is mainly used by remote orbiters, non-OSD orbiters. Because these orbiters don’t have access to core’s file system, all the graphic files are obtained by network connection and it might be slow. So instead of requesting same image over and over, the image is cached on the local drivers. The collection of images cached are associated with a timestamp (the generation date for the screens). If the user decides to regenerate the screens, the timestamp is changed and the cache is purged and the images are requested, on demand, again from the server.&lt;br /&gt;
&lt;br /&gt;
====9.2.4. Self update module====&lt;br /&gt;
&lt;br /&gt;
The “Self update” module is also used for non-OSD orbiters. Once a new version of the Orbiter XP/CE is available, a new binary data is stored on core’s filesystem. When an non-OSD orbiter starts, compares the md5sum of the current binary with the one from the server. If it’s different, the UpdateBinary is spawned, Orbiter exits and UpdateBinary requests the new binary from server, it downloads it, replaces the old binary and restart Orbiter.&lt;br /&gt;
&lt;br /&gt;
====9.2.5. Simulator====&lt;br /&gt;
&lt;br /&gt;
The simulator is responsible for generating mouse and keyboard events used for stress testing. It also stores some configuration settings.&lt;br /&gt;
&lt;br /&gt;
====9.2.6. Graphic objects====&lt;br /&gt;
&lt;br /&gt;
They are all derived from PlutoGraphic class and store info about the filename, width, height, the block of data and its length, graphic format and graphic management. The operations required are related to loading graphics from a file or a block of data, clearing the data stored, initializations, etc.&lt;br /&gt;
In the derived classes like PocketFrogGraphic, SDLGraphic, OpenGLGraphic, specific info are stored like the Surface for PocketFrong, SDL_Surface for SDL and the texture for OpenGL.&lt;br /&gt;
&lt;br /&gt;
====9.2.7. Orbiter logic module====&lt;br /&gt;
&lt;br /&gt;
Just like any other device, Orbiter is derived from a {Device_name}_Command class, the wrapper class generated by DCEGen to allow the device communicate with the router. However, Orbiter is also derived from OrbiterData and IRReceiverBase.&lt;br /&gt;
&lt;br /&gt;
[[Image:orbiterlogicclassdiagram.jpg|frame|none|Orbiter logic – class diagram]]&lt;br /&gt;
&lt;br /&gt;
 &lt;br /&gt;
OrbiterData helps Orbiter deserialize the data needed for its graphic objects, data serialized by OrbiterGen. IRReceiverBase is the base class for all IR receiver devices and it translates IR codes into actions, base on the current screen type and remote layout.&lt;br /&gt;
&lt;br /&gt;
====9.2.7. Mouse handlers====&lt;br /&gt;
&lt;br /&gt;
The goal of handlers is the interpret mouse movements and perform specific actions depending on current screen type. This is one of the main features add in UI2 version.&lt;br /&gt;
&lt;br /&gt;
See below the class diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image:mousehandlers.jpg|frame|none|Mouse handlers – class diagram]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Note that the mouse handlers are not available for UI1 version of Orbiter.&lt;br /&gt;
&lt;br /&gt;
MouseIterator and MouseGovernor limit the mouse movements the only one move per x ms to prevent extreme numbers of messages burdening the system.&lt;br /&gt;
MouseBehaviour handles special mouse behavior, such as locking axis’s, ramping and acceleration.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
====9.2.7. HID interface====&lt;br /&gt;
&lt;br /&gt;
This module gets events from the Gyration remote. See below the class diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image:HIDinterface.jpg|frame|none|HID interface – class diagram]]&lt;br /&gt;
&lt;br /&gt;
===9.3 Skinning and User Interface===&lt;br /&gt;
&lt;br /&gt;
====9.3.1 HADesigner====&lt;br /&gt;
The graphics, layout and display for the screens rendered in different Orbiter interfaces for the different UI versions are generated and manipulated using a Windows UI management tool called HADesigner.&lt;br /&gt;
&lt;br /&gt;
The following series of screencasts describes the use of the HADesigner tool and the process of generating a brand new UI for a specific plugin for all different variations of the Orbiter UI versions.&lt;br /&gt;
&lt;br /&gt;
# [http://www.localeconcept.com/HADesigner-Screencasts/01-basic_hadesigner_fundamentals.html Basic Designer Fundamentals]&lt;br /&gt;
# [http://www.localeconcept.com/HADesigner-Screencasts/ogg/02_designobj_basics_1.ogg Design Object Basics]&lt;br /&gt;
# [http://www.localeconcept.com/HADesigner-Screencasts/ogg/03_ui2_popup_part_1.ogg UI2 Popup Part I]&lt;br /&gt;
# [http://www.localeconcept.com/HADesigner-Screencasts/ogg/04_ui2_popup_part_2.ogg UI2 Popup Part II]&lt;br /&gt;
# [http://www.localeconcept.com/HADesigner-Screencasts/ogg/05_UI1_Orbiter.ogg UI1 Orbiter]&lt;br /&gt;
# [http://www.localeconcept.com/HADesigner-Screencasts/ogg/06_UI1_Full_Screen_OSD.ogg UI1 Full Screen OSD]&lt;br /&gt;
# [http://www.localeconcept.com/HADesigner-Screencasts/ogg/07_UI1_Full_Screen_OSD_2.ogg UI1 Full Screen OSD Part II]&lt;br /&gt;
# [http://www.localeconcept.com/HADesigner-Screencasts/ogg/08_UI1_PDA.ogg UI1 PDA]&lt;br /&gt;
# [http://www.localeconcept.com/HADesigner-Screencasts/ogg/09_Mobile_Remote.ogg Mobile Remote]&lt;br /&gt;
# [http://www.localeconcept.com/HADesigner-Screencasts/ogg/10_cisco_7970_orbiter.ogg Cisco 7970 Orbiter]&lt;br /&gt;
# [http://www.localeconcept.com/HADesigner-Screencasts/ogg/11_Monitor_mode.ogg Monitor Mode]&lt;br /&gt;
&lt;br /&gt;
The Basic skin, included with LinuxMCE, should really not be modified, since it is used extensively by LinuxMCE and Pluto and is known to work.&lt;br /&gt;
&lt;br /&gt;
====9.3.2 UI Design and process====&lt;br /&gt;
The following series of screencasts walks through the design considerations involved in creating a brand new skin for LinuxMCE.&lt;br /&gt;
&lt;br /&gt;
# [http://www.localeconcept.com/Skin-Screencasts/01_introduction_and_aesthetic.ogg Introduction and Aesthetic considerations]&lt;br /&gt;
# [http://www.localeconcept.com/Skin-Screencasts/02_main_menu_first_pass.ogg First Pass at the Main Menu]&lt;br /&gt;
# [http://www.localeconcept.com/Skin-Screencasts/03_main_menu_notes_and_corrections.ogg Main Menu Notes and Corrections]&lt;br /&gt;
# [http://www.localeconcept.com/Skin-Screencasts/04_the_floorplan_buttons.ogg The Floorplan Buttons]&lt;/div&gt;</summary>
		<author><name>Juanfe</name></author>
	</entry>
	<entry>
		<id>http://wiki.linuxmce.org/index.php?title=Developers_Guide&amp;diff=15146</id>
		<title>Developers Guide</title>
		<link rel="alternate" type="text/html" href="http://wiki.linuxmce.org/index.php?title=Developers_Guide&amp;diff=15146"/>
		<updated>2008-07-31T15:43:34Z</updated>

		<summary type="html">&lt;p&gt;Juanfe: /* 9. Orbiter */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Category: Programmer&#039;s Guide]]&lt;br /&gt;
&lt;br /&gt;
{| align=&amp;quot;right&amp;quot;&lt;br /&gt;
  | __TOC__&lt;br /&gt;
  |}&lt;br /&gt;
LinuxMCE developer’s guide&lt;br /&gt;
Document version 1.0&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==1. Architecture==&lt;br /&gt;
&lt;br /&gt;
LinuxMCE uses a modular architecture. The heart of LinuxMCE, the &#039;main application&#039; DCERouter is nothing but a general-purpose message router. It has absolutely no code relating to any of LinuxMCE’s functionality--it just relays messages between &amp;quot;Devices&amp;quot;. The functionality of LinuxMCE is entirely in separate programs (aka &amp;quot;Devices&amp;quot;) which all run independently and communicate with each other by passing messages through DCERouter over sockets. &lt;br /&gt;
&lt;br /&gt;
[[Image:LMCE_Architecture_mini.jpg|frame|none|LinuxMCE architecture – the devices]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The plug-in’s are also devices, but instead of running as separate binaries, they run as dynamic libraries in DCERouter’s memory space.&lt;br /&gt;
A LinuxMCE system can have one or more Media Directors (MD’s). Also, a Core machine can have also the functionality of a Media Director. We call it a Hybrid:&lt;br /&gt;
&lt;br /&gt;
[[Image:LMCE_Architecture_-_the_machines.jpg|frame|none|Linux MCE architecture – the machines]]&lt;br /&gt;
&lt;br /&gt;
==2. DCE== &lt;br /&gt;
&lt;br /&gt;
DCE (Data, Commands and Events) is a lightweight network protocol allowing any device to access its configuration (ie data) from a central database, send + receive commands, and fire + respond to events.&lt;br /&gt;
&lt;br /&gt;
The DCE protocol can be implemented with any device that supports standard networking. LinuxMCE provides a DCE library written in Ansi C++ that implements the protocol on any socket-compatible operating system, and has been tested on Linux and Windows. Porting to other languages should not be a big task. Because the messaging is socket-based, any device, regardless of operating system or language, can be used with any other device.&lt;br /&gt;
&lt;br /&gt;
In each installation there is also one DCE Router, through which all messages are routed. An &amp;quot;installation&amp;quot; is a group of devices treated as a unit, and normally corresponds to a physical residence.&lt;br /&gt;
&lt;br /&gt;
The DCE Router is itself quite simple. It just opens a port for incoming connections. When a device connects, the device sends its unique ID, or Mac Address. The DCE Router does a lookup in a database, and returns that device&#039;s data (configuration). DCERouter also sends back a list of all the other devices in the installation with basic information including the commands they know how to implement. The DCE Device then opens a minimum of 2 socket connections to the router. One is for incoming messages (usually commands) from the router, another for outgoing messages (usually events) to it. The DCE Library, which implements the protocol for DCE Devices and the DCE Router, will also open a 3rd socket connection so that it has 2 outgoing sockets: 1 dedicated for sending events and the other for sending other types of messages, like requests and commands to other devices.&lt;br /&gt;
&lt;br /&gt;
All messages go through the router. The devices do not communicate directly to each other. The message will contain information such as the destination device, the type of message, the message id and any number of optional parameters. The router does nothing with the message but forward it to the destination device or devices if the message is being sent to more than one. The DCE library, from which DCE Devices and the DCE Router are derived, knows how to receive incoming messages of the type command and route them to a message handler in the DCE Device. &lt;br /&gt;
&lt;br /&gt;
Another important library is PlutoUtils. It has cross-platform wrapper classes to handle file, strings, processes, threads synchronization, database utils, etc.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==3. DCERouter==&lt;br /&gt;
&lt;br /&gt;
When a DCE Device connects, DCERouter gives it its configuration data and is responsible for receiving and forwarding any messages to and from the devices that connect to it. The most common types of messages are commands and events. All communication goes through DCE Router. If a doorbell device fires an event that the button was pushed, that event goes to DCERouter, which will forward it whatever plug-in has indicated it wants to handle that type of event. If the plug-in then wants to send a command to the media player, this command goes first to the DCE Router, which will then forward it to the media player. The DCE Devices never communicate with each other directly--everything goes through DCE Router. Devices can create their own types of messages specific to them--not just commands and events. For example, a DVD player may send a message that contains a screen capture, or a TV program may send a stream of messages with streaming video. To DCE Router it makes no difference. Messages just have sources and destinations, and DCE Router does not care what type of message it is.&lt;br /&gt;
&lt;br /&gt;
DCERouter also allows you to Message Interceptors. This means a device or plug-in can say that it wants to pre-process all messages that meet a certain criteria. For example, a security plug-in may want to see all events relating to security.&lt;br /&gt;
Plug-in’s are DCE Devices that run within the DCERouter&#039;s memory space. They are DCE Devices just like any other and they are created like any other DCE Device. The code is the same, it&#039;s just a compilation option whether the device is built as a normal DCE Device, which runs in its own memory space and communicates with DCERouter over a socket, or if it&#039;s a plug-in which gets loaded into DCERouter&#039;s memory space. Plug-in’s have the ability to get pointers to the in-memory instance of the other plug-ins so they can share memory and call each others methods.&lt;br /&gt;
&lt;br /&gt;
See below a simplified class diagram for DCERouter:&lt;br /&gt;
[[Image:DCERouter.jpg|frame|none|Simplified class diagram for the DCE router]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==4. The binary communication protocol==&lt;br /&gt;
&lt;br /&gt;
===4.1 Introduction===&lt;br /&gt;
A device can create a command connection and one or more event connections to the router. &lt;br /&gt;
*The command connection is used as an incoming connection and device will use it to receive message from the router (commands). &lt;br /&gt;
*An event connection is used by the device as an outgoing connection to notify the router about events or the deliver commands to other devices. &lt;br /&gt;
The DCERouter process is listening on 3450 port. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===4.2. How to create an event connection===&lt;br /&gt;
Here is how the handshake is made for an event connection: &lt;br /&gt;
&lt;br /&gt;
&amp;gt;&amp;gt; Device sends: &lt;br /&gt;
EVENT &amp;lt;my_device_id&amp;gt; &#039;\n&#039; &lt;br /&gt;
&lt;br /&gt;
&amp;lt;&amp;lt; The router will respond with : &lt;br /&gt;
OK &amp;lt;my_device_id&amp;gt; IP=&amp;lt;device_ip_address&amp;gt; &#039;\n&#039; &lt;br /&gt;
&lt;br /&gt;
&amp;gt;&amp;gt; To send a message, the device will send : &lt;br /&gt;
MESSAGE &amp;lt;size_of_binary_message&amp;gt; &#039;\n&#039; &lt;br /&gt;
&lt;br /&gt;
and then:&lt;br /&gt;
&amp;lt;serialized_binary_message&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===4.3 How to serialize data===&lt;br /&gt;
DCE uses SerializeClass to serialize/deserialize data. &lt;br /&gt;
The sources can be found here : src/SerializeClass/Serialize.h/cpp. &lt;br /&gt;
The deserialize the data, the deserializing module must know the way the data was serialized like this: &lt;br /&gt;
* 4 bytes, unsigned long&lt;br /&gt;
* 1 byte, unsigned char &lt;br /&gt;
&lt;br /&gt;
Primitives: &lt;br /&gt;
* 8 bytes, unsigned int64 &lt;br /&gt;
* 8 bytes, int64 &lt;br /&gt;
* 4 bytes, unsigned long &lt;br /&gt;
* 4 bytes, unsigned short &lt;br /&gt;
* 1 byte, unsigned char &lt;br /&gt;
* 1 byte, char &lt;br /&gt;
* 4 byte, long &lt;br /&gt;
* 4 bytes, float &lt;br /&gt;
* 8 bytes, double &lt;br /&gt;
* 2 bytes, short&lt;br /&gt;
&lt;br /&gt;
Complex types: &lt;br /&gt;
&lt;br /&gt;
#string &lt;br /&gt;
#*STR_LENGTH bytes, the array with chars &lt;br /&gt;
#*1 byte, &#039;/0&#039; (value 0x00) &lt;br /&gt;
#:&lt;br /&gt;
#block of data &lt;br /&gt;
#*BLOCK_LENGTH bytes, the array with bytes &lt;br /&gt;
#:&lt;br /&gt;
#vector of strings &lt;br /&gt;
#*VECT_LENGTH bytes, the number of strings from vector &lt;br /&gt;
#*string 0 &lt;br /&gt;
#*string 1 &lt;br /&gt;
#*... &lt;br /&gt;
#*string VECT_LENGTH - 1 &lt;br /&gt;
&lt;br /&gt;
Other complex types serialized (see SerializeClass.cpp for details) : &lt;br /&gt;
* map&amp;lt;int,string&amp;gt; &lt;br /&gt;
* map&amp;lt;u_int64_t,string&amp;gt; &lt;br /&gt;
* map&amp;lt;int,int&amp;gt; &lt;br /&gt;
* map&amp;lt;string,string&amp;gt; &lt;br /&gt;
* vector&amp;lt;int&amp;gt; &lt;br /&gt;
* vector&amp;lt; pair&amp;lt;int,int&amp;gt; &amp;gt; &lt;br /&gt;
* map&amp;lt;string, pair&amp;lt;int,int&amp;gt; &amp;gt; &lt;br /&gt;
&lt;br /&gt;
SerializeClass also allowed you to serialize/deserialize custom objects. Examples: &lt;br /&gt;
* PlutoColor &lt;br /&gt;
* PlutoPoint &lt;br /&gt;
* PlutoSize &lt;br /&gt;
* PlutoRectangle &lt;br /&gt;
* PlutoDataBlock&lt;br /&gt;
&lt;br /&gt;
===4.4 How to serialize a message===&lt;br /&gt;
&lt;br /&gt;
The class used by DCE is Message class from src/DCE/Message.h/cpp unit. &lt;br /&gt;
&lt;br /&gt;
This is how the raw data looks like into a binary message: &lt;br /&gt;
&lt;br /&gt;
* long, value must be 1234 (magic number) &lt;br /&gt;
* long, &amp;lt;device_from_id&amp;gt; &lt;br /&gt;
* long, &amp;lt;device_to_id&amp;gt; &lt;br /&gt;
* long, &amp;lt;device_group_to_id&amp;gt; &lt;br /&gt;
* long, &amp;lt;message_id&amp;gt; &lt;br /&gt;
* long, &amp;lt;message_priority&amp;gt; &lt;br /&gt;
* long, &amp;lt;message_type&amp;gt; &lt;br /&gt;
* long, &amp;lt;device_category_to&amp;gt; &lt;br /&gt;
* long, &amp;lt;device_template_to&amp;gt; &lt;br /&gt;
* unsigned char, &amp;lt;include_children&amp;gt; &lt;br /&gt;
* long, &amp;lt;message_broadcast_level&amp;gt; &lt;br /&gt;
* long, &amp;lt;message_retry&amp;gt; &lt;br /&gt;
* unsigned char, &amp;lt;relative_to_sender&amp;gt; &lt;br /&gt;
* long, &amp;lt;expected_response&amp;gt; &lt;br /&gt;
* string, &amp;lt;device_list_to&amp;gt; &lt;br /&gt;
* unsigned long, &amp;lt;number_of_string_parameters&amp;gt; &lt;br /&gt;
**	foreach &amp;lt;string_parameter&amp;gt; &lt;br /&gt;
***	long, &amp;lt;string_parameter_id&amp;gt; &lt;br /&gt;
***     string, &amp;lt;string_parameter_value&amp;gt; &lt;br /&gt;
**	end_foreach &lt;br /&gt;
* unsigned long, &amp;lt;number_of_data_parameters&amp;gt; &lt;br /&gt;
**	foreach &amp;lt;data_parameter&amp;gt; &lt;br /&gt;
***	long, &amp;lt;data_parameter_id&amp;gt; &lt;br /&gt;
***	unsigned long, &amp;lt;data_parameter_length&amp;gt; &lt;br /&gt;
***	array of bytes, &amp;lt;data_parameter_value&amp;gt; &lt;br /&gt;
**      end_foreach &lt;br /&gt;
* unsigned long, &amp;lt;number_of_extra_messages&amp;gt; &lt;br /&gt;
**	foreach &amp;lt;extra_message&amp;gt; &lt;br /&gt;
***	unsigned long, &amp;lt;serialized_extra_message_length&amp;gt; &lt;br /&gt;
***	array of bytes, &amp;lt;serialized_extra_message_value&amp;gt; &lt;br /&gt;
**	end_foreach &lt;br /&gt;
* unsigned long, must be 6789 &lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Enums:&#039;&#039;&#039; &lt;br /&gt;
* enum eBroadcastLevel { BL_None=0, BL_DirectSiblings=1, BL_SameComputer=2, BL_SameRoom=3, BL_SameHouse=4, BL_AllHouses=5 }; &lt;br /&gt;
* enum eRetry { MR_None=0, MR_Retry=1, MR_Persist=2 }; &lt;br /&gt;
* enum eExpectedResponse { ER_None=0, ER_ReplyMessage, ER_ReplyString, ER_DeliveryConfirmation }; &lt;br /&gt;
* message types: enum { MESSAGETYPE_COMMAND=1, MESSAGETYPE_EVENT=2, MESSAGETYPE_DATAPARM_CHANGE=3, MESSAGETYPE_REPLY=4, MESSAGETYPE_DATAPARM_REQUEST=5, MESSAGETYPE_LOG=6, MESSAGETYPE_SYSCOMMAND=7, MESSAGETYPE_REGISTER_INTERCEPTOR=8, MESSAGETYPE_MESSAGE_INTERCEPTED=9, MESSAGETYPE_EXEC_COMMAND_GROUP=10, MESSAGETYPE_START_PING=11, MESSAGETYPE_STOP_PING=12, MESSAGETYPE_PURGE_INTERCEPTORS=13, MESSAGETYPE_PENDING_TASKS=14 }; &lt;br /&gt;
* message priority : enum { PRIORITY_LOW=0, PRIORITY_NORMAL=1, PRIORITY_HIGH=2, PRIORITY_URGENT=3 }; &lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Important notes:&#039;&#039;&#039; &lt;br /&gt;
* when sending to device template, set &amp;lt;device_template_to&amp;gt; to desired device template and also &amp;lt;device_to_id&amp;gt; to -2000 (DEVICEID_MASTERDEVICE) &lt;br /&gt;
* when sending to device category, set &amp;lt;device_category_to&amp;gt; to desired device category and also &amp;lt;device_to_id&amp;gt; to -2001 (DEVICEID_CATEGORY) &lt;br /&gt;
* when sending to a list with devices, set &amp;lt;device_list_to&amp;gt; to comma delimited list with devices and also &amp;lt;device_to_id&amp;gt; to -2002 (DEVICEID_LIST). &lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Example:&#039;&#039;&#039; &lt;br /&gt;
Here is the pseudocode to send the &amp;quot;on&amp;quot; command to a light switch. &lt;br /&gt;
We&#039;ll assume that the your device has #id 250 and the light switch has device #id 100 &lt;br /&gt;
&lt;br /&gt;
*MyDevice.Connect(router_ip, 3450 /*port*/)&lt;br /&gt;
*MyDevice.SendData(&amp;quot;EVENT 250\n&amp;quot;) &lt;br /&gt;
*MyDevice.ReceiveData() //until you&#039;ll get a &#039;\n&#039; ; you should receive: &amp;quot;OK 250 IP=&amp;lt;device_ip_address&amp;gt; &#039;\n&#039;; &lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;next: creating a message&#039;&#039;&#039; &lt;br /&gt;
let&#039;s say MyData is an array of bytes &lt;br /&gt;
*SerializeLong(MyData, 1234) //magic number &lt;br /&gt;
*SerializeLong(MyData, 250) //my id &lt;br /&gt;
*SerializeLong(MyData, 100) //the light switch &lt;br /&gt;
*SerializeLong(MyData, 0) //not used now &lt;br /&gt;
*SerializeLong(MyData, 192) //message id of command &#039;on&#039; &lt;br /&gt;
*SerializeLong(MyData, 1) //normal priority &lt;br /&gt;
*SerializeLong(MyData, 1) //message type : command &lt;br /&gt;
*SerializeLong(MyData, 0) //not used now &lt;br /&gt;
*SerializeLong(MyData, 0) //not used now &lt;br /&gt;
*SerializeUnsignedChar(MyData, 0) //not including children &lt;br /&gt;
*SerializeLong(MyData, 0) //broadcast level : none &lt;br /&gt;
*SerializeLong(MyData, 0) //don&#039;t retry &lt;br /&gt;
*SerializeUnsignedChar(MyData, 0) //relative to sender false &lt;br /&gt;
*SerializeLong(MyData, 3) //delivery confirmation &lt;br /&gt;
*SerializeString(MyData, &amp;quot;&amp;quot;) //device list to empty &lt;br /&gt;
*SerializeUnsignedLong(MyData, 2) //2 parameters &lt;br /&gt;
*SerializeLong(MyData, 98) //parameter type #98 &lt;br /&gt;
*SerializeString(MyData, &amp;quot;&amp;quot;) //empty value &lt;br /&gt;
*SerializeLong(MyData, 97) //parameter type #97 &lt;br /&gt;
*SerializeString(MyData, &amp;quot;&amp;quot;) //empty value &lt;br /&gt;
*SerializeUnsignedLong(MyData, 0) //no binary parameters &lt;br /&gt;
*SerializeUnsignedLong(MyData, 0) //no extra messages &lt;br /&gt;
*SerializeUnsignedLong(6789) //magic number &lt;br /&gt;
&lt;br /&gt;
*MyDevice.SendData(&amp;quot;MESSAGE &amp;quot; + MyData.length() + &#039;\n&#039;) &lt;br /&gt;
*MyDevice.SendData(MyData) &lt;br /&gt;
*MyDevice.ReceiveData() //until you&#039;ll get a &#039;\n&#039; ; you should receive: &amp;quot;OK&amp;quot; or an error message &lt;br /&gt;
&lt;br /&gt;
*MyDevice.CloseConnection();&lt;br /&gt;
&lt;br /&gt;
===4.5 How to serialize data-grids ===&lt;br /&gt;
&#039;&#039;&#039;Complex objects:&#039;&#039;&#039; &lt;br /&gt;
# DataGridCellSerializableData &lt;br /&gt;
#* unsigned long, &amp;lt;sizeof(DataGridCellSerializableData)&amp;gt; &lt;br /&gt;
#* unsigned long, &amp;lt;graphic_length&amp;gt; &lt;br /&gt;
#* unsigned long, &amp;lt;message_length&amp;gt; &lt;br /&gt;
#* unsigned long, &amp;lt;text_length&amp;gt; &lt;br /&gt;
#* unsigned long, &amp;lt;value_length&amp;gt; &lt;br /&gt;
#* unsigned long, &amp;lt;image_path_length&amp;gt; &lt;br /&gt;
#* unsigned long, &amp;lt;number_of_attributes_length&amp;gt; &lt;br /&gt;
#* unsigned long, &amp;lt;attributes_length&amp;gt; &lt;br /&gt;
#* int, &amp;lt;alternate_color&amp;gt; &lt;br /&gt;
#* unsigned long, &amp;lt;graphic_format&amp;gt; &lt;br /&gt;
#* unsigned char, &amp;lt;selectable&amp;gt; &lt;br /&gt;
#* int, &amp;lt;style_detail&amp;gt; &lt;br /&gt;
#* int, &amp;lt;col_span&amp;gt; &lt;br /&gt;
#* int, &amp;lt;row_span&amp;gt; &lt;br /&gt;
#* unsigned char, &amp;lt;dont_fire_grid_event&amp;gt; &lt;br /&gt;
#:&lt;br /&gt;
#:Enums: &lt;br /&gt;
#* enum eGraphicFormat { GR_UNKNOWN=0, GR_JPG=1, GR_GIF=2, GR_TIF=3, GR_PNG=4, GR_MNG=5, GR_BMP=6, GR_OCG=7, GR_PFG=8 }; &lt;br /&gt;
#:&lt;br /&gt;
# DataGridCell &lt;br /&gt;
#* DataGridCellSerializableData, &amp;lt;datagrid_cell_serializable_data&amp;gt; &lt;br /&gt;
#* array of chars, &amp;lt;text&amp;gt; &lt;br /&gt;
#* array of chars, &amp;lt;value&amp;gt; &lt;br /&gt;
#* array of bytes, &amp;lt;graphic_data&amp;gt; &lt;br /&gt;
#* array of bytes, &amp;lt;message_data&amp;gt; &lt;br /&gt;
#* array of chars, &amp;lt;image_path&amp;gt; &lt;br /&gt;
#*:&lt;br /&gt;
#**	foreach &amp;lt;cell_attribute&amp;gt; &lt;br /&gt;
#***	array of chars ended with &#039;\0&#039; , &amp;lt;cell_attribute_name&amp;gt; &lt;br /&gt;
#***	array of chars ended with &#039;\0&#039;, &amp;lt;cell_attribute_value&amp;gt; &lt;br /&gt;
#**	end_foreach &lt;br /&gt;
#:&lt;br /&gt;
#DataGridTableSerializableData &lt;br /&gt;
#* int, &amp;lt;total_number_of_columns&amp;gt; &lt;br /&gt;
#* int, &amp;lt;total_number_of_rows&amp;gt; &lt;br /&gt;
#* unsigned char, &amp;lt;keep_row_header&amp;gt; &lt;br /&gt;
#* unsigned char, &amp;lt;keep_column_header&amp;gt; &lt;br /&gt;
#* int, &amp;lt;column_count&amp;gt; &lt;br /&gt;
#* int, &amp;lt;row_count&amp;gt; &lt;br /&gt;
#* int, &amp;lt;starting_column&amp;gt; &lt;br /&gt;
#* int, &amp;lt;starting_row&amp;gt; &lt;br /&gt;
#* int, &amp;lt;cell_count&amp;gt; &lt;br /&gt;
#:&lt;br /&gt;
#DataGridTableCellIndex &lt;br /&gt;
#* unsigned int, &amp;lt;column_row_type&amp;gt; &lt;br /&gt;
#* unsigned int, &amp;lt;size&amp;gt; &lt;br /&gt;
#:&lt;br /&gt;
#DataGridTable &lt;br /&gt;
#* unsigned long, &amp;lt;sizeof(DataGridTableSerializableData)&amp;gt; &lt;br /&gt;
#* array of DataGridTableCellIndex, &amp;lt;col * row * sizeof(DataGridTableCellIndex)&amp;gt; &lt;br /&gt;
#* array of DataGridCell, &amp;lt;col * row * serialized DataGridCell&amp;gt; &lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
Additional step: lzo compression/decompression &lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; can be disabled if compiled with DISABLE_LZO_DATAGRID &lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
==5. The devices==&lt;br /&gt;
&lt;br /&gt;
Each device has associated an interface, which we call device template. A device template is a set of commands to be implemented, events which can be fired by the device and device data (persistent information for device).&lt;br /&gt;
To create device templates and modify them, go to LinuxMCE Web Admin -&amp;gt; Advanced -&amp;gt; Configuration -&amp;gt; Device Templates.&lt;br /&gt;
To generate the C++ code for the device implementing a device template interface, you must use DCEGen tool, specifying the database ip address and the device template number.&lt;br /&gt;
Here is the simplified class diagram for one of the devices (App_Server):&lt;br /&gt;
&lt;br /&gt;
[[Image:App_Server.jpg|frame|none|Simplified class diagram for a DCE device]]&lt;br /&gt;
&lt;br /&gt;
The classes App_Server_Event, App_Server_Command and App_Server_Data are generated using DCEGen tool. The base classes for them are implemented in DCE Library.&lt;br /&gt;
&lt;br /&gt;
==6. App_Server device==&lt;br /&gt;
&lt;br /&gt;
App_Server device is present by default on all LinuxMCE machines. It spawns/kills applications, handles volume of sound on that machine, restarts/halts the device.&lt;br /&gt;
&lt;br /&gt;
# Implemented commands:&lt;br /&gt;
#*CMD_Spawn_Application - Spawns an application&lt;br /&gt;
#*CMD_Kill_Application - Kills an application&lt;br /&gt;
#*CMD_Application_Is_Running - Checks if the given application is running.&lt;br /&gt;
#*CMD_Halt_Device - Halts or reboots this device&lt;br /&gt;
#*CMD_Vol_Up - Increases the volume 1%&lt;br /&gt;
#*CMD_Vol_Down - Decreases the volume 1%&lt;br /&gt;
#*CMD_Set_Volume - Sets the volume to a specific level between 0-100&lt;br /&gt;
#*CMD_Mute - Toggles mute/unmute&lt;br /&gt;
#: &lt;br /&gt;
#: &lt;br /&gt;
#It doesn’t fire any events.&lt;br /&gt;
#: &lt;br /&gt;
#: &lt;br /&gt;
#It has the following device data:&lt;br /&gt;
#*Discrete Volume&lt;br /&gt;
#*Volume Level&lt;br /&gt;
&lt;br /&gt;
==7. Photo_Screen_Saver device==&lt;br /&gt;
&lt;br /&gt;
The photo screen saver (PSS) displays pictures when there is no video playing, even if you just happen to be listening to music. By default, the photos come from Flickr and are downloaded regularly to local drive.&lt;br /&gt;
&lt;br /&gt;
PSS is a OpenGL application and it slides pictures and fades them between transitions. &lt;br /&gt;
&lt;br /&gt;
1. Implemented commands&lt;br /&gt;
&lt;br /&gt;
The list with pictures is taken by sending a command to Orbiter Plugin : CMD_Get_Screen_Saver_Files which has an output parameter Filename. The filenames are delimited by a ‘\n’ character.&lt;br /&gt;
&lt;br /&gt;
The PSS animations are started/stopped using CMD_On/CMD_Off commands. To force PSS reload the list with pictures from Orbiter Plugin, CMD_Reload is used.&lt;br /&gt;
&lt;br /&gt;
When PSS starts, it should check every 10 minutes if there are any pictures downloaded and ready to be displayed. If there are pictures to display it should display them on CMD_On command and refresh the list with pictures every 24 hours.&lt;br /&gt;
&lt;br /&gt;
2. It doesn’t fire any events&lt;br /&gt;
&lt;br /&gt;
3. Device data:&lt;br /&gt;
* ZoomTime - Value in miliseconds that a zoom effect will take &lt;br /&gt;
* FadeTime - value in miliseconds that a fade effect will take &lt;br /&gt;
* Name - The window name to activate&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==8. Media Player device==&lt;br /&gt;
&lt;br /&gt;
Currently there are two Media Players in LinuxMCE, the primary Xine_Player and &lt;br /&gt;
secondary MPlayer_Player.&lt;br /&gt;
First one is based one the Xine engine (http://xinehq.de) and supports the &lt;br /&gt;
following formats:&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;File formats (System layer / media types)supported:&#039;&#039;&#039;&lt;br /&gt;
**direct DVD playback (of unlocked/unencrypted DVDs, see below)&lt;br /&gt;
** Video CD&lt;br /&gt;
** Audio CD&lt;br /&gt;
** mpeg program streams (.mpg, .mpeg)&lt;br /&gt;
** mpeg transport streams (.ts)&lt;br /&gt;
** ogg (.ogg, .ogm)&lt;br /&gt;
** avi (.avi)&lt;br /&gt;
** asf (.asf, .wmv, .wma)&lt;br /&gt;
** quicktime (.mov, .mp4)&lt;br /&gt;
** mpeg-video (.mpv, .m2v)&lt;br /&gt;
** mpeg-audio (.mp2, .mp3)&lt;br /&gt;
** Sega Saturn FILM (.cpk)&lt;br /&gt;
** Id Software RoQ (.roq)&lt;br /&gt;
** wav (.wav)&lt;br /&gt;
** Autodesk FLIC (.fli)&lt;br /&gt;
** real (.rm, .ra, .ram)&lt;br /&gt;
** raw dv (.dv)&lt;br /&gt;
** network graphics format (.png, .mng)&lt;br /&gt;
** Creative Voice (.voc)&lt;br /&gt;
** Sun/NeXT SND/AU (.snd, .au)&lt;br /&gt;
** Wing Commander III (.mve)&lt;br /&gt;
** Westwood Studios files (.vqa, .aud)&lt;br /&gt;
** Electronic Arts WVE (.wve)&lt;br /&gt;
** AIFF (.aif, .aiff)&lt;br /&gt;
** YUV4MPEG2 (.y4m)&lt;br /&gt;
** SMJPEG (.mjpg)&lt;br /&gt;
** raw AC3 (.ac3)&lt;br /&gt;
** Dialogic VOX (.vox)&lt;br /&gt;
** TechnoTrend PVA (.pva)&lt;br /&gt;
** Playstation STR (.str)&lt;br /&gt;
** Nullsoft Video (.nsv)&lt;br /&gt;
** 4X Technologies (.4xm)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Video codecs supported:&#039;&#039;&#039;&lt;br /&gt;
** mpeg 1/2&lt;br /&gt;
** mpeg 4 (aka OpenDivX)&lt;br /&gt;
** ms mpeg 4&lt;br /&gt;
** divx 3/4/5&lt;br /&gt;
** windows media video 7 &amp;amp; 8&lt;br /&gt;
** motion jpeg&lt;br /&gt;
** Cinepak&lt;br /&gt;
** DV&lt;br /&gt;
** ms video 1 (msvc)&lt;br /&gt;
** ms rle&lt;br /&gt;
** Sorenson SVQ1/SVQ3 (often used in Quicktime trailers)&lt;br /&gt;
** creative yuv (cyuv)&lt;br /&gt;
** roq video&lt;br /&gt;
** QT RLE, SMC, RPZA&lt;br /&gt;
** theora&lt;br /&gt;
** via external binary/win32 codecs (not included in xine):&lt;br /&gt;
** Indeo 3.1-5.0&lt;br /&gt;
** Window Media Video 8,9&lt;br /&gt;
** On2 VP3.1&lt;br /&gt;
** I263&lt;br /&gt;
** Real Media 2.0, 3.0, 4.0&lt;br /&gt;
* currently unsupported/untested Formats:&lt;br /&gt;
** 3ivx&lt;br /&gt;
** h263 (aka Real Video 1.0)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Audio codecs&#039;&#039;&#039;&lt;br /&gt;
** mpeg audio (layer 1,2,3)&lt;br /&gt;
** a/52 (aka ac3, dolby digital)&lt;br /&gt;
** aac (used in .mp4 files)&lt;br /&gt;
** dts (via external decoder)&lt;br /&gt;
** vorbis&lt;br /&gt;
** pcm&lt;br /&gt;
** adpcm (MS/IMA/DVI/Dialogic)&lt;br /&gt;
** mu-law and A-law&lt;br /&gt;
** roq dpcm&lt;br /&gt;
** Real Media dnet audio&lt;br /&gt;
** Real Media 28.8 audio&lt;br /&gt;
** DivX audio (WMA)&lt;br /&gt;
** GSM 6.10&lt;br /&gt;
** FLAC&lt;br /&gt;
** NSF (NES sound format)&lt;br /&gt;
** Speex&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The MPlayer_Player is used as the fallback player for the formats Xine doesn&#039;t &lt;br /&gt;
support/supports not well and currently is used for playing HD-DVD/Bluray &lt;br /&gt;
video files and disks.&lt;br /&gt;
&lt;br /&gt;
A media player device plays all kind of media: audio and video, stored media or from cd/dvd/hd/bluray drivers, etc.&lt;br /&gt;
&lt;br /&gt;
1. Implemented commands&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Keyboard input:&#039;&#039;&#039; &lt;br /&gt;
** CMD_EnterGo - Select the currently highlighted menu item&lt;br /&gt;
** CMD_Move_Up, CMD_Move_Down, CMD_Move_Left, CMD_Move_Right - Move the highlighter&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Media Player Commands&#039;&#039;&#039;&lt;br /&gt;
** CMD_Pause - Pause the media&lt;br /&gt;
** CMD_Play - Play the media&lt;br /&gt;
** CMD_Skip_Back_ChannelTrack_Lower - Lower the channel, track, station, etc. by 1.  Same as Jump to Pos in Playlist with value -1 for a smart media player&lt;br /&gt;
** CMD_Skip_Fwd_ChannelTrack_Greater - Raise  the channel, track, station, etc. by 1.  Same as Jump to Pos in Playlist with value +1 for a smart media player&lt;br /&gt;
** CMD_Stop - Stop the media&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Menu Navigation&#039;&#039;&#039;&lt;br /&gt;
** CMD_EnterGo - Select the currently highlighted menu item&lt;br /&gt;
** CMD_Move_Up, CMD_Move_Down, CMD_Move_Left, CMD_Move_Right - Move the highlighter&lt;br /&gt;
** CMD_Get_Video_Frame - Gets the current video frame from the media player.&lt;br /&gt;
** CMD_Goto_Media_Menu - Goto to the current media Root Menu.&lt;br /&gt;
** CMD_Navigate_Next - Nagivate to the next possible navigable area. (The actual outcome depends on the specifc device)&lt;br /&gt;
** CMD_Navigate_Prev - Nagivate the previous possible navigable area. (The actual outcome depends on the specific device).&lt;br /&gt;
** CMD_Simulate_Mouse_Click - Simlate a mouse click at a certain position on the screen&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;Smart DVD commands&#039;&#039;&#039;&lt;br /&gt;
** CMD_Angle – Go to an angle&lt;br /&gt;
** CMD_Audio_Track – Go to an audio track&lt;br /&gt;
** Subtitle – Go to a subtitle&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Smart Media Player&#039;&#039;&#039;&lt;br /&gt;
** CMD_Change_Playback_Speed – Will make the playback to FF with a configurable amount of speed.&lt;br /&gt;
** CMD_Guide - Show guide information.  For a dvd this may be the menu, just like the menu command&lt;br /&gt;
** CMD_Jump_Position_In_Playlist - Jump to a specific position in the playlist, or a track, or a chapter.  Smart media players should also understand the skip fwd/skip back (which non-DCE media players use) to be the same thing as a jump +1 or -1&lt;br /&gt;
** CMD_Jump_To_Position_In_Stream - Jump to a position in the stream, specified in seconds.&lt;br /&gt;
** CMD_Menu - Show a menu associated with this media&lt;br /&gt;
** CMD_Pause_Media - This will stop a media that is currently played. This method should be paired with the &amp;quot;Restart Media&amp;quot; and used when the playback will be stopped and restarted on the same display device.&lt;br /&gt;
** CMD_Play_Media - This command will instruct a Media Player to play a media stream identified by a media descriptor created by the &amp;quot;Create Media&amp;quot; command.&lt;br /&gt;
** CMD_Report_Playback_Position - This will report the playback position of the current stream.&lt;br /&gt;
** CMD_Restart_Media - This will restart a media was paused with the above command&lt;br /&gt;
** CMD_Set_Aspect_Ratio - Force aspect ratio&lt;br /&gt;
** CMD_Set_Media_ID - Set Media ID - information about media stream&lt;br /&gt;
** CMD_Set_Media_Position - Jump to a certain media position&lt;br /&gt;
** CMD_SetZoom - Sets zoom level, relative, absolute or &#039;auto&#039;&lt;br /&gt;
** CMD_Simulate_Keypress - Send a key to the device&#039;s OSD, or simulate keypresses on the device&#039;s panel&lt;br /&gt;
** CMD_Start_Streaming - Like play media, but it means the destination device is not the same as the source&lt;br /&gt;
** CMD_Stop_Media - This will instruct the media player to stop the playback of a media started with the &amp;quot;Play Media&amp;quot; Command&lt;br /&gt;
** CMD_Update_Object_Image - Display an image on the media player&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
2. &#039;&#039;&#039;It fires the following events&#039;&#039;&#039;&lt;br /&gt;
* EVENT_Menu_Onscreen - A DVD Menu appeared on screen&lt;br /&gt;
* EVENT_Playblack_Completed - Fired when the playback of a stream has completed.&lt;br /&gt;
* EVENT_Playback_Info_Changed – Playback info changed&lt;br /&gt;
* EVENT_Playback_Started – Media has start playing&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
3. &#039;&#039;&#039;Device data:&#039;&#039;&#039;&lt;br /&gt;
* Name - The name of the window for this app&lt;br /&gt;
* Hardware acceleration - driver used&lt;br /&gt;
* Deinterlacing Mode - Movie deinterlacing filter status&lt;br /&gt;
* Port – Time code notification every second&lt;br /&gt;
* Zoom Level – default zoom level&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;NOTE:&#039;&#039;&#039; A deviation from design, the media player must bind on a port specified in the device data and report the time code every one second. Any device like an Orbiter could connect to that port and read the time code. Here is the format used for time code:&lt;br /&gt;
Speed,CurrentTime,TotalTime,StreamID,Title,Chapter,MediaType,MediaID,Filename (comma delimited).&lt;br /&gt;
&lt;br /&gt;
==9. Orbiter==&lt;br /&gt;
&lt;br /&gt;
===9.1 Introduction===&lt;br /&gt;
&lt;br /&gt;
The Orbiter is really a device just like any other. The main class, Orbiter, is a normal DCE command implementation. However, the Orbiter class was written so that it has no platform-specific functions, such as graphics and sound. It handles the basic logic, and calls pure virtual functions that derived classes must implement to handle the platform-specific commands. Most of the code and virtually all of the logic is contained in the base classes. Therefore, it is a fairly easy task to make a new version of Orbiter for a platform other than SDL, perhaps one that uses Windows SDK calls, or another image library.&lt;br /&gt;
&lt;br /&gt;
Right now there are implementations of Orbiter using SDL. PocketFrog and OpenGL engines. Orbiter runs on different operation systems like Linux, Windows, Windows CE, Window Mobile, Symbian60. There also implementation for web orbiter (running into a browser) or for a Cisco hard phones (using XML services).&lt;br /&gt;
&lt;br /&gt;
===9.2 Architecture===&lt;br /&gt;
&lt;br /&gt;
[[Image:architecture.jpg|frame|none|Orbiter application architecture]]&lt;br /&gt;
&lt;br /&gt;
The present diagram shows how the Orbiter application architecture looks like. Depending on the Graphic Engine and the platform, the only modules dependent on them are “Renderers – engine specific” and “Orbiter - platform specific”. &lt;br /&gt;
&lt;br /&gt;
====9.2.1. The renderers====&lt;br /&gt;
&lt;br /&gt;
There are two kinds of renders:&lt;br /&gt;
* orbiter renderers&lt;br /&gt;
* object renderers&lt;br /&gt;
&lt;br /&gt;
The orbiter renderers (derived from OrbiterRenderer class) handle the graphic primitives, having pure virtual methods for operations like this:&lt;br /&gt;
* RenderText&lt;br /&gt;
* SolidRectangle&lt;br /&gt;
* HollowRectangle&lt;br /&gt;
* DrawLine&lt;br /&gt;
* FloodFill&lt;br /&gt;
* RenderGraphic&lt;br /&gt;
* ReplaceColorInRectangle&lt;br /&gt;
* etc.&lt;br /&gt;
&lt;br /&gt;
and applications flow :&lt;br /&gt;
* event loop&lt;br /&gt;
* configure&lt;br /&gt;
* destroy&lt;br /&gt;
* on quit&lt;br /&gt;
* on reload&lt;br /&gt;
&lt;br /&gt;
However, OrbiterRenderer is not an interface. It also has implemented the logic needed for: &lt;br /&gt;
* render screen action&lt;br /&gt;
* show a progress bar&lt;br /&gt;
* highlighting / un-highlighting objects&lt;br /&gt;
* render shortcuts&lt;br /&gt;
* show / hide popup’s&lt;br /&gt;
* redraw objects&lt;br /&gt;
* refresh screen&lt;br /&gt;
* render object asynchronously&lt;br /&gt;
* object on screen / off screen actions&lt;br /&gt;
* background image loading&lt;br /&gt;
* drawing an arrow&lt;br /&gt;
&lt;br /&gt;
Here is the class diagram for derived OrbiterRenderer‘s:&lt;br /&gt;
&lt;br /&gt;
[[Image:orbiterrenderer.jpg|frame|none|OrbiterRenderer class diagram]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Also, there are renderer classes of complex objects like button, data grid, edit box, etc. The base classes for them are : ObjectRenderer, DataGridRenderer. Each renderer is attached to an object like DesignObj_Orbiter, DesignObj_DataGrid. &lt;br /&gt;
&lt;br /&gt;
Here is the class diagram for OpenGL implementation:&lt;br /&gt;
&lt;br /&gt;
[[Image:openGLimplementation.jpg|frame|none|OpenGL implementation]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The screens are actually trees of objects. The characteristics of the objects are set using the Designer application and stored in the database, then serialized by OrbiterGen and then deserialized by Orbiter. &lt;br /&gt;
OrbiterGen scales and pre-renders the screens. Also, OrbiterGen embeds in the serialized data info about the actions to be executed when an object is loaded, activated, unloaded, etc.&lt;br /&gt;
&lt;br /&gt;
====9.2.2. Orbiter – platform specific====&lt;br /&gt;
&lt;br /&gt;
Orbiter also has to take care of the input events like mouse click, keyboard events, etc. For example, Orbiter_Win32 is derived from Orbiter class and takes care of enabling the auto-update mechanism. &lt;br /&gt;
Platform specific are the external dialogs with progress bar and prompt user, or the way the composite or masks are used (see OrbiterRenderer_Linux, OrbiterLinux, OrbiterRenderer_SDL_Win32&lt;br /&gt;
&lt;br /&gt;
The Linux version uses XRecord extension to intercept events. The Windows versions use PocketFrog engine’s event loop or SDL event loop.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
====9.2.3. Cache image manager====&lt;br /&gt;
&lt;br /&gt;
This module is mainly used by remote orbiters, non-OSD orbiters. Because these orbiters don’t have access to core’s file system, all the graphic files are obtained by network connection and it might be slow. So instead of requesting same image over and over, the image is cached on the local drivers. The collection of images cached are associated with a timestamp (the generation date for the screens). If the user decides to regenerate the screens, the timestamp is changed and the cache is purged and the images are requested, on demand, again from the server.&lt;br /&gt;
&lt;br /&gt;
====9.2.4. Self update module====&lt;br /&gt;
&lt;br /&gt;
The “Self update” module is also used for non-OSD orbiters. Once a new version of the Orbiter XP/CE is available, a new binary data is stored on core’s filesystem. When an non-OSD orbiter starts, compares the md5sum of the current binary with the one from the server. If it’s different, the UpdateBinary is spawned, Orbiter exits and UpdateBinary requests the new binary from server, it downloads it, replaces the old binary and restart Orbiter.&lt;br /&gt;
&lt;br /&gt;
====9.2.5. Simulator====&lt;br /&gt;
&lt;br /&gt;
The simulator is responsible for generating mouse and keyboard events used for stress testing. It also stores some configuration settings.&lt;br /&gt;
&lt;br /&gt;
====9.2.6. Graphic objects====&lt;br /&gt;
&lt;br /&gt;
They are all derived from PlutoGraphic class and store info about the filename, width, height, the block of data and its length, graphic format and graphic management. The operations required are related to loading graphics from a file or a block of data, clearing the data stored, initializations, etc.&lt;br /&gt;
In the derived classes like PocketFrogGraphic, SDLGraphic, OpenGLGraphic, specific info are stored like the Surface for PocketFrong, SDL_Surface for SDL and the texture for OpenGL.&lt;br /&gt;
&lt;br /&gt;
====9.2.7. Orbiter logic module====&lt;br /&gt;
&lt;br /&gt;
Just like any other device, Orbiter is derived from a {Device_name}_Command class, the wrapper class generated by DCEGen to allow the device communicate with the router. However, Orbiter is also derived from OrbiterData and IRReceiverBase.&lt;br /&gt;
&lt;br /&gt;
[[Image:orbiterlogicclassdiagram.jpg|frame|none|Orbiter logic – class diagram]]&lt;br /&gt;
&lt;br /&gt;
 &lt;br /&gt;
OrbiterData helps Orbiter deserialize the data needed for its graphic objects, data serialized by OrbiterGen. IRReceiverBase is the base class for all IR receiver devices and it translates IR codes into actions, base on the current screen type and remote layout.&lt;br /&gt;
&lt;br /&gt;
====9.2.7. Mouse handlers====&lt;br /&gt;
&lt;br /&gt;
The goal of handlers is the interpret mouse movements and perform specific actions depending on current screen type. This is one of the main features add in UI2 version.&lt;br /&gt;
&lt;br /&gt;
See below the class diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image:mousehandlers.jpg|frame|none|Mouse handlers – class diagram]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Note that the mouse handlers are not available for UI1 version of Orbiter.&lt;br /&gt;
&lt;br /&gt;
MouseIterator and MouseGovernor limit the mouse movements the only one move per x ms to prevent extreme numbers of messages burdening the system.&lt;br /&gt;
MouseBehaviour handles special mouse behavior, such as locking axis’s, ramping and acceleration.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
====9.2.7. HID interface====&lt;br /&gt;
&lt;br /&gt;
This module gets events from the Gyration remote. See below the class diagram:&lt;br /&gt;
&lt;br /&gt;
[[Image:HIDinterface.jpg|frame|none|HID interface – class diagram]]&lt;br /&gt;
&lt;br /&gt;
===9.3 Skinning and User Interface===&lt;br /&gt;
&lt;br /&gt;
The graphics, layout and display for the screens rendered in different Orbiter interfaces for the different UI versions are generated and manipulated using a Windows UI management tool called HADesigner.&lt;br /&gt;
&lt;br /&gt;
The following series of screencasts describes the HADesigner tool and generates a brand new UI for a specific plugin for all different variations of the Orbiter UI versions.&lt;br /&gt;
&lt;br /&gt;
# [http://www.localeconcept.com/HADesigner-Screencasts/01-basic_hadesigner_fundamentals.html Basic Designer Fundamentals]&lt;br /&gt;
# [http://www.localeconcept.com/HADesigner-Screencasts/ogg/02_designobj_basics_1.ogg Design Object Basics]&lt;br /&gt;
# [http://www.localeconcept.com/HADesigner-Screencasts/ogg/03_ui2_popup_part_1.ogg UI2 Popup Part I]&lt;br /&gt;
# [http://www.localeconcept.com/HADesigner-Screencasts/ogg/04_ui2_popup_part_2.ogg UI2 Popup Part II]&lt;br /&gt;
# [http://www.localeconcept.com/HADesigner-Screencasts/ogg/05_UI1_Orbiter.ogg UI1 Orbiter]&lt;br /&gt;
# [http://www.localeconcept.com/HADesigner-Screencasts/ogg/06_UI1_Full_Screen_OSD.ogg UI1 Full Screen OSD]&lt;br /&gt;
# [http://www.localeconcept.com/HADesigner-Screencasts/ogg/07_UI1_Full_Screen_OSD_2.ogg UI1 Full Screen OSD Part II]&lt;br /&gt;
# [http://www.localeconcept.com/HADesigner-Screencasts/ogg/08_UI1_PDA.ogg UI1 PDA]&lt;br /&gt;
# [http://www.localeconcept.com/HADesigner-Screencasts/ogg/09_Mobile_Remote.ogg Mobile Remote]&lt;br /&gt;
# [http://www.localeconcept.com/HADesigner-Screencasts/ogg/10_cisco_7970_orbiter.ogg Cisco 7970 Orbiter]&lt;br /&gt;
# [http://www.localeconcept.com/HADesigner-Screencasts/ogg/11_Monitor_mode.ogg Monitor Mode]&lt;/div&gt;</summary>
		<author><name>Juanfe</name></author>
	</entry>
	<entry>
		<id>http://wiki.linuxmce.org/index.php?title=Usage_Intro&amp;diff=14832</id>
		<title>Usage Intro</title>
		<link rel="alternate" type="text/html" href="http://wiki.linuxmce.org/index.php?title=Usage_Intro&amp;diff=14832"/>
		<updated>2008-07-12T22:38:50Z</updated>

		<summary type="html">&lt;p&gt;Juanfe: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{| align=&amp;quot;right&amp;quot;&lt;br /&gt;
  | __TOC__&lt;br /&gt;
  |}&lt;br /&gt;
LinuxMCE&#039;s main concepts are [[Devices]], Commands (aka [[Scenarios]] and Activities), and [[Events]]. An  [[Orbiter]] is the device that displays the User Interface. It can be a [[Media Director|Media Station]], web pad, mobile phone, or other remote control device. The Orbiter User Interface is standardized for all Orbiters.&lt;br /&gt;
&lt;br /&gt;
== Devices ==&lt;br /&gt;
&lt;br /&gt;
A device is generally a piece of hardware or software, like the Xine Media Player, a light switch, or a mobile phone.  Devices have three functions, abbreviated &amp;quot;DCE&amp;quot; (Data, Commands, Events): &lt;br /&gt;
&lt;br /&gt;
# Retrieve configuration &#039;&#039;&#039;data&#039;&#039;&#039;&lt;br /&gt;
# Perform a &#039;&#039;&#039;command&#039;&#039;&#039; (turn on, turn off, fast forward, etc.)&lt;br /&gt;
# Report certain triggered &#039;&#039;&#039;events&#039;&#039;&#039; (e.g. &#039;motion detected&#039;, &#039;playback started&#039;, etc.)&lt;br /&gt;
&lt;br /&gt;
== Scenarios ==&lt;br /&gt;
&lt;br /&gt;
&amp;quot;[[Scenarios]]&amp;quot;, &amp;quot;Activities&amp;quot;, and &amp;quot;Command Groups&amp;quot; are interchangeable terms -- they mean the same thing.  A scenario is a group of commands that can be sent to a device (or series of devices).  In LinuxMCE, the default Orbiter main menu consists of several scenario categories, grouped by room. These categories are&lt;br /&gt;
&lt;br /&gt;
* Lighting&lt;br /&gt;
* Media&lt;br /&gt;
* Climate&lt;br /&gt;
* Telecom&lt;br /&gt;
* Security&lt;br /&gt;
&lt;br /&gt;
(These default categories are arbitrary and are set up at installation.) To perform an action in LinuxMCE, a scenario is chosen from one of these categories (located on the main menu of an Orbiter). &lt;br /&gt;
&lt;br /&gt;
For example, in rooms which have both a TV and lights, LinuxMCE automatically creates a scenario called &#039;Showtime.&#039; This scenario dims the lights to 10% whenever the TV starts playing.  In rooms with a PVR or other TV-enabled device, another scenario is created called &#039;TV&#039; (in the &#039;Media&#039; category) to start the TV.  Another scenario in the &#039;Media&#039; category called &#039;Video&#039; sends a command to the Orbiter to list your video content. Telecom scenarios are created to make phone calls. Security scenarios are created to view cameras and to arm an alarm.&lt;br /&gt;
&lt;br /&gt;
Some [[What_scenarios_are_created_automatically%3F|default scenarios]] are created for you at installation. A fully-functional system can run using only the default scenarios, if you choose. You can also change or remove the default scenarios or add new ones. This is done though the &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Wizard--&amp;gt;[[Scenarios]]&#039;&#039;&#039; menu. When creating a scenario, the [[LinuxMCE Admin Website]] will show you the most appropriate wizard, based on the category you pick.  If you&#039;re adding an activity in the lighting category, for example, the wizard will display a list of the lights in the room and let you pick which ones to turn off.  If you&#039;re creating a scenario in the security category, it will list the installed cameras and will allow you to select which ones to display.&lt;br /&gt;
&lt;br /&gt;
A scenario can send a command to any device in the system. By default, scenarios in the lighting category show you the room lights, allowing you to select which ones to which to send commands. However, from the &#039;&#039;&#039;Wizard--&amp;gt;[[Scenarios]]&#039;&#039;&#039; menu for the specific scenario, you can also specify a command to any device in your home. You could make a phone call, for example, even from a scenario in the lighting category.&lt;br /&gt;
&lt;br /&gt;
Certain scenarios are assigned to certain rooms by default. This can be customized, however. When you manually select a room from the Orbiter main menu, the default scenarios for that room are displayed. In general they control devices in that room, but this can also be changed. If your kitchen is near the garage and you want a scenario to &#039;turn off the garage light&#039;, you can assign a scenario to the room &#039;kitchen&#039; that will do just that. It doesn&#039;t matter that the light is in the garage.&lt;br /&gt;
&lt;br /&gt;
For a Media Director, the on-screen Orbiter User Interface appears on the TV screen. It is manipulated by the mouse/keyboard or remote control connected to your Media Director. By default it is set to display the scenarios for the room in which the Media Director is located.&lt;br /&gt;
&lt;br /&gt;
In contrast, a mobile Orbiter (such as a webpad) can be carried throughout the house. It must be able to select the scenarios for multiple rooms. Fortunately, the option to manually select which room you are currently in is available on every Orbiter&#039;s main menu.&lt;br /&gt;
&lt;br /&gt;
This can occasionally cause some confusion. Perhaps both the Living Room and the Bedroom have a scenario called &#039;TV&#039;. You may have a web pad that is in the Bedroom, but you then carry it to the Living Room. You may forget to tell the web pad that it&#039;s now in the Living Room (at the bottom of the Orbiter screen it will still say &#039;Bedroom&#039;). You hit the &#039;TV&#039; button expecting the Living Room TV to come on, but in fact you&#039;re still controlling the Bedroom and the TV comes on there instead. Finally you may realize that you must change your room location to Living Room, and you can then finally control the TV there.&lt;br /&gt;
&lt;br /&gt;
Once you get used to this concept, though, you&#039;ll find it very useful.  Conveniently, any Orbiter can be set to control any room and choose from the scenarios assigned to that room. No matter which Orbiter you use, the same set of scenarios will be displayed for each specific room. For example, the kitchen scenarios will always be the same, no matter which Orbiter you are using. (The scenarios are assigned by room -- not by Orbiter.) No matter whether you pick up your mobile phone, your web pad, or your remote control, you will always be shown the same list of scenario options for the Living Room.&lt;br /&gt;
&lt;br /&gt;
You have the option of preventing some family members from using certain scenarios. From the [[LinuxMCE Admin Website]], certain scenarios and rooms can be [[Users#Restrict_Access|restricted to certain users]].  Maybe little Suzy&#039;s mobile phone Orbiter should be restricted so that she is only able to control her room and the living room, for example. She would only be able to execute the scenarios in those rooms, but not the Master Bedroom. Other possible options include [[Users#Restrict_Access|requiring a pin code]] to access the scenarios for a particular room.&lt;br /&gt;
&lt;br /&gt;
== Events ==&lt;br /&gt;
&lt;br /&gt;
Devices report events, such as &#039;Playback started&#039; and &#039;Motion Sensor tripped&#039;. If you want something to happen automatically in LinuxMCE, you create Event Handlers that react to these events. For example, you can create an event handler that listens for the &#039;Motion Sensor tripped&#039; event from a motion detector and turns on the lights in response.  An event handler might listen for the &#039;Sunrise&#039; event, which could then prompt the sprinklers to come on. &lt;br /&gt;
&lt;br /&gt;
LinuxMCE creates several default event handlers. In rooms in which you have a TV and lights, an event handler is created that listens for the &#039;Watching Media&#039; event sent by a media player. When the event is detected, the Showtime scenario (which dims the lights) is executed in response.  When you start a movie, therefore, the Showtime activity will be executed and the lights will be dimmed.  There are other default event handlers that monitor for events like &#039;Security Breach&#039; and &#039;Fire Alarm&#039; (from a home security system).&lt;br /&gt;
&lt;br /&gt;
== Controlling an Orbiter ==&lt;br /&gt;
&lt;br /&gt;
To control the system, you use an [[Orbiter]], which is the LinuxMCE term for a remote control.  All [[Orbiters]] have the same basic function: to display the scenarios in the room you&#039;re in and let you select one.  The different Orbiters may [[Selecting_the_Right_UI|display the User Interface slightly differently]], depending on their screen size, but the function and the list of scenarios is always the same. For example, the [[Selecting_the_Right_UI|&amp;quot;UI1&amp;quot; interface]] (which is used on webpads and PDAs) displays the scenarios in horizontal rows. (If there are more than will fit on a row, there will be a &amp;quot;more&amp;quot; button.) A home button is always displayed that takes you to the main menu. On smaller displays, as on mobile phones or desktop phones, there&#039;s not enough room to show the scenarios themselves. The top level menu shows only the categories: Lights, Media, Climate, Security and Telecom. Selecting a category displays the scenarios in that category. &lt;br /&gt;
&lt;br /&gt;
[[Selecting_the_Right_UI|&amp;quot;UI2&amp;quot;]] is the [[Selecting_the_Right_UI|preferred User Interface]] for Media Stations.  Using a traditional I/R remote is not much different from using any other Media Center PC remote.  The menu button brings up the main menu, and you use the &#039;&#039;left/right/up/down/enter&#039;&#039; buttons to navigate it. The &#039;&#039;fast forward/rewind/skip +/skip -&#039;&#039; keys are used for media playback.&lt;br /&gt;
&lt;br /&gt;
If you have a pointing device like a mouse or gyro air mouse, the UI2 interface also supports a unique control architecture that lets you do everything with 3 (programmable) buttons (plus ok and cancel). The 3 buttons are &amp;quot;MEDIA&amp;quot;, &amp;quot;MENU&amp;quot;, &amp;quot;AMBIANCE&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
On a mouse with 3 programmable buttons (such as the [[Using_the_Gyration_Remote_GYR3101US_%28Non-Fiire_Chief%29|gyration]]), these functions correspond to the buttons from left to right. If you are using a traditional 3 button mouse, you can use the F6, F7 and F8 keys on the keyboard for the three programmable functions instead. In both cases, the left mouse button is &amp;quot;ok&amp;quot;, and the right mouse button is &amp;quot;cancel/go back&amp;quot;. &lt;br /&gt;
&lt;br /&gt;
Mouse button behavior is &amp;quot;absolute&amp;quot; when you press and hold the media/menu/ambiance button and &amp;quot;relative&amp;quot; when you tap and release.&lt;br /&gt;
&lt;br /&gt;
The &amp;quot;absolute&amp;quot; behavior is generally more efficient. For example, in the case of the middle button (F7), &amp;quot;absolute&amp;quot; behavior means the action is executed without having to additionally click &amp;quot;ok&amp;quot;.  If you press and hold the middle button (F7) while moving your mouse pointer to the option, then let go, that option is executed. If you instead tap and release the menu button (&amp;quot;relative&amp;quot; behavior), you will only highlight the menu option. You must then press ok (the left mouse button) to execute the option.&lt;br /&gt;
&lt;br /&gt;
Categories appear along the bottom of the screen, and the scenarios in each category popup vertically (like a pull-down menu in a PC, except upside down).  If the main menu isn&#039;t already visible, bring it up by pressing the &amp;quot;start&amp;quot; button on a Windows I/R remote, or the &amp;quot;menu&amp;quot; button on a 3-button mouse.  To exit a menu, use the back button on the I/R remote, the cancel button (right mouse button on a 3-button mouse), or the ESC key on a keyboard.&lt;br /&gt;
&lt;br /&gt;
In UI2 the media is always full screen. If you&#039;re not playing your own media, the background media (i.e. screensaver images) is gallery art from the Internet (using flickr) or [[Use_my_own_pictures_in_the_Screen_Saver|pictures you select]]. If only the screensaver images are displayed on the Media Station, press the menu/middle/F7 button to bring up the menu. Right click/ESC to get rid of it. (This works even if your own media is playing.)&lt;br /&gt;
&lt;br /&gt;
If you&#039;re using UI2&#039;s 3-button navigation model, the normal media control options on a traditional remote are replaced with a single button: &amp;quot;media&amp;quot; (left soft button or F6). Press this and move the pointer up and down for your skip functions (&#039;&#039;ch+, ch-, skip fwd, skip back&#039;&#039;). Move the pointer left and right for speed control (&#039;&#039;rewind, fast forward&#039;&#039;).  The further you move, the faster the media playback changes.  If you hold the button down (the left soft button or F6), your movement will be &amp;quot;absolute&amp;quot;. Instead of the traditional &amp;quot;jog shuttle-type&amp;quot; control, movement to the right skips to the end of your media, and movement to the left skips to the beginning.  Once you get used to it, you will find that navigating media is orders of magnitude faster and easier with this model than with a traditional remote. You can find a spot in a 2 hour movie in only a couple seconds with a click of a single button (compared to a slew of button clicks required using a traditional remote).&lt;br /&gt;
&lt;br /&gt;
Also, in UI2 you can press the &amp;quot;ambiance&amp;quot; button (right soft button or F8). Move up/down to adjust the lights, and left/right to adjust the volume. As with the media playback, if you hold the F8/right soft button down while you move left and right, your volume control is in &amp;quot;absolute&amp;quot; mode (not &amp;quot;relative&amp;quot;). Moving hard right turns up the volume full blast; hard left is mute.  This requires you have a TV or receiver that is serial-controlled, however. LinuxMCE can then directly and instantly set the volume position in sync with your hand movements. (Few TVs and receivers have this feature, unfortunately.)&lt;br /&gt;
&lt;br /&gt;
There are other media control functions besides the most commonly used &#039;&#039;fast fwd/rewind/skip up/skip down&#039;&#039;. You can, for example, choose &#039;subtitles&#039; while watching a DVD, &#039;guide&#039; while watching TV, and &#039;random&#039; while listening to an audio CD. In the UI2 3 button model, these functions appear on the main menu (on the left-most pad, entitled &#039;now playing&#039;) and changes according to the type of media you&#039;re playing. Press the menu button (middle button/F7) to select these options.&lt;br /&gt;
&lt;br /&gt;
This 3 button model is a new concept and very different from traditional navigation. Most people find it much faster once they become accustomed to it.&lt;br /&gt;
&lt;br /&gt;
==Reload Router &amp;amp; Regen Orbiters==&lt;br /&gt;
&lt;br /&gt;
While using LinuxMCE you&#039;ll see sometimes a message asking if you want to [[Quick reload router|reload the router]], or if you want to [[Orbiter Generator|regenerate the Orbiter UIs]] (User Interfaces). In general, these options refresh the LinuxMCE databases so that changes to the system can be recognized.&lt;br /&gt;
&lt;br /&gt;
===Reload Router===&lt;br /&gt;
All devices in LinuxMCE obtain their configuration information from the [[DCERouter]], which is the central piece of software on the Core.  All devices request a list of the other devices in the home from the router, so they can respond to them appropriately.  (For example, an IP camera device might turn on the lights in the room whenever you&#039;re viewing the camera.  To do so, the IP camera needs to know what lights are in the room.) Typically a device requests this information only when it&#039;s starting up.  When you connect additional plug and play devices to the system, these new devices generally will work immediately, but their functionality may not be fully enabled within the LinuxMCE system until the DCE router is reloaded. When the router reloads, it signals all devices on the system to simultaneously reload and re-request the system data. Each existing device can then work with each new device.  This process is known as a &#039;reload&#039;.  It generally takes about 10 seconds.  Every time you add or remove devices, or change a device&#039;s configuration, you may be asked to do a reload. If you&#039;re going to add more devices or make more device changes, you can do the reload once you&#039;re done. If you&#039;re in the middle of watching a movie or TV, you can postpone the reload, since media players generally stop playing during reloads.  Phone calls aren&#039;t affected, though, and TV shows being recorded by MythTV in the background are also unaffected.&lt;br /&gt;
&lt;br /&gt;
===Regen the Orbiter===&lt;br /&gt;
LinuxMCE&#039;s [[Selecting_the_Right_UI|Orbiter User Interfaces]] are all &amp;quot;pre-rendered&amp;quot; in order to be more efficient.  The User Interface source images are all very high resolution, but need to be resized to accommodate the resolution of each Orbiter screen. The Core server has a list of the Orbiters used by your system, and will generate the appropriate User Interface screen for each Orbiter. It will do this each time you request a &amp;quot;regen&amp;quot;. If you have five different types of Orbiters (each with a different type of screen), then five different images will be generated during each regen.&lt;br /&gt;
&lt;br /&gt;
These User Interface screen images are stored in the Core. The appropriate UI image is sent to an Orbiter whenever it is activated. For many low-power devices (like mobile phones or desktop phones) there just isn&#039;t the processing power to do scaling and rendering of a User Interface screen on the fly. They need to be pre-rendered (with text pre-embedded in the images) to be efficient.&lt;br /&gt;
&lt;br /&gt;
Adding new scenarios may result in the creation of new buttons for the User Interface, or changes to the text on existing buttons. Perhaps an entirely new screen will be created.&lt;br /&gt;
&lt;br /&gt;
Until the User Interface images are regenerated, though, you won&#039;t be able to see these new buttons (or screens) on your Orbiter. During the regen, new User Interface images for each type of Orbiter is generated by the Core. This can take about 2-5 minutes, depending on how many Orbiter types you have in your system.&lt;br /&gt;
&lt;br /&gt;
You needn&#039;t do a regen every time you add a scenario. You can wait until you have finished adding all the scenarios. Furthermore, you can also regen only the Orbiter you are currently using by doing a &amp;quot;Quick regen&amp;quot;. This allows you to see the new User Interface (following the addition of new scenarios) without having to do a full regen for all the Orbiters. Once you have finished adding scenarios, then you can do a full regen.&lt;br /&gt;
&lt;br /&gt;
This regen process can be a bit annoying, but is necessary. In future editions of LinuxMCE, it is planned to allow Media Directors, which have a lot more processing power, to render their on-screen Orbiter User Interfaces on the fly (so you don&#039;t have to do a regen each time you add or remove a scenario).&lt;br /&gt;
&lt;br /&gt;
You can do a [[Orbiter Generator#Running OrbiterGen (performing a &amp;quot;regen&amp;quot;)|full Orbiter regen or a Quick regen]] at any time by using buttons on the Core&#039;s LinuxMCE [[Launch Manager]].&lt;br /&gt;
&lt;br /&gt;
==Managing your media==&lt;br /&gt;
LinuxMCE is always scanning for network shares, on Network-Attached Storage (NAS) devices and other Hard Disk Drives (HDDs) of PCs connected to the system (including Windows PCs). Universal Serial Bus (USB) drives are also detected. Every time a LinuxMCE finds a network share, you will be asked if you would like to use it. Whenever you reply &amp;quot;Yes&amp;quot;, the file share can be used by any Media Director on the system. The file share is scanned for media, such as audio, video and photos, and any that are found are then cataloged in the Core&#039;s central database. For example, when you plug in a USB drive on a Media Station in the living room and tell LinuxMCE to use it, the media on the drive will be available to Media Directors in other rooms.&lt;br /&gt;
&lt;br /&gt;
At the moment there is no way to restrict your media for &#039;local use only&#039;; all Media Stations in the LinuxMCE system share the media catalog stored on the Core.  (This is a limitation that will be addressed in the near future. Sometimes it is desirable to attach a USB drive in the master bedroom and not allow it to be shared, for example. &#039;&#039;Note: However, see [[folder lock|this article that describes a method to address this problem]].&#039;&#039;)&lt;br /&gt;
&lt;br /&gt;
Storage devices (NAS, USB drives, extra HDDs on the Core or Media Directors) are referred to as &amp;quot;Extra Drives&amp;quot;.  When an extra drive is added, it is listed in the device tree in &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Advanced--&amp;gt;Configuration--&amp;gt;[[Devices]]&#039;&#039;&#039;.  Under &#039;Core&#039; you&#039;ll see a device listed for each HDD in the Core, as well as for each NAS device. Under each Media Station will be listed the HDDs in that Media Station.  By clicking on the device you can change the device&#039;s properties, such as the mount username/password.  Each NAS device, and each file share on another PC, will show as a device listed under the Core; each is considered a child of the Core.&lt;br /&gt;
&lt;br /&gt;
===Access control for shared media===&lt;br /&gt;
LinuxMCE creates a top level folder for &#039;public&#039; media. This folder can be used by every user in the system.  A &#039;private&#039; media folder is also created for each user.  Within each of those folders are sub-folders, labeled &#039;audio&#039;, &#039;video&#039;, &#039;pictures&#039;, &#039;data&#039; and &#039;other&#039;.  Within each of those will also be sub-folders for the extra storage devices (NAS, USB, extra internal drives, etc).  When you attach an extra storage device, you can specify whether the default directory structure should be used for it. Alternatively, you can specify &#039;just make it public&#039; or &#039;make it private&#039;.&lt;br /&gt;
&lt;br /&gt;
Here&#039;s an example.  Let&#039;s say you have 2 users: john and mary.  You connect 3 storage devices:&lt;br /&gt;
# a NAS, for which you specify &#039;use default directory structure&#039;. It is named &#039;Generic Network Storage [50]&#039;&lt;br /&gt;
# a USB drive for which you specify &#039;make it all public&#039;. It is named &#039;USB Drive [51]&#039;&lt;br /&gt;
# a SATA drive for which you choose &#039;make it private for john&#039;. It is named &#039;General Internal HDD [52]&lt;br /&gt;
&lt;br /&gt;
Now let&#039;s say you&#039;re running Windows. Go to Network Neighborhood and find the LinuxMCE Core server.  The directory tree ought to look like this:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
public&lt;br /&gt;
  video&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  audio&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  pictures&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  data&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  other&lt;br /&gt;
    USB Drive [51]&lt;br /&gt;
john&lt;br /&gt;
  video&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  audio&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  pictures&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  data&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  other&lt;br /&gt;
    General Internal HDD [52]&lt;br /&gt;
mary&lt;br /&gt;
  video&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  audio&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  pictures&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  data&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  other&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Whether you put your media under video, audio, pictures, data or other is unimportant.  It will be scanned by LinuxMCE anyway. The contents of &amp;quot;General Internal HDD [52]&amp;quot; will be displayed in the folder john/other/General Internal HDD [52]. The contents of USB Drive [51] will be displayed in the folder public/other/USB Drive [51].  When John browses the contents in Network Neighborhood, he will be asked for his username and password. He can then access the content in both the public folder as well as the &amp;quot;john&amp;quot; folders (including General Internal HDD [52]).  When Mary browses the contents with her username and password, she will see both the public and &amp;quot;mary&amp;quot; folders. She will not be able to see anything on General Internal HDD [52], however, since that drive was specified to be private for John.&lt;br /&gt;
&lt;br /&gt;
In the case of John&#039;s private media, it won&#039;t be displayed in the LinuxMCE media browser unless you click &#039;Sources&#039;--&amp;gt;&#039;John&#039;. However you &#039;&#039;can&#039;&#039; see the contents of General Internal HDD [52] (unless you deselect &#039;Sources&#039;--&amp;gt;&#039;Public&#039; from the media browser).  Generic Network Storage [50] would be different, however, since you specified to use the default directory structure for it.  LinuxMCE will have created public directories on Generic Network Storage [50] for public video and public audio, as well as for john&#039;s video and mary&#039;s audio. The media file browser will show only the media that is in the public directories. (The same is true with the Windows Network Neighborhood browser.) &lt;br /&gt;
&lt;br /&gt;
If Generic Network Storage [50] has existing media in the top (root) folder, you won&#039;t see it listed anywhere.&lt;br /&gt;
&lt;br /&gt;
It is generally recommended, therefore, that when you add a new (blank) &amp;quot;extra&amp;quot; storage device, you choose to use the default directory structure on it.  When you rip media to that device, the media can then be made either public or private, and LinuxMCE will automatically put it in the correct folder (audio, video, etc.).&lt;br /&gt;
&lt;br /&gt;
If you connect an extra storage device that already has media on it, however, and that media isn&#039;t already organized in LinuxMCE&#039;s default directory structure, it&#039;s easiest if you simply &#039;make it all public&#039; or &#039;make it all private&#039;. If you were to &#039;use the default directory structure&#039;, you would need to manually move the files from the existing folders into one of the directory folders that LinuxMCE would then create for you.&lt;br /&gt;
&lt;br /&gt;
When you rip files, you have the option of copying them to the Core.  If you rip a CD and make it public, it will be stored in public/audio.  If you go into Network Neighborhood and add a folder under public/audio, you would essentially be adding a folder on the Core. If you add a folder under public/audio/Generic Network Storage [50], you would be adding it to Generic Network Storage [50].&lt;br /&gt;
&lt;br /&gt;
===Drive and network drive management===&lt;br /&gt;
This concept behind drive/network drive management is not the same as the method to which Linux and Windows users are accustomed. In Windows, for example, each network device shows up separately; they are never grouped together.  There is an advantage to the way LinuxMCE manages drives. It&#039;s much simpler to add devices when you&#039;re a novice and don&#039;t understand networking. Further, if you&#039;re using an infrared remote control, you can manage drives with a single &#039;yes&#039; or &#039;no,&#039; click, which is very convenient. Lastly, all your media content is cataloged and presented in the same structure throughout the system, no matter which Media Director you&#039;re using or what room you&#039;re in.&lt;br /&gt;
&lt;br /&gt;
In Windows, by comparison, if you connect a USB drive to a Windows PC in the bedroom, you won&#039;t see that content in the living room unless you 1) open file explorer, 2) create a new network share for it, 3) go into the living room, and 4) create a new mapped network drive there. (That isn&#039;t so easy to do with an infrared remote and without some knowledge of networking.)  Further, you wouldn&#039;t be able to see the media in any other room in the house unless you were to also create mapped network shares in those rooms as well. &lt;br /&gt;
&lt;br /&gt;
With LinuxMCE, when you connect a USB drive, for example, you can &#039;make it all public&#039;; the media will be available everywhere. No other typing is required. With LinuxMCE, instead of managing multiple network shares and mapped drives, you can choose the Core&#039;s public folders in the Network Neighborhood browser from anywhere in the home, without having to know which storage devices the media is actually on.  When you remove a USB drive from a Media Station, that media instantly disappears from the catalog displayed in every room. If you reattach it, it will re-appear.&lt;br /&gt;
&lt;br /&gt;
You can also backup the media securely on the Core. LinuxMCE has built-in [http://en.wikipedia.org/wiki/RAID RAID] 5 (see &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Advanced--&amp;gt;[[RAID]]&#039;&#039;&#039;), so its HDD has similar backup capabilities to a [[NAS]] device.&lt;br /&gt;
&lt;br /&gt;
To change the name of an extra device, go to the &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Advanced--&amp;gt;Configuration--&amp;gt;[[Devices]]&#039;&#039;&#039; and under the Core you will see listed the HDDs in the core and any connected NAS devices. Under each Media Station you will see the HDDs in that Media Station. All are given default names.  You can change the description, which will also change the folder name.  In the above example, changing &amp;quot;USB Drive [51]&amp;quot; to &amp;quot;Tokyo&amp;quot; means the directory public/other/USB Drive [51] would change to public/other/Tokyo.&lt;br /&gt;
&lt;br /&gt;
You can see a list of the files in the system by folder In the &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Files &amp;amp; Media--&amp;gt;[[Media Files Sync]]&#039;&#039;&#039; menu.  If a file is shown with a check box, the file exists both on the local disk as well as in LinuxMCE&#039;s master catalog.  If it has a different icon, then LinuxMCE hasn&#039;t finished cataloging the media; just be patient. It should appear with a check mark soon (depending on how much new media was added). &lt;br /&gt;
&lt;br /&gt;
Use this interface to manage change cover art and attributes. Under Files &amp;amp; Media there is also a cover art scan utility that will find cover art, as well as other attributes (actor, genre, etc.) obtained from Amazon.&lt;br /&gt;
&lt;br /&gt;
===Linux operational details of network and disk mounts===&lt;br /&gt;
[[UpdateMedia]] is a daemon that constantly scans for media files in the /home/public and the /home/user_xxx folder created for each user. Any added media is cataloged in the pluto_media database File table, and attributes and cover art go into the Attribute and Picture tables.  Under /home/public and /home/users_xxx is a data subfolder which contains the actual video, audio, pictures folders.  (The /home/user_xxx directories themselves contain the system files for each user (like email boxes) as well as the main login for that user (in a &amp;quot;data&amp;quot; subfolder).&lt;br /&gt;
&lt;br /&gt;
Extra devices are mounted as /mnt/device/xxx (where xxx is the device number).  The mount point is the same whether it&#039;s a local drive or not.  For example, USB drive [50] in a Media Station may be mounted as a local device named /mnt/device/50, but is also mounted as a Samba mount on other Media Stations as /mnt/device/50.  The Core and the Media Stations all use the same mount names (/mnt/device/).&lt;br /&gt;
&lt;br /&gt;
Within the /home/public/data and /home/user_xxx/data are symlinks to the physical directories specified by /mnt/device/xxx.  Since the Core and all Media Stations mount the same /home directory (and all have the same /mnt/device mounts), they will all show the same files.  Therefore, if the [[UpdateMedia]] daemon locates the file /home/public/data/audio/Generic Internal Drive [50]/The Beatles/Let it be.mp3, that file will be listed on every Media Station, too.&lt;br /&gt;
&lt;br /&gt;
[[Category: Tutorials]]&lt;/div&gt;</summary>
		<author><name>Juanfe</name></author>
	</entry>
	<entry>
		<id>http://wiki.linuxmce.org/index.php?title=Usage_Intro&amp;diff=14831</id>
		<title>Usage Intro</title>
		<link rel="alternate" type="text/html" href="http://wiki.linuxmce.org/index.php?title=Usage_Intro&amp;diff=14831"/>
		<updated>2008-07-12T22:38:13Z</updated>

		<summary type="html">&lt;p&gt;Juanfe: /* Media Management */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{| align=&amp;quot;right&amp;quot;&lt;br /&gt;
  | __TOC__&lt;br /&gt;
  |}&lt;br /&gt;
LinuxMCE&#039;s main concepts are [[Devices]], Commands (aka [[Scenarios]] and Activities), and [[Events]]. An  [[Orbiter]] is the device that displays the User Interface. It can be a [[Media Director|Media Station]], web pad, mobile phone, or other remote control device. The Orbiter User Interface is standardized for all Orbiters.&lt;br /&gt;
&lt;br /&gt;
== Devices ==&lt;br /&gt;
&lt;br /&gt;
A device is generally a piece of hardware or software, like the Xine Media Player, a light switch, or a mobile phone.  Devices have three functions, abbreviated &amp;quot;DCE&amp;quot; (Data, Commands, Events): &lt;br /&gt;
&lt;br /&gt;
# Retrieve configuration &#039;&#039;&#039;data&#039;&#039;&#039;&lt;br /&gt;
# Perform a &#039;&#039;&#039;command&#039;&#039;&#039; (turn on, turn off, fast forward, etc.)&lt;br /&gt;
# Report certain triggered &#039;&#039;&#039;events&#039;&#039;&#039; (e.g. &#039;motion detected&#039;, &#039;playback started&#039;, etc.)&lt;br /&gt;
&lt;br /&gt;
== Scenarios ==&lt;br /&gt;
&lt;br /&gt;
&amp;quot;[[Scenarios]]&amp;quot;, &amp;quot;Activities&amp;quot;, and &amp;quot;Command Groups&amp;quot; are interchangeable terms -- they mean the same thing.  A scenario is a group of commands that can be sent to a device (or series of devices).  In LinuxMCE, the default Orbiter main menu consists of several scenario categories, grouped by room. These categories are&lt;br /&gt;
&lt;br /&gt;
* Lighting&lt;br /&gt;
* Media&lt;br /&gt;
* Climate&lt;br /&gt;
* Telecom&lt;br /&gt;
* Security&lt;br /&gt;
&lt;br /&gt;
(These default categories are arbitrary and are set up at installation.) To perform an action in LinuxMCE, a scenario is chosen from one of these categories (located on the main menu of an Orbiter). &lt;br /&gt;
&lt;br /&gt;
For example, in rooms which have both a TV and lights, LinuxMCE automatically creates a scenario called &#039;Showtime.&#039; This scenario dims the lights to 10% whenever the TV starts playing.  In rooms with a PVR or other TV-enabled device, another scenario is created called &#039;TV&#039; (in the &#039;Media&#039; category) to start the TV.  Another scenario in the &#039;Media&#039; category called &#039;Video&#039; sends a command to the Orbiter to list your video content. Telecom scenarios are created to make phone calls. Security scenarios are created to view cameras and to arm an alarm.&lt;br /&gt;
&lt;br /&gt;
Some [[What_scenarios_are_created_automatically%3F|default scenarios]] are created for you at installation. A fully-functional system can run using only the default scenarios, if you choose. You can also change or remove the default scenarios or add new ones. This is done though the &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Wizard--&amp;gt;[[Scenarios]]&#039;&#039;&#039; menu. When creating a scenario, the [[LinuxMCE Admin Website]] will show you the most appropriate wizard, based on the category you pick.  If you&#039;re adding an activity in the lighting category, for example, the wizard will display a list of the lights in the room and let you pick which ones to turn off.  If you&#039;re creating a scenario in the security category, it will list the installed cameras and will allow you to select which ones to display.&lt;br /&gt;
&lt;br /&gt;
A scenario can send a command to any device in the system. By default, scenarios in the lighting category show you the room lights, allowing you to select which ones to which to send commands. However, from the &#039;&#039;&#039;Wizard--&amp;gt;[[Scenarios]]&#039;&#039;&#039; menu for the specific scenario, you can also specify a command to any device in your home. You could make a phone call, for example, even from a scenario in the lighting category.&lt;br /&gt;
&lt;br /&gt;
Certain scenarios are assigned to certain rooms by default. This can be customized, however. When you manually select a room from the Orbiter main menu, the default scenarios for that room are displayed. In general they control devices in that room, but this can also be changed. If your kitchen is near the garage and you want a scenario to &#039;turn off the garage light&#039;, you can assign a scenario to the room &#039;kitchen&#039; that will do just that. It doesn&#039;t matter that the light is in the garage.&lt;br /&gt;
&lt;br /&gt;
For a Media Director, the on-screen Orbiter User Interface appears on the TV screen. It is manipulated by the mouse/keyboard or remote control connected to your Media Director. By default it is set to display the scenarios for the room in which the Media Director is located.&lt;br /&gt;
&lt;br /&gt;
In contrast, a mobile Orbiter (such as a webpad) can be carried throughout the house. It must be able to select the scenarios for multiple rooms. Fortunately, the option to manually select which room you are currently in is available on every Orbiter&#039;s main menu.&lt;br /&gt;
&lt;br /&gt;
This can occasionally cause some confusion. Perhaps both the Living Room and the Bedroom have a scenario called &#039;TV&#039;. You may have a web pad that is in the Bedroom, but you then carry it to the Living Room. You may forget to tell the web pad that it&#039;s now in the Living Room (at the bottom of the Orbiter screen it will still say &#039;Bedroom&#039;). You hit the &#039;TV&#039; button expecting the Living Room TV to come on, but in fact you&#039;re still controlling the Bedroom and the TV comes on there instead. Finally you may realize that you must change your room location to Living Room, and you can then finally control the TV there.&lt;br /&gt;
&lt;br /&gt;
Once you get used to this concept, though, you&#039;ll find it very useful.  Conveniently, any Orbiter can be set to control any room and choose from the scenarios assigned to that room. No matter which Orbiter you use, the same set of scenarios will be displayed for each specific room. For example, the kitchen scenarios will always be the same, no matter which Orbiter you are using. (The scenarios are assigned by room -- not by Orbiter.) No matter whether you pick up your mobile phone, your web pad, or your remote control, you will always be shown the same list of scenario options for the Living Room.&lt;br /&gt;
&lt;br /&gt;
You have the option of preventing some family members from using certain scenarios. From the [[LinuxMCE Admin Website]], certain scenarios and rooms can be [[Users#Restrict_Access|restricted to certain users]].  Maybe little Suzy&#039;s mobile phone Orbiter should be restricted so that she is only able to control her room and the living room, for example. She would only be able to execute the scenarios in those rooms, but not the Master Bedroom. Other possible options include [[Users#Restrict_Access|requiring a pin code]] to access the scenarios for a particular room.&lt;br /&gt;
&lt;br /&gt;
== Events ==&lt;br /&gt;
&lt;br /&gt;
Devices report events, such as &#039;Playback started&#039; and &#039;Motion Sensor tripped&#039;. If you want something to happen automatically in LinuxMCE, you create Event Handlers that react to these events. For example, you can create an event handler that listens for the &#039;Motion Sensor tripped&#039; event from a motion detector and turns on the lights in response.  An event handler might listen for the &#039;Sunrise&#039; event, which could then prompt the sprinklers to come on. &lt;br /&gt;
&lt;br /&gt;
LinuxMCE creates several default event handlers. In rooms in which you have a TV and lights, an event handler is created that listens for the &#039;Watching Media&#039; event sent by a media player. When the event is detected, the Showtime scenario (which dims the lights) is executed in response.  When you start a movie, therefore, the Showtime activity will be executed and the lights will be dimmed.  There are other default event handlers that monitor for events like &#039;Security Breach&#039; and &#039;Fire Alarm&#039; (from a home security system).&lt;br /&gt;
&lt;br /&gt;
== Controlling an Orbiter ==&lt;br /&gt;
&lt;br /&gt;
To control the system, you use an [[Orbiter]], which is the LinuxMCE term for a remote control.  All [[Orbiters]] have the same basic function: to display the scenarios in the room you&#039;re in and let you select one.  The different Orbiters may [[Selecting_the_Right_UI|display the User Interface slightly differently]], depending on their screen size, but the function and the list of scenarios is always the same. For example, the [[Selecting_the_Right_UI|&amp;quot;UI1&amp;quot; interface]] (which is used on webpads and PDAs) displays the scenarios in horizontal rows. (If there are more than will fit on a row, there will be a &amp;quot;more&amp;quot; button.) A home button is always displayed that takes you to the main menu. On smaller displays, as on mobile phones or desktop phones, there&#039;s not enough room to show the scenarios themselves. The top level menu shows only the categories: Lights, Media, Climate, Security and Telecom. Selecting a category displays the scenarios in that category. &lt;br /&gt;
&lt;br /&gt;
[[Selecting_the_Right_UI|&amp;quot;UI2&amp;quot;]] is the [[Selecting_the_Right_UI|preferred User Interface]] for Media Stations.  Using a traditional I/R remote is not much different from using any other Media Center PC remote.  The menu button brings up the main menu, and you use the &#039;&#039;left/right/up/down/enter&#039;&#039; buttons to navigate it. The &#039;&#039;fast forward/rewind/skip +/skip -&#039;&#039; keys are used for media playback.&lt;br /&gt;
&lt;br /&gt;
If you have a pointing device like a mouse or gyro air mouse, the UI2 interface also supports a unique control architecture that lets you do everything with 3 (programmable) buttons (plus ok and cancel). The 3 buttons are &amp;quot;MEDIA&amp;quot;, &amp;quot;MENU&amp;quot;, &amp;quot;AMBIANCE&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
On a mouse with 3 programmable buttons (such as the [[Using_the_Gyration_Remote_GYR3101US_%28Non-Fiire_Chief%29|gyration]]), these functions correspond to the buttons from left to right. If you are using a traditional 3 button mouse, you can use the F6, F7 and F8 keys on the keyboard for the three programmable functions instead. In both cases, the left mouse button is &amp;quot;ok&amp;quot;, and the right mouse button is &amp;quot;cancel/go back&amp;quot;. &lt;br /&gt;
&lt;br /&gt;
Mouse button behavior is &amp;quot;absolute&amp;quot; when you press and hold the media/menu/ambiance button and &amp;quot;relative&amp;quot; when you tap and release.&lt;br /&gt;
&lt;br /&gt;
The &amp;quot;absolute&amp;quot; behavior is generally more efficient. For example, in the case of the middle button (F7), &amp;quot;absolute&amp;quot; behavior means the action is executed without having to additionally click &amp;quot;ok&amp;quot;.  If you press and hold the middle button (F7) while moving your mouse pointer to the option, then let go, that option is executed. If you instead tap and release the menu button (&amp;quot;relative&amp;quot; behavior), you will only highlight the menu option. You must then press ok (the left mouse button) to execute the option.&lt;br /&gt;
&lt;br /&gt;
Categories appear along the bottom of the screen, and the scenarios in each category popup vertically (like a pull-down menu in a PC, except upside down).  If the main menu isn&#039;t already visible, bring it up by pressing the &amp;quot;start&amp;quot; button on a Windows I/R remote, or the &amp;quot;menu&amp;quot; button on a 3-button mouse.  To exit a menu, use the back button on the I/R remote, the cancel button (right mouse button on a 3-button mouse), or the ESC key on a keyboard.&lt;br /&gt;
&lt;br /&gt;
In UI2 the media is always full screen. If you&#039;re not playing your own media, the background media (i.e. screensaver images) is gallery art from the Internet (using flickr) or [[Use_my_own_pictures_in_the_Screen_Saver|pictures you select]]. If only the screensaver images are displayed on the Media Station, press the menu/middle/F7 button to bring up the menu. Right click/ESC to get rid of it. (This works even if your own media is playing.)&lt;br /&gt;
&lt;br /&gt;
If you&#039;re using UI2&#039;s 3-button navigation model, the normal media control options on a traditional remote are replaced with a single button: &amp;quot;media&amp;quot; (left soft button or F6). Press this and move the pointer up and down for your skip functions (&#039;&#039;ch+, ch-, skip fwd, skip back&#039;&#039;). Move the pointer left and right for speed control (&#039;&#039;rewind, fast forward&#039;&#039;).  The further you move, the faster the media playback changes.  If you hold the button down (the left soft button or F6), your movement will be &amp;quot;absolute&amp;quot;. Instead of the traditional &amp;quot;jog shuttle-type&amp;quot; control, movement to the right skips to the end of your media, and movement to the left skips to the beginning.  Once you get used to it, you will find that navigating media is orders of magnitude faster and easier with this model than with a traditional remote. You can find a spot in a 2 hour movie in only a couple seconds with a click of a single button (compared to a slew of button clicks required using a traditional remote).&lt;br /&gt;
&lt;br /&gt;
Also, in UI2 you can press the &amp;quot;ambiance&amp;quot; button (right soft button or F8). Move up/down to adjust the lights, and left/right to adjust the volume. As with the media playback, if you hold the F8/right soft button down while you move left and right, your volume control is in &amp;quot;absolute&amp;quot; mode (not &amp;quot;relative&amp;quot;). Moving hard right turns up the volume full blast; hard left is mute.  This requires you have a TV or receiver that is serial-controlled, however. LinuxMCE can then directly and instantly set the volume position in sync with your hand movements. (Few TVs and receivers have this feature, unfortunately.)&lt;br /&gt;
&lt;br /&gt;
There are other media control functions besides the most commonly used &#039;&#039;fast fwd/rewind/skip up/skip down&#039;&#039;. You can, for example, choose &#039;subtitles&#039; while watching a DVD, &#039;guide&#039; while watching TV, and &#039;random&#039; while listening to an audio CD. In the UI2 3 button model, these functions appear on the main menu (on the left-most pad, entitled &#039;now playing&#039;) and changes according to the type of media you&#039;re playing. Press the menu button (middle button/F7) to select these options.&lt;br /&gt;
&lt;br /&gt;
This 3 button model is a new concept and very different from traditional navigation. Most people find it much faster once they become accustomed to it.&lt;br /&gt;
&lt;br /&gt;
==Reload Router &amp;amp; Regen Orbiters==&lt;br /&gt;
&lt;br /&gt;
While using LinuxMCE you&#039;ll see sometimes a message asking if you want to [[Quick reload router|reload the router]], or if you want to [[Orbiter Generator|regenerate the Orbiter UIs]] (User Interfaces). In general, these options refresh the LinuxMCE databases so that changes to the system can be recognized.&lt;br /&gt;
&lt;br /&gt;
===Reload Router===&lt;br /&gt;
All devices in LinuxMCE obtain their configuration information from the [[DCERouter]], which is the central piece of software on the Core.  All devices request a list of the other devices in the home from the router, so they can respond to them appropriately.  (For example, an IP camera device might turn on the lights in the room whenever you&#039;re viewing the camera.  To do so, the IP camera needs to know what lights are in the room.) Typically a device requests this information only when it&#039;s starting up.  When you connect additional plug and play devices to the system, these new devices generally will work immediately, but their functionality may not be fully enabled within the LinuxMCE system until the DCE router is reloaded. When the router reloads, it signals all devices on the system to simultaneously reload and re-request the system data. Each existing device can then work with each new device.  This process is known as a &#039;reload&#039;.  It generally takes about 10 seconds.  Every time you add or remove devices, or change a device&#039;s configuration, you may be asked to do a reload. If you&#039;re going to add more devices or make more device changes, you can do the reload once you&#039;re done. If you&#039;re in the middle of watching a movie or TV, you can postpone the reload, since media players generally stop playing during reloads.  Phone calls aren&#039;t affected, though, and TV shows being recorded by MythTV in the background are also unaffected.&lt;br /&gt;
&lt;br /&gt;
===Regen the Orbiter===&lt;br /&gt;
LinuxMCE&#039;s [[Selecting_the_Right_UI|Orbiter User Interfaces]] are all &amp;quot;pre-rendered&amp;quot; in order to be more efficient.  The User Interface source images are all very high resolution, but need to be resized to accommodate the resolution of each Orbiter screen. The Core server has a list of the Orbiters used by your system, and will generate the appropriate User Interface screen for each Orbiter. It will do this each time you request a &amp;quot;regen&amp;quot;. If you have five different types of Orbiters (each with a different type of screen), then five different images will be generated during each regen.&lt;br /&gt;
&lt;br /&gt;
These User Interface screen images are stored in the Core. The appropriate UI image is sent to an Orbiter whenever it is activated. For many low-power devices (like mobile phones or desktop phones) there just isn&#039;t the processing power to do scaling and rendering of a User Interface screen on the fly. They need to be pre-rendered (with text pre-embedded in the images) to be efficient.&lt;br /&gt;
&lt;br /&gt;
Adding new scenarios may result in the creation of new buttons for the User Interface, or changes to the text on existing buttons. Perhaps an entirely new screen will be created.&lt;br /&gt;
&lt;br /&gt;
Until the User Interface images are regenerated, though, you won&#039;t be able to see these new buttons (or screens) on your Orbiter. During the regen, new User Interface images for each type of Orbiter is generated by the Core. This can take about 2-5 minutes, depending on how many Orbiter types you have in your system.&lt;br /&gt;
&lt;br /&gt;
You needn&#039;t do a regen every time you add a scenario. You can wait until you have finished adding all the scenarios. Furthermore, you can also regen only the Orbiter you are currently using by doing a &amp;quot;Quick regen&amp;quot;. This allows you to see the new User Interface (following the addition of new scenarios) without having to do a full regen for all the Orbiters. Once you have finished adding scenarios, then you can do a full regen.&lt;br /&gt;
&lt;br /&gt;
This regen process can be a bit annoying, but is necessary. In future editions of LinuxMCE, it is planned to allow Media Directors, which have a lot more processing power, to render their on-screen Orbiter User Interfaces on the fly (so you don&#039;t have to do a regen each time you add or remove a scenario).&lt;br /&gt;
&lt;br /&gt;
You can do a [[Orbiter Generator#Running OrbiterGen (performing a &amp;quot;regen&amp;quot;)|full Orbiter regen or a Quick regen]] at any time by using buttons on the Core&#039;s LinuxMCE [[Launch Manager]].&lt;br /&gt;
&lt;br /&gt;
==Managing your media==&lt;br /&gt;
LinuxMCE is always scanning for network shares, on Network-Attached Storage (NAS) devices and other Hard Disk Drives (HDDs) of PCs connected to the system (including Windows PCs). Universal Serial Bus (USB) drives are also detected. Every time a LinuxMCE finds a network share, you will be asked if you would like to use it. Whenever you reply &amp;quot;Yes&amp;quot;, the file share can be used by any Media Director on the system. The file share is scanned for media, such as audio, video and photos, and any that are found are then cataloged in the Core&#039;s central database. For example, when you plug in a USB drive on a Media Station in the living room and tell LinuxMCE to use it, the media on the drive will be available to Media Directors in other rooms.&lt;br /&gt;
&lt;br /&gt;
At the moment there is no way to restrict your media for &#039;local use only&#039;; all Media Stations in the LinuxMCE system share the media catalog stored on the Core.  (This is a limitation that will be addressed in the near future. Sometimes it is desirable to attach a USB drive in the master bedroom and not allow it to be shared, for example. &#039;&#039;Note: However, see [[folder lock|this article that describes a method to address this problem]].&#039;&#039;)&lt;br /&gt;
&lt;br /&gt;
Storage devices (NAS, USB drives, extra HDDs on the Core or Media Directors) are referred to as &amp;quot;Extra Drives&amp;quot;.  When an extra drive is added, it is listed in the device tree in &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Advanced--&amp;gt;Configuration--&amp;gt;[[Devices]]&#039;&#039;&#039;.  Under &#039;Core&#039; you&#039;ll see a device listed for each HDD in the Core, as well as for each NAS device. Under each Media Station will be listed the HDDs in that Media Station.  By clicking on the device you can change the device&#039;s properties, such as the mount username/password.  Each NAS device, and each file share on another PC, will show as a device listed under the Core; each is considered a child of the Core.&lt;br /&gt;
&lt;br /&gt;
==Access control for shared media==&lt;br /&gt;
LinuxMCE creates a top level folder for &#039;public&#039; media. This folder can be used by every user in the system.  A &#039;private&#039; media folder is also created for each user.  Within each of those folders are sub-folders, labeled &#039;audio&#039;, &#039;video&#039;, &#039;pictures&#039;, &#039;data&#039; and &#039;other&#039;.  Within each of those will also be sub-folders for the extra storage devices (NAS, USB, extra internal drives, etc).  When you attach an extra storage device, you can specify whether the default directory structure should be used for it. Alternatively, you can specify &#039;just make it public&#039; or &#039;make it private&#039;.&lt;br /&gt;
&lt;br /&gt;
Here&#039;s an example.  Let&#039;s say you have 2 users: john and mary.  You connect 3 storage devices:&lt;br /&gt;
# a NAS, for which you specify &#039;use default directory structure&#039;. It is named &#039;Generic Network Storage [50]&#039;&lt;br /&gt;
# a USB drive for which you specify &#039;make it all public&#039;. It is named &#039;USB Drive [51]&#039;&lt;br /&gt;
# a SATA drive for which you choose &#039;make it private for john&#039;. It is named &#039;General Internal HDD [52]&lt;br /&gt;
&lt;br /&gt;
Now let&#039;s say you&#039;re running Windows. Go to Network Neighborhood and find the LinuxMCE Core server.  The directory tree ought to look like this:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
public&lt;br /&gt;
  video&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  audio&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  pictures&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  data&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  other&lt;br /&gt;
    USB Drive [51]&lt;br /&gt;
john&lt;br /&gt;
  video&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  audio&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  pictures&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  data&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  other&lt;br /&gt;
    General Internal HDD [52]&lt;br /&gt;
mary&lt;br /&gt;
  video&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  audio&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  pictures&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  data&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  other&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Whether you put your media under video, audio, pictures, data or other is unimportant.  It will be scanned by LinuxMCE anyway. The contents of &amp;quot;General Internal HDD [52]&amp;quot; will be displayed in the folder john/other/General Internal HDD [52]. The contents of USB Drive [51] will be displayed in the folder public/other/USB Drive [51].  When John browses the contents in Network Neighborhood, he will be asked for his username and password. He can then access the content in both the public folder as well as the &amp;quot;john&amp;quot; folders (including General Internal HDD [52]).  When Mary browses the contents with her username and password, she will see both the public and &amp;quot;mary&amp;quot; folders. She will not be able to see anything on General Internal HDD [52], however, since that drive was specified to be private for John.&lt;br /&gt;
&lt;br /&gt;
In the case of John&#039;s private media, it won&#039;t be displayed in the LinuxMCE media browser unless you click &#039;Sources&#039;--&amp;gt;&#039;John&#039;. However you &#039;&#039;can&#039;&#039; see the contents of General Internal HDD [52] (unless you deselect &#039;Sources&#039;--&amp;gt;&#039;Public&#039; from the media browser).  Generic Network Storage [50] would be different, however, since you specified to use the default directory structure for it.  LinuxMCE will have created public directories on Generic Network Storage [50] for public video and public audio, as well as for john&#039;s video and mary&#039;s audio. The media file browser will show only the media that is in the public directories. (The same is true with the Windows Network Neighborhood browser.) &lt;br /&gt;
&lt;br /&gt;
If Generic Network Storage [50] has existing media in the top (root) folder, you won&#039;t see it listed anywhere.&lt;br /&gt;
&lt;br /&gt;
It is generally recommended, therefore, that when you add a new (blank) &amp;quot;extra&amp;quot; storage device, you choose to use the default directory structure on it.  When you rip media to that device, the media can then be made either public or private, and LinuxMCE will automatically put it in the correct folder (audio, video, etc.).&lt;br /&gt;
&lt;br /&gt;
If you connect an extra storage device that already has media on it, however, and that media isn&#039;t already organized in LinuxMCE&#039;s default directory structure, it&#039;s easiest if you simply &#039;make it all public&#039; or &#039;make it all private&#039;. If you were to &#039;use the default directory structure&#039;, you would need to manually move the files from the existing folders into one of the directory folders that LinuxMCE would then create for you.&lt;br /&gt;
&lt;br /&gt;
When you rip files, you have the option of copying them to the Core.  If you rip a CD and make it public, it will be stored in public/audio.  If you go into Network Neighborhood and add a folder under public/audio, you would essentially be adding a folder on the Core. If you add a folder under public/audio/Generic Network Storage [50], you would be adding it to Generic Network Storage [50].&lt;br /&gt;
&lt;br /&gt;
==Drive and network drive management==&lt;br /&gt;
This concept behind drive/network drive management is not the same as the method to which Linux and Windows users are accustomed. In Windows, for example, each network device shows up separately; they are never grouped together.  There is an advantage to the way LinuxMCE manages drives. It&#039;s much simpler to add devices when you&#039;re a novice and don&#039;t understand networking. Further, if you&#039;re using an infrared remote control, you can manage drives with a single &#039;yes&#039; or &#039;no,&#039; click, which is very convenient. Lastly, all your media content is cataloged and presented in the same structure throughout the system, no matter which Media Director you&#039;re using or what room you&#039;re in.&lt;br /&gt;
&lt;br /&gt;
In Windows, by comparison, if you connect a USB drive to a Windows PC in the bedroom, you won&#039;t see that content in the living room unless you 1) open file explorer, 2) create a new network share for it, 3) go into the living room, and 4) create a new mapped network drive there. (That isn&#039;t so easy to do with an infrared remote and without some knowledge of networking.)  Further, you wouldn&#039;t be able to see the media in any other room in the house unless you were to also create mapped network shares in those rooms as well. &lt;br /&gt;
&lt;br /&gt;
With LinuxMCE, when you connect a USB drive, for example, you can &#039;make it all public&#039;; the media will be available everywhere. No other typing is required. With LinuxMCE, instead of managing multiple network shares and mapped drives, you can choose the Core&#039;s public folders in the Network Neighborhood browser from anywhere in the home, without having to know which storage devices the media is actually on.  When you remove a USB drive from a Media Station, that media instantly disappears from the catalog displayed in every room. If you reattach it, it will re-appear.&lt;br /&gt;
&lt;br /&gt;
You can also backup the media securely on the Core. LinuxMCE has built-in [http://en.wikipedia.org/wiki/RAID RAID] 5 (see &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Advanced--&amp;gt;[[RAID]]&#039;&#039;&#039;), so its HDD has similar backup capabilities to a [[NAS]] device.&lt;br /&gt;
&lt;br /&gt;
To change the name of an extra device, go to the &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Advanced--&amp;gt;Configuration--&amp;gt;[[Devices]]&#039;&#039;&#039; and under the Core you will see listed the HDDs in the core and any connected NAS devices. Under each Media Station you will see the HDDs in that Media Station. All are given default names.  You can change the description, which will also change the folder name.  In the above example, changing &amp;quot;USB Drive [51]&amp;quot; to &amp;quot;Tokyo&amp;quot; means the directory public/other/USB Drive [51] would change to public/other/Tokyo.&lt;br /&gt;
&lt;br /&gt;
You can see a list of the files in the system by folder In the &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Files &amp;amp; Media--&amp;gt;[[Media Files Sync]]&#039;&#039;&#039; menu.  If a file is shown with a check box, the file exists both on the local disk as well as in LinuxMCE&#039;s master catalog.  If it has a different icon, then LinuxMCE hasn&#039;t finished cataloging the media; just be patient. It should appear with a check mark soon (depending on how much new media was added). &lt;br /&gt;
&lt;br /&gt;
Use this interface to manage change cover art and attributes. Under Files &amp;amp; Media there is also a cover art scan utility that will find cover art, as well as other attributes (actor, genre, etc.) obtained from Amazon.&lt;br /&gt;
&lt;br /&gt;
==Linux operational details of network and disk mounts==&lt;br /&gt;
[[UpdateMedia]] is a daemon that constantly scans for media files in the /home/public and the /home/user_xxx folder created for each user. Any added media is cataloged in the pluto_media database File table, and attributes and cover art go into the Attribute and Picture tables.  Under /home/public and /home/users_xxx is a data subfolder which contains the actual video, audio, pictures folders.  (The /home/user_xxx directories themselves contain the system files for each user (like email boxes) as well as the main login for that user (in a &amp;quot;data&amp;quot; subfolder).&lt;br /&gt;
&lt;br /&gt;
Extra devices are mounted as /mnt/device/xxx (where xxx is the device number).  The mount point is the same whether it&#039;s a local drive or not.  For example, USB drive [50] in a Media Station may be mounted as a local device named /mnt/device/50, but is also mounted as a Samba mount on other Media Stations as /mnt/device/50.  The Core and the Media Stations all use the same mount names (/mnt/device/).&lt;br /&gt;
&lt;br /&gt;
Within the /home/public/data and /home/user_xxx/data are symlinks to the physical directories specified by /mnt/device/xxx.  Since the Core and all Media Stations mount the same /home directory (and all have the same /mnt/device mounts), they will all show the same files.  Therefore, if the [[UpdateMedia]] daemon locates the file /home/public/data/audio/Generic Internal Drive [50]/The Beatles/Let it be.mp3, that file will be listed on every Media Station, too.&lt;br /&gt;
&lt;br /&gt;
[[Category: Tutorials]]&lt;/div&gt;</summary>
		<author><name>Juanfe</name></author>
	</entry>
	<entry>
		<id>http://wiki.linuxmce.org/index.php?title=Usage_Intro&amp;diff=14830</id>
		<title>Usage Intro</title>
		<link rel="alternate" type="text/html" href="http://wiki.linuxmce.org/index.php?title=Usage_Intro&amp;diff=14830"/>
		<updated>2008-07-12T22:36:24Z</updated>

		<summary type="html">&lt;p&gt;Juanfe: /* Managing your media */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{| align=&amp;quot;right&amp;quot;&lt;br /&gt;
  | __TOC__&lt;br /&gt;
  |}&lt;br /&gt;
LinuxMCE&#039;s main concepts are [[Devices]], Commands (aka [[Scenarios]] and Activities), and [[Events]]. An  [[Orbiter]] is the device that displays the User Interface. It can be a [[Media Director|Media Station]], web pad, mobile phone, or other remote control device. The Orbiter User Interface is standardized for all Orbiters.&lt;br /&gt;
&lt;br /&gt;
== Devices ==&lt;br /&gt;
&lt;br /&gt;
A device is generally a piece of hardware or software, like the Xine Media Player, a light switch, or a mobile phone.  Devices have three functions, abbreviated &amp;quot;DCE&amp;quot; (Data, Commands, Events): &lt;br /&gt;
&lt;br /&gt;
# Retrieve configuration &#039;&#039;&#039;data&#039;&#039;&#039;&lt;br /&gt;
# Perform a &#039;&#039;&#039;command&#039;&#039;&#039; (turn on, turn off, fast forward, etc.)&lt;br /&gt;
# Report certain triggered &#039;&#039;&#039;events&#039;&#039;&#039; (e.g. &#039;motion detected&#039;, &#039;playback started&#039;, etc.)&lt;br /&gt;
&lt;br /&gt;
== Scenarios ==&lt;br /&gt;
&lt;br /&gt;
&amp;quot;[[Scenarios]]&amp;quot;, &amp;quot;Activities&amp;quot;, and &amp;quot;Command Groups&amp;quot; are interchangeable terms -- they mean the same thing.  A scenario is a group of commands that can be sent to a device (or series of devices).  In LinuxMCE, the default Orbiter main menu consists of several scenario categories, grouped by room. These categories are&lt;br /&gt;
&lt;br /&gt;
* Lighting&lt;br /&gt;
* Media&lt;br /&gt;
* Climate&lt;br /&gt;
* Telecom&lt;br /&gt;
* Security&lt;br /&gt;
&lt;br /&gt;
(These default categories are arbitrary and are set up at installation.) To perform an action in LinuxMCE, a scenario is chosen from one of these categories (located on the main menu of an Orbiter). &lt;br /&gt;
&lt;br /&gt;
For example, in rooms which have both a TV and lights, LinuxMCE automatically creates a scenario called &#039;Showtime.&#039; This scenario dims the lights to 10% whenever the TV starts playing.  In rooms with a PVR or other TV-enabled device, another scenario is created called &#039;TV&#039; (in the &#039;Media&#039; category) to start the TV.  Another scenario in the &#039;Media&#039; category called &#039;Video&#039; sends a command to the Orbiter to list your video content. Telecom scenarios are created to make phone calls. Security scenarios are created to view cameras and to arm an alarm.&lt;br /&gt;
&lt;br /&gt;
Some [[What_scenarios_are_created_automatically%3F|default scenarios]] are created for you at installation. A fully-functional system can run using only the default scenarios, if you choose. You can also change or remove the default scenarios or add new ones. This is done though the &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Wizard--&amp;gt;[[Scenarios]]&#039;&#039;&#039; menu. When creating a scenario, the [[LinuxMCE Admin Website]] will show you the most appropriate wizard, based on the category you pick.  If you&#039;re adding an activity in the lighting category, for example, the wizard will display a list of the lights in the room and let you pick which ones to turn off.  If you&#039;re creating a scenario in the security category, it will list the installed cameras and will allow you to select which ones to display.&lt;br /&gt;
&lt;br /&gt;
A scenario can send a command to any device in the system. By default, scenarios in the lighting category show you the room lights, allowing you to select which ones to which to send commands. However, from the &#039;&#039;&#039;Wizard--&amp;gt;[[Scenarios]]&#039;&#039;&#039; menu for the specific scenario, you can also specify a command to any device in your home. You could make a phone call, for example, even from a scenario in the lighting category.&lt;br /&gt;
&lt;br /&gt;
Certain scenarios are assigned to certain rooms by default. This can be customized, however. When you manually select a room from the Orbiter main menu, the default scenarios for that room are displayed. In general they control devices in that room, but this can also be changed. If your kitchen is near the garage and you want a scenario to &#039;turn off the garage light&#039;, you can assign a scenario to the room &#039;kitchen&#039; that will do just that. It doesn&#039;t matter that the light is in the garage.&lt;br /&gt;
&lt;br /&gt;
For a Media Director, the on-screen Orbiter User Interface appears on the TV screen. It is manipulated by the mouse/keyboard or remote control connected to your Media Director. By default it is set to display the scenarios for the room in which the Media Director is located.&lt;br /&gt;
&lt;br /&gt;
In contrast, a mobile Orbiter (such as a webpad) can be carried throughout the house. It must be able to select the scenarios for multiple rooms. Fortunately, the option to manually select which room you are currently in is available on every Orbiter&#039;s main menu.&lt;br /&gt;
&lt;br /&gt;
This can occasionally cause some confusion. Perhaps both the Living Room and the Bedroom have a scenario called &#039;TV&#039;. You may have a web pad that is in the Bedroom, but you then carry it to the Living Room. You may forget to tell the web pad that it&#039;s now in the Living Room (at the bottom of the Orbiter screen it will still say &#039;Bedroom&#039;). You hit the &#039;TV&#039; button expecting the Living Room TV to come on, but in fact you&#039;re still controlling the Bedroom and the TV comes on there instead. Finally you may realize that you must change your room location to Living Room, and you can then finally control the TV there.&lt;br /&gt;
&lt;br /&gt;
Once you get used to this concept, though, you&#039;ll find it very useful.  Conveniently, any Orbiter can be set to control any room and choose from the scenarios assigned to that room. No matter which Orbiter you use, the same set of scenarios will be displayed for each specific room. For example, the kitchen scenarios will always be the same, no matter which Orbiter you are using. (The scenarios are assigned by room -- not by Orbiter.) No matter whether you pick up your mobile phone, your web pad, or your remote control, you will always be shown the same list of scenario options for the Living Room.&lt;br /&gt;
&lt;br /&gt;
You have the option of preventing some family members from using certain scenarios. From the [[LinuxMCE Admin Website]], certain scenarios and rooms can be [[Users#Restrict_Access|restricted to certain users]].  Maybe little Suzy&#039;s mobile phone Orbiter should be restricted so that she is only able to control her room and the living room, for example. She would only be able to execute the scenarios in those rooms, but not the Master Bedroom. Other possible options include [[Users#Restrict_Access|requiring a pin code]] to access the scenarios for a particular room.&lt;br /&gt;
&lt;br /&gt;
== Events ==&lt;br /&gt;
&lt;br /&gt;
Devices report events, such as &#039;Playback started&#039; and &#039;Motion Sensor tripped&#039;. If you want something to happen automatically in LinuxMCE, you create Event Handlers that react to these events. For example, you can create an event handler that listens for the &#039;Motion Sensor tripped&#039; event from a motion detector and turns on the lights in response.  An event handler might listen for the &#039;Sunrise&#039; event, which could then prompt the sprinklers to come on. &lt;br /&gt;
&lt;br /&gt;
LinuxMCE creates several default event handlers. In rooms in which you have a TV and lights, an event handler is created that listens for the &#039;Watching Media&#039; event sent by a media player. When the event is detected, the Showtime scenario (which dims the lights) is executed in response.  When you start a movie, therefore, the Showtime activity will be executed and the lights will be dimmed.  There are other default event handlers that monitor for events like &#039;Security Breach&#039; and &#039;Fire Alarm&#039; (from a home security system).&lt;br /&gt;
&lt;br /&gt;
== Controlling an Orbiter ==&lt;br /&gt;
&lt;br /&gt;
To control the system, you use an [[Orbiter]], which is the LinuxMCE term for a remote control.  All [[Orbiters]] have the same basic function: to display the scenarios in the room you&#039;re in and let you select one.  The different Orbiters may [[Selecting_the_Right_UI|display the User Interface slightly differently]], depending on their screen size, but the function and the list of scenarios is always the same. For example, the [[Selecting_the_Right_UI|&amp;quot;UI1&amp;quot; interface]] (which is used on webpads and PDAs) displays the scenarios in horizontal rows. (If there are more than will fit on a row, there will be a &amp;quot;more&amp;quot; button.) A home button is always displayed that takes you to the main menu. On smaller displays, as on mobile phones or desktop phones, there&#039;s not enough room to show the scenarios themselves. The top level menu shows only the categories: Lights, Media, Climate, Security and Telecom. Selecting a category displays the scenarios in that category. &lt;br /&gt;
&lt;br /&gt;
[[Selecting_the_Right_UI|&amp;quot;UI2&amp;quot;]] is the [[Selecting_the_Right_UI|preferred User Interface]] for Media Stations.  Using a traditional I/R remote is not much different from using any other Media Center PC remote.  The menu button brings up the main menu, and you use the &#039;&#039;left/right/up/down/enter&#039;&#039; buttons to navigate it. The &#039;&#039;fast forward/rewind/skip +/skip -&#039;&#039; keys are used for media playback.&lt;br /&gt;
&lt;br /&gt;
If you have a pointing device like a mouse or gyro air mouse, the UI2 interface also supports a unique control architecture that lets you do everything with 3 (programmable) buttons (plus ok and cancel). The 3 buttons are &amp;quot;MEDIA&amp;quot;, &amp;quot;MENU&amp;quot;, &amp;quot;AMBIANCE&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
On a mouse with 3 programmable buttons (such as the [[Using_the_Gyration_Remote_GYR3101US_%28Non-Fiire_Chief%29|gyration]]), these functions correspond to the buttons from left to right. If you are using a traditional 3 button mouse, you can use the F6, F7 and F8 keys on the keyboard for the three programmable functions instead. In both cases, the left mouse button is &amp;quot;ok&amp;quot;, and the right mouse button is &amp;quot;cancel/go back&amp;quot;. &lt;br /&gt;
&lt;br /&gt;
Mouse button behavior is &amp;quot;absolute&amp;quot; when you press and hold the media/menu/ambiance button and &amp;quot;relative&amp;quot; when you tap and release.&lt;br /&gt;
&lt;br /&gt;
The &amp;quot;absolute&amp;quot; behavior is generally more efficient. For example, in the case of the middle button (F7), &amp;quot;absolute&amp;quot; behavior means the action is executed without having to additionally click &amp;quot;ok&amp;quot;.  If you press and hold the middle button (F7) while moving your mouse pointer to the option, then let go, that option is executed. If you instead tap and release the menu button (&amp;quot;relative&amp;quot; behavior), you will only highlight the menu option. You must then press ok (the left mouse button) to execute the option.&lt;br /&gt;
&lt;br /&gt;
Categories appear along the bottom of the screen, and the scenarios in each category popup vertically (like a pull-down menu in a PC, except upside down).  If the main menu isn&#039;t already visible, bring it up by pressing the &amp;quot;start&amp;quot; button on a Windows I/R remote, or the &amp;quot;menu&amp;quot; button on a 3-button mouse.  To exit a menu, use the back button on the I/R remote, the cancel button (right mouse button on a 3-button mouse), or the ESC key on a keyboard.&lt;br /&gt;
&lt;br /&gt;
In UI2 the media is always full screen. If you&#039;re not playing your own media, the background media (i.e. screensaver images) is gallery art from the Internet (using flickr) or [[Use_my_own_pictures_in_the_Screen_Saver|pictures you select]]. If only the screensaver images are displayed on the Media Station, press the menu/middle/F7 button to bring up the menu. Right click/ESC to get rid of it. (This works even if your own media is playing.)&lt;br /&gt;
&lt;br /&gt;
If you&#039;re using UI2&#039;s 3-button navigation model, the normal media control options on a traditional remote are replaced with a single button: &amp;quot;media&amp;quot; (left soft button or F6). Press this and move the pointer up and down for your skip functions (&#039;&#039;ch+, ch-, skip fwd, skip back&#039;&#039;). Move the pointer left and right for speed control (&#039;&#039;rewind, fast forward&#039;&#039;).  The further you move, the faster the media playback changes.  If you hold the button down (the left soft button or F6), your movement will be &amp;quot;absolute&amp;quot;. Instead of the traditional &amp;quot;jog shuttle-type&amp;quot; control, movement to the right skips to the end of your media, and movement to the left skips to the beginning.  Once you get used to it, you will find that navigating media is orders of magnitude faster and easier with this model than with a traditional remote. You can find a spot in a 2 hour movie in only a couple seconds with a click of a single button (compared to a slew of button clicks required using a traditional remote).&lt;br /&gt;
&lt;br /&gt;
Also, in UI2 you can press the &amp;quot;ambiance&amp;quot; button (right soft button or F8). Move up/down to adjust the lights, and left/right to adjust the volume. As with the media playback, if you hold the F8/right soft button down while you move left and right, your volume control is in &amp;quot;absolute&amp;quot; mode (not &amp;quot;relative&amp;quot;). Moving hard right turns up the volume full blast; hard left is mute.  This requires you have a TV or receiver that is serial-controlled, however. LinuxMCE can then directly and instantly set the volume position in sync with your hand movements. (Few TVs and receivers have this feature, unfortunately.)&lt;br /&gt;
&lt;br /&gt;
There are other media control functions besides the most commonly used &#039;&#039;fast fwd/rewind/skip up/skip down&#039;&#039;. You can, for example, choose &#039;subtitles&#039; while watching a DVD, &#039;guide&#039; while watching TV, and &#039;random&#039; while listening to an audio CD. In the UI2 3 button model, these functions appear on the main menu (on the left-most pad, entitled &#039;now playing&#039;) and changes according to the type of media you&#039;re playing. Press the menu button (middle button/F7) to select these options.&lt;br /&gt;
&lt;br /&gt;
This 3 button model is a new concept and very different from traditional navigation. Most people find it much faster once they become accustomed to it.&lt;br /&gt;
&lt;br /&gt;
==Reload Router &amp;amp; Regen Orbiters==&lt;br /&gt;
&lt;br /&gt;
While using LinuxMCE you&#039;ll see sometimes a message asking if you want to [[Quick reload router|reload the router]], or if you want to [[Orbiter Generator|regenerate the Orbiter UIs]] (User Interfaces). In general, these options refresh the LinuxMCE databases so that changes to the system can be recognized.&lt;br /&gt;
&lt;br /&gt;
===Reload Router===&lt;br /&gt;
All devices in LinuxMCE obtain their configuration information from the [[DCERouter]], which is the central piece of software on the Core.  All devices request a list of the other devices in the home from the router, so they can respond to them appropriately.  (For example, an IP camera device might turn on the lights in the room whenever you&#039;re viewing the camera.  To do so, the IP camera needs to know what lights are in the room.) Typically a device requests this information only when it&#039;s starting up.  When you connect additional plug and play devices to the system, these new devices generally will work immediately, but their functionality may not be fully enabled within the LinuxMCE system until the DCE router is reloaded. When the router reloads, it signals all devices on the system to simultaneously reload and re-request the system data. Each existing device can then work with each new device.  This process is known as a &#039;reload&#039;.  It generally takes about 10 seconds.  Every time you add or remove devices, or change a device&#039;s configuration, you may be asked to do a reload. If you&#039;re going to add more devices or make more device changes, you can do the reload once you&#039;re done. If you&#039;re in the middle of watching a movie or TV, you can postpone the reload, since media players generally stop playing during reloads.  Phone calls aren&#039;t affected, though, and TV shows being recorded by MythTV in the background are also unaffected.&lt;br /&gt;
&lt;br /&gt;
===Regen the Orbiter===&lt;br /&gt;
LinuxMCE&#039;s [[Selecting_the_Right_UI|Orbiter User Interfaces]] are all &amp;quot;pre-rendered&amp;quot; in order to be more efficient.  The User Interface source images are all very high resolution, but need to be resized to accommodate the resolution of each Orbiter screen. The Core server has a list of the Orbiters used by your system, and will generate the appropriate User Interface screen for each Orbiter. It will do this each time you request a &amp;quot;regen&amp;quot;. If you have five different types of Orbiters (each with a different type of screen), then five different images will be generated during each regen.&lt;br /&gt;
&lt;br /&gt;
These User Interface screen images are stored in the Core. The appropriate UI image is sent to an Orbiter whenever it is activated. For many low-power devices (like mobile phones or desktop phones) there just isn&#039;t the processing power to do scaling and rendering of a User Interface screen on the fly. They need to be pre-rendered (with text pre-embedded in the images) to be efficient.&lt;br /&gt;
&lt;br /&gt;
Adding new scenarios may result in the creation of new buttons for the User Interface, or changes to the text on existing buttons. Perhaps an entirely new screen will be created.&lt;br /&gt;
&lt;br /&gt;
Until the User Interface images are regenerated, though, you won&#039;t be able to see these new buttons (or screens) on your Orbiter. During the regen, new User Interface images for each type of Orbiter is generated by the Core. This can take about 2-5 minutes, depending on how many Orbiter types you have in your system.&lt;br /&gt;
&lt;br /&gt;
You needn&#039;t do a regen every time you add a scenario. You can wait until you have finished adding all the scenarios. Furthermore, you can also regen only the Orbiter you are currently using by doing a &amp;quot;Quick regen&amp;quot;. This allows you to see the new User Interface (following the addition of new scenarios) without having to do a full regen for all the Orbiters. Once you have finished adding scenarios, then you can do a full regen.&lt;br /&gt;
&lt;br /&gt;
This regen process can be a bit annoying, but is necessary. In future editions of LinuxMCE, it is planned to allow Media Directors, which have a lot more processing power, to render their on-screen Orbiter User Interfaces on the fly (so you don&#039;t have to do a regen each time you add or remove a scenario).&lt;br /&gt;
&lt;br /&gt;
You can do a [[Orbiter Generator#Running OrbiterGen (performing a &amp;quot;regen&amp;quot;)|full Orbiter regen or a Quick regen]] at any time by using buttons on the Core&#039;s LinuxMCE [[Launch Manager]].&lt;br /&gt;
&lt;br /&gt;
= Media Management =&lt;br /&gt;
==Managing your media==&lt;br /&gt;
LinuxMCE is always scanning for network shares, on Network-Attached Storage (NAS) devices and other Hard Disk Drives (HDDs) of PCs connected to the system (including Windows PCs). Universal Serial Bus (USB) drives are also detected. Every time a LinuxMCE finds a network share, you will be asked if you would like to use it. Whenever you reply &amp;quot;Yes&amp;quot;, the file share can be used by any Media Director on the system. The file share is scanned for media, such as audio, video and photos, and any that are found are then cataloged in the Core&#039;s central database. For example, when you plug in a USB drive on a Media Station in the living room and tell LinuxMCE to use it, the media on the drive will be available to Media Directors in other rooms.&lt;br /&gt;
&lt;br /&gt;
At the moment there is no way to restrict your media for &#039;local use only&#039;; all Media Stations in the LinuxMCE system share the media catalog stored on the Core.  (This is a limitation that will be addressed in the near future. Sometimes it is desirable to attach a USB drive in the master bedroom and not allow it to be shared, for example. &#039;&#039;Note: However, see [[folder lock|this article that describes a method to address this problem]].&#039;&#039;)&lt;br /&gt;
&lt;br /&gt;
Storage devices (NAS, USB drives, extra HDDs on the Core or Media Directors) are referred to as &amp;quot;Extra Drives&amp;quot;.  When an extra drive is added, it is listed in the device tree in &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Advanced--&amp;gt;Configuration--&amp;gt;[[Devices]]&#039;&#039;&#039;.  Under &#039;Core&#039; you&#039;ll see a device listed for each HDD in the Core, as well as for each NAS device. Under each Media Station will be listed the HDDs in that Media Station.  By clicking on the device you can change the device&#039;s properties, such as the mount username/password.  Each NAS device, and each file share on another PC, will show as a device listed under the Core; each is considered a child of the Core.&lt;br /&gt;
&lt;br /&gt;
==Access control for shared media==&lt;br /&gt;
LinuxMCE creates a top level folder for &#039;public&#039; media. This folder can be used by every user in the system.  A &#039;private&#039; media folder is also created for each user.  Within each of those folders are sub-folders, labeled &#039;audio&#039;, &#039;video&#039;, &#039;pictures&#039;, &#039;data&#039; and &#039;other&#039;.  Within each of those will also be sub-folders for the extra storage devices (NAS, USB, extra internal drives, etc).  When you attach an extra storage device, you can specify whether the default directory structure should be used for it. Alternatively, you can specify &#039;just make it public&#039; or &#039;make it private&#039;.&lt;br /&gt;
&lt;br /&gt;
Here&#039;s an example.  Let&#039;s say you have 2 users: john and mary.  You connect 3 storage devices:&lt;br /&gt;
# a NAS, for which you specify &#039;use default directory structure&#039;. It is named &#039;Generic Network Storage [50]&#039;&lt;br /&gt;
# a USB drive for which you specify &#039;make it all public&#039;. It is named &#039;USB Drive [51]&#039;&lt;br /&gt;
# a SATA drive for which you choose &#039;make it private for john&#039;. It is named &#039;General Internal HDD [52]&lt;br /&gt;
&lt;br /&gt;
Now let&#039;s say you&#039;re running Windows. Go to Network Neighborhood and find the LinuxMCE Core server.  The directory tree ought to look like this:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
public&lt;br /&gt;
  video&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  audio&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  pictures&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  data&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  other&lt;br /&gt;
    USB Drive [51]&lt;br /&gt;
john&lt;br /&gt;
  video&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  audio&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  pictures&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  data&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  other&lt;br /&gt;
    General Internal HDD [52]&lt;br /&gt;
mary&lt;br /&gt;
  video&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  audio&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  pictures&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  data&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  other&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Whether you put your media under video, audio, pictures, data or other is unimportant.  It will be scanned by LinuxMCE anyway. The contents of &amp;quot;General Internal HDD [52]&amp;quot; will be displayed in the folder john/other/General Internal HDD [52]. The contents of USB Drive [51] will be displayed in the folder public/other/USB Drive [51].  When John browses the contents in Network Neighborhood, he will be asked for his username and password. He can then access the content in both the public folder as well as the &amp;quot;john&amp;quot; folders (including General Internal HDD [52]).  When Mary browses the contents with her username and password, she will see both the public and &amp;quot;mary&amp;quot; folders. She will not be able to see anything on General Internal HDD [52], however, since that drive was specified to be private for John.&lt;br /&gt;
&lt;br /&gt;
In the case of John&#039;s private media, it won&#039;t be displayed in the LinuxMCE media browser unless you click &#039;Sources&#039;--&amp;gt;&#039;John&#039;. However you &#039;&#039;can&#039;&#039; see the contents of General Internal HDD [52] (unless you deselect &#039;Sources&#039;--&amp;gt;&#039;Public&#039; from the media browser).  Generic Network Storage [50] would be different, however, since you specified to use the default directory structure for it.  LinuxMCE will have created public directories on Generic Network Storage [50] for public video and public audio, as well as for john&#039;s video and mary&#039;s audio. The media file browser will show only the media that is in the public directories. (The same is true with the Windows Network Neighborhood browser.) &lt;br /&gt;
&lt;br /&gt;
If Generic Network Storage [50] has existing media in the top (root) folder, you won&#039;t see it listed anywhere.&lt;br /&gt;
&lt;br /&gt;
It is generally recommended, therefore, that when you add a new (blank) &amp;quot;extra&amp;quot; storage device, you choose to use the default directory structure on it.  When you rip media to that device, the media can then be made either public or private, and LinuxMCE will automatically put it in the correct folder (audio, video, etc.).&lt;br /&gt;
&lt;br /&gt;
If you connect an extra storage device that already has media on it, however, and that media isn&#039;t already organized in LinuxMCE&#039;s default directory structure, it&#039;s easiest if you simply &#039;make it all public&#039; or &#039;make it all private&#039;. If you were to &#039;use the default directory structure&#039;, you would need to manually move the files from the existing folders into one of the directory folders that LinuxMCE would then create for you.&lt;br /&gt;
&lt;br /&gt;
When you rip files, you have the option of copying them to the Core.  If you rip a CD and make it public, it will be stored in public/audio.  If you go into Network Neighborhood and add a folder under public/audio, you would essentially be adding a folder on the Core. If you add a folder under public/audio/Generic Network Storage [50], you would be adding it to Generic Network Storage [50].&lt;br /&gt;
&lt;br /&gt;
==Drive and network drive management==&lt;br /&gt;
This concept behind drive/network drive management is not the same as the method to which Linux and Windows users are accustomed. In Windows, for example, each network device shows up separately; they are never grouped together.  There is an advantage to the way LinuxMCE manages drives. It&#039;s much simpler to add devices when you&#039;re a novice and don&#039;t understand networking. Further, if you&#039;re using an infrared remote control, you can manage drives with a single &#039;yes&#039; or &#039;no,&#039; click, which is very convenient. Lastly, all your media content is cataloged and presented in the same structure throughout the system, no matter which Media Director you&#039;re using or what room you&#039;re in.&lt;br /&gt;
&lt;br /&gt;
In Windows, by comparison, if you connect a USB drive to a Windows PC in the bedroom, you won&#039;t see that content in the living room unless you 1) open file explorer, 2) create a new network share for it, 3) go into the living room, and 4) create a new mapped network drive there. (That isn&#039;t so easy to do with an infrared remote and without some knowledge of networking.)  Further, you wouldn&#039;t be able to see the media in any other room in the house unless you were to also create mapped network shares in those rooms as well. &lt;br /&gt;
&lt;br /&gt;
With LinuxMCE, when you connect a USB drive, for example, you can &#039;make it all public&#039;; the media will be available everywhere. No other typing is required. With LinuxMCE, instead of managing multiple network shares and mapped drives, you can choose the Core&#039;s public folders in the Network Neighborhood browser from anywhere in the home, without having to know which storage devices the media is actually on.  When you remove a USB drive from a Media Station, that media instantly disappears from the catalog displayed in every room. If you reattach it, it will re-appear.&lt;br /&gt;
&lt;br /&gt;
You can also backup the media securely on the Core. LinuxMCE has built-in [http://en.wikipedia.org/wiki/RAID RAID] 5 (see &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Advanced--&amp;gt;[[RAID]]&#039;&#039;&#039;), so its HDD has similar backup capabilities to a [[NAS]] device.&lt;br /&gt;
&lt;br /&gt;
To change the name of an extra device, go to the &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Advanced--&amp;gt;Configuration--&amp;gt;[[Devices]]&#039;&#039;&#039; and under the Core you will see listed the HDDs in the core and any connected NAS devices. Under each Media Station you will see the HDDs in that Media Station. All are given default names.  You can change the description, which will also change the folder name.  In the above example, changing &amp;quot;USB Drive [51]&amp;quot; to &amp;quot;Tokyo&amp;quot; means the directory public/other/USB Drive [51] would change to public/other/Tokyo.&lt;br /&gt;
&lt;br /&gt;
You can see a list of the files in the system by folder In the &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Files &amp;amp; Media--&amp;gt;[[Media Files Sync]]&#039;&#039;&#039; menu.  If a file is shown with a check box, the file exists both on the local disk as well as in LinuxMCE&#039;s master catalog.  If it has a different icon, then LinuxMCE hasn&#039;t finished cataloging the media; just be patient. It should appear with a check mark soon (depending on how much new media was added). &lt;br /&gt;
&lt;br /&gt;
Use this interface to manage change cover art and attributes. Under Files &amp;amp; Media there is also a cover art scan utility that will find cover art, as well as other attributes (actor, genre, etc.) obtained from Amazon.&lt;br /&gt;
&lt;br /&gt;
==Linux operational details of network and disk mounts==&lt;br /&gt;
[[UpdateMedia]] is a daemon that constantly scans for media files in the /home/public and the /home/user_xxx folder created for each user. Any added media is cataloged in the pluto_media database File table, and attributes and cover art go into the Attribute and Picture tables.  Under /home/public and /home/users_xxx is a data subfolder which contains the actual video, audio, pictures folders.  (The /home/user_xxx directories themselves contain the system files for each user (like email boxes) as well as the main login for that user (in a &amp;quot;data&amp;quot; subfolder).&lt;br /&gt;
&lt;br /&gt;
Extra devices are mounted as /mnt/device/xxx (where xxx is the device number).  The mount point is the same whether it&#039;s a local drive or not.  For example, USB drive [50] in a Media Station may be mounted as a local device named /mnt/device/50, but is also mounted as a Samba mount on other Media Stations as /mnt/device/50.  The Core and the Media Stations all use the same mount names (/mnt/device/).&lt;br /&gt;
&lt;br /&gt;
Within the /home/public/data and /home/user_xxx/data are symlinks to the physical directories specified by /mnt/device/xxx.  Since the Core and all Media Stations mount the same /home directory (and all have the same /mnt/device mounts), they will all show the same files.  Therefore, if the [[UpdateMedia]] daemon locates the file /home/public/data/audio/Generic Internal Drive [50]/The Beatles/Let it be.mp3, that file will be listed on every Media Station, too.&lt;br /&gt;
&lt;br /&gt;
[[Category: Tutorials]]&lt;/div&gt;</summary>
		<author><name>Juanfe</name></author>
	</entry>
	<entry>
		<id>http://wiki.linuxmce.org/index.php?title=Usage_Intro&amp;diff=14829</id>
		<title>Usage Intro</title>
		<link rel="alternate" type="text/html" href="http://wiki.linuxmce.org/index.php?title=Usage_Intro&amp;diff=14829"/>
		<updated>2008-07-12T22:35:19Z</updated>

		<summary type="html">&lt;p&gt;Juanfe: /* Background and Linux operational details */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{| align=&amp;quot;right&amp;quot;&lt;br /&gt;
  | __TOC__&lt;br /&gt;
  |}&lt;br /&gt;
LinuxMCE&#039;s main concepts are [[Devices]], Commands (aka [[Scenarios]] and Activities), and [[Events]]. An  [[Orbiter]] is the device that displays the User Interface. It can be a [[Media Director|Media Station]], web pad, mobile phone, or other remote control device. The Orbiter User Interface is standardized for all Orbiters.&lt;br /&gt;
&lt;br /&gt;
== Devices ==&lt;br /&gt;
&lt;br /&gt;
A device is generally a piece of hardware or software, like the Xine Media Player, a light switch, or a mobile phone.  Devices have three functions, abbreviated &amp;quot;DCE&amp;quot; (Data, Commands, Events): &lt;br /&gt;
&lt;br /&gt;
# Retrieve configuration &#039;&#039;&#039;data&#039;&#039;&#039;&lt;br /&gt;
# Perform a &#039;&#039;&#039;command&#039;&#039;&#039; (turn on, turn off, fast forward, etc.)&lt;br /&gt;
# Report certain triggered &#039;&#039;&#039;events&#039;&#039;&#039; (e.g. &#039;motion detected&#039;, &#039;playback started&#039;, etc.)&lt;br /&gt;
&lt;br /&gt;
== Scenarios ==&lt;br /&gt;
&lt;br /&gt;
&amp;quot;[[Scenarios]]&amp;quot;, &amp;quot;Activities&amp;quot;, and &amp;quot;Command Groups&amp;quot; are interchangeable terms -- they mean the same thing.  A scenario is a group of commands that can be sent to a device (or series of devices).  In LinuxMCE, the default Orbiter main menu consists of several scenario categories, grouped by room. These categories are&lt;br /&gt;
&lt;br /&gt;
* Lighting&lt;br /&gt;
* Media&lt;br /&gt;
* Climate&lt;br /&gt;
* Telecom&lt;br /&gt;
* Security&lt;br /&gt;
&lt;br /&gt;
(These default categories are arbitrary and are set up at installation.) To perform an action in LinuxMCE, a scenario is chosen from one of these categories (located on the main menu of an Orbiter). &lt;br /&gt;
&lt;br /&gt;
For example, in rooms which have both a TV and lights, LinuxMCE automatically creates a scenario called &#039;Showtime.&#039; This scenario dims the lights to 10% whenever the TV starts playing.  In rooms with a PVR or other TV-enabled device, another scenario is created called &#039;TV&#039; (in the &#039;Media&#039; category) to start the TV.  Another scenario in the &#039;Media&#039; category called &#039;Video&#039; sends a command to the Orbiter to list your video content. Telecom scenarios are created to make phone calls. Security scenarios are created to view cameras and to arm an alarm.&lt;br /&gt;
&lt;br /&gt;
Some [[What_scenarios_are_created_automatically%3F|default scenarios]] are created for you at installation. A fully-functional system can run using only the default scenarios, if you choose. You can also change or remove the default scenarios or add new ones. This is done though the &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Wizard--&amp;gt;[[Scenarios]]&#039;&#039;&#039; menu. When creating a scenario, the [[LinuxMCE Admin Website]] will show you the most appropriate wizard, based on the category you pick.  If you&#039;re adding an activity in the lighting category, for example, the wizard will display a list of the lights in the room and let you pick which ones to turn off.  If you&#039;re creating a scenario in the security category, it will list the installed cameras and will allow you to select which ones to display.&lt;br /&gt;
&lt;br /&gt;
A scenario can send a command to any device in the system. By default, scenarios in the lighting category show you the room lights, allowing you to select which ones to which to send commands. However, from the &#039;&#039;&#039;Wizard--&amp;gt;[[Scenarios]]&#039;&#039;&#039; menu for the specific scenario, you can also specify a command to any device in your home. You could make a phone call, for example, even from a scenario in the lighting category.&lt;br /&gt;
&lt;br /&gt;
Certain scenarios are assigned to certain rooms by default. This can be customized, however. When you manually select a room from the Orbiter main menu, the default scenarios for that room are displayed. In general they control devices in that room, but this can also be changed. If your kitchen is near the garage and you want a scenario to &#039;turn off the garage light&#039;, you can assign a scenario to the room &#039;kitchen&#039; that will do just that. It doesn&#039;t matter that the light is in the garage.&lt;br /&gt;
&lt;br /&gt;
For a Media Director, the on-screen Orbiter User Interface appears on the TV screen. It is manipulated by the mouse/keyboard or remote control connected to your Media Director. By default it is set to display the scenarios for the room in which the Media Director is located.&lt;br /&gt;
&lt;br /&gt;
In contrast, a mobile Orbiter (such as a webpad) can be carried throughout the house. It must be able to select the scenarios for multiple rooms. Fortunately, the option to manually select which room you are currently in is available on every Orbiter&#039;s main menu.&lt;br /&gt;
&lt;br /&gt;
This can occasionally cause some confusion. Perhaps both the Living Room and the Bedroom have a scenario called &#039;TV&#039;. You may have a web pad that is in the Bedroom, but you then carry it to the Living Room. You may forget to tell the web pad that it&#039;s now in the Living Room (at the bottom of the Orbiter screen it will still say &#039;Bedroom&#039;). You hit the &#039;TV&#039; button expecting the Living Room TV to come on, but in fact you&#039;re still controlling the Bedroom and the TV comes on there instead. Finally you may realize that you must change your room location to Living Room, and you can then finally control the TV there.&lt;br /&gt;
&lt;br /&gt;
Once you get used to this concept, though, you&#039;ll find it very useful.  Conveniently, any Orbiter can be set to control any room and choose from the scenarios assigned to that room. No matter which Orbiter you use, the same set of scenarios will be displayed for each specific room. For example, the kitchen scenarios will always be the same, no matter which Orbiter you are using. (The scenarios are assigned by room -- not by Orbiter.) No matter whether you pick up your mobile phone, your web pad, or your remote control, you will always be shown the same list of scenario options for the Living Room.&lt;br /&gt;
&lt;br /&gt;
You have the option of preventing some family members from using certain scenarios. From the [[LinuxMCE Admin Website]], certain scenarios and rooms can be [[Users#Restrict_Access|restricted to certain users]].  Maybe little Suzy&#039;s mobile phone Orbiter should be restricted so that she is only able to control her room and the living room, for example. She would only be able to execute the scenarios in those rooms, but not the Master Bedroom. Other possible options include [[Users#Restrict_Access|requiring a pin code]] to access the scenarios for a particular room.&lt;br /&gt;
&lt;br /&gt;
== Events ==&lt;br /&gt;
&lt;br /&gt;
Devices report events, such as &#039;Playback started&#039; and &#039;Motion Sensor tripped&#039;. If you want something to happen automatically in LinuxMCE, you create Event Handlers that react to these events. For example, you can create an event handler that listens for the &#039;Motion Sensor tripped&#039; event from a motion detector and turns on the lights in response.  An event handler might listen for the &#039;Sunrise&#039; event, which could then prompt the sprinklers to come on. &lt;br /&gt;
&lt;br /&gt;
LinuxMCE creates several default event handlers. In rooms in which you have a TV and lights, an event handler is created that listens for the &#039;Watching Media&#039; event sent by a media player. When the event is detected, the Showtime scenario (which dims the lights) is executed in response.  When you start a movie, therefore, the Showtime activity will be executed and the lights will be dimmed.  There are other default event handlers that monitor for events like &#039;Security Breach&#039; and &#039;Fire Alarm&#039; (from a home security system).&lt;br /&gt;
&lt;br /&gt;
== Controlling an Orbiter ==&lt;br /&gt;
&lt;br /&gt;
To control the system, you use an [[Orbiter]], which is the LinuxMCE term for a remote control.  All [[Orbiters]] have the same basic function: to display the scenarios in the room you&#039;re in and let you select one.  The different Orbiters may [[Selecting_the_Right_UI|display the User Interface slightly differently]], depending on their screen size, but the function and the list of scenarios is always the same. For example, the [[Selecting_the_Right_UI|&amp;quot;UI1&amp;quot; interface]] (which is used on webpads and PDAs) displays the scenarios in horizontal rows. (If there are more than will fit on a row, there will be a &amp;quot;more&amp;quot; button.) A home button is always displayed that takes you to the main menu. On smaller displays, as on mobile phones or desktop phones, there&#039;s not enough room to show the scenarios themselves. The top level menu shows only the categories: Lights, Media, Climate, Security and Telecom. Selecting a category displays the scenarios in that category. &lt;br /&gt;
&lt;br /&gt;
[[Selecting_the_Right_UI|&amp;quot;UI2&amp;quot;]] is the [[Selecting_the_Right_UI|preferred User Interface]] for Media Stations.  Using a traditional I/R remote is not much different from using any other Media Center PC remote.  The menu button brings up the main menu, and you use the &#039;&#039;left/right/up/down/enter&#039;&#039; buttons to navigate it. The &#039;&#039;fast forward/rewind/skip +/skip -&#039;&#039; keys are used for media playback.&lt;br /&gt;
&lt;br /&gt;
If you have a pointing device like a mouse or gyro air mouse, the UI2 interface also supports a unique control architecture that lets you do everything with 3 (programmable) buttons (plus ok and cancel). The 3 buttons are &amp;quot;MEDIA&amp;quot;, &amp;quot;MENU&amp;quot;, &amp;quot;AMBIANCE&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
On a mouse with 3 programmable buttons (such as the [[Using_the_Gyration_Remote_GYR3101US_%28Non-Fiire_Chief%29|gyration]]), these functions correspond to the buttons from left to right. If you are using a traditional 3 button mouse, you can use the F6, F7 and F8 keys on the keyboard for the three programmable functions instead. In both cases, the left mouse button is &amp;quot;ok&amp;quot;, and the right mouse button is &amp;quot;cancel/go back&amp;quot;. &lt;br /&gt;
&lt;br /&gt;
Mouse button behavior is &amp;quot;absolute&amp;quot; when you press and hold the media/menu/ambiance button and &amp;quot;relative&amp;quot; when you tap and release.&lt;br /&gt;
&lt;br /&gt;
The &amp;quot;absolute&amp;quot; behavior is generally more efficient. For example, in the case of the middle button (F7), &amp;quot;absolute&amp;quot; behavior means the action is executed without having to additionally click &amp;quot;ok&amp;quot;.  If you press and hold the middle button (F7) while moving your mouse pointer to the option, then let go, that option is executed. If you instead tap and release the menu button (&amp;quot;relative&amp;quot; behavior), you will only highlight the menu option. You must then press ok (the left mouse button) to execute the option.&lt;br /&gt;
&lt;br /&gt;
Categories appear along the bottom of the screen, and the scenarios in each category popup vertically (like a pull-down menu in a PC, except upside down).  If the main menu isn&#039;t already visible, bring it up by pressing the &amp;quot;start&amp;quot; button on a Windows I/R remote, or the &amp;quot;menu&amp;quot; button on a 3-button mouse.  To exit a menu, use the back button on the I/R remote, the cancel button (right mouse button on a 3-button mouse), or the ESC key on a keyboard.&lt;br /&gt;
&lt;br /&gt;
In UI2 the media is always full screen. If you&#039;re not playing your own media, the background media (i.e. screensaver images) is gallery art from the Internet (using flickr) or [[Use_my_own_pictures_in_the_Screen_Saver|pictures you select]]. If only the screensaver images are displayed on the Media Station, press the menu/middle/F7 button to bring up the menu. Right click/ESC to get rid of it. (This works even if your own media is playing.)&lt;br /&gt;
&lt;br /&gt;
If you&#039;re using UI2&#039;s 3-button navigation model, the normal media control options on a traditional remote are replaced with a single button: &amp;quot;media&amp;quot; (left soft button or F6). Press this and move the pointer up and down for your skip functions (&#039;&#039;ch+, ch-, skip fwd, skip back&#039;&#039;). Move the pointer left and right for speed control (&#039;&#039;rewind, fast forward&#039;&#039;).  The further you move, the faster the media playback changes.  If you hold the button down (the left soft button or F6), your movement will be &amp;quot;absolute&amp;quot;. Instead of the traditional &amp;quot;jog shuttle-type&amp;quot; control, movement to the right skips to the end of your media, and movement to the left skips to the beginning.  Once you get used to it, you will find that navigating media is orders of magnitude faster and easier with this model than with a traditional remote. You can find a spot in a 2 hour movie in only a couple seconds with a click of a single button (compared to a slew of button clicks required using a traditional remote).&lt;br /&gt;
&lt;br /&gt;
Also, in UI2 you can press the &amp;quot;ambiance&amp;quot; button (right soft button or F8). Move up/down to adjust the lights, and left/right to adjust the volume. As with the media playback, if you hold the F8/right soft button down while you move left and right, your volume control is in &amp;quot;absolute&amp;quot; mode (not &amp;quot;relative&amp;quot;). Moving hard right turns up the volume full blast; hard left is mute.  This requires you have a TV or receiver that is serial-controlled, however. LinuxMCE can then directly and instantly set the volume position in sync with your hand movements. (Few TVs and receivers have this feature, unfortunately.)&lt;br /&gt;
&lt;br /&gt;
There are other media control functions besides the most commonly used &#039;&#039;fast fwd/rewind/skip up/skip down&#039;&#039;. You can, for example, choose &#039;subtitles&#039; while watching a DVD, &#039;guide&#039; while watching TV, and &#039;random&#039; while listening to an audio CD. In the UI2 3 button model, these functions appear on the main menu (on the left-most pad, entitled &#039;now playing&#039;) and changes according to the type of media you&#039;re playing. Press the menu button (middle button/F7) to select these options.&lt;br /&gt;
&lt;br /&gt;
This 3 button model is a new concept and very different from traditional navigation. Most people find it much faster once they become accustomed to it.&lt;br /&gt;
&lt;br /&gt;
==Reload Router &amp;amp; Regen Orbiters==&lt;br /&gt;
&lt;br /&gt;
While using LinuxMCE you&#039;ll see sometimes a message asking if you want to [[Quick reload router|reload the router]], or if you want to [[Orbiter Generator|regenerate the Orbiter UIs]] (User Interfaces). In general, these options refresh the LinuxMCE databases so that changes to the system can be recognized.&lt;br /&gt;
&lt;br /&gt;
===Reload Router===&lt;br /&gt;
All devices in LinuxMCE obtain their configuration information from the [[DCERouter]], which is the central piece of software on the Core.  All devices request a list of the other devices in the home from the router, so they can respond to them appropriately.  (For example, an IP camera device might turn on the lights in the room whenever you&#039;re viewing the camera.  To do so, the IP camera needs to know what lights are in the room.) Typically a device requests this information only when it&#039;s starting up.  When you connect additional plug and play devices to the system, these new devices generally will work immediately, but their functionality may not be fully enabled within the LinuxMCE system until the DCE router is reloaded. When the router reloads, it signals all devices on the system to simultaneously reload and re-request the system data. Each existing device can then work with each new device.  This process is known as a &#039;reload&#039;.  It generally takes about 10 seconds.  Every time you add or remove devices, or change a device&#039;s configuration, you may be asked to do a reload. If you&#039;re going to add more devices or make more device changes, you can do the reload once you&#039;re done. If you&#039;re in the middle of watching a movie or TV, you can postpone the reload, since media players generally stop playing during reloads.  Phone calls aren&#039;t affected, though, and TV shows being recorded by MythTV in the background are also unaffected.&lt;br /&gt;
&lt;br /&gt;
===Regen the Orbiter===&lt;br /&gt;
LinuxMCE&#039;s [[Selecting_the_Right_UI|Orbiter User Interfaces]] are all &amp;quot;pre-rendered&amp;quot; in order to be more efficient.  The User Interface source images are all very high resolution, but need to be resized to accommodate the resolution of each Orbiter screen. The Core server has a list of the Orbiters used by your system, and will generate the appropriate User Interface screen for each Orbiter. It will do this each time you request a &amp;quot;regen&amp;quot;. If you have five different types of Orbiters (each with a different type of screen), then five different images will be generated during each regen.&lt;br /&gt;
&lt;br /&gt;
These User Interface screen images are stored in the Core. The appropriate UI image is sent to an Orbiter whenever it is activated. For many low-power devices (like mobile phones or desktop phones) there just isn&#039;t the processing power to do scaling and rendering of a User Interface screen on the fly. They need to be pre-rendered (with text pre-embedded in the images) to be efficient.&lt;br /&gt;
&lt;br /&gt;
Adding new scenarios may result in the creation of new buttons for the User Interface, or changes to the text on existing buttons. Perhaps an entirely new screen will be created.&lt;br /&gt;
&lt;br /&gt;
Until the User Interface images are regenerated, though, you won&#039;t be able to see these new buttons (or screens) on your Orbiter. During the regen, new User Interface images for each type of Orbiter is generated by the Core. This can take about 2-5 minutes, depending on how many Orbiter types you have in your system.&lt;br /&gt;
&lt;br /&gt;
You needn&#039;t do a regen every time you add a scenario. You can wait until you have finished adding all the scenarios. Furthermore, you can also regen only the Orbiter you are currently using by doing a &amp;quot;Quick regen&amp;quot;. This allows you to see the new User Interface (following the addition of new scenarios) without having to do a full regen for all the Orbiters. Once you have finished adding scenarios, then you can do a full regen.&lt;br /&gt;
&lt;br /&gt;
This regen process can be a bit annoying, but is necessary. In future editions of LinuxMCE, it is planned to allow Media Directors, which have a lot more processing power, to render their on-screen Orbiter User Interfaces on the fly (so you don&#039;t have to do a regen each time you add or remove a scenario).&lt;br /&gt;
&lt;br /&gt;
You can do a [[Orbiter Generator#Running OrbiterGen (performing a &amp;quot;regen&amp;quot;)|full Orbiter regen or a Quick regen]] at any time by using buttons on the Core&#039;s LinuxMCE [[Launch Manager]].&lt;br /&gt;
&lt;br /&gt;
== Managing your media ==&lt;br /&gt;
&lt;br /&gt;
LinuxMCE is always scanning for network shares, on Network-Attached Storage (NAS) devices and other Hard Disk Drives (HDDs) of PCs connected to the system (including Windows PCs). Universal Serial Bus (USB) drives are also detected. Every time a LinuxMCE finds a network share, you will be asked if you would like to use it. Whenever you reply &amp;quot;Yes&amp;quot;, the file share can be used by any Media Director on the system. The file share is scanned for media, such as audio, video and photos, and any that are found are then cataloged in the Core&#039;s central database. For example, when you plug in a USB drive on a Media Station in the living room and tell LinuxMCE to use it, the media on the drive will be available to Media Directors in other rooms.&lt;br /&gt;
&lt;br /&gt;
At the moment there is no way to restrict your media for &#039;local use only&#039;; all Media Stations in the LinuxMCE system share the media catalog stored on the Core.  (This is a limitation that will be addressed in the near future. Sometimes it is desirable to attach a USB drive in the master bedroom and not allow it to be shared, for example. &#039;&#039;Note: However, see [[folder lock|this article that describes a method to address this problem]].&#039;&#039;)&lt;br /&gt;
&lt;br /&gt;
Storage devices (NAS, USB drives, extra HDDs on the Core or Media Directors) are referred to as &amp;quot;Extra Drives&amp;quot;.  When an extra drive is added, it is listed in the device tree in &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Advanced--&amp;gt;Configuration--&amp;gt;[[Devices]]&#039;&#039;&#039;.  Under &#039;Core&#039; you&#039;ll see a device listed for each HDD in the Core, as well as for each NAS device. Under each Media Station will be listed the HDDs in that Media Station.  By clicking on the device you can change the device&#039;s properties, such as the mount username/password.  Each NAS device, and each file share on another PC, will show as a device listed under the Core; each is considered a child of the Core.&lt;br /&gt;
&lt;br /&gt;
===Access control for shared media===&lt;br /&gt;
LinuxMCE creates a top level folder for &#039;public&#039; media. This folder can be used by every user in the system.  A &#039;private&#039; media folder is also created for each user.  Within each of those folders are sub-folders, labeled &#039;audio&#039;, &#039;video&#039;, &#039;pictures&#039;, &#039;data&#039; and &#039;other&#039;.  Within each of those will also be sub-folders for the extra storage devices (NAS, USB, extra internal drives, etc).  When you attach an extra storage device, you can specify whether the default directory structure should be used for it. Alternatively, you can specify &#039;just make it public&#039; or &#039;make it private&#039;.&lt;br /&gt;
&lt;br /&gt;
Here&#039;s an example.  Let&#039;s say you have 2 users: john and mary.  You connect 3 storage devices:&lt;br /&gt;
# a NAS, for which you specify &#039;use default directory structure&#039;. It is named &#039;Generic Network Storage [50]&#039;&lt;br /&gt;
# a USB drive for which you specify &#039;make it all public&#039;. It is named &#039;USB Drive [51]&#039;&lt;br /&gt;
# a SATA drive for which you choose &#039;make it private for john&#039;. It is named &#039;General Internal HDD [52]&lt;br /&gt;
&lt;br /&gt;
Now let&#039;s say you&#039;re running Windows. Go to Network Neighborhood and find the LinuxMCE Core server.  The directory tree ought to look like this:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
public&lt;br /&gt;
  video&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  audio&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  pictures&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  data&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  other&lt;br /&gt;
    USB Drive [51]&lt;br /&gt;
john&lt;br /&gt;
  video&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  audio&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  pictures&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  data&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  other&lt;br /&gt;
    General Internal HDD [52]&lt;br /&gt;
mary&lt;br /&gt;
  video&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  audio&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  pictures&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  data&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  other&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Whether you put your media under video, audio, pictures, data or other is unimportant.  It will be scanned by LinuxMCE anyway. The contents of &amp;quot;General Internal HDD [52]&amp;quot; will be displayed in the folder john/other/General Internal HDD [52]. The contents of USB Drive [51] will be displayed in the folder public/other/USB Drive [51].  When John browses the contents in Network Neighborhood, he will be asked for his username and password. He can then access the content in both the public folder as well as the &amp;quot;john&amp;quot; folders (including General Internal HDD [52]).  When Mary browses the contents with her username and password, she will see both the public and &amp;quot;mary&amp;quot; folders. She will not be able to see anything on General Internal HDD [52], however, since that drive was specified to be private for John.&lt;br /&gt;
&lt;br /&gt;
In the case of John&#039;s private media, it won&#039;t be displayed in the LinuxMCE media browser unless you click &#039;Sources&#039;--&amp;gt;&#039;John&#039;. However you &#039;&#039;can&#039;&#039; see the contents of General Internal HDD [52] (unless you deselect &#039;Sources&#039;--&amp;gt;&#039;Public&#039; from the media browser).  Generic Network Storage [50] would be different, however, since you specified to use the default directory structure for it.  LinuxMCE will have created public directories on Generic Network Storage [50] for public video and public audio, as well as for john&#039;s video and mary&#039;s audio. The media file browser will show only the media that is in the public directories. (The same is true with the Windows Network Neighborhood browser.) &lt;br /&gt;
&lt;br /&gt;
If Generic Network Storage [50] has existing media in the top (root) folder, you won&#039;t see it listed anywhere.&lt;br /&gt;
&lt;br /&gt;
It is generally recommended, therefore, that when you add a new (blank) &amp;quot;extra&amp;quot; storage device, you choose to use the default directory structure on it.  When you rip media to that device, the media can then be made either public or private, and LinuxMCE will automatically put it in the correct folder (audio, video, etc.).&lt;br /&gt;
&lt;br /&gt;
If you connect an extra storage device that already has media on it, however, and that media isn&#039;t already organized in LinuxMCE&#039;s default directory structure, it&#039;s easiest if you simply &#039;make it all public&#039; or &#039;make it all private&#039;. If you were to &#039;use the default directory structure&#039;, you would need to manually move the files from the existing folders into one of the directory folders that LinuxMCE would then create for you.&lt;br /&gt;
&lt;br /&gt;
When you rip files, you have the option of copying them to the Core.  If you rip a CD and make it public, it will be stored in public/audio.  If you go into Network Neighborhood and add a folder under public/audio, you would essentially be adding a folder on the Core. If you add a folder under public/audio/Generic Network Storage [50], you would be adding it to Generic Network Storage [50].&lt;br /&gt;
&lt;br /&gt;
===Drive and network drive management===&lt;br /&gt;
This concept behind drive/network drive management is not the same as the method to which Linux and Windows users are accustomed. In Windows, for example, each network device shows up separately; they are never grouped together.  There is an advantage to the way LinuxMCE manages drives. It&#039;s much simpler to add devices when you&#039;re a novice and don&#039;t understand networking. Further, if you&#039;re using an infrared remote control, you can manage drives with a single &#039;yes&#039; or &#039;no,&#039; click, which is very convenient. Lastly, all your media content is cataloged and presented in the same structure throughout the system, no matter which Media Director you&#039;re using or what room you&#039;re in.&lt;br /&gt;
&lt;br /&gt;
In Windows, by comparison, if you connect a USB drive to a Windows PC in the bedroom, you won&#039;t see that content in the living room unless you 1) open file explorer, 2) create a new network share for it, 3) go into the living room, and 4) create a new mapped network drive there. (That isn&#039;t so easy to do with an infrared remote and without some knowledge of networking.)  Further, you wouldn&#039;t be able to see the media in any other room in the house unless you were to also create mapped network shares in those rooms as well. &lt;br /&gt;
&lt;br /&gt;
With LinuxMCE, when you connect a USB drive, for example, you can &#039;make it all public&#039;; the media will be available everywhere. No other typing is required. With LinuxMCE, instead of managing multiple network shares and mapped drives, you can choose the Core&#039;s public folders in the Network Neighborhood browser from anywhere in the home, without having to know which storage devices the media is actually on.  When you remove a USB drive from a Media Station, that media instantly disappears from the catalog displayed in every room. If you reattach it, it will re-appear.&lt;br /&gt;
&lt;br /&gt;
You can also backup the media securely on the Core. LinuxMCE has built-in [http://en.wikipedia.org/wiki/RAID RAID] 5 (see &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Advanced--&amp;gt;[[RAID]]&#039;&#039;&#039;), so its HDD has similar backup capabilities to a [[NAS]] device.&lt;br /&gt;
&lt;br /&gt;
To change the name of an extra device, go to the &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Advanced--&amp;gt;Configuration--&amp;gt;[[Devices]]&#039;&#039;&#039; and under the Core you will see listed the HDDs in the core and any connected NAS devices. Under each Media Station you will see the HDDs in that Media Station. All are given default names.  You can change the description, which will also change the folder name.  In the above example, changing &amp;quot;USB Drive [51]&amp;quot; to &amp;quot;Tokyo&amp;quot; means the directory public/other/USB Drive [51] would change to public/other/Tokyo.&lt;br /&gt;
&lt;br /&gt;
You can see a list of the files in the system by folder In the &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Files &amp;amp; Media--&amp;gt;[[Media Files Sync]]&#039;&#039;&#039; menu.  If a file is shown with a check box, the file exists both on the local disk as well as in LinuxMCE&#039;s master catalog.  If it has a different icon, then LinuxMCE hasn&#039;t finished cataloging the media; just be patient. It should appear with a check mark soon (depending on how much new media was added). &lt;br /&gt;
&lt;br /&gt;
Use this interface to manage change cover art and attributes. Under Files &amp;amp; Media there is also a cover art scan utility that will find cover art, as well as other attributes (actor, genre, etc.) obtained from Amazon.&lt;br /&gt;
&lt;br /&gt;
====Linux operational details of network and disk mounts====&lt;br /&gt;
[[UpdateMedia]] is a daemon that constantly scans for media files in the /home/public and the /home/user_xxx folder created for each user. Any added media is cataloged in the pluto_media database File table, and attributes and cover art go into the Attribute and Picture tables.  Under /home/public and /home/users_xxx is a data subfolder which contains the actual video, audio, pictures folders.  (The /home/user_xxx directories themselves contain the system files for each user (like email boxes) as well as the main login for that user (in a &amp;quot;data&amp;quot; subfolder).&lt;br /&gt;
&lt;br /&gt;
Extra devices are mounted as /mnt/device/xxx (where xxx is the device number).  The mount point is the same whether it&#039;s a local drive or not.  For example, USB drive [50] in a Media Station may be mounted as a local device named /mnt/device/50, but is also mounted as a Samba mount on other Media Stations as /mnt/device/50.  The Core and the Media Stations all use the same mount names (/mnt/device/).&lt;br /&gt;
&lt;br /&gt;
Within the /home/public/data and /home/user_xxx/data are symlinks to the physical directories specified by /mnt/device/xxx.  Since the Core and all Media Stations mount the same /home directory (and all have the same /mnt/device mounts), they will all show the same files.  Therefore, if the [[UpdateMedia]] daemon locates the file /home/public/data/audio/Generic Internal Drive [50]/The Beatles/Let it be.mp3, that file will be listed on every Media Station, too.&lt;br /&gt;
&lt;br /&gt;
[[Category: Tutorials]]&lt;/div&gt;</summary>
		<author><name>Juanfe</name></author>
	</entry>
	<entry>
		<id>http://wiki.linuxmce.org/index.php?title=Usage_Intro&amp;diff=14828</id>
		<title>Usage Intro</title>
		<link rel="alternate" type="text/html" href="http://wiki.linuxmce.org/index.php?title=Usage_Intro&amp;diff=14828"/>
		<updated>2008-07-12T22:34:38Z</updated>

		<summary type="html">&lt;p&gt;Juanfe: /* Managing your media */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{| align=&amp;quot;right&amp;quot;&lt;br /&gt;
  | __TOC__&lt;br /&gt;
  |}&lt;br /&gt;
LinuxMCE&#039;s main concepts are [[Devices]], Commands (aka [[Scenarios]] and Activities), and [[Events]]. An  [[Orbiter]] is the device that displays the User Interface. It can be a [[Media Director|Media Station]], web pad, mobile phone, or other remote control device. The Orbiter User Interface is standardized for all Orbiters.&lt;br /&gt;
&lt;br /&gt;
== Devices ==&lt;br /&gt;
&lt;br /&gt;
A device is generally a piece of hardware or software, like the Xine Media Player, a light switch, or a mobile phone.  Devices have three functions, abbreviated &amp;quot;DCE&amp;quot; (Data, Commands, Events): &lt;br /&gt;
&lt;br /&gt;
# Retrieve configuration &#039;&#039;&#039;data&#039;&#039;&#039;&lt;br /&gt;
# Perform a &#039;&#039;&#039;command&#039;&#039;&#039; (turn on, turn off, fast forward, etc.)&lt;br /&gt;
# Report certain triggered &#039;&#039;&#039;events&#039;&#039;&#039; (e.g. &#039;motion detected&#039;, &#039;playback started&#039;, etc.)&lt;br /&gt;
&lt;br /&gt;
== Scenarios ==&lt;br /&gt;
&lt;br /&gt;
&amp;quot;[[Scenarios]]&amp;quot;, &amp;quot;Activities&amp;quot;, and &amp;quot;Command Groups&amp;quot; are interchangeable terms -- they mean the same thing.  A scenario is a group of commands that can be sent to a device (or series of devices).  In LinuxMCE, the default Orbiter main menu consists of several scenario categories, grouped by room. These categories are&lt;br /&gt;
&lt;br /&gt;
* Lighting&lt;br /&gt;
* Media&lt;br /&gt;
* Climate&lt;br /&gt;
* Telecom&lt;br /&gt;
* Security&lt;br /&gt;
&lt;br /&gt;
(These default categories are arbitrary and are set up at installation.) To perform an action in LinuxMCE, a scenario is chosen from one of these categories (located on the main menu of an Orbiter). &lt;br /&gt;
&lt;br /&gt;
For example, in rooms which have both a TV and lights, LinuxMCE automatically creates a scenario called &#039;Showtime.&#039; This scenario dims the lights to 10% whenever the TV starts playing.  In rooms with a PVR or other TV-enabled device, another scenario is created called &#039;TV&#039; (in the &#039;Media&#039; category) to start the TV.  Another scenario in the &#039;Media&#039; category called &#039;Video&#039; sends a command to the Orbiter to list your video content. Telecom scenarios are created to make phone calls. Security scenarios are created to view cameras and to arm an alarm.&lt;br /&gt;
&lt;br /&gt;
Some [[What_scenarios_are_created_automatically%3F|default scenarios]] are created for you at installation. A fully-functional system can run using only the default scenarios, if you choose. You can also change or remove the default scenarios or add new ones. This is done though the &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Wizard--&amp;gt;[[Scenarios]]&#039;&#039;&#039; menu. When creating a scenario, the [[LinuxMCE Admin Website]] will show you the most appropriate wizard, based on the category you pick.  If you&#039;re adding an activity in the lighting category, for example, the wizard will display a list of the lights in the room and let you pick which ones to turn off.  If you&#039;re creating a scenario in the security category, it will list the installed cameras and will allow you to select which ones to display.&lt;br /&gt;
&lt;br /&gt;
A scenario can send a command to any device in the system. By default, scenarios in the lighting category show you the room lights, allowing you to select which ones to which to send commands. However, from the &#039;&#039;&#039;Wizard--&amp;gt;[[Scenarios]]&#039;&#039;&#039; menu for the specific scenario, you can also specify a command to any device in your home. You could make a phone call, for example, even from a scenario in the lighting category.&lt;br /&gt;
&lt;br /&gt;
Certain scenarios are assigned to certain rooms by default. This can be customized, however. When you manually select a room from the Orbiter main menu, the default scenarios for that room are displayed. In general they control devices in that room, but this can also be changed. If your kitchen is near the garage and you want a scenario to &#039;turn off the garage light&#039;, you can assign a scenario to the room &#039;kitchen&#039; that will do just that. It doesn&#039;t matter that the light is in the garage.&lt;br /&gt;
&lt;br /&gt;
For a Media Director, the on-screen Orbiter User Interface appears on the TV screen. It is manipulated by the mouse/keyboard or remote control connected to your Media Director. By default it is set to display the scenarios for the room in which the Media Director is located.&lt;br /&gt;
&lt;br /&gt;
In contrast, a mobile Orbiter (such as a webpad) can be carried throughout the house. It must be able to select the scenarios for multiple rooms. Fortunately, the option to manually select which room you are currently in is available on every Orbiter&#039;s main menu.&lt;br /&gt;
&lt;br /&gt;
This can occasionally cause some confusion. Perhaps both the Living Room and the Bedroom have a scenario called &#039;TV&#039;. You may have a web pad that is in the Bedroom, but you then carry it to the Living Room. You may forget to tell the web pad that it&#039;s now in the Living Room (at the bottom of the Orbiter screen it will still say &#039;Bedroom&#039;). You hit the &#039;TV&#039; button expecting the Living Room TV to come on, but in fact you&#039;re still controlling the Bedroom and the TV comes on there instead. Finally you may realize that you must change your room location to Living Room, and you can then finally control the TV there.&lt;br /&gt;
&lt;br /&gt;
Once you get used to this concept, though, you&#039;ll find it very useful.  Conveniently, any Orbiter can be set to control any room and choose from the scenarios assigned to that room. No matter which Orbiter you use, the same set of scenarios will be displayed for each specific room. For example, the kitchen scenarios will always be the same, no matter which Orbiter you are using. (The scenarios are assigned by room -- not by Orbiter.) No matter whether you pick up your mobile phone, your web pad, or your remote control, you will always be shown the same list of scenario options for the Living Room.&lt;br /&gt;
&lt;br /&gt;
You have the option of preventing some family members from using certain scenarios. From the [[LinuxMCE Admin Website]], certain scenarios and rooms can be [[Users#Restrict_Access|restricted to certain users]].  Maybe little Suzy&#039;s mobile phone Orbiter should be restricted so that she is only able to control her room and the living room, for example. She would only be able to execute the scenarios in those rooms, but not the Master Bedroom. Other possible options include [[Users#Restrict_Access|requiring a pin code]] to access the scenarios for a particular room.&lt;br /&gt;
&lt;br /&gt;
== Events ==&lt;br /&gt;
&lt;br /&gt;
Devices report events, such as &#039;Playback started&#039; and &#039;Motion Sensor tripped&#039;. If you want something to happen automatically in LinuxMCE, you create Event Handlers that react to these events. For example, you can create an event handler that listens for the &#039;Motion Sensor tripped&#039; event from a motion detector and turns on the lights in response.  An event handler might listen for the &#039;Sunrise&#039; event, which could then prompt the sprinklers to come on. &lt;br /&gt;
&lt;br /&gt;
LinuxMCE creates several default event handlers. In rooms in which you have a TV and lights, an event handler is created that listens for the &#039;Watching Media&#039; event sent by a media player. When the event is detected, the Showtime scenario (which dims the lights) is executed in response.  When you start a movie, therefore, the Showtime activity will be executed and the lights will be dimmed.  There are other default event handlers that monitor for events like &#039;Security Breach&#039; and &#039;Fire Alarm&#039; (from a home security system).&lt;br /&gt;
&lt;br /&gt;
== Controlling an Orbiter ==&lt;br /&gt;
&lt;br /&gt;
To control the system, you use an [[Orbiter]], which is the LinuxMCE term for a remote control.  All [[Orbiters]] have the same basic function: to display the scenarios in the room you&#039;re in and let you select one.  The different Orbiters may [[Selecting_the_Right_UI|display the User Interface slightly differently]], depending on their screen size, but the function and the list of scenarios is always the same. For example, the [[Selecting_the_Right_UI|&amp;quot;UI1&amp;quot; interface]] (which is used on webpads and PDAs) displays the scenarios in horizontal rows. (If there are more than will fit on a row, there will be a &amp;quot;more&amp;quot; button.) A home button is always displayed that takes you to the main menu. On smaller displays, as on mobile phones or desktop phones, there&#039;s not enough room to show the scenarios themselves. The top level menu shows only the categories: Lights, Media, Climate, Security and Telecom. Selecting a category displays the scenarios in that category. &lt;br /&gt;
&lt;br /&gt;
[[Selecting_the_Right_UI|&amp;quot;UI2&amp;quot;]] is the [[Selecting_the_Right_UI|preferred User Interface]] for Media Stations.  Using a traditional I/R remote is not much different from using any other Media Center PC remote.  The menu button brings up the main menu, and you use the &#039;&#039;left/right/up/down/enter&#039;&#039; buttons to navigate it. The &#039;&#039;fast forward/rewind/skip +/skip -&#039;&#039; keys are used for media playback.&lt;br /&gt;
&lt;br /&gt;
If you have a pointing device like a mouse or gyro air mouse, the UI2 interface also supports a unique control architecture that lets you do everything with 3 (programmable) buttons (plus ok and cancel). The 3 buttons are &amp;quot;MEDIA&amp;quot;, &amp;quot;MENU&amp;quot;, &amp;quot;AMBIANCE&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
On a mouse with 3 programmable buttons (such as the [[Using_the_Gyration_Remote_GYR3101US_%28Non-Fiire_Chief%29|gyration]]), these functions correspond to the buttons from left to right. If you are using a traditional 3 button mouse, you can use the F6, F7 and F8 keys on the keyboard for the three programmable functions instead. In both cases, the left mouse button is &amp;quot;ok&amp;quot;, and the right mouse button is &amp;quot;cancel/go back&amp;quot;. &lt;br /&gt;
&lt;br /&gt;
Mouse button behavior is &amp;quot;absolute&amp;quot; when you press and hold the media/menu/ambiance button and &amp;quot;relative&amp;quot; when you tap and release.&lt;br /&gt;
&lt;br /&gt;
The &amp;quot;absolute&amp;quot; behavior is generally more efficient. For example, in the case of the middle button (F7), &amp;quot;absolute&amp;quot; behavior means the action is executed without having to additionally click &amp;quot;ok&amp;quot;.  If you press and hold the middle button (F7) while moving your mouse pointer to the option, then let go, that option is executed. If you instead tap and release the menu button (&amp;quot;relative&amp;quot; behavior), you will only highlight the menu option. You must then press ok (the left mouse button) to execute the option.&lt;br /&gt;
&lt;br /&gt;
Categories appear along the bottom of the screen, and the scenarios in each category popup vertically (like a pull-down menu in a PC, except upside down).  If the main menu isn&#039;t already visible, bring it up by pressing the &amp;quot;start&amp;quot; button on a Windows I/R remote, or the &amp;quot;menu&amp;quot; button on a 3-button mouse.  To exit a menu, use the back button on the I/R remote, the cancel button (right mouse button on a 3-button mouse), or the ESC key on a keyboard.&lt;br /&gt;
&lt;br /&gt;
In UI2 the media is always full screen. If you&#039;re not playing your own media, the background media (i.e. screensaver images) is gallery art from the Internet (using flickr) or [[Use_my_own_pictures_in_the_Screen_Saver|pictures you select]]. If only the screensaver images are displayed on the Media Station, press the menu/middle/F7 button to bring up the menu. Right click/ESC to get rid of it. (This works even if your own media is playing.)&lt;br /&gt;
&lt;br /&gt;
If you&#039;re using UI2&#039;s 3-button navigation model, the normal media control options on a traditional remote are replaced with a single button: &amp;quot;media&amp;quot; (left soft button or F6). Press this and move the pointer up and down for your skip functions (&#039;&#039;ch+, ch-, skip fwd, skip back&#039;&#039;). Move the pointer left and right for speed control (&#039;&#039;rewind, fast forward&#039;&#039;).  The further you move, the faster the media playback changes.  If you hold the button down (the left soft button or F6), your movement will be &amp;quot;absolute&amp;quot;. Instead of the traditional &amp;quot;jog shuttle-type&amp;quot; control, movement to the right skips to the end of your media, and movement to the left skips to the beginning.  Once you get used to it, you will find that navigating media is orders of magnitude faster and easier with this model than with a traditional remote. You can find a spot in a 2 hour movie in only a couple seconds with a click of a single button (compared to a slew of button clicks required using a traditional remote).&lt;br /&gt;
&lt;br /&gt;
Also, in UI2 you can press the &amp;quot;ambiance&amp;quot; button (right soft button or F8). Move up/down to adjust the lights, and left/right to adjust the volume. As with the media playback, if you hold the F8/right soft button down while you move left and right, your volume control is in &amp;quot;absolute&amp;quot; mode (not &amp;quot;relative&amp;quot;). Moving hard right turns up the volume full blast; hard left is mute.  This requires you have a TV or receiver that is serial-controlled, however. LinuxMCE can then directly and instantly set the volume position in sync with your hand movements. (Few TVs and receivers have this feature, unfortunately.)&lt;br /&gt;
&lt;br /&gt;
There are other media control functions besides the most commonly used &#039;&#039;fast fwd/rewind/skip up/skip down&#039;&#039;. You can, for example, choose &#039;subtitles&#039; while watching a DVD, &#039;guide&#039; while watching TV, and &#039;random&#039; while listening to an audio CD. In the UI2 3 button model, these functions appear on the main menu (on the left-most pad, entitled &#039;now playing&#039;) and changes according to the type of media you&#039;re playing. Press the menu button (middle button/F7) to select these options.&lt;br /&gt;
&lt;br /&gt;
This 3 button model is a new concept and very different from traditional navigation. Most people find it much faster once they become accustomed to it.&lt;br /&gt;
&lt;br /&gt;
==Reload Router &amp;amp; Regen Orbiters==&lt;br /&gt;
&lt;br /&gt;
While using LinuxMCE you&#039;ll see sometimes a message asking if you want to [[Quick reload router|reload the router]], or if you want to [[Orbiter Generator|regenerate the Orbiter UIs]] (User Interfaces). In general, these options refresh the LinuxMCE databases so that changes to the system can be recognized.&lt;br /&gt;
&lt;br /&gt;
===Reload Router===&lt;br /&gt;
All devices in LinuxMCE obtain their configuration information from the [[DCERouter]], which is the central piece of software on the Core.  All devices request a list of the other devices in the home from the router, so they can respond to them appropriately.  (For example, an IP camera device might turn on the lights in the room whenever you&#039;re viewing the camera.  To do so, the IP camera needs to know what lights are in the room.) Typically a device requests this information only when it&#039;s starting up.  When you connect additional plug and play devices to the system, these new devices generally will work immediately, but their functionality may not be fully enabled within the LinuxMCE system until the DCE router is reloaded. When the router reloads, it signals all devices on the system to simultaneously reload and re-request the system data. Each existing device can then work with each new device.  This process is known as a &#039;reload&#039;.  It generally takes about 10 seconds.  Every time you add or remove devices, or change a device&#039;s configuration, you may be asked to do a reload. If you&#039;re going to add more devices or make more device changes, you can do the reload once you&#039;re done. If you&#039;re in the middle of watching a movie or TV, you can postpone the reload, since media players generally stop playing during reloads.  Phone calls aren&#039;t affected, though, and TV shows being recorded by MythTV in the background are also unaffected.&lt;br /&gt;
&lt;br /&gt;
===Regen the Orbiter===&lt;br /&gt;
LinuxMCE&#039;s [[Selecting_the_Right_UI|Orbiter User Interfaces]] are all &amp;quot;pre-rendered&amp;quot; in order to be more efficient.  The User Interface source images are all very high resolution, but need to be resized to accommodate the resolution of each Orbiter screen. The Core server has a list of the Orbiters used by your system, and will generate the appropriate User Interface screen for each Orbiter. It will do this each time you request a &amp;quot;regen&amp;quot;. If you have five different types of Orbiters (each with a different type of screen), then five different images will be generated during each regen.&lt;br /&gt;
&lt;br /&gt;
These User Interface screen images are stored in the Core. The appropriate UI image is sent to an Orbiter whenever it is activated. For many low-power devices (like mobile phones or desktop phones) there just isn&#039;t the processing power to do scaling and rendering of a User Interface screen on the fly. They need to be pre-rendered (with text pre-embedded in the images) to be efficient.&lt;br /&gt;
&lt;br /&gt;
Adding new scenarios may result in the creation of new buttons for the User Interface, or changes to the text on existing buttons. Perhaps an entirely new screen will be created.&lt;br /&gt;
&lt;br /&gt;
Until the User Interface images are regenerated, though, you won&#039;t be able to see these new buttons (or screens) on your Orbiter. During the regen, new User Interface images for each type of Orbiter is generated by the Core. This can take about 2-5 minutes, depending on how many Orbiter types you have in your system.&lt;br /&gt;
&lt;br /&gt;
You needn&#039;t do a regen every time you add a scenario. You can wait until you have finished adding all the scenarios. Furthermore, you can also regen only the Orbiter you are currently using by doing a &amp;quot;Quick regen&amp;quot;. This allows you to see the new User Interface (following the addition of new scenarios) without having to do a full regen for all the Orbiters. Once you have finished adding scenarios, then you can do a full regen.&lt;br /&gt;
&lt;br /&gt;
This regen process can be a bit annoying, but is necessary. In future editions of LinuxMCE, it is planned to allow Media Directors, which have a lot more processing power, to render their on-screen Orbiter User Interfaces on the fly (so you don&#039;t have to do a regen each time you add or remove a scenario).&lt;br /&gt;
&lt;br /&gt;
You can do a [[Orbiter Generator#Running OrbiterGen (performing a &amp;quot;regen&amp;quot;)|full Orbiter regen or a Quick regen]] at any time by using buttons on the Core&#039;s LinuxMCE [[Launch Manager]].&lt;br /&gt;
&lt;br /&gt;
== Managing your media ==&lt;br /&gt;
&lt;br /&gt;
LinuxMCE is always scanning for network shares, on Network-Attached Storage (NAS) devices and other Hard Disk Drives (HDDs) of PCs connected to the system (including Windows PCs). Universal Serial Bus (USB) drives are also detected. Every time a LinuxMCE finds a network share, you will be asked if you would like to use it. Whenever you reply &amp;quot;Yes&amp;quot;, the file share can be used by any Media Director on the system. The file share is scanned for media, such as audio, video and photos, and any that are found are then cataloged in the Core&#039;s central database. For example, when you plug in a USB drive on a Media Station in the living room and tell LinuxMCE to use it, the media on the drive will be available to Media Directors in other rooms.&lt;br /&gt;
&lt;br /&gt;
At the moment there is no way to restrict your media for &#039;local use only&#039;; all Media Stations in the LinuxMCE system share the media catalog stored on the Core.  (This is a limitation that will be addressed in the near future. Sometimes it is desirable to attach a USB drive in the master bedroom and not allow it to be shared, for example. &#039;&#039;Note: However, see [[folder lock|this article that describes a method to address this problem]].&#039;&#039;)&lt;br /&gt;
&lt;br /&gt;
Storage devices (NAS, USB drives, extra HDDs on the Core or Media Directors) are referred to as &amp;quot;Extra Drives&amp;quot;.  When an extra drive is added, it is listed in the device tree in &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Advanced--&amp;gt;Configuration--&amp;gt;[[Devices]]&#039;&#039;&#039;.  Under &#039;Core&#039; you&#039;ll see a device listed for each HDD in the Core, as well as for each NAS device. Under each Media Station will be listed the HDDs in that Media Station.  By clicking on the device you can change the device&#039;s properties, such as the mount username/password.  Each NAS device, and each file share on another PC, will show as a device listed under the Core; each is considered a child of the Core.&lt;br /&gt;
&lt;br /&gt;
===Access control for shared media===&lt;br /&gt;
LinuxMCE creates a top level folder for &#039;public&#039; media. This folder can be used by every user in the system.  A &#039;private&#039; media folder is also created for each user.  Within each of those folders are sub-folders, labeled &#039;audio&#039;, &#039;video&#039;, &#039;pictures&#039;, &#039;data&#039; and &#039;other&#039;.  Within each of those will also be sub-folders for the extra storage devices (NAS, USB, extra internal drives, etc).  When you attach an extra storage device, you can specify whether the default directory structure should be used for it. Alternatively, you can specify &#039;just make it public&#039; or &#039;make it private&#039;.&lt;br /&gt;
&lt;br /&gt;
Here&#039;s an example.  Let&#039;s say you have 2 users: john and mary.  You connect 3 storage devices:&lt;br /&gt;
# a NAS, for which you specify &#039;use default directory structure&#039;. It is named &#039;Generic Network Storage [50]&#039;&lt;br /&gt;
# a USB drive for which you specify &#039;make it all public&#039;. It is named &#039;USB Drive [51]&#039;&lt;br /&gt;
# a SATA drive for which you choose &#039;make it private for john&#039;. It is named &#039;General Internal HDD [52]&lt;br /&gt;
&lt;br /&gt;
Now let&#039;s say you&#039;re running Windows. Go to Network Neighborhood and find the LinuxMCE Core server.  The directory tree ought to look like this:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
public&lt;br /&gt;
  video&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  audio&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  pictures&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  data&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  other&lt;br /&gt;
    USB Drive [51]&lt;br /&gt;
john&lt;br /&gt;
  video&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  audio&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  pictures&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  data&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  other&lt;br /&gt;
    General Internal HDD [52]&lt;br /&gt;
mary&lt;br /&gt;
  video&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  audio&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  pictures&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  data&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  other&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Whether you put your media under video, audio, pictures, data or other is unimportant.  It will be scanned by LinuxMCE anyway. The contents of &amp;quot;General Internal HDD [52]&amp;quot; will be displayed in the folder john/other/General Internal HDD [52]. The contents of USB Drive [51] will be displayed in the folder public/other/USB Drive [51].  When John browses the contents in Network Neighborhood, he will be asked for his username and password. He can then access the content in both the public folder as well as the &amp;quot;john&amp;quot; folders (including General Internal HDD [52]).  When Mary browses the contents with her username and password, she will see both the public and &amp;quot;mary&amp;quot; folders. She will not be able to see anything on General Internal HDD [52], however, since that drive was specified to be private for John.&lt;br /&gt;
&lt;br /&gt;
In the case of John&#039;s private media, it won&#039;t be displayed in the LinuxMCE media browser unless you click &#039;Sources&#039;--&amp;gt;&#039;John&#039;. However you &#039;&#039;can&#039;&#039; see the contents of General Internal HDD [52] (unless you deselect &#039;Sources&#039;--&amp;gt;&#039;Public&#039; from the media browser).  Generic Network Storage [50] would be different, however, since you specified to use the default directory structure for it.  LinuxMCE will have created public directories on Generic Network Storage [50] for public video and public audio, as well as for john&#039;s video and mary&#039;s audio. The media file browser will show only the media that is in the public directories. (The same is true with the Windows Network Neighborhood browser.) &lt;br /&gt;
&lt;br /&gt;
If Generic Network Storage [50] has existing media in the top (root) folder, you won&#039;t see it listed anywhere.&lt;br /&gt;
&lt;br /&gt;
It is generally recommended, therefore, that when you add a new (blank) &amp;quot;extra&amp;quot; storage device, you choose to use the default directory structure on it.  When you rip media to that device, the media can then be made either public or private, and LinuxMCE will automatically put it in the correct folder (audio, video, etc.).&lt;br /&gt;
&lt;br /&gt;
If you connect an extra storage device that already has media on it, however, and that media isn&#039;t already organized in LinuxMCE&#039;s default directory structure, it&#039;s easiest if you simply &#039;make it all public&#039; or &#039;make it all private&#039;. If you were to &#039;use the default directory structure&#039;, you would need to manually move the files from the existing folders into one of the directory folders that LinuxMCE would then create for you.&lt;br /&gt;
&lt;br /&gt;
When you rip files, you have the option of copying them to the Core.  If you rip a CD and make it public, it will be stored in public/audio.  If you go into Network Neighborhood and add a folder under public/audio, you would essentially be adding a folder on the Core. If you add a folder under public/audio/Generic Network Storage [50], you would be adding it to Generic Network Storage [50].&lt;br /&gt;
&lt;br /&gt;
===Drive and network drive management===&lt;br /&gt;
This concept behind drive/network drive management is not the same as the method to which Linux and Windows users are accustomed. In Windows, for example, each network device shows up separately; they are never grouped together.  There is an advantage to the way LinuxMCE manages drives. It&#039;s much simpler to add devices when you&#039;re a novice and don&#039;t understand networking. Further, if you&#039;re using an infrared remote control, you can manage drives with a single &#039;yes&#039; or &#039;no,&#039; click, which is very convenient. Lastly, all your media content is cataloged and presented in the same structure throughout the system, no matter which Media Director you&#039;re using or what room you&#039;re in.&lt;br /&gt;
&lt;br /&gt;
In Windows, by comparison, if you connect a USB drive to a Windows PC in the bedroom, you won&#039;t see that content in the living room unless you 1) open file explorer, 2) create a new network share for it, 3) go into the living room, and 4) create a new mapped network drive there. (That isn&#039;t so easy to do with an infrared remote and without some knowledge of networking.)  Further, you wouldn&#039;t be able to see the media in any other room in the house unless you were to also create mapped network shares in those rooms as well. &lt;br /&gt;
&lt;br /&gt;
With LinuxMCE, when you connect a USB drive, for example, you can &#039;make it all public&#039;; the media will be available everywhere. No other typing is required. With LinuxMCE, instead of managing multiple network shares and mapped drives, you can choose the Core&#039;s public folders in the Network Neighborhood browser from anywhere in the home, without having to know which storage devices the media is actually on.  When you remove a USB drive from a Media Station, that media instantly disappears from the catalog displayed in every room. If you reattach it, it will re-appear.&lt;br /&gt;
&lt;br /&gt;
You can also backup the media securely on the Core. LinuxMCE has built-in [http://en.wikipedia.org/wiki/RAID RAID] 5 (see &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Advanced--&amp;gt;[[RAID]]&#039;&#039;&#039;), so its HDD has similar backup capabilities to a [[NAS]] device.&lt;br /&gt;
&lt;br /&gt;
To change the name of an extra device, go to the &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Advanced--&amp;gt;Configuration--&amp;gt;[[Devices]]&#039;&#039;&#039; and under the Core you will see listed the HDDs in the core and any connected NAS devices. Under each Media Station you will see the HDDs in that Media Station. All are given default names.  You can change the description, which will also change the folder name.  In the above example, changing &amp;quot;USB Drive [51]&amp;quot; to &amp;quot;Tokyo&amp;quot; means the directory public/other/USB Drive [51] would change to public/other/Tokyo.&lt;br /&gt;
&lt;br /&gt;
You can see a list of the files in the system by folder In the &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Files &amp;amp; Media--&amp;gt;[[Media Files Sync]]&#039;&#039;&#039; menu.  If a file is shown with a check box, the file exists both on the local disk as well as in LinuxMCE&#039;s master catalog.  If it has a different icon, then LinuxMCE hasn&#039;t finished cataloging the media; just be patient. It should appear with a check mark soon (depending on how much new media was added). &lt;br /&gt;
&lt;br /&gt;
Use this interface to manage change cover art and attributes. Under Files &amp;amp; Media there is also a cover art scan utility that will find cover art, as well as other attributes (actor, genre, etc.) obtained from Amazon.&lt;br /&gt;
&lt;br /&gt;
====Background and Linux operational details====&lt;br /&gt;
[[UpdateMedia]] is a daemon that constantly scans for media files in the /home/public and the /home/user_xxx folder created for each user. Any added media is cataloged in the pluto_media database File table, and attributes and cover art go into the Attribute and Picture tables.  Under /home/public and /home/users_xxx is a data subfolder which contains the actual video, audio, pictures folders.  (The /home/user_xxx directories themselves contain the system files for each user (like email boxes) as well as the main login for that user (in a &amp;quot;data&amp;quot; subfolder).&lt;br /&gt;
&lt;br /&gt;
Extra devices are mounted as /mnt/device/xxx (where xxx is the device number).  The mount point is the same whether it&#039;s a local drive or not.  For example, USB drive [50] in a Media Station may be mounted as a local device named /mnt/device/50, but is also mounted as a Samba mount on other Media Stations as /mnt/device/50.  The Core and the Media Stations all use the same mount names (/mnt/device/).&lt;br /&gt;
&lt;br /&gt;
Within the /home/public/data and /home/user_xxx/data are symlinks to the physical directories specified by /mnt/device/xxx.  Since the Core and all Media Stations mount the same /home directory (and all have the same /mnt/device mounts), they will all show the same files.  Therefore, if the [[UpdateMedia]] daemon locates the file /home/public/data/audio/Generic Internal Drive [50]/The Beatles/Let it be.mp3, that file will be listed on every Media Station, too.&lt;br /&gt;
&lt;br /&gt;
[[Category: Tutorials]]&lt;/div&gt;</summary>
		<author><name>Juanfe</name></author>
	</entry>
	<entry>
		<id>http://wiki.linuxmce.org/index.php?title=Help:Editing&amp;diff=14827</id>
		<title>Help:Editing</title>
		<link rel="alternate" type="text/html" href="http://wiki.linuxmce.org/index.php?title=Help:Editing&amp;diff=14827"/>
		<updated>2008-07-12T22:30:01Z</updated>

		<summary type="html">&lt;p&gt;Juanfe: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[http://en.wikipedia.org/wiki/Help:Editing link on wikipedia]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You can look at &amp;quot;edit&amp;quot; of this page to see how the following simple markup works:&lt;br /&gt;
&lt;br /&gt;
=Top Header=&lt;br /&gt;
==Second: This is how you can do a section header==&lt;br /&gt;
===Third: Which can be nested by adding more equal signs===&lt;br /&gt;
====Fourth Header====&lt;br /&gt;
The headings will be put into a table of contents at the top, but only when the page has 4 or more section headers (nested or not).&lt;br /&gt;
&lt;br /&gt;
*This is an unordered (bullet) list.&lt;br /&gt;
**These can also be nested&lt;br /&gt;
&lt;br /&gt;
#This is an ordered (numbered) list&lt;br /&gt;
##I think these can be nested as well&lt;br /&gt;
##They can&lt;br /&gt;
#Next ordered (numbered) list&lt;br /&gt;
##Nested&lt;br /&gt;
##Nested&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
:This will be indented&lt;br /&gt;
::Indented more&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
 Lines starting with a space will be &amp;quot;preformatted&amp;quot;, and placed in one of those typical dotted boxes.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Italic text&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;bold text&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;&#039;&#039;italic and bold&#039;&#039;&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Urls are automaticly recognized, but there are more possibilities.  For example:&lt;br /&gt;
http://some.domain/page.html  shows the URL &#039;as is&#039;&lt;br /&gt;
[http://some.domain/page.html]  shows up as an increasing number&lt;br /&gt;
[http://some.domain/page.html alternative text]  shows up as &amp;quot;alternative text&amp;quot;&lt;br /&gt;
&lt;br /&gt;
[[other wiki page]] link to other_wiki_page, shows as &amp;quot;other wiki page&amp;quot;&lt;br /&gt;
[[other wiki page|alternative text]] link to other_wiki_page, shows as &amp;quot;alternative text&amp;quot;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;this will stop the wiki from applying formatting, useful if you don&#039;t want url&#039;s turned into links for instance: http://some.domain/page.html&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Alternatively you can also use the standard HTML tags.&lt;br /&gt;
===Third Level: You unnest by removing one level of equal signs===&lt;/div&gt;</summary>
		<author><name>Juanfe</name></author>
	</entry>
	<entry>
		<id>http://wiki.linuxmce.org/index.php?title=Help:Editing&amp;diff=14826</id>
		<title>Help:Editing</title>
		<link rel="alternate" type="text/html" href="http://wiki.linuxmce.org/index.php?title=Help:Editing&amp;diff=14826"/>
		<updated>2008-07-12T22:29:03Z</updated>

		<summary type="html">&lt;p&gt;Juanfe: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[http://en.wikipedia.org/wiki/Help:Editing link on wikipedia]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You can look at &amp;quot;edit&amp;quot; of this page to see how the following simple markup works:&lt;br /&gt;
&lt;br /&gt;
=Top Header=&lt;br /&gt;
==This is how you can do a section header==&lt;br /&gt;
===Which can be nested by adding more equal signs===&lt;br /&gt;
====Fourth Header====&lt;br /&gt;
The headings will be put into a table of contents at the top, but only when the page has 4 or more section headers (nested or not).&lt;br /&gt;
&lt;br /&gt;
*This is an unordered (bullet) list.&lt;br /&gt;
**These can also be nested&lt;br /&gt;
&lt;br /&gt;
#This is an ordered (numbered) list&lt;br /&gt;
##I think these can be nested as well&lt;br /&gt;
##They can&lt;br /&gt;
#Next ordered (numbered) list&lt;br /&gt;
##Nested&lt;br /&gt;
##Nested&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
:This will be indented&lt;br /&gt;
::Indented more&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
 Lines starting with a space will be &amp;quot;preformatted&amp;quot;, and placed in one of those typical dotted boxes.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Italic text&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;bold text&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;&#039;&#039;italic and bold&#039;&#039;&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Urls are automaticly recognized, but there are more possibilities.  For example:&lt;br /&gt;
http://some.domain/page.html  shows the URL &#039;as is&#039;&lt;br /&gt;
[http://some.domain/page.html]  shows up as an increasing number&lt;br /&gt;
[http://some.domain/page.html alternative text]  shows up as &amp;quot;alternative text&amp;quot;&lt;br /&gt;
&lt;br /&gt;
[[other wiki page]] link to other_wiki_page, shows as &amp;quot;other wiki page&amp;quot;&lt;br /&gt;
[[other wiki page|alternative text]] link to other_wiki_page, shows as &amp;quot;alternative text&amp;quot;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;this will stop the wiki from applying formatting, useful if you don&#039;t want url&#039;s turned into links for instance: http://some.domain/page.html&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Alternatively you can also use the standard HTML tags.&lt;br /&gt;
===You unnest by removing one level of equal signs===&lt;/div&gt;</summary>
		<author><name>Juanfe</name></author>
	</entry>
	<entry>
		<id>http://wiki.linuxmce.org/index.php?title=Help:Editing&amp;diff=14825</id>
		<title>Help:Editing</title>
		<link rel="alternate" type="text/html" href="http://wiki.linuxmce.org/index.php?title=Help:Editing&amp;diff=14825"/>
		<updated>2008-07-12T22:27:06Z</updated>

		<summary type="html">&lt;p&gt;Juanfe: /* Fourth Header */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[http://en.wikipedia.org/wiki/Help:Editing link on wikipedia]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You can look at &amp;quot;edit&amp;quot; of this page to see how the following simple markup works:&lt;br /&gt;
&lt;br /&gt;
=Top Header=&lt;br /&gt;
==This is how you can do a section header==&lt;br /&gt;
===Which can be nested by adding more equal signs===&lt;br /&gt;
====Fourth Header====&lt;br /&gt;
The headings will be put into a table of contents at the top, but only when the page has 4 or more section headers (nested or not).&lt;br /&gt;
&lt;br /&gt;
*This is an unordered (bullet) list.&lt;br /&gt;
**These can also be nested&lt;br /&gt;
&lt;br /&gt;
#This is an ordered (numbered) list&lt;br /&gt;
##I think these can be nested as well&lt;br /&gt;
##They can&lt;br /&gt;
#Next ordered (numbered) list&lt;br /&gt;
##Nested&lt;br /&gt;
##Nested&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
:This will be indented&lt;br /&gt;
::Indented more&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
 Lines starting with a space will be &amp;quot;preformatted&amp;quot;, and placed in one of those typical dotted boxes.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;Italic text&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;bold text&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;&#039;&#039;italic and bold&#039;&#039;&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Urls are automaticly recognized, but there are more possibilities.  For example:&lt;br /&gt;
http://some.domain/page.html  shows the URL &#039;as is&#039;&lt;br /&gt;
[http://some.domain/page.html]  shows up as an increasing number&lt;br /&gt;
[http://some.domain/page.html alternative text]  shows up as &amp;quot;alternative text&amp;quot;&lt;br /&gt;
&lt;br /&gt;
[[other wiki page]] link to other_wiki_page, shows as &amp;quot;other wiki page&amp;quot;&lt;br /&gt;
[[other wiki page|alternative text]] link to other_wiki_page, shows as &amp;quot;alternative text&amp;quot;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;this will stop the wiki from applying formatting, useful if you don&#039;t want url&#039;s turned into links for instance: http://some.domain/page.html&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Alternatively you can also use the standard HTML tags.&lt;/div&gt;</summary>
		<author><name>Juanfe</name></author>
	</entry>
	<entry>
		<id>http://wiki.linuxmce.org/index.php?title=Usage_Intro&amp;diff=14824</id>
		<title>Usage Intro</title>
		<link rel="alternate" type="text/html" href="http://wiki.linuxmce.org/index.php?title=Usage_Intro&amp;diff=14824"/>
		<updated>2008-07-12T22:24:17Z</updated>

		<summary type="html">&lt;p&gt;Juanfe: /* Managing your media */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{| align=&amp;quot;right&amp;quot;&lt;br /&gt;
  | __TOC__&lt;br /&gt;
  |}&lt;br /&gt;
LinuxMCE&#039;s main concepts are [[Devices]], Commands (aka [[Scenarios]] and Activities), and [[Events]]. An  [[Orbiter]] is the device that displays the User Interface. It can be a [[Media Director|Media Station]], web pad, mobile phone, or other remote control device. The Orbiter User Interface is standardized for all Orbiters.&lt;br /&gt;
&lt;br /&gt;
== Devices ==&lt;br /&gt;
&lt;br /&gt;
A device is generally a piece of hardware or software, like the Xine Media Player, a light switch, or a mobile phone.  Devices have three functions, abbreviated &amp;quot;DCE&amp;quot; (Data, Commands, Events): &lt;br /&gt;
&lt;br /&gt;
# Retrieve configuration &#039;&#039;&#039;data&#039;&#039;&#039;&lt;br /&gt;
# Perform a &#039;&#039;&#039;command&#039;&#039;&#039; (turn on, turn off, fast forward, etc.)&lt;br /&gt;
# Report certain triggered &#039;&#039;&#039;events&#039;&#039;&#039; (e.g. &#039;motion detected&#039;, &#039;playback started&#039;, etc.)&lt;br /&gt;
&lt;br /&gt;
== Scenarios ==&lt;br /&gt;
&lt;br /&gt;
&amp;quot;[[Scenarios]]&amp;quot;, &amp;quot;Activities&amp;quot;, and &amp;quot;Command Groups&amp;quot; are interchangeable terms -- they mean the same thing.  A scenario is a group of commands that can be sent to a device (or series of devices).  In LinuxMCE, the default Orbiter main menu consists of several scenario categories, grouped by room. These categories are&lt;br /&gt;
&lt;br /&gt;
* Lighting&lt;br /&gt;
* Media&lt;br /&gt;
* Climate&lt;br /&gt;
* Telecom&lt;br /&gt;
* Security&lt;br /&gt;
&lt;br /&gt;
(These default categories are arbitrary and are set up at installation.) To perform an action in LinuxMCE, a scenario is chosen from one of these categories (located on the main menu of an Orbiter). &lt;br /&gt;
&lt;br /&gt;
For example, in rooms which have both a TV and lights, LinuxMCE automatically creates a scenario called &#039;Showtime.&#039; This scenario dims the lights to 10% whenever the TV starts playing.  In rooms with a PVR or other TV-enabled device, another scenario is created called &#039;TV&#039; (in the &#039;Media&#039; category) to start the TV.  Another scenario in the &#039;Media&#039; category called &#039;Video&#039; sends a command to the Orbiter to list your video content. Telecom scenarios are created to make phone calls. Security scenarios are created to view cameras and to arm an alarm.&lt;br /&gt;
&lt;br /&gt;
Some [[What_scenarios_are_created_automatically%3F|default scenarios]] are created for you at installation. A fully-functional system can run using only the default scenarios, if you choose. You can also change or remove the default scenarios or add new ones. This is done though the &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Wizard--&amp;gt;[[Scenarios]]&#039;&#039;&#039; menu. When creating a scenario, the [[LinuxMCE Admin Website]] will show you the most appropriate wizard, based on the category you pick.  If you&#039;re adding an activity in the lighting category, for example, the wizard will display a list of the lights in the room and let you pick which ones to turn off.  If you&#039;re creating a scenario in the security category, it will list the installed cameras and will allow you to select which ones to display.&lt;br /&gt;
&lt;br /&gt;
A scenario can send a command to any device in the system. By default, scenarios in the lighting category show you the room lights, allowing you to select which ones to which to send commands. However, from the &#039;&#039;&#039;Wizard--&amp;gt;[[Scenarios]]&#039;&#039;&#039; menu for the specific scenario, you can also specify a command to any device in your home. You could make a phone call, for example, even from a scenario in the lighting category.&lt;br /&gt;
&lt;br /&gt;
Certain scenarios are assigned to certain rooms by default. This can be customized, however. When you manually select a room from the Orbiter main menu, the default scenarios for that room are displayed. In general they control devices in that room, but this can also be changed. If your kitchen is near the garage and you want a scenario to &#039;turn off the garage light&#039;, you can assign a scenario to the room &#039;kitchen&#039; that will do just that. It doesn&#039;t matter that the light is in the garage.&lt;br /&gt;
&lt;br /&gt;
For a Media Director, the on-screen Orbiter User Interface appears on the TV screen. It is manipulated by the mouse/keyboard or remote control connected to your Media Director. By default it is set to display the scenarios for the room in which the Media Director is located.&lt;br /&gt;
&lt;br /&gt;
In contrast, a mobile Orbiter (such as a webpad) can be carried throughout the house. It must be able to select the scenarios for multiple rooms. Fortunately, the option to manually select which room you are currently in is available on every Orbiter&#039;s main menu.&lt;br /&gt;
&lt;br /&gt;
This can occasionally cause some confusion. Perhaps both the Living Room and the Bedroom have a scenario called &#039;TV&#039;. You may have a web pad that is in the Bedroom, but you then carry it to the Living Room. You may forget to tell the web pad that it&#039;s now in the Living Room (at the bottom of the Orbiter screen it will still say &#039;Bedroom&#039;). You hit the &#039;TV&#039; button expecting the Living Room TV to come on, but in fact you&#039;re still controlling the Bedroom and the TV comes on there instead. Finally you may realize that you must change your room location to Living Room, and you can then finally control the TV there.&lt;br /&gt;
&lt;br /&gt;
Once you get used to this concept, though, you&#039;ll find it very useful.  Conveniently, any Orbiter can be set to control any room and choose from the scenarios assigned to that room. No matter which Orbiter you use, the same set of scenarios will be displayed for each specific room. For example, the kitchen scenarios will always be the same, no matter which Orbiter you are using. (The scenarios are assigned by room -- not by Orbiter.) No matter whether you pick up your mobile phone, your web pad, or your remote control, you will always be shown the same list of scenario options for the Living Room.&lt;br /&gt;
&lt;br /&gt;
You have the option of preventing some family members from using certain scenarios. From the [[LinuxMCE Admin Website]], certain scenarios and rooms can be [[Users#Restrict_Access|restricted to certain users]].  Maybe little Suzy&#039;s mobile phone Orbiter should be restricted so that she is only able to control her room and the living room, for example. She would only be able to execute the scenarios in those rooms, but not the Master Bedroom. Other possible options include [[Users#Restrict_Access|requiring a pin code]] to access the scenarios for a particular room.&lt;br /&gt;
&lt;br /&gt;
== Events ==&lt;br /&gt;
&lt;br /&gt;
Devices report events, such as &#039;Playback started&#039; and &#039;Motion Sensor tripped&#039;. If you want something to happen automatically in LinuxMCE, you create Event Handlers that react to these events. For example, you can create an event handler that listens for the &#039;Motion Sensor tripped&#039; event from a motion detector and turns on the lights in response.  An event handler might listen for the &#039;Sunrise&#039; event, which could then prompt the sprinklers to come on. &lt;br /&gt;
&lt;br /&gt;
LinuxMCE creates several default event handlers. In rooms in which you have a TV and lights, an event handler is created that listens for the &#039;Watching Media&#039; event sent by a media player. When the event is detected, the Showtime scenario (which dims the lights) is executed in response.  When you start a movie, therefore, the Showtime activity will be executed and the lights will be dimmed.  There are other default event handlers that monitor for events like &#039;Security Breach&#039; and &#039;Fire Alarm&#039; (from a home security system).&lt;br /&gt;
&lt;br /&gt;
== Controlling an Orbiter ==&lt;br /&gt;
&lt;br /&gt;
To control the system, you use an [[Orbiter]], which is the LinuxMCE term for a remote control.  All [[Orbiters]] have the same basic function: to display the scenarios in the room you&#039;re in and let you select one.  The different Orbiters may [[Selecting_the_Right_UI|display the User Interface slightly differently]], depending on their screen size, but the function and the list of scenarios is always the same. For example, the [[Selecting_the_Right_UI|&amp;quot;UI1&amp;quot; interface]] (which is used on webpads and PDAs) displays the scenarios in horizontal rows. (If there are more than will fit on a row, there will be a &amp;quot;more&amp;quot; button.) A home button is always displayed that takes you to the main menu. On smaller displays, as on mobile phones or desktop phones, there&#039;s not enough room to show the scenarios themselves. The top level menu shows only the categories: Lights, Media, Climate, Security and Telecom. Selecting a category displays the scenarios in that category. &lt;br /&gt;
&lt;br /&gt;
[[Selecting_the_Right_UI|&amp;quot;UI2&amp;quot;]] is the [[Selecting_the_Right_UI|preferred User Interface]] for Media Stations.  Using a traditional I/R remote is not much different from using any other Media Center PC remote.  The menu button brings up the main menu, and you use the &#039;&#039;left/right/up/down/enter&#039;&#039; buttons to navigate it. The &#039;&#039;fast forward/rewind/skip +/skip -&#039;&#039; keys are used for media playback.&lt;br /&gt;
&lt;br /&gt;
If you have a pointing device like a mouse or gyro air mouse, the UI2 interface also supports a unique control architecture that lets you do everything with 3 (programmable) buttons (plus ok and cancel). The 3 buttons are &amp;quot;MEDIA&amp;quot;, &amp;quot;MENU&amp;quot;, &amp;quot;AMBIANCE&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
On a mouse with 3 programmable buttons (such as the [[Using_the_Gyration_Remote_GYR3101US_%28Non-Fiire_Chief%29|gyration]]), these functions correspond to the buttons from left to right. If you are using a traditional 3 button mouse, you can use the F6, F7 and F8 keys on the keyboard for the three programmable functions instead. In both cases, the left mouse button is &amp;quot;ok&amp;quot;, and the right mouse button is &amp;quot;cancel/go back&amp;quot;. &lt;br /&gt;
&lt;br /&gt;
Mouse button behavior is &amp;quot;absolute&amp;quot; when you press and hold the media/menu/ambiance button and &amp;quot;relative&amp;quot; when you tap and release.&lt;br /&gt;
&lt;br /&gt;
The &amp;quot;absolute&amp;quot; behavior is generally more efficient. For example, in the case of the middle button (F7), &amp;quot;absolute&amp;quot; behavior means the action is executed without having to additionally click &amp;quot;ok&amp;quot;.  If you press and hold the middle button (F7) while moving your mouse pointer to the option, then let go, that option is executed. If you instead tap and release the menu button (&amp;quot;relative&amp;quot; behavior), you will only highlight the menu option. You must then press ok (the left mouse button) to execute the option.&lt;br /&gt;
&lt;br /&gt;
Categories appear along the bottom of the screen, and the scenarios in each category popup vertically (like a pull-down menu in a PC, except upside down).  If the main menu isn&#039;t already visible, bring it up by pressing the &amp;quot;start&amp;quot; button on a Windows I/R remote, or the &amp;quot;menu&amp;quot; button on a 3-button mouse.  To exit a menu, use the back button on the I/R remote, the cancel button (right mouse button on a 3-button mouse), or the ESC key on a keyboard.&lt;br /&gt;
&lt;br /&gt;
In UI2 the media is always full screen. If you&#039;re not playing your own media, the background media (i.e. screensaver images) is gallery art from the Internet (using flickr) or [[Use_my_own_pictures_in_the_Screen_Saver|pictures you select]]. If only the screensaver images are displayed on the Media Station, press the menu/middle/F7 button to bring up the menu. Right click/ESC to get rid of it. (This works even if your own media is playing.)&lt;br /&gt;
&lt;br /&gt;
If you&#039;re using UI2&#039;s 3-button navigation model, the normal media control options on a traditional remote are replaced with a single button: &amp;quot;media&amp;quot; (left soft button or F6). Press this and move the pointer up and down for your skip functions (&#039;&#039;ch+, ch-, skip fwd, skip back&#039;&#039;). Move the pointer left and right for speed control (&#039;&#039;rewind, fast forward&#039;&#039;).  The further you move, the faster the media playback changes.  If you hold the button down (the left soft button or F6), your movement will be &amp;quot;absolute&amp;quot;. Instead of the traditional &amp;quot;jog shuttle-type&amp;quot; control, movement to the right skips to the end of your media, and movement to the left skips to the beginning.  Once you get used to it, you will find that navigating media is orders of magnitude faster and easier with this model than with a traditional remote. You can find a spot in a 2 hour movie in only a couple seconds with a click of a single button (compared to a slew of button clicks required using a traditional remote).&lt;br /&gt;
&lt;br /&gt;
Also, in UI2 you can press the &amp;quot;ambiance&amp;quot; button (right soft button or F8). Move up/down to adjust the lights, and left/right to adjust the volume. As with the media playback, if you hold the F8/right soft button down while you move left and right, your volume control is in &amp;quot;absolute&amp;quot; mode (not &amp;quot;relative&amp;quot;). Moving hard right turns up the volume full blast; hard left is mute.  This requires you have a TV or receiver that is serial-controlled, however. LinuxMCE can then directly and instantly set the volume position in sync with your hand movements. (Few TVs and receivers have this feature, unfortunately.)&lt;br /&gt;
&lt;br /&gt;
There are other media control functions besides the most commonly used &#039;&#039;fast fwd/rewind/skip up/skip down&#039;&#039;. You can, for example, choose &#039;subtitles&#039; while watching a DVD, &#039;guide&#039; while watching TV, and &#039;random&#039; while listening to an audio CD. In the UI2 3 button model, these functions appear on the main menu (on the left-most pad, entitled &#039;now playing&#039;) and changes according to the type of media you&#039;re playing. Press the menu button (middle button/F7) to select these options.&lt;br /&gt;
&lt;br /&gt;
This 3 button model is a new concept and very different from traditional navigation. Most people find it much faster once they become accustomed to it.&lt;br /&gt;
&lt;br /&gt;
==Reload Router &amp;amp; Regen Orbiters==&lt;br /&gt;
&lt;br /&gt;
While using LinuxMCE you&#039;ll see sometimes a message asking if you want to [[Quick reload router|reload the router]], or if you want to [[Orbiter Generator|regenerate the Orbiter UIs]] (User Interfaces). In general, these options refresh the LinuxMCE databases so that changes to the system can be recognized.&lt;br /&gt;
&lt;br /&gt;
===Reload Router===&lt;br /&gt;
All devices in LinuxMCE obtain their configuration information from the [[DCERouter]], which is the central piece of software on the Core.  All devices request a list of the other devices in the home from the router, so they can respond to them appropriately.  (For example, an IP camera device might turn on the lights in the room whenever you&#039;re viewing the camera.  To do so, the IP camera needs to know what lights are in the room.) Typically a device requests this information only when it&#039;s starting up.  When you connect additional plug and play devices to the system, these new devices generally will work immediately, but their functionality may not be fully enabled within the LinuxMCE system until the DCE router is reloaded. When the router reloads, it signals all devices on the system to simultaneously reload and re-request the system data. Each existing device can then work with each new device.  This process is known as a &#039;reload&#039;.  It generally takes about 10 seconds.  Every time you add or remove devices, or change a device&#039;s configuration, you may be asked to do a reload. If you&#039;re going to add more devices or make more device changes, you can do the reload once you&#039;re done. If you&#039;re in the middle of watching a movie or TV, you can postpone the reload, since media players generally stop playing during reloads.  Phone calls aren&#039;t affected, though, and TV shows being recorded by MythTV in the background are also unaffected.&lt;br /&gt;
&lt;br /&gt;
===Regen the Orbiter===&lt;br /&gt;
LinuxMCE&#039;s [[Selecting_the_Right_UI|Orbiter User Interfaces]] are all &amp;quot;pre-rendered&amp;quot; in order to be more efficient.  The User Interface source images are all very high resolution, but need to be resized to accommodate the resolution of each Orbiter screen. The Core server has a list of the Orbiters used by your system, and will generate the appropriate User Interface screen for each Orbiter. It will do this each time you request a &amp;quot;regen&amp;quot;. If you have five different types of Orbiters (each with a different type of screen), then five different images will be generated during each regen.&lt;br /&gt;
&lt;br /&gt;
These User Interface screen images are stored in the Core. The appropriate UI image is sent to an Orbiter whenever it is activated. For many low-power devices (like mobile phones or desktop phones) there just isn&#039;t the processing power to do scaling and rendering of a User Interface screen on the fly. They need to be pre-rendered (with text pre-embedded in the images) to be efficient.&lt;br /&gt;
&lt;br /&gt;
Adding new scenarios may result in the creation of new buttons for the User Interface, or changes to the text on existing buttons. Perhaps an entirely new screen will be created.&lt;br /&gt;
&lt;br /&gt;
Until the User Interface images are regenerated, though, you won&#039;t be able to see these new buttons (or screens) on your Orbiter. During the regen, new User Interface images for each type of Orbiter is generated by the Core. This can take about 2-5 minutes, depending on how many Orbiter types you have in your system.&lt;br /&gt;
&lt;br /&gt;
You needn&#039;t do a regen every time you add a scenario. You can wait until you have finished adding all the scenarios. Furthermore, you can also regen only the Orbiter you are currently using by doing a &amp;quot;Quick regen&amp;quot;. This allows you to see the new User Interface (following the addition of new scenarios) without having to do a full regen for all the Orbiters. Once you have finished adding scenarios, then you can do a full regen.&lt;br /&gt;
&lt;br /&gt;
This regen process can be a bit annoying, but is necessary. In future editions of LinuxMCE, it is planned to allow Media Directors, which have a lot more processing power, to render their on-screen Orbiter User Interfaces on the fly (so you don&#039;t have to do a regen each time you add or remove a scenario).&lt;br /&gt;
&lt;br /&gt;
You can do a [[Orbiter Generator#Running OrbiterGen (performing a &amp;quot;regen&amp;quot;)|full Orbiter regen or a Quick regen]] at any time by using buttons on the Core&#039;s LinuxMCE [[Launch Manager]].&lt;br /&gt;
&lt;br /&gt;
== Managing your media ==&lt;br /&gt;
&lt;br /&gt;
LinuxMCE is always scanning for network shares, on Network-Attached Storage (NAS) devices and other Hard Disk Drives (HDDs) of PCs connected to the system (including Windows PCs). Universal Serial Bus (USB) drives are also detected. Every time a LinuxMCE finds a network share, you will be asked if you would like to use it. Whenever you reply &amp;quot;Yes&amp;quot;, the file share can be used by any Media Director on the system. The file share is scanned for media, such as audio, video and photos, and any that are found are then cataloged in the Core&#039;s central database. For example, when you plug in a USB drive on a Media Station in the living room and tell LinuxMCE to use it, the media on the drive will be available to Media Directors in other rooms.&lt;br /&gt;
&lt;br /&gt;
At the moment there is no way to restrict your media for &#039;local use only&#039;; all Media Stations in the LinuxMCE system share the media catalog stored on the Core.  (This is a limitation that will be addressed in the near future. Sometimes it is desirable to attach a USB drive in the master bedroom and not allow it to be shared, for example. &#039;&#039;Note: However, see [[folder lock|this article that describes a method to address this problem]].&#039;&#039;)&lt;br /&gt;
&lt;br /&gt;
Storage devices (NAS, USB drives, extra HDDs on the Core or Media Directors) are referred to as &amp;quot;Extra Drives&amp;quot;.  When an extra drive is added, it is listed in the device tree in &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Advanced--&amp;gt;Configuration--&amp;gt;[[Devices]]&#039;&#039;&#039;.  Under &#039;Core&#039; you&#039;ll see a device listed for each HDD in the Core, as well as for each NAS device. Under each Media Station will be listed the HDDs in that Media Station.  By clicking on the device you can change the device&#039;s properties, such as the mount username/password.  Each NAS device, and each file share on another PC, will show as a device listed under the Core; each is considered a child of the Core.&lt;br /&gt;
&lt;br /&gt;
LinuxMCE creates a top level folder for &#039;public&#039; media. This folder can be used by every user in the system.  A &#039;private&#039; media folder is also created for each user.  Within each of those folders are sub-folders, labeled &#039;audio&#039;, &#039;video&#039;, &#039;pictures&#039;, &#039;data&#039; and &#039;other&#039;.  Within each of those will also be sub-folders for the extra storage devices (NAS, USB, extra internal drives, etc).  When you attach an extra storage device, you can specify whether the default directory structure should be used for it. Alternatively, you can specify &#039;just make it public&#039; or &#039;make it private&#039;.&lt;br /&gt;
&lt;br /&gt;
Here&#039;s an example.  Let&#039;s say you have 2 users: john and mary.  You connect 3 storage devices:&lt;br /&gt;
# a NAS, for which you specify &#039;use default directory structure&#039;. It is named &#039;Generic Network Storage [50]&#039;&lt;br /&gt;
# a USB drive for which you specify &#039;make it all public&#039;. It is named &#039;USB Drive [51]&#039;&lt;br /&gt;
# a SATA drive for which you choose &#039;make it private for john&#039;. It is named &#039;General Internal HDD [52]&lt;br /&gt;
&lt;br /&gt;
Now let&#039;s say you&#039;re running Windows. Go to Network Neighborhood and find the LinuxMCE Core server.  The directory tree ought to look like this:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
public&lt;br /&gt;
  video&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  audio&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  pictures&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  data&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  other&lt;br /&gt;
    USB Drive [51]&lt;br /&gt;
john&lt;br /&gt;
  video&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  audio&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  pictures&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  data&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  other&lt;br /&gt;
    General Internal HDD [52]&lt;br /&gt;
mary&lt;br /&gt;
  video&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  audio&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  pictures&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  data&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  other&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Whether you put your media under video, audio, pictures, data or other is unimportant.  It will be scanned by LinuxMCE anyway. The contents of &amp;quot;General Internal HDD [52]&amp;quot; will be displayed in the folder john/other/General Internal HDD [52]. The contents of USB Drive [51] will be displayed in the folder public/other/USB Drive [51].  When John browses the contents in Network Neighborhood, he will be asked for his username and password. He can then access the content in both the public folder as well as the &amp;quot;john&amp;quot; folders (including General Internal HDD [52]).  When Mary browses the contents with her username and password, she will see both the public and &amp;quot;mary&amp;quot; folders. She will not be able to see anything on General Internal HDD [52], however, since that drive was specified to be private for John.&lt;br /&gt;
&lt;br /&gt;
In the case of John&#039;s private media, it won&#039;t be displayed in the LinuxMCE media browser unless you click &#039;Sources&#039;--&amp;gt;&#039;John&#039;. However you &#039;&#039;can&#039;&#039; see the contents of General Internal HDD [52] (unless you deselect &#039;Sources&#039;--&amp;gt;&#039;Public&#039; from the media browser).  Generic Network Storage [50] would be different, however, since you specified to use the default directory structure for it.  LinuxMCE will have created public directories on Generic Network Storage [50] for public video and public audio, as well as for john&#039;s video and mary&#039;s audio. The media file browser will show only the media that is in the public directories. (The same is true with the Windows Network Neighborhood browser.) &lt;br /&gt;
&lt;br /&gt;
If Generic Network Storage [50] has existing media in the top (root) folder, you won&#039;t see it listed anywhere.&lt;br /&gt;
&lt;br /&gt;
It is generally recommended, therefore, that when you add a new (blank) &amp;quot;extra&amp;quot; storage device, you choose to use the default directory structure on it.  When you rip media to that device, the media can then be made either public or private, and LinuxMCE will automatically put it in the correct folder (audio, video, etc.).&lt;br /&gt;
&lt;br /&gt;
If you connect an extra storage device that already has media on it, however, and that media isn&#039;t already organized in LinuxMCE&#039;s default directory structure, it&#039;s easiest if you simply &#039;make it all public&#039; or &#039;make it all private&#039;. If you were to &#039;use the default directory structure&#039;, you would need to manually move the files from the existing folders into one of the directory folders that LinuxMCE would then create for you.&lt;br /&gt;
&lt;br /&gt;
When you rip files, you have the option of copying them to the Core.  If you rip a CD and make it public, it will be stored in public/audio.  If you go into Network Neighborhood and add a folder under public/audio, you would essentially be adding a folder on the Core. If you add a folder under public/audio/Generic Network Storage [50], you would be adding it to Generic Network Storage [50].&lt;br /&gt;
&lt;br /&gt;
This concept behind drive/network drive management is not the same as the method to which Linux and Windows users are accustomed. In Windows, for example, each network device shows up separately; they are never grouped together.  There is an advantage to the way LinuxMCE manages drives. It&#039;s much simpler to add devices when you&#039;re a novice and don&#039;t understand networking. Further, if you&#039;re using an infrared remote control, you can manage drives with a single &#039;yes&#039; or &#039;no,&#039; click, which is very convenient. Lastly, all your media content is cataloged and presented in the same structure throughout the system, no matter which Media Director you&#039;re using or what room you&#039;re in.&lt;br /&gt;
&lt;br /&gt;
In Windows, by comparison, if you connect a USB drive to a Windows PC in the bedroom, you won&#039;t see that content in the living room unless you 1) open file explorer, 2) create a new network share for it, 3) go into the living room, and 4) create a new mapped network drive there. (That isn&#039;t so easy to do with an infrared remote and without some knowledge of networking.)  Further, you wouldn&#039;t be able to see the media in any other room in the house unless you were to also create mapped network shares in those rooms as well. &lt;br /&gt;
&lt;br /&gt;
With LinuxMCE, when you connect a USB drive, for example, you can &#039;make it all public&#039;; the media will be available everywhere. No other typing is required. With LinuxMCE, instead of managing multiple network shares and mapped drives, you can choose the Core&#039;s public folders in the Network Neighborhood browser from anywhere in the home, without having to know which storage devices the media is actually on.  When you remove a USB drive from a Media Station, that media instantly disappears from the catalog displayed in every room. If you reattach it, it will re-appear.&lt;br /&gt;
&lt;br /&gt;
You can also backup the media securely on the Core. LinuxMCE has built-in [http://en.wikipedia.org/wiki/RAID RAID] 5 (see &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Advanced--&amp;gt;[[RAID]]&#039;&#039;&#039;), so its HDD has similar backup capabilities to an [[NAS]].&lt;br /&gt;
&lt;br /&gt;
To change the name of an extra device, go to the &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Advanced--&amp;gt;Configuration--&amp;gt;[[Devices]]&#039;&#039;&#039; and under the Core you will see listed the HDDs in the core and any connected NAS devices. Under each Media Station you will see the HDDs in that Media Station. All are given default names.  You can change the description, which will also change the folder name.  In the above example, changing &amp;quot;USB Drive [51]&amp;quot; to &amp;quot;Tokyo&amp;quot; means the directory public/other/USB Drive [51] would change to public/other/Tokyo.&lt;br /&gt;
&lt;br /&gt;
In the &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Files &amp;amp; Media--&amp;gt;[[Media Files Sync]]&#039;&#039;&#039; is listed the files in the system by folder. You can change the cover art and attributes.  If a file is shown with a check box, the file exists both on the local disk as well as in LinuxMCE&#039;s master catalog.  If it has a different icon, then LinuxMCE hasn&#039;t finished cataloging the media; just be patient. It should appear with a check mark soon (depending on how much new media was added). Under Files &amp;amp; Media there is also a cover art scan utility that will find cover art, as well as other attributes (actor, genre, etc.) obtained from Amazon.&lt;br /&gt;
&lt;br /&gt;
====Background details====&lt;br /&gt;
Here&#039;s how it works:  [[UpdateMedia]] is a daemon that constantly scans for media files in the /home/public and the /home/user_xxx folder created for each user. Any added media is cataloged in the pluto_media database File table, and attributes and cover art go into the Attribute and Picture tables.  Under /home/public and /home/users_xxx is a data subfolder which contains the actual video, audio, pictures folders.  (The /home/user_xxx directories themselves contain the system files for each user (like email boxes) as well as the main login for that user (in a &amp;quot;data&amp;quot; subfolder).&lt;br /&gt;
&lt;br /&gt;
Extra devices are mounted as /mnt/device/xxx (where xxx is the device number).  The mount point is the same whether it&#039;s a local drive or not.  For example, USB drive [50] in a Media Station may be mounted as a local device named /mnt/device/50, but is also mounted as a Samba mount on other Media Stations as /mnt/device/50.  The Core and the Media Stations all use the same mount names (/mnt/device/).&lt;br /&gt;
&lt;br /&gt;
Within the /home/public/data and /home/user_xxx/data are symlinks to the physical directories specified by /mnt/device/xxx.  Since the Core and all Media Stations mount the same /home directory (and all have the same /mnt/device mounts), they will all show the same files.  Therefore, if the [[UpdateMedia]] daemon locates the file /home/public/data/audio/Generic Internal Drive [50]/The Beatles/Let it be.mp3, that file will be listed on every Media Station, too.&lt;br /&gt;
&lt;br /&gt;
[[Category: Tutorials]]&lt;/div&gt;</summary>
		<author><name>Juanfe</name></author>
	</entry>
	<entry>
		<id>http://wiki.linuxmce.org/index.php?title=Usage_Intro&amp;diff=14823</id>
		<title>Usage Intro</title>
		<link rel="alternate" type="text/html" href="http://wiki.linuxmce.org/index.php?title=Usage_Intro&amp;diff=14823"/>
		<updated>2008-07-12T22:23:48Z</updated>

		<summary type="html">&lt;p&gt;Juanfe: /* Managing your media */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{| align=&amp;quot;right&amp;quot;&lt;br /&gt;
  | __TOC__&lt;br /&gt;
  |}&lt;br /&gt;
LinuxMCE&#039;s main concepts are [[Devices]], Commands (aka [[Scenarios]] and Activities), and [[Events]]. An  [[Orbiter]] is the device that displays the User Interface. It can be a [[Media Director|Media Station]], web pad, mobile phone, or other remote control device. The Orbiter User Interface is standardized for all Orbiters.&lt;br /&gt;
&lt;br /&gt;
== Devices ==&lt;br /&gt;
&lt;br /&gt;
A device is generally a piece of hardware or software, like the Xine Media Player, a light switch, or a mobile phone.  Devices have three functions, abbreviated &amp;quot;DCE&amp;quot; (Data, Commands, Events): &lt;br /&gt;
&lt;br /&gt;
# Retrieve configuration &#039;&#039;&#039;data&#039;&#039;&#039;&lt;br /&gt;
# Perform a &#039;&#039;&#039;command&#039;&#039;&#039; (turn on, turn off, fast forward, etc.)&lt;br /&gt;
# Report certain triggered &#039;&#039;&#039;events&#039;&#039;&#039; (e.g. &#039;motion detected&#039;, &#039;playback started&#039;, etc.)&lt;br /&gt;
&lt;br /&gt;
== Scenarios ==&lt;br /&gt;
&lt;br /&gt;
&amp;quot;[[Scenarios]]&amp;quot;, &amp;quot;Activities&amp;quot;, and &amp;quot;Command Groups&amp;quot; are interchangeable terms -- they mean the same thing.  A scenario is a group of commands that can be sent to a device (or series of devices).  In LinuxMCE, the default Orbiter main menu consists of several scenario categories, grouped by room. These categories are&lt;br /&gt;
&lt;br /&gt;
* Lighting&lt;br /&gt;
* Media&lt;br /&gt;
* Climate&lt;br /&gt;
* Telecom&lt;br /&gt;
* Security&lt;br /&gt;
&lt;br /&gt;
(These default categories are arbitrary and are set up at installation.) To perform an action in LinuxMCE, a scenario is chosen from one of these categories (located on the main menu of an Orbiter). &lt;br /&gt;
&lt;br /&gt;
For example, in rooms which have both a TV and lights, LinuxMCE automatically creates a scenario called &#039;Showtime.&#039; This scenario dims the lights to 10% whenever the TV starts playing.  In rooms with a PVR or other TV-enabled device, another scenario is created called &#039;TV&#039; (in the &#039;Media&#039; category) to start the TV.  Another scenario in the &#039;Media&#039; category called &#039;Video&#039; sends a command to the Orbiter to list your video content. Telecom scenarios are created to make phone calls. Security scenarios are created to view cameras and to arm an alarm.&lt;br /&gt;
&lt;br /&gt;
Some [[What_scenarios_are_created_automatically%3F|default scenarios]] are created for you at installation. A fully-functional system can run using only the default scenarios, if you choose. You can also change or remove the default scenarios or add new ones. This is done though the &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Wizard--&amp;gt;[[Scenarios]]&#039;&#039;&#039; menu. When creating a scenario, the [[LinuxMCE Admin Website]] will show you the most appropriate wizard, based on the category you pick.  If you&#039;re adding an activity in the lighting category, for example, the wizard will display a list of the lights in the room and let you pick which ones to turn off.  If you&#039;re creating a scenario in the security category, it will list the installed cameras and will allow you to select which ones to display.&lt;br /&gt;
&lt;br /&gt;
A scenario can send a command to any device in the system. By default, scenarios in the lighting category show you the room lights, allowing you to select which ones to which to send commands. However, from the &#039;&#039;&#039;Wizard--&amp;gt;[[Scenarios]]&#039;&#039;&#039; menu for the specific scenario, you can also specify a command to any device in your home. You could make a phone call, for example, even from a scenario in the lighting category.&lt;br /&gt;
&lt;br /&gt;
Certain scenarios are assigned to certain rooms by default. This can be customized, however. When you manually select a room from the Orbiter main menu, the default scenarios for that room are displayed. In general they control devices in that room, but this can also be changed. If your kitchen is near the garage and you want a scenario to &#039;turn off the garage light&#039;, you can assign a scenario to the room &#039;kitchen&#039; that will do just that. It doesn&#039;t matter that the light is in the garage.&lt;br /&gt;
&lt;br /&gt;
For a Media Director, the on-screen Orbiter User Interface appears on the TV screen. It is manipulated by the mouse/keyboard or remote control connected to your Media Director. By default it is set to display the scenarios for the room in which the Media Director is located.&lt;br /&gt;
&lt;br /&gt;
In contrast, a mobile Orbiter (such as a webpad) can be carried throughout the house. It must be able to select the scenarios for multiple rooms. Fortunately, the option to manually select which room you are currently in is available on every Orbiter&#039;s main menu.&lt;br /&gt;
&lt;br /&gt;
This can occasionally cause some confusion. Perhaps both the Living Room and the Bedroom have a scenario called &#039;TV&#039;. You may have a web pad that is in the Bedroom, but you then carry it to the Living Room. You may forget to tell the web pad that it&#039;s now in the Living Room (at the bottom of the Orbiter screen it will still say &#039;Bedroom&#039;). You hit the &#039;TV&#039; button expecting the Living Room TV to come on, but in fact you&#039;re still controlling the Bedroom and the TV comes on there instead. Finally you may realize that you must change your room location to Living Room, and you can then finally control the TV there.&lt;br /&gt;
&lt;br /&gt;
Once you get used to this concept, though, you&#039;ll find it very useful.  Conveniently, any Orbiter can be set to control any room and choose from the scenarios assigned to that room. No matter which Orbiter you use, the same set of scenarios will be displayed for each specific room. For example, the kitchen scenarios will always be the same, no matter which Orbiter you are using. (The scenarios are assigned by room -- not by Orbiter.) No matter whether you pick up your mobile phone, your web pad, or your remote control, you will always be shown the same list of scenario options for the Living Room.&lt;br /&gt;
&lt;br /&gt;
You have the option of preventing some family members from using certain scenarios. From the [[LinuxMCE Admin Website]], certain scenarios and rooms can be [[Users#Restrict_Access|restricted to certain users]].  Maybe little Suzy&#039;s mobile phone Orbiter should be restricted so that she is only able to control her room and the living room, for example. She would only be able to execute the scenarios in those rooms, but not the Master Bedroom. Other possible options include [[Users#Restrict_Access|requiring a pin code]] to access the scenarios for a particular room.&lt;br /&gt;
&lt;br /&gt;
== Events ==&lt;br /&gt;
&lt;br /&gt;
Devices report events, such as &#039;Playback started&#039; and &#039;Motion Sensor tripped&#039;. If you want something to happen automatically in LinuxMCE, you create Event Handlers that react to these events. For example, you can create an event handler that listens for the &#039;Motion Sensor tripped&#039; event from a motion detector and turns on the lights in response.  An event handler might listen for the &#039;Sunrise&#039; event, which could then prompt the sprinklers to come on. &lt;br /&gt;
&lt;br /&gt;
LinuxMCE creates several default event handlers. In rooms in which you have a TV and lights, an event handler is created that listens for the &#039;Watching Media&#039; event sent by a media player. When the event is detected, the Showtime scenario (which dims the lights) is executed in response.  When you start a movie, therefore, the Showtime activity will be executed and the lights will be dimmed.  There are other default event handlers that monitor for events like &#039;Security Breach&#039; and &#039;Fire Alarm&#039; (from a home security system).&lt;br /&gt;
&lt;br /&gt;
== Controlling an Orbiter ==&lt;br /&gt;
&lt;br /&gt;
To control the system, you use an [[Orbiter]], which is the LinuxMCE term for a remote control.  All [[Orbiters]] have the same basic function: to display the scenarios in the room you&#039;re in and let you select one.  The different Orbiters may [[Selecting_the_Right_UI|display the User Interface slightly differently]], depending on their screen size, but the function and the list of scenarios is always the same. For example, the [[Selecting_the_Right_UI|&amp;quot;UI1&amp;quot; interface]] (which is used on webpads and PDAs) displays the scenarios in horizontal rows. (If there are more than will fit on a row, there will be a &amp;quot;more&amp;quot; button.) A home button is always displayed that takes you to the main menu. On smaller displays, as on mobile phones or desktop phones, there&#039;s not enough room to show the scenarios themselves. The top level menu shows only the categories: Lights, Media, Climate, Security and Telecom. Selecting a category displays the scenarios in that category. &lt;br /&gt;
&lt;br /&gt;
[[Selecting_the_Right_UI|&amp;quot;UI2&amp;quot;]] is the [[Selecting_the_Right_UI|preferred User Interface]] for Media Stations.  Using a traditional I/R remote is not much different from using any other Media Center PC remote.  The menu button brings up the main menu, and you use the &#039;&#039;left/right/up/down/enter&#039;&#039; buttons to navigate it. The &#039;&#039;fast forward/rewind/skip +/skip -&#039;&#039; keys are used for media playback.&lt;br /&gt;
&lt;br /&gt;
If you have a pointing device like a mouse or gyro air mouse, the UI2 interface also supports a unique control architecture that lets you do everything with 3 (programmable) buttons (plus ok and cancel). The 3 buttons are &amp;quot;MEDIA&amp;quot;, &amp;quot;MENU&amp;quot;, &amp;quot;AMBIANCE&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
On a mouse with 3 programmable buttons (such as the [[Using_the_Gyration_Remote_GYR3101US_%28Non-Fiire_Chief%29|gyration]]), these functions correspond to the buttons from left to right. If you are using a traditional 3 button mouse, you can use the F6, F7 and F8 keys on the keyboard for the three programmable functions instead. In both cases, the left mouse button is &amp;quot;ok&amp;quot;, and the right mouse button is &amp;quot;cancel/go back&amp;quot;. &lt;br /&gt;
&lt;br /&gt;
Mouse button behavior is &amp;quot;absolute&amp;quot; when you press and hold the media/menu/ambiance button and &amp;quot;relative&amp;quot; when you tap and release.&lt;br /&gt;
&lt;br /&gt;
The &amp;quot;absolute&amp;quot; behavior is generally more efficient. For example, in the case of the middle button (F7), &amp;quot;absolute&amp;quot; behavior means the action is executed without having to additionally click &amp;quot;ok&amp;quot;.  If you press and hold the middle button (F7) while moving your mouse pointer to the option, then let go, that option is executed. If you instead tap and release the menu button (&amp;quot;relative&amp;quot; behavior), you will only highlight the menu option. You must then press ok (the left mouse button) to execute the option.&lt;br /&gt;
&lt;br /&gt;
Categories appear along the bottom of the screen, and the scenarios in each category popup vertically (like a pull-down menu in a PC, except upside down).  If the main menu isn&#039;t already visible, bring it up by pressing the &amp;quot;start&amp;quot; button on a Windows I/R remote, or the &amp;quot;menu&amp;quot; button on a 3-button mouse.  To exit a menu, use the back button on the I/R remote, the cancel button (right mouse button on a 3-button mouse), or the ESC key on a keyboard.&lt;br /&gt;
&lt;br /&gt;
In UI2 the media is always full screen. If you&#039;re not playing your own media, the background media (i.e. screensaver images) is gallery art from the Internet (using flickr) or [[Use_my_own_pictures_in_the_Screen_Saver|pictures you select]]. If only the screensaver images are displayed on the Media Station, press the menu/middle/F7 button to bring up the menu. Right click/ESC to get rid of it. (This works even if your own media is playing.)&lt;br /&gt;
&lt;br /&gt;
If you&#039;re using UI2&#039;s 3-button navigation model, the normal media control options on a traditional remote are replaced with a single button: &amp;quot;media&amp;quot; (left soft button or F6). Press this and move the pointer up and down for your skip functions (&#039;&#039;ch+, ch-, skip fwd, skip back&#039;&#039;). Move the pointer left and right for speed control (&#039;&#039;rewind, fast forward&#039;&#039;).  The further you move, the faster the media playback changes.  If you hold the button down (the left soft button or F6), your movement will be &amp;quot;absolute&amp;quot;. Instead of the traditional &amp;quot;jog shuttle-type&amp;quot; control, movement to the right skips to the end of your media, and movement to the left skips to the beginning.  Once you get used to it, you will find that navigating media is orders of magnitude faster and easier with this model than with a traditional remote. You can find a spot in a 2 hour movie in only a couple seconds with a click of a single button (compared to a slew of button clicks required using a traditional remote).&lt;br /&gt;
&lt;br /&gt;
Also, in UI2 you can press the &amp;quot;ambiance&amp;quot; button (right soft button or F8). Move up/down to adjust the lights, and left/right to adjust the volume. As with the media playback, if you hold the F8/right soft button down while you move left and right, your volume control is in &amp;quot;absolute&amp;quot; mode (not &amp;quot;relative&amp;quot;). Moving hard right turns up the volume full blast; hard left is mute.  This requires you have a TV or receiver that is serial-controlled, however. LinuxMCE can then directly and instantly set the volume position in sync with your hand movements. (Few TVs and receivers have this feature, unfortunately.)&lt;br /&gt;
&lt;br /&gt;
There are other media control functions besides the most commonly used &#039;&#039;fast fwd/rewind/skip up/skip down&#039;&#039;. You can, for example, choose &#039;subtitles&#039; while watching a DVD, &#039;guide&#039; while watching TV, and &#039;random&#039; while listening to an audio CD. In the UI2 3 button model, these functions appear on the main menu (on the left-most pad, entitled &#039;now playing&#039;) and changes according to the type of media you&#039;re playing. Press the menu button (middle button/F7) to select these options.&lt;br /&gt;
&lt;br /&gt;
This 3 button model is a new concept and very different from traditional navigation. Most people find it much faster once they become accustomed to it.&lt;br /&gt;
&lt;br /&gt;
==Reload Router &amp;amp; Regen Orbiters==&lt;br /&gt;
&lt;br /&gt;
While using LinuxMCE you&#039;ll see sometimes a message asking if you want to [[Quick reload router|reload the router]], or if you want to [[Orbiter Generator|regenerate the Orbiter UIs]] (User Interfaces). In general, these options refresh the LinuxMCE databases so that changes to the system can be recognized.&lt;br /&gt;
&lt;br /&gt;
===Reload Router===&lt;br /&gt;
All devices in LinuxMCE obtain their configuration information from the [[DCERouter]], which is the central piece of software on the Core.  All devices request a list of the other devices in the home from the router, so they can respond to them appropriately.  (For example, an IP camera device might turn on the lights in the room whenever you&#039;re viewing the camera.  To do so, the IP camera needs to know what lights are in the room.) Typically a device requests this information only when it&#039;s starting up.  When you connect additional plug and play devices to the system, these new devices generally will work immediately, but their functionality may not be fully enabled within the LinuxMCE system until the DCE router is reloaded. When the router reloads, it signals all devices on the system to simultaneously reload and re-request the system data. Each existing device can then work with each new device.  This process is known as a &#039;reload&#039;.  It generally takes about 10 seconds.  Every time you add or remove devices, or change a device&#039;s configuration, you may be asked to do a reload. If you&#039;re going to add more devices or make more device changes, you can do the reload once you&#039;re done. If you&#039;re in the middle of watching a movie or TV, you can postpone the reload, since media players generally stop playing during reloads.  Phone calls aren&#039;t affected, though, and TV shows being recorded by MythTV in the background are also unaffected.&lt;br /&gt;
&lt;br /&gt;
===Regen the Orbiter===&lt;br /&gt;
LinuxMCE&#039;s [[Selecting_the_Right_UI|Orbiter User Interfaces]] are all &amp;quot;pre-rendered&amp;quot; in order to be more efficient.  The User Interface source images are all very high resolution, but need to be resized to accommodate the resolution of each Orbiter screen. The Core server has a list of the Orbiters used by your system, and will generate the appropriate User Interface screen for each Orbiter. It will do this each time you request a &amp;quot;regen&amp;quot;. If you have five different types of Orbiters (each with a different type of screen), then five different images will be generated during each regen.&lt;br /&gt;
&lt;br /&gt;
These User Interface screen images are stored in the Core. The appropriate UI image is sent to an Orbiter whenever it is activated. For many low-power devices (like mobile phones or desktop phones) there just isn&#039;t the processing power to do scaling and rendering of a User Interface screen on the fly. They need to be pre-rendered (with text pre-embedded in the images) to be efficient.&lt;br /&gt;
&lt;br /&gt;
Adding new scenarios may result in the creation of new buttons for the User Interface, or changes to the text on existing buttons. Perhaps an entirely new screen will be created.&lt;br /&gt;
&lt;br /&gt;
Until the User Interface images are regenerated, though, you won&#039;t be able to see these new buttons (or screens) on your Orbiter. During the regen, new User Interface images for each type of Orbiter is generated by the Core. This can take about 2-5 minutes, depending on how many Orbiter types you have in your system.&lt;br /&gt;
&lt;br /&gt;
You needn&#039;t do a regen every time you add a scenario. You can wait until you have finished adding all the scenarios. Furthermore, you can also regen only the Orbiter you are currently using by doing a &amp;quot;Quick regen&amp;quot;. This allows you to see the new User Interface (following the addition of new scenarios) without having to do a full regen for all the Orbiters. Once you have finished adding scenarios, then you can do a full regen.&lt;br /&gt;
&lt;br /&gt;
This regen process can be a bit annoying, but is necessary. In future editions of LinuxMCE, it is planned to allow Media Directors, which have a lot more processing power, to render their on-screen Orbiter User Interfaces on the fly (so you don&#039;t have to do a regen each time you add or remove a scenario).&lt;br /&gt;
&lt;br /&gt;
You can do a [[Orbiter Generator#Running OrbiterGen (performing a &amp;quot;regen&amp;quot;)|full Orbiter regen or a Quick regen]] at any time by using buttons on the Core&#039;s LinuxMCE [[Launch Manager]].&lt;br /&gt;
&lt;br /&gt;
== Managing your media ==&lt;br /&gt;
&lt;br /&gt;
LinuxMCE is always scanning for network shares, on Network-Attached Storage (NAS) devices and other Hard Disk Drives (HDDs) of PCs connected to the system (including Windows PCs). Universal Serial Bus (USB) drives are also detected. Every time a LinuxMCE finds a network share, you will be asked if you would like to use it. Whenever you reply &amp;quot;Yes&amp;quot;, the file share can be used by any Media Director on the system. The file share is scanned for media, such as audio, video and photos,and any that are found \are then cataloged in the Core&#039;s central database. For example, when you plug in a USB drive on a Media Station in the living room and tell LinuxMCE to use it, the media on the drive will be available to Media Directors in other rooms.&lt;br /&gt;
&lt;br /&gt;
At the moment there is no way to restrict your media for &#039;local use only&#039;; all Media Stations in the LinuxMCE system share the media catalog stored on the Core.  (This is a limitation that will be addressed in the near future. Sometimes it is desirable to attach a USB drive in the master bedroom and not allow it to be shared, for example. &#039;&#039;Note: However, see [[folder lock|this article that describes a method to address this problem]].&#039;&#039;)&lt;br /&gt;
&lt;br /&gt;
Storage devices (NAS, USB drives, extra HDDs on the Core or Media Directors) are referred to as &amp;quot;Extra Drives&amp;quot;.  When an extra drive is added, it is listed in the device tree in &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Advanced--&amp;gt;Configuration--&amp;gt;[[Devices]]&#039;&#039;&#039;.  Under &#039;Core&#039; you&#039;ll see a device listed for each HDD in the Core, as well as for each NAS device. Under each Media Station will be listed the HDDs in that Media Station.  By clicking on the device you can change the device&#039;s properties, such as the mount username/password.  Each NAS device, and each file share on another PC, will show as a device listed under the Core; each is considered a child of the Core.&lt;br /&gt;
&lt;br /&gt;
LinuxMCE creates a top level folder for &#039;public&#039; media. This folder can be used by every user in the system.  A &#039;private&#039; media folder is also created for each user.  Within each of those folders are sub-folders, labeled &#039;audio&#039;, &#039;video&#039;, &#039;pictures&#039;, &#039;data&#039; and &#039;other&#039;.  Within each of those will also be sub-folders for the extra storage devices (NAS, USB, extra internal drives, etc).  When you attach an extra storage device, you can specify whether the default directory structure should be used for it. Alternatively, you can specify &#039;just make it public&#039; or &#039;make it private&#039;.&lt;br /&gt;
&lt;br /&gt;
Here&#039;s an example.  Let&#039;s say you have 2 users: john and mary.  You connect 3 storage devices:&lt;br /&gt;
# a NAS, for which you specify &#039;use default directory structure&#039;. It is named &#039;Generic Network Storage [50]&#039;&lt;br /&gt;
# a USB drive for which you specify &#039;make it all public&#039;. It is named &#039;USB Drive [51]&#039;&lt;br /&gt;
# a SATA drive for which you choose &#039;make it private for john&#039;. It is named &#039;General Internal HDD [52]&lt;br /&gt;
&lt;br /&gt;
Now let&#039;s say you&#039;re running Windows. Go to Network Neighborhood and find the LinuxMCE Core server.  The directory tree ought to look like this:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
public&lt;br /&gt;
  video&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  audio&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  pictures&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  data&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  other&lt;br /&gt;
    USB Drive [51]&lt;br /&gt;
john&lt;br /&gt;
  video&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  audio&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  pictures&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  data&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  other&lt;br /&gt;
    General Internal HDD [52]&lt;br /&gt;
mary&lt;br /&gt;
  video&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  audio&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  pictures&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  data&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  other&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Whether you put your media under video, audio, pictures, data or other is unimportant.  It will be scanned by LinuxMCE anyway. The contents of &amp;quot;General Internal HDD [52]&amp;quot; will be displayed in the folder john/other/General Internal HDD [52]. The contents of USB Drive [51] will be displayed in the folder public/other/USB Drive [51].  When John browses the contents in Network Neighborhood, he will be asked for his username and password. He can then access the content in both the public folder as well as the &amp;quot;john&amp;quot; folders (including General Internal HDD [52]).  When Mary browses the contents with her username and password, she will see both the public and &amp;quot;mary&amp;quot; folders. She will not be able to see anything on General Internal HDD [52], however, since that drive was specified to be private for John.&lt;br /&gt;
&lt;br /&gt;
In the case of John&#039;s private media, it won&#039;t be displayed in the LinuxMCE media browser unless you click &#039;Sources&#039;--&amp;gt;&#039;John&#039;. However you &#039;&#039;can&#039;&#039; see the contents of General Internal HDD [52] (unless you deselect &#039;Sources&#039;--&amp;gt;&#039;Public&#039; from the media browser).  Generic Network Storage [50] would be different, however, since you specified to use the default directory structure for it.  LinuxMCE will have created public directories on Generic Network Storage [50] for public video and public audio, as well as for john&#039;s video and mary&#039;s audio. The media file browser will show only the media that is in the public directories. (The same is true with the Windows Network Neighborhood browser.) &lt;br /&gt;
&lt;br /&gt;
If Generic Network Storage [50] has existing media in the top (root) folder, you won&#039;t see it listed anywhere.&lt;br /&gt;
&lt;br /&gt;
It is generally recommended, therefore, that when you add a new (blank) &amp;quot;extra&amp;quot; storage device, you choose to use the default directory structure on it.  When you rip media to that device, the media can then be made either public or private, and LinuxMCE will automatically put it in the correct folder (audio, video, etc.).&lt;br /&gt;
&lt;br /&gt;
If you connect an extra storage device that already has media on it, however, and that media isn&#039;t already organized in LinuxMCE&#039;s default directory structure, it&#039;s easiest if you simply &#039;make it all public&#039; or &#039;make it all private&#039;. If you were to &#039;use the default directory structure&#039;, you would need to manually move the files from the existing folders into one of the directory folders that LinuxMCE would then create for you.&lt;br /&gt;
&lt;br /&gt;
When you rip files, you have the option of copying them to the Core.  If you rip a CD and make it public, it will be stored in public/audio.  If you go into Network Neighborhood and add a folder under public/audio, you would essentially be adding a folder on the Core. If you add a folder under public/audio/Generic Network Storage [50], you would be adding it to Generic Network Storage [50].&lt;br /&gt;
&lt;br /&gt;
This concept behind drive/network drive management is not the same as the method to which Linux and Windows users are accustomed. In Windows, for example, each network device shows up separately; they are never grouped together.  There is an advantage to the way LinuxMCE manages drives. It&#039;s much simpler to add devices when you&#039;re a novice and don&#039;t understand networking. Further, if you&#039;re using an infrared remote control, you can manage drives with a single &#039;yes&#039; or &#039;no,&#039; click, which is very convenient. Lastly, all your media content is cataloged and presented in the same structure throughout the system, no matter which Media Director you&#039;re using or what room you&#039;re in.&lt;br /&gt;
&lt;br /&gt;
In Windows, by comparison, if you connect a USB drive to a Windows PC in the bedroom, you won&#039;t see that content in the living room unless you 1) open file explorer, 2) create a new network share for it, 3) go into the living room, and 4) create a new mapped network drive there. (That isn&#039;t so easy to do with an infrared remote and without some knowledge of networking.)  Further, you wouldn&#039;t be able to see the media in any other room in the house unless you were to also create mapped network shares in those rooms as well. &lt;br /&gt;
&lt;br /&gt;
With LinuxMCE, when you connect a USB drive, for example, you can &#039;make it all public&#039;; the media will be available everywhere. No other typing is required. With LinuxMCE, instead of managing multiple network shares and mapped drives, you can choose the Core&#039;s public folders in the Network Neighborhood browser from anywhere in the home, without having to know which storage devices the media is actually on.  When you remove a USB drive from a Media Station, that media instantly disappears from the catalog displayed in every room. If you reattach it, it will re-appear.&lt;br /&gt;
&lt;br /&gt;
You can also backup the media securely on the Core. LinuxMCE has built-in [http://en.wikipedia.org/wiki/RAID RAID] 5 (see &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Advanced--&amp;gt;[[RAID]]&#039;&#039;&#039;), so its HDD has similar backup capabilities to an [[NAS]].&lt;br /&gt;
&lt;br /&gt;
To change the name of an extra device, go to the &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Advanced--&amp;gt;Configuration--&amp;gt;[[Devices]]&#039;&#039;&#039; and under the Core you will see listed the HDDs in the core and any connected NAS devices. Under each Media Station you will see the HDDs in that Media Station. All are given default names.  You can change the description, which will also change the folder name.  In the above example, changing &amp;quot;USB Drive [51]&amp;quot; to &amp;quot;Tokyo&amp;quot; means the directory public/other/USB Drive [51] would change to public/other/Tokyo.&lt;br /&gt;
&lt;br /&gt;
In the &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Files &amp;amp; Media--&amp;gt;[[Media Files Sync]]&#039;&#039;&#039; is listed the files in the system by folder. You can change the cover art and attributes.  If a file is shown with a check box, the file exists both on the local disk as well as in LinuxMCE&#039;s master catalog.  If it has a different icon, then LinuxMCE hasn&#039;t finished cataloging the media; just be patient. It should appear with a check mark soon (depending on how much new media was added). Under Files &amp;amp; Media there is also a cover art scan utility that will find cover art, as well as other attributes (actor, genre, etc.) obtained from Amazon.&lt;br /&gt;
&lt;br /&gt;
====Background details====&lt;br /&gt;
Here&#039;s how it works:  [[UpdateMedia]] is a daemon that constantly scans for media files in the /home/public and the /home/user_xxx folder created for each user. Any added media is cataloged in the pluto_media database File table, and attributes and cover art go into the Attribute and Picture tables.  Under /home/public and /home/users_xxx is a data subfolder which contains the actual video, audio, pictures folders.  (The /home/user_xxx directories themselves contain the system files for each user (like email boxes) as well as the main login for that user (in a &amp;quot;data&amp;quot; subfolder).&lt;br /&gt;
&lt;br /&gt;
Extra devices are mounted as /mnt/device/xxx (where xxx is the device number).  The mount point is the same whether it&#039;s a local drive or not.  For example, USB drive [50] in a Media Station may be mounted as a local device named /mnt/device/50, but is also mounted as a Samba mount on other Media Stations as /mnt/device/50.  The Core and the Media Stations all use the same mount names (/mnt/device/).&lt;br /&gt;
&lt;br /&gt;
Within the /home/public/data and /home/user_xxx/data are symlinks to the physical directories specified by /mnt/device/xxx.  Since the Core and all Media Stations mount the same /home directory (and all have the same /mnt/device mounts), they will all show the same files.  Therefore, if the [[UpdateMedia]] daemon locates the file /home/public/data/audio/Generic Internal Drive [50]/The Beatles/Let it be.mp3, that file will be listed on every Media Station, too.&lt;br /&gt;
&lt;br /&gt;
[[Category: Tutorials]]&lt;/div&gt;</summary>
		<author><name>Juanfe</name></author>
	</entry>
	<entry>
		<id>http://wiki.linuxmce.org/index.php?title=Usage_Intro&amp;diff=14822</id>
		<title>Usage Intro</title>
		<link rel="alternate" type="text/html" href="http://wiki.linuxmce.org/index.php?title=Usage_Intro&amp;diff=14822"/>
		<updated>2008-07-12T22:21:56Z</updated>

		<summary type="html">&lt;p&gt;Juanfe: /* Managing your media */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{| align=&amp;quot;right&amp;quot;&lt;br /&gt;
  | __TOC__&lt;br /&gt;
  |}&lt;br /&gt;
LinuxMCE&#039;s main concepts are [[Devices]], Commands (aka [[Scenarios]] and Activities), and [[Events]]. An  [[Orbiter]] is the device that displays the User Interface. It can be a [[Media Director|Media Station]], web pad, mobile phone, or other remote control device. The Orbiter User Interface is standardized for all Orbiters.&lt;br /&gt;
&lt;br /&gt;
== Devices ==&lt;br /&gt;
&lt;br /&gt;
A device is generally a piece of hardware or software, like the Xine Media Player, a light switch, or a mobile phone.  Devices have three functions, abbreviated &amp;quot;DCE&amp;quot; (Data, Commands, Events): &lt;br /&gt;
&lt;br /&gt;
# Retrieve configuration &#039;&#039;&#039;data&#039;&#039;&#039;&lt;br /&gt;
# Perform a &#039;&#039;&#039;command&#039;&#039;&#039; (turn on, turn off, fast forward, etc.)&lt;br /&gt;
# Report certain triggered &#039;&#039;&#039;events&#039;&#039;&#039; (e.g. &#039;motion detected&#039;, &#039;playback started&#039;, etc.)&lt;br /&gt;
&lt;br /&gt;
== Scenarios ==&lt;br /&gt;
&lt;br /&gt;
&amp;quot;[[Scenarios]]&amp;quot;, &amp;quot;Activities&amp;quot;, and &amp;quot;Command Groups&amp;quot; are interchangeable terms -- they mean the same thing.  A scenario is a group of commands that can be sent to a device (or series of devices).  In LinuxMCE, the default Orbiter main menu consists of several scenario categories, grouped by room. These categories are&lt;br /&gt;
&lt;br /&gt;
* Lighting&lt;br /&gt;
* Media&lt;br /&gt;
* Climate&lt;br /&gt;
* Telecom&lt;br /&gt;
* Security&lt;br /&gt;
&lt;br /&gt;
(These default categories are arbitrary and are set up at installation.) To perform an action in LinuxMCE, a scenario is chosen from one of these categories (located on the main menu of an Orbiter). &lt;br /&gt;
&lt;br /&gt;
For example, in rooms which have both a TV and lights, LinuxMCE automatically creates a scenario called &#039;Showtime.&#039; This scenario dims the lights to 10% whenever the TV starts playing.  In rooms with a PVR or other TV-enabled device, another scenario is created called &#039;TV&#039; (in the &#039;Media&#039; category) to start the TV.  Another scenario in the &#039;Media&#039; category called &#039;Video&#039; sends a command to the Orbiter to list your video content. Telecom scenarios are created to make phone calls. Security scenarios are created to view cameras and to arm an alarm.&lt;br /&gt;
&lt;br /&gt;
Some [[What_scenarios_are_created_automatically%3F|default scenarios]] are created for you at installation. A fully-functional system can run using only the default scenarios, if you choose. You can also change or remove the default scenarios or add new ones. This is done though the &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Wizard--&amp;gt;[[Scenarios]]&#039;&#039;&#039; menu. When creating a scenario, the [[LinuxMCE Admin Website]] will show you the most appropriate wizard, based on the category you pick.  If you&#039;re adding an activity in the lighting category, for example, the wizard will display a list of the lights in the room and let you pick which ones to turn off.  If you&#039;re creating a scenario in the security category, it will list the installed cameras and will allow you to select which ones to display.&lt;br /&gt;
&lt;br /&gt;
A scenario can send a command to any device in the system. By default, scenarios in the lighting category show you the room lights, allowing you to select which ones to which to send commands. However, from the &#039;&#039;&#039;Wizard--&amp;gt;[[Scenarios]]&#039;&#039;&#039; menu for the specific scenario, you can also specify a command to any device in your home. You could make a phone call, for example, even from a scenario in the lighting category.&lt;br /&gt;
&lt;br /&gt;
Certain scenarios are assigned to certain rooms by default. This can be customized, however. When you manually select a room from the Orbiter main menu, the default scenarios for that room are displayed. In general they control devices in that room, but this can also be changed. If your kitchen is near the garage and you want a scenario to &#039;turn off the garage light&#039;, you can assign a scenario to the room &#039;kitchen&#039; that will do just that. It doesn&#039;t matter that the light is in the garage.&lt;br /&gt;
&lt;br /&gt;
For a Media Director, the on-screen Orbiter User Interface appears on the TV screen. It is manipulated by the mouse/keyboard or remote control connected to your Media Director. By default it is set to display the scenarios for the room in which the Media Director is located.&lt;br /&gt;
&lt;br /&gt;
In contrast, a mobile Orbiter (such as a webpad) can be carried throughout the house. It must be able to select the scenarios for multiple rooms. Fortunately, the option to manually select which room you are currently in is available on every Orbiter&#039;s main menu.&lt;br /&gt;
&lt;br /&gt;
This can occasionally cause some confusion. Perhaps both the Living Room and the Bedroom have a scenario called &#039;TV&#039;. You may have a web pad that is in the Bedroom, but you then carry it to the Living Room. You may forget to tell the web pad that it&#039;s now in the Living Room (at the bottom of the Orbiter screen it will still say &#039;Bedroom&#039;). You hit the &#039;TV&#039; button expecting the Living Room TV to come on, but in fact you&#039;re still controlling the Bedroom and the TV comes on there instead. Finally you may realize that you must change your room location to Living Room, and you can then finally control the TV there.&lt;br /&gt;
&lt;br /&gt;
Once you get used to this concept, though, you&#039;ll find it very useful.  Conveniently, any Orbiter can be set to control any room and choose from the scenarios assigned to that room. No matter which Orbiter you use, the same set of scenarios will be displayed for each specific room. For example, the kitchen scenarios will always be the same, no matter which Orbiter you are using. (The scenarios are assigned by room -- not by Orbiter.) No matter whether you pick up your mobile phone, your web pad, or your remote control, you will always be shown the same list of scenario options for the Living Room.&lt;br /&gt;
&lt;br /&gt;
You have the option of preventing some family members from using certain scenarios. From the [[LinuxMCE Admin Website]], certain scenarios and rooms can be [[Users#Restrict_Access|restricted to certain users]].  Maybe little Suzy&#039;s mobile phone Orbiter should be restricted so that she is only able to control her room and the living room, for example. She would only be able to execute the scenarios in those rooms, but not the Master Bedroom. Other possible options include [[Users#Restrict_Access|requiring a pin code]] to access the scenarios for a particular room.&lt;br /&gt;
&lt;br /&gt;
== Events ==&lt;br /&gt;
&lt;br /&gt;
Devices report events, such as &#039;Playback started&#039; and &#039;Motion Sensor tripped&#039;. If you want something to happen automatically in LinuxMCE, you create Event Handlers that react to these events. For example, you can create an event handler that listens for the &#039;Motion Sensor tripped&#039; event from a motion detector and turns on the lights in response.  An event handler might listen for the &#039;Sunrise&#039; event, which could then prompt the sprinklers to come on. &lt;br /&gt;
&lt;br /&gt;
LinuxMCE creates several default event handlers. In rooms in which you have a TV and lights, an event handler is created that listens for the &#039;Watching Media&#039; event sent by a media player. When the event is detected, the Showtime scenario (which dims the lights) is executed in response.  When you start a movie, therefore, the Showtime activity will be executed and the lights will be dimmed.  There are other default event handlers that monitor for events like &#039;Security Breach&#039; and &#039;Fire Alarm&#039; (from a home security system).&lt;br /&gt;
&lt;br /&gt;
== Controlling an Orbiter ==&lt;br /&gt;
&lt;br /&gt;
To control the system, you use an [[Orbiter]], which is the LinuxMCE term for a remote control.  All [[Orbiters]] have the same basic function: to display the scenarios in the room you&#039;re in and let you select one.  The different Orbiters may [[Selecting_the_Right_UI|display the User Interface slightly differently]], depending on their screen size, but the function and the list of scenarios is always the same. For example, the [[Selecting_the_Right_UI|&amp;quot;UI1&amp;quot; interface]] (which is used on webpads and PDAs) displays the scenarios in horizontal rows. (If there are more than will fit on a row, there will be a &amp;quot;more&amp;quot; button.) A home button is always displayed that takes you to the main menu. On smaller displays, as on mobile phones or desktop phones, there&#039;s not enough room to show the scenarios themselves. The top level menu shows only the categories: Lights, Media, Climate, Security and Telecom. Selecting a category displays the scenarios in that category. &lt;br /&gt;
&lt;br /&gt;
[[Selecting_the_Right_UI|&amp;quot;UI2&amp;quot;]] is the [[Selecting_the_Right_UI|preferred User Interface]] for Media Stations.  Using a traditional I/R remote is not much different from using any other Media Center PC remote.  The menu button brings up the main menu, and you use the &#039;&#039;left/right/up/down/enter&#039;&#039; buttons to navigate it. The &#039;&#039;fast forward/rewind/skip +/skip -&#039;&#039; keys are used for media playback.&lt;br /&gt;
&lt;br /&gt;
If you have a pointing device like a mouse or gyro air mouse, the UI2 interface also supports a unique control architecture that lets you do everything with 3 (programmable) buttons (plus ok and cancel). The 3 buttons are &amp;quot;MEDIA&amp;quot;, &amp;quot;MENU&amp;quot;, &amp;quot;AMBIANCE&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
On a mouse with 3 programmable buttons (such as the [[Using_the_Gyration_Remote_GYR3101US_%28Non-Fiire_Chief%29|gyration]]), these functions correspond to the buttons from left to right. If you are using a traditional 3 button mouse, you can use the F6, F7 and F8 keys on the keyboard for the three programmable functions instead. In both cases, the left mouse button is &amp;quot;ok&amp;quot;, and the right mouse button is &amp;quot;cancel/go back&amp;quot;. &lt;br /&gt;
&lt;br /&gt;
Mouse button behavior is &amp;quot;absolute&amp;quot; when you press and hold the media/menu/ambiance button and &amp;quot;relative&amp;quot; when you tap and release.&lt;br /&gt;
&lt;br /&gt;
The &amp;quot;absolute&amp;quot; behavior is generally more efficient. For example, in the case of the middle button (F7), &amp;quot;absolute&amp;quot; behavior means the action is executed without having to additionally click &amp;quot;ok&amp;quot;.  If you press and hold the middle button (F7) while moving your mouse pointer to the option, then let go, that option is executed. If you instead tap and release the menu button (&amp;quot;relative&amp;quot; behavior), you will only highlight the menu option. You must then press ok (the left mouse button) to execute the option.&lt;br /&gt;
&lt;br /&gt;
Categories appear along the bottom of the screen, and the scenarios in each category popup vertically (like a pull-down menu in a PC, except upside down).  If the main menu isn&#039;t already visible, bring it up by pressing the &amp;quot;start&amp;quot; button on a Windows I/R remote, or the &amp;quot;menu&amp;quot; button on a 3-button mouse.  To exit a menu, use the back button on the I/R remote, the cancel button (right mouse button on a 3-button mouse), or the ESC key on a keyboard.&lt;br /&gt;
&lt;br /&gt;
In UI2 the media is always full screen. If you&#039;re not playing your own media, the background media (i.e. screensaver images) is gallery art from the Internet (using flickr) or [[Use_my_own_pictures_in_the_Screen_Saver|pictures you select]]. If only the screensaver images are displayed on the Media Station, press the menu/middle/F7 button to bring up the menu. Right click/ESC to get rid of it. (This works even if your own media is playing.)&lt;br /&gt;
&lt;br /&gt;
If you&#039;re using UI2&#039;s 3-button navigation model, the normal media control options on a traditional remote are replaced with a single button: &amp;quot;media&amp;quot; (left soft button or F6). Press this and move the pointer up and down for your skip functions (&#039;&#039;ch+, ch-, skip fwd, skip back&#039;&#039;). Move the pointer left and right for speed control (&#039;&#039;rewind, fast forward&#039;&#039;).  The further you move, the faster the media playback changes.  If you hold the button down (the left soft button or F6), your movement will be &amp;quot;absolute&amp;quot;. Instead of the traditional &amp;quot;jog shuttle-type&amp;quot; control, movement to the right skips to the end of your media, and movement to the left skips to the beginning.  Once you get used to it, you will find that navigating media is orders of magnitude faster and easier with this model than with a traditional remote. You can find a spot in a 2 hour movie in only a couple seconds with a click of a single button (compared to a slew of button clicks required using a traditional remote).&lt;br /&gt;
&lt;br /&gt;
Also, in UI2 you can press the &amp;quot;ambiance&amp;quot; button (right soft button or F8). Move up/down to adjust the lights, and left/right to adjust the volume. As with the media playback, if you hold the F8/right soft button down while you move left and right, your volume control is in &amp;quot;absolute&amp;quot; mode (not &amp;quot;relative&amp;quot;). Moving hard right turns up the volume full blast; hard left is mute.  This requires you have a TV or receiver that is serial-controlled, however. LinuxMCE can then directly and instantly set the volume position in sync with your hand movements. (Few TVs and receivers have this feature, unfortunately.)&lt;br /&gt;
&lt;br /&gt;
There are other media control functions besides the most commonly used &#039;&#039;fast fwd/rewind/skip up/skip down&#039;&#039;. You can, for example, choose &#039;subtitles&#039; while watching a DVD, &#039;guide&#039; while watching TV, and &#039;random&#039; while listening to an audio CD. In the UI2 3 button model, these functions appear on the main menu (on the left-most pad, entitled &#039;now playing&#039;) and changes according to the type of media you&#039;re playing. Press the menu button (middle button/F7) to select these options.&lt;br /&gt;
&lt;br /&gt;
This 3 button model is a new concept and very different from traditional navigation. Most people find it much faster once they become accustomed to it.&lt;br /&gt;
&lt;br /&gt;
==Reload Router &amp;amp; Regen Orbiters==&lt;br /&gt;
&lt;br /&gt;
While using LinuxMCE you&#039;ll see sometimes a message asking if you want to [[Quick reload router|reload the router]], or if you want to [[Orbiter Generator|regenerate the Orbiter UIs]] (User Interfaces). In general, these options refresh the LinuxMCE databases so that changes to the system can be recognized.&lt;br /&gt;
&lt;br /&gt;
===Reload Router===&lt;br /&gt;
All devices in LinuxMCE obtain their configuration information from the [[DCERouter]], which is the central piece of software on the Core.  All devices request a list of the other devices in the home from the router, so they can respond to them appropriately.  (For example, an IP camera device might turn on the lights in the room whenever you&#039;re viewing the camera.  To do so, the IP camera needs to know what lights are in the room.) Typically a device requests this information only when it&#039;s starting up.  When you connect additional plug and play devices to the system, these new devices generally will work immediately, but their functionality may not be fully enabled within the LinuxMCE system until the DCE router is reloaded. When the router reloads, it signals all devices on the system to simultaneously reload and re-request the system data. Each existing device can then work with each new device.  This process is known as a &#039;reload&#039;.  It generally takes about 10 seconds.  Every time you add or remove devices, or change a device&#039;s configuration, you may be asked to do a reload. If you&#039;re going to add more devices or make more device changes, you can do the reload once you&#039;re done. If you&#039;re in the middle of watching a movie or TV, you can postpone the reload, since media players generally stop playing during reloads.  Phone calls aren&#039;t affected, though, and TV shows being recorded by MythTV in the background are also unaffected.&lt;br /&gt;
&lt;br /&gt;
===Regen the Orbiter===&lt;br /&gt;
LinuxMCE&#039;s [[Selecting_the_Right_UI|Orbiter User Interfaces]] are all &amp;quot;pre-rendered&amp;quot; in order to be more efficient.  The User Interface source images are all very high resolution, but need to be resized to accommodate the resolution of each Orbiter screen. The Core server has a list of the Orbiters used by your system, and will generate the appropriate User Interface screen for each Orbiter. It will do this each time you request a &amp;quot;regen&amp;quot;. If you have five different types of Orbiters (each with a different type of screen), then five different images will be generated during each regen.&lt;br /&gt;
&lt;br /&gt;
These User Interface screen images are stored in the Core. The appropriate UI image is sent to an Orbiter whenever it is activated. For many low-power devices (like mobile phones or desktop phones) there just isn&#039;t the processing power to do scaling and rendering of a User Interface screen on the fly. They need to be pre-rendered (with text pre-embedded in the images) to be efficient.&lt;br /&gt;
&lt;br /&gt;
Adding new scenarios may result in the creation of new buttons for the User Interface, or changes to the text on existing buttons. Perhaps an entirely new screen will be created.&lt;br /&gt;
&lt;br /&gt;
Until the User Interface images are regenerated, though, you won&#039;t be able to see these new buttons (or screens) on your Orbiter. During the regen, new User Interface images for each type of Orbiter is generated by the Core. This can take about 2-5 minutes, depending on how many Orbiter types you have in your system.&lt;br /&gt;
&lt;br /&gt;
You needn&#039;t do a regen every time you add a scenario. You can wait until you have finished adding all the scenarios. Furthermore, you can also regen only the Orbiter you are currently using by doing a &amp;quot;Quick regen&amp;quot;. This allows you to see the new User Interface (following the addition of new scenarios) without having to do a full regen for all the Orbiters. Once you have finished adding scenarios, then you can do a full regen.&lt;br /&gt;
&lt;br /&gt;
This regen process can be a bit annoying, but is necessary. In future editions of LinuxMCE, it is planned to allow Media Directors, which have a lot more processing power, to render their on-screen Orbiter User Interfaces on the fly (so you don&#039;t have to do a regen each time you add or remove a scenario).&lt;br /&gt;
&lt;br /&gt;
You can do a [[Orbiter Generator#Running OrbiterGen (performing a &amp;quot;regen&amp;quot;)|full Orbiter regen or a Quick regen]] at any time by using buttons on the Core&#039;s LinuxMCE [[Launch Manager]].&lt;br /&gt;
&lt;br /&gt;
== Managing your media ==&lt;br /&gt;
&lt;br /&gt;
LinuxMCE is always scanning for network shares, on Network-Attached Storage (NAS) devices and other Hard Disk Drives (HDDs) of PCs connected to the system (including Windows PCs). Universal Serial Bus (USB) drives are also detected. You will be asked if you &amp;quot;if you want to use it&amp;quot; every time a network share is found. Whenever you reply &amp;quot;Yes&amp;quot;, the file share can be used by any Media Director on the system. The file share is scanned for media (audio, video and photos) which is then cataloged in the Core&#039;s central database. For example, when you plug in a USB drive on a Media Station in the living room and say &#039;yes&#039; to use it, the media on the drive will be available to Media Directors in other rooms.&lt;br /&gt;
&lt;br /&gt;
At the moment there is no way to restrict your media for &#039;local use only&#039;; all Media Stations in the LinuxMCE system share the media catalog stored on the Core.  (This is a limitation that will be addressed in the near future. Sometimes it is desirable to attach a USB drive in the master bedroom and not allow it to be shared, for example. &#039;&#039;Note: However, see [[folder lock|this article that describes a method to address this problem]].&#039;&#039;)&lt;br /&gt;
&lt;br /&gt;
Storage devices (NAS, USB drives, extra HDDs on the Core or Media Directors) are referred to as &amp;quot;Extra Drives&amp;quot;.  When an extra drive is added, it is listed in the device tree in &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Advanced--&amp;gt;Configuration--&amp;gt;[[Devices]]&#039;&#039;&#039;.  Under &#039;Core&#039; you&#039;ll see a device listed for each HDD in the Core, as well as for each NAS device. Under each Media Station will be listed the HDDs in that Media Station.  By clicking on the device you can change the device&#039;s properties, such as the mount username/password.  Each NAS device, and each file share on another PC, will show as a device listed under the Core; each is considered a child of the Core.&lt;br /&gt;
&lt;br /&gt;
LinuxMCE creates a top level folder for &#039;public&#039; media. This folder can be used by every user in the system.  A &#039;private&#039; media folder is also created for each user.  Within each of those folders are sub-folders, labeled &#039;audio&#039;, &#039;video&#039;, &#039;pictures&#039;, &#039;data&#039; and &#039;other&#039;.  Within each of those will also be sub-folders for the extra storage devices (NAS, USB, extra internal drives, etc).  When you attach an extra storage device, you can specify whether the default directory structure should be used for it. Alternatively, you can specify &#039;just make it public&#039; or &#039;make it private&#039;.&lt;br /&gt;
&lt;br /&gt;
Here&#039;s an example.  Let&#039;s say you have 2 users: john and mary.  You connect 3 storage devices:&lt;br /&gt;
# a NAS, for which you specify &#039;use default directory structure&#039;. It is named &#039;Generic Network Storage [50]&#039;&lt;br /&gt;
# a USB drive for which you specify &#039;make it all public&#039;. It is named &#039;USB Drive [51]&#039;&lt;br /&gt;
# a SATA drive for which you choose &#039;make it private for john&#039;. It is named &#039;General Internal HDD [52]&lt;br /&gt;
&lt;br /&gt;
Now let&#039;s say you&#039;re running Windows. Go to Network Neighborhood and find the LinuxMCE Core server.  The directory tree ought to look like this:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
public&lt;br /&gt;
  video&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  audio&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  pictures&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  data&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  other&lt;br /&gt;
    USB Drive [51]&lt;br /&gt;
john&lt;br /&gt;
  video&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  audio&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  pictures&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  data&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  other&lt;br /&gt;
    General Internal HDD [52]&lt;br /&gt;
mary&lt;br /&gt;
  video&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  audio&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  pictures&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  data&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  other&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Whether you put your media under video, audio, pictures, data or other is unimportant.  It will be scanned by LinuxMCE anyway. The contents of &amp;quot;General Internal HDD [52]&amp;quot; will be displayed in the folder john/other/General Internal HDD [52]. The contents of USB Drive [51] will be displayed in the folder public/other/USB Drive [51].  When John browses the contents in Network Neighborhood, he will be asked for his username and password. He can then access the content in both the public folder as well as the &amp;quot;john&amp;quot; folders (including General Internal HDD [52]).  When Mary browses the contents with her username and password, she will see both the public and &amp;quot;mary&amp;quot; folders. She will not be able to see anything on General Internal HDD [52], however, since that drive was specified to be private for John.&lt;br /&gt;
&lt;br /&gt;
In the case of John&#039;s private media, it won&#039;t be displayed in the LinuxMCE media browser unless you click &#039;Sources&#039;--&amp;gt;&#039;John&#039;. However you &#039;&#039;can&#039;&#039; see the contents of General Internal HDD [52] (unless you deselect &#039;Sources&#039;--&amp;gt;&#039;Public&#039; from the media browser).  Generic Network Storage [50] would be different, however, since you specified to use the default directory structure for it.  LinuxMCE will have created public directories on Generic Network Storage [50] for public video and public audio, as well as for john&#039;s video and mary&#039;s audio. The media file browser will show only the media that is in the public directories. (The same is true with the Windows Network Neighborhood browser.) &lt;br /&gt;
&lt;br /&gt;
If Generic Network Storage [50] has existing media in the top (root) folder, you won&#039;t see it listed anywhere.&lt;br /&gt;
&lt;br /&gt;
It is generally recommended, therefore, that when you add a new (blank) &amp;quot;extra&amp;quot; storage device, you choose to use the default directory structure on it.  When you rip media to that device, the media can then be made either public or private, and LinuxMCE will automatically put it in the correct folder (audio, video, etc.).&lt;br /&gt;
&lt;br /&gt;
If you connect an extra storage device that already has media on it, however, and that media isn&#039;t already organized in LinuxMCE&#039;s default directory structure, it&#039;s easiest if you simply &#039;make it all public&#039; or &#039;make it all private&#039;. If you were to &#039;use the default directory structure&#039;, you would need to manually move the files from the existing folders into one of the directory folders that LinuxMCE would then create for you.&lt;br /&gt;
&lt;br /&gt;
When you rip files, you have the option of copying them to the Core.  If you rip a CD and make it public, it will be stored in public/audio.  If you go into Network Neighborhood and add a folder under public/audio, you would essentially be adding a folder on the Core. If you add a folder under public/audio/Generic Network Storage [50], you would be adding it to Generic Network Storage [50].&lt;br /&gt;
&lt;br /&gt;
This concept behind drive/network drive management is not the same as the method to which Linux and Windows users are accustomed. In Windows, for example, each network device shows up separately; they are never grouped together.  There is an advantage to the way LinuxMCE manages drives. It&#039;s much simpler to add devices when you&#039;re a novice and don&#039;t understand networking. Further, if you&#039;re using an infrared remote control, you can manage drives with a single &#039;yes&#039; or &#039;no,&#039; click, which is very convenient. Lastly, all your media content is cataloged and presented in the same structure throughout the system, no matter which Media Director you&#039;re using or what room you&#039;re in.&lt;br /&gt;
&lt;br /&gt;
In Windows, by comparison, if you connect a USB drive to a Windows PC in the bedroom, you won&#039;t see that content in the living room unless you 1) open file explorer, 2) create a new network share for it, 3) go into the living room, and 4) create a new mapped network drive there. (That isn&#039;t so easy to do with an infrared remote and without some knowledge of networking.)  Further, you wouldn&#039;t be able to see the media in any other room in the house unless you were to also create mapped network shares in those rooms as well. &lt;br /&gt;
&lt;br /&gt;
With LinuxMCE, when you connect a USB drive, for example, you can &#039;make it all public&#039;; the media will be available everywhere. No other typing is required. With LinuxMCE, instead of managing multiple network shares and mapped drives, you can choose the Core&#039;s public folders in the Network Neighborhood browser from anywhere in the home, without having to know which storage devices the media is actually on.  When you remove a USB drive from a Media Station, that media instantly disappears from the catalog displayed in every room. If you reattach it, it will re-appear.&lt;br /&gt;
&lt;br /&gt;
You can also backup the media securely on the Core. LinuxMCE has built-in [http://en.wikipedia.org/wiki/RAID RAID] 5 (see &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Advanced--&amp;gt;[[RAID]]&#039;&#039;&#039;), so its HDD has similar backup capabilities to an [[NAS]].&lt;br /&gt;
&lt;br /&gt;
To change the name of an extra device, go to the &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Advanced--&amp;gt;Configuration--&amp;gt;[[Devices]]&#039;&#039;&#039; and under the Core you will see listed the HDDs in the core and any connected NAS devices. Under each Media Station you will see the HDDs in that Media Station. All are given default names.  You can change the description, which will also change the folder name.  In the above example, changing &amp;quot;USB Drive [51]&amp;quot; to &amp;quot;Tokyo&amp;quot; means the directory public/other/USB Drive [51] would change to public/other/Tokyo.&lt;br /&gt;
&lt;br /&gt;
In the &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Files &amp;amp; Media--&amp;gt;[[Media Files Sync]]&#039;&#039;&#039; is listed the files in the system by folder. You can change the cover art and attributes.  If a file is shown with a check box, the file exists both on the local disk as well as in LinuxMCE&#039;s master catalog.  If it has a different icon, then LinuxMCE hasn&#039;t finished cataloging the media; just be patient. It should appear with a check mark soon (depending on how much new media was added). Under Files &amp;amp; Media there is also a cover art scan utility that will find cover art, as well as other attributes (actor, genre, etc.) obtained from Amazon.&lt;br /&gt;
&lt;br /&gt;
====Background details====&lt;br /&gt;
Here&#039;s how it works:  [[UpdateMedia]] is a daemon that constantly scans for media files in the /home/public and the /home/user_xxx folder created for each user. Any added media is cataloged in the pluto_media database File table, and attributes and cover art go into the Attribute and Picture tables.  Under /home/public and /home/users_xxx is a data subfolder which contains the actual video, audio, pictures folders.  (The /home/user_xxx directories themselves contain the system files for each user (like email boxes) as well as the main login for that user (in a &amp;quot;data&amp;quot; subfolder).&lt;br /&gt;
&lt;br /&gt;
Extra devices are mounted as /mnt/device/xxx (where xxx is the device number).  The mount point is the same whether it&#039;s a local drive or not.  For example, USB drive [50] in a Media Station may be mounted as a local device named /mnt/device/50, but is also mounted as a Samba mount on other Media Stations as /mnt/device/50.  The Core and the Media Stations all use the same mount names (/mnt/device/).&lt;br /&gt;
&lt;br /&gt;
Within the /home/public/data and /home/user_xxx/data are symlinks to the physical directories specified by /mnt/device/xxx.  Since the Core and all Media Stations mount the same /home directory (and all have the same /mnt/device mounts), they will all show the same files.  Therefore, if the [[UpdateMedia]] daemon locates the file /home/public/data/audio/Generic Internal Drive [50]/The Beatles/Let it be.mp3, that file will be listed on every Media Station, too.&lt;br /&gt;
&lt;br /&gt;
[[Category: Tutorials]]&lt;/div&gt;</summary>
		<author><name>Juanfe</name></author>
	</entry>
	<entry>
		<id>http://wiki.linuxmce.org/index.php?title=Usage_Intro&amp;diff=14821</id>
		<title>Usage Intro</title>
		<link rel="alternate" type="text/html" href="http://wiki.linuxmce.org/index.php?title=Usage_Intro&amp;diff=14821"/>
		<updated>2008-07-12T22:09:44Z</updated>

		<summary type="html">&lt;p&gt;Juanfe: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{| align=&amp;quot;right&amp;quot;&lt;br /&gt;
  | __TOC__&lt;br /&gt;
  |}&lt;br /&gt;
LinuxMCE&#039;s main concepts are [[Devices]], Commands (aka [[Scenarios]] and Activities), and [[Events]]. An  [[Orbiter]] is the device that displays the User Interface. It can be a [[Media Director|Media Station]], web pad, mobile phone, or other remote control device. The Orbiter User Interface is standardized for all Orbiters.&lt;br /&gt;
&lt;br /&gt;
== Devices ==&lt;br /&gt;
&lt;br /&gt;
A device is generally a piece of hardware or software, like the Xine Media Player, a light switch, or a mobile phone.  Devices have three functions, abbreviated &amp;quot;DCE&amp;quot; (Data, Commands, Events): &lt;br /&gt;
&lt;br /&gt;
# Retrieve configuration &#039;&#039;&#039;data&#039;&#039;&#039;&lt;br /&gt;
# Perform a &#039;&#039;&#039;command&#039;&#039;&#039; (turn on, turn off, fast forward, etc.)&lt;br /&gt;
# Report certain triggered &#039;&#039;&#039;events&#039;&#039;&#039; (e.g. &#039;motion detected&#039;, &#039;playback started&#039;, etc.)&lt;br /&gt;
&lt;br /&gt;
== Scenarios ==&lt;br /&gt;
&lt;br /&gt;
&amp;quot;[[Scenarios]]&amp;quot;, &amp;quot;Activities&amp;quot;, and &amp;quot;Command Groups&amp;quot; are interchangeable terms -- they mean the same thing.  A scenario is a group of commands that can be sent to a device (or series of devices).  In LinuxMCE, the default Orbiter main menu consists of several scenario categories, grouped by room. These categories are&lt;br /&gt;
&lt;br /&gt;
* Lighting&lt;br /&gt;
* Media&lt;br /&gt;
* Climate&lt;br /&gt;
* Telecom&lt;br /&gt;
* Security&lt;br /&gt;
&lt;br /&gt;
(These default categories are arbitrary and are set up at installation.) To perform an action in LinuxMCE, a scenario is chosen from one of these categories (located on the main menu of an Orbiter). &lt;br /&gt;
&lt;br /&gt;
For example, in rooms which have both a TV and lights, LinuxMCE automatically creates a scenario called &#039;Showtime.&#039; This scenario dims the lights to 10% whenever the TV starts playing.  In rooms with a PVR or other TV-enabled device, another scenario is created called &#039;TV&#039; (in the &#039;Media&#039; category) to start the TV.  Another scenario in the &#039;Media&#039; category called &#039;Video&#039; sends a command to the Orbiter to list your video content. Telecom scenarios are created to make phone calls. Security scenarios are created to view cameras and to arm an alarm.&lt;br /&gt;
&lt;br /&gt;
Some [[What_scenarios_are_created_automatically%3F|default scenarios]] are created for you at installation. A fully-functional system can run using only the default scenarios, if you choose. You can also change or remove the default scenarios or add new ones. This is done though the &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Wizard--&amp;gt;[[Scenarios]]&#039;&#039;&#039; menu. When creating a scenario, the [[LinuxMCE Admin Website]] will show you the most appropriate wizard, based on the category you pick.  If you&#039;re adding an activity in the lighting category, for example, the wizard will display a list of the lights in the room and let you pick which ones to turn off.  If you&#039;re creating a scenario in the security category, it will list the installed cameras and will allow you to select which ones to display.&lt;br /&gt;
&lt;br /&gt;
A scenario can send a command to any device in the system. By default, scenarios in the lighting category show you the room lights, allowing you to select which ones to which to send commands. However, from the &#039;&#039;&#039;Wizard--&amp;gt;[[Scenarios]]&#039;&#039;&#039; menu for the specific scenario, you can also specify a command to any device in your home. You could make a phone call, for example, even from a scenario in the lighting category.&lt;br /&gt;
&lt;br /&gt;
Certain scenarios are assigned to certain rooms by default. This can be customized, however. When you manually select a room from the Orbiter main menu, the default scenarios for that room are displayed. In general they control devices in that room, but this can also be changed. If your kitchen is near the garage and you want a scenario to &#039;turn off the garage light&#039;, you can assign a scenario to the room &#039;kitchen&#039; that will do just that. It doesn&#039;t matter that the light is in the garage.&lt;br /&gt;
&lt;br /&gt;
For a Media Director, the on-screen Orbiter User Interface appears on the TV screen. It is manipulated by the mouse/keyboard or remote control connected to your Media Director. By default it is set to display the scenarios for the room in which the Media Director is located.&lt;br /&gt;
&lt;br /&gt;
In contrast, a mobile Orbiter (such as a webpad) can be carried throughout the house. It must be able to select the scenarios for multiple rooms. Fortunately, the option to manually select which room you are currently in is available on every Orbiter&#039;s main menu.&lt;br /&gt;
&lt;br /&gt;
This can occasionally cause some confusion. Perhaps both the Living Room and the Bedroom have a scenario called &#039;TV&#039;. You may have a web pad that is in the Bedroom, but you then carry it to the Living Room. You may forget to tell the web pad that it&#039;s now in the Living Room (at the bottom of the Orbiter screen it will still say &#039;Bedroom&#039;). You hit the &#039;TV&#039; button expecting the Living Room TV to come on, but in fact you&#039;re still controlling the Bedroom and the TV comes on there instead. Finally you may realize that you must change your room location to Living Room, and you can then finally control the TV there.&lt;br /&gt;
&lt;br /&gt;
Once you get used to this concept, though, you&#039;ll find it very useful.  Conveniently, any Orbiter can be set to control any room and choose from the scenarios assigned to that room. No matter which Orbiter you use, the same set of scenarios will be displayed for each specific room. For example, the kitchen scenarios will always be the same, no matter which Orbiter you are using. (The scenarios are assigned by room -- not by Orbiter.) No matter whether you pick up your mobile phone, your web pad, or your remote control, you will always be shown the same list of scenario options for the Living Room.&lt;br /&gt;
&lt;br /&gt;
You have the option of preventing some family members from using certain scenarios. From the [[LinuxMCE Admin Website]], certain scenarios and rooms can be [[Users#Restrict_Access|restricted to certain users]].  Maybe little Suzy&#039;s mobile phone Orbiter should be restricted so that she is only able to control her room and the living room, for example. She would only be able to execute the scenarios in those rooms, but not the Master Bedroom. Other possible options include [[Users#Restrict_Access|requiring a pin code]] to access the scenarios for a particular room.&lt;br /&gt;
&lt;br /&gt;
== Events ==&lt;br /&gt;
&lt;br /&gt;
Devices report events, such as &#039;Playback started&#039; and &#039;Motion Sensor tripped&#039;. If you want something to happen automatically in LinuxMCE, you create Event Handlers that react to these events. For example, you can create an event handler that listens for the &#039;Motion Sensor tripped&#039; event from a motion detector and turns on the lights in response.  An event handler might listen for the &#039;Sunrise&#039; event, which could then prompt the sprinklers to come on. &lt;br /&gt;
&lt;br /&gt;
LinuxMCE creates several default event handlers. In rooms in which you have a TV and lights, an event handler is created that listens for the &#039;Watching Media&#039; event sent by a media player. When the event is detected, the Showtime scenario (which dims the lights) is executed in response.  When you start a movie, therefore, the Showtime activity will be executed and the lights will be dimmed.  There are other default event handlers that monitor for events like &#039;Security Breach&#039; and &#039;Fire Alarm&#039; (from a home security system).&lt;br /&gt;
&lt;br /&gt;
== Controlling an Orbiter ==&lt;br /&gt;
&lt;br /&gt;
To control the system, you use an [[Orbiter]], which is the LinuxMCE term for a remote control.  All [[Orbiters]] have the same basic function: to display the scenarios in the room you&#039;re in and let you select one.  The different Orbiters may [[Selecting_the_Right_UI|display the User Interface slightly differently]], depending on their screen size, but the function and the list of scenarios is always the same. For example, the [[Selecting_the_Right_UI|&amp;quot;UI1&amp;quot; interface]] (which is used on webpads and PDAs) displays the scenarios in horizontal rows. (If there are more than will fit on a row, there will be a &amp;quot;more&amp;quot; button.) A home button is always displayed that takes you to the main menu. On smaller displays, as on mobile phones or desktop phones, there&#039;s not enough room to show the scenarios themselves. The top level menu shows only the categories: Lights, Media, Climate, Security and Telecom. Selecting a category displays the scenarios in that category. &lt;br /&gt;
&lt;br /&gt;
[[Selecting_the_Right_UI|&amp;quot;UI2&amp;quot;]] is the [[Selecting_the_Right_UI|preferred User Interface]] for Media Stations.  Using a traditional I/R remote is not much different from using any other Media Center PC remote.  The menu button brings up the main menu, and you use the &#039;&#039;left/right/up/down/enter&#039;&#039; buttons to navigate it. The &#039;&#039;fast forward/rewind/skip +/skip -&#039;&#039; keys are used for media playback.&lt;br /&gt;
&lt;br /&gt;
If you have a pointing device like a mouse or gyro air mouse, the UI2 interface also supports a unique control architecture that lets you do everything with 3 (programmable) buttons (plus ok and cancel). The 3 buttons are &amp;quot;MEDIA&amp;quot;, &amp;quot;MENU&amp;quot;, &amp;quot;AMBIANCE&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
On a mouse with 3 programmable buttons (such as the [[Using_the_Gyration_Remote_GYR3101US_%28Non-Fiire_Chief%29|gyration]]), these functions correspond to the buttons from left to right. If you are using a traditional 3 button mouse, you can use the F6, F7 and F8 keys on the keyboard for the three programmable functions instead. In both cases, the left mouse button is &amp;quot;ok&amp;quot;, and the right mouse button is &amp;quot;cancel/go back&amp;quot;. &lt;br /&gt;
&lt;br /&gt;
Mouse button behavior is &amp;quot;absolute&amp;quot; when you press and hold the media/menu/ambiance button and &amp;quot;relative&amp;quot; when you tap and release.&lt;br /&gt;
&lt;br /&gt;
The &amp;quot;absolute&amp;quot; behavior is generally more efficient. For example, in the case of the middle button (F7), &amp;quot;absolute&amp;quot; behavior means the action is executed without having to additionally click &amp;quot;ok&amp;quot;.  If you press and hold the middle button (F7) while moving your mouse pointer to the option, then let go, that option is executed. If you instead tap and release the menu button (&amp;quot;relative&amp;quot; behavior), you will only highlight the menu option. You must then press ok (the left mouse button) to execute the option.&lt;br /&gt;
&lt;br /&gt;
Categories appear along the bottom of the screen, and the scenarios in each category popup vertically (like a pull-down menu in a PC, except upside down).  If the main menu isn&#039;t already visible, bring it up by pressing the &amp;quot;start&amp;quot; button on a Windows I/R remote, or the &amp;quot;menu&amp;quot; button on a 3-button mouse.  To exit a menu, use the back button on the I/R remote, the cancel button (right mouse button on a 3-button mouse), or the ESC key on a keyboard.&lt;br /&gt;
&lt;br /&gt;
In UI2 the media is always full screen. If you&#039;re not playing your own media, the background media (i.e. screensaver images) is gallery art from the Internet (using flickr) or [[Use_my_own_pictures_in_the_Screen_Saver|pictures you select]]. If only the screensaver images are displayed on the Media Station, press the menu/middle/F7 button to bring up the menu. Right click/ESC to get rid of it. (This works even if your own media is playing.)&lt;br /&gt;
&lt;br /&gt;
If you&#039;re using UI2&#039;s 3-button navigation model, the normal media control options on a traditional remote are replaced with a single button: &amp;quot;media&amp;quot; (left soft button or F6). Press this and move the pointer up and down for your skip functions (&#039;&#039;ch+, ch-, skip fwd, skip back&#039;&#039;). Move the pointer left and right for speed control (&#039;&#039;rewind, fast forward&#039;&#039;).  The further you move, the faster the media playback changes.  If you hold the button down (the left soft button or F6), your movement will be &amp;quot;absolute&amp;quot;. Instead of the traditional &amp;quot;jog shuttle-type&amp;quot; control, movement to the right skips to the end of your media, and movement to the left skips to the beginning.  Once you get used to it, you will find that navigating media is orders of magnitude faster and easier with this model than with a traditional remote. You can find a spot in a 2 hour movie in only a couple seconds with a click of a single button (compared to a slew of button clicks required using a traditional remote).&lt;br /&gt;
&lt;br /&gt;
Also, in UI2 you can press the &amp;quot;ambiance&amp;quot; button (right soft button or F8). Move up/down to adjust the lights, and left/right to adjust the volume. As with the media playback, if you hold the F8/right soft button down while you move left and right, your volume control is in &amp;quot;absolute&amp;quot; mode (not &amp;quot;relative&amp;quot;). Moving hard right turns up the volume full blast; hard left is mute.  This requires you have a TV or receiver that is serial-controlled, however. LinuxMCE can then directly and instantly set the volume position in sync with your hand movements. (Few TVs and receivers have this feature, unfortunately.)&lt;br /&gt;
&lt;br /&gt;
There are other media control functions besides the most commonly used &#039;&#039;fast fwd/rewind/skip up/skip down&#039;&#039;. You can, for example, choose &#039;subtitles&#039; while watching a DVD, &#039;guide&#039; while watching TV, and &#039;random&#039; while listening to an audio CD. In the UI2 3 button model, these functions appear on the main menu (on the left-most pad, entitled &#039;now playing&#039;) and changes according to the type of media you&#039;re playing. Press the menu button (middle button/F7) to select these options.&lt;br /&gt;
&lt;br /&gt;
This 3 button model is a new concept and very different from traditional navigation. Most people find it much faster once they become accustomed to it.&lt;br /&gt;
&lt;br /&gt;
==Reload Router &amp;amp; Regen Orbiters==&lt;br /&gt;
&lt;br /&gt;
While using LinuxMCE you&#039;ll see sometimes a message asking if you want to [[Quick reload router|reload the router]], or if you want to [[Orbiter Generator|regenerate the Orbiter UIs]] (User Interfaces). In general, these options refresh the LinuxMCE databases so that changes to the system can be recognized.&lt;br /&gt;
&lt;br /&gt;
===Reload Router===&lt;br /&gt;
All devices in LinuxMCE obtain their configuration information from the [[DCERouter]], which is the central piece of software on the Core.  All devices request a list of the other devices in the home from the router, so they can respond to them appropriately.  (For example, an IP camera device might turn on the lights in the room whenever you&#039;re viewing the camera.  To do so, the IP camera needs to know what lights are in the room.) Typically a device requests this information only when it&#039;s starting up.  When you connect additional plug and play devices to the system, these new devices generally will work immediately, but their functionality may not be fully enabled within the LinuxMCE system until the DCE router is reloaded. When the router reloads, it signals all devices on the system to simultaneously reload and re-request the system data. Each existing device can then work with each new device.  This process is known as a &#039;reload&#039;.  It generally takes about 10 seconds.  Every time you add or remove devices, or change a device&#039;s configuration, you may be asked to do a reload. If you&#039;re going to add more devices or make more device changes, you can do the reload once you&#039;re done. If you&#039;re in the middle of watching a movie or TV, you can postpone the reload, since media players generally stop playing during reloads.  Phone calls aren&#039;t affected, though, and TV shows being recorded by MythTV in the background are also unaffected.&lt;br /&gt;
&lt;br /&gt;
===Regen the Orbiter===&lt;br /&gt;
LinuxMCE&#039;s [[Selecting_the_Right_UI|Orbiter User Interfaces]] are all &amp;quot;pre-rendered&amp;quot; in order to be more efficient.  The User Interface source images are all very high resolution, but need to be resized to accommodate the resolution of each Orbiter screen. The Core server has a list of the Orbiters used by your system, and will generate the appropriate User Interface screen for each Orbiter. It will do this each time you request a &amp;quot;regen&amp;quot;. If you have five different types of Orbiters (each with a different type of screen), then five different images will be generated during each regen.&lt;br /&gt;
&lt;br /&gt;
These User Interface screen images are stored in the Core. The appropriate UI image is sent to an Orbiter whenever it is activated. For many low-power devices (like mobile phones or desktop phones) there just isn&#039;t the processing power to do scaling and rendering of a User Interface screen on the fly. They need to be pre-rendered (with text pre-embedded in the images) to be efficient.&lt;br /&gt;
&lt;br /&gt;
Adding new scenarios may result in the creation of new buttons for the User Interface, or changes to the text on existing buttons. Perhaps an entirely new screen will be created.&lt;br /&gt;
&lt;br /&gt;
Until the User Interface images are regenerated, though, you won&#039;t be able to see these new buttons (or screens) on your Orbiter. During the regen, new User Interface images for each type of Orbiter is generated by the Core. This can take about 2-5 minutes, depending on how many Orbiter types you have in your system.&lt;br /&gt;
&lt;br /&gt;
You needn&#039;t do a regen every time you add a scenario. You can wait until you have finished adding all the scenarios. Furthermore, you can also regen only the Orbiter you are currently using by doing a &amp;quot;Quick regen&amp;quot;. This allows you to see the new User Interface (following the addition of new scenarios) without having to do a full regen for all the Orbiters. Once you have finished adding scenarios, then you can do a full regen.&lt;br /&gt;
&lt;br /&gt;
This regen process can be a bit annoying, but is necessary. In future editions of LinuxMCE, it is planned to allow Media Directors, which have a lot more processing power, to render their on-screen Orbiter User Interfaces on the fly (so you don&#039;t have to do a regen each time you add or remove a scenario).&lt;br /&gt;
&lt;br /&gt;
You can do a [[Orbiter Generator#Running OrbiterGen (performing a &amp;quot;regen&amp;quot;)|full Orbiter regen or a Quick regen]] at any time by using buttons on the Core&#039;s LinuxMCE [[Launch Manager]].&lt;br /&gt;
&lt;br /&gt;
== Managing your media ==&lt;br /&gt;
&lt;br /&gt;
LinuxMCE is always scanning for network shares, on NAS devices and other HDDs of PCs connected to the system (including Windows PCs). USB drives are also detected. You will be asked if you &amp;quot;if you want to use it&amp;quot; every time a network share is found. Whenever you reply &amp;quot;Yes&amp;quot;, the file share can be used by any Media Director on the system. The file share is scanned for media (audio, video and photos) which is then cataloged in the Core&#039;s central database. For example, when you plug in a USB drive on a Media Station in the living room and say &#039;yes&#039; to use it, the media on the drive will be available to Media Directors in other rooms.&lt;br /&gt;
&lt;br /&gt;
At the moment there is no way to restrict your media for &#039;local use only&#039;; all Media Stations in the LinuxMCE system share the media catalog stored on the Core.  (This is a limitation that will be addressed in the near future. Sometimes it is desirable to attach a USB drive in the master bedroom and not allow it to be shared, for example. &#039;&#039;Note: However, see [[folder lock|this article that describes a method to address this problem]].&#039;&#039;)&lt;br /&gt;
&lt;br /&gt;
Storage devices (NAS, USB drives, extra HDDs on the Core or Media Directors) are referred to as &amp;quot;Extra Drives&amp;quot;.  When an extra drive is added, it is listed in the device tree in &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Advanced--&amp;gt;Configuration--&amp;gt;[[Devices]]&#039;&#039;&#039;.  Under &#039;Core&#039; you&#039;ll see a device listed for each HDD in the Core, as well as for each NAS device. Under each Media Station will be listed the HDDs in that Media Station.  By clicking on the device you can change the device&#039;s properties, such as the mount username/password.  Each NAS device, and each file share on another PC, will show as a device listed under the Core; each is considered a child of the Core.&lt;br /&gt;
&lt;br /&gt;
LinuxMCE creates a top level folder for &#039;public&#039; media. This folder can be used by every user in the system.  A &#039;private&#039; media folder is also created for each user.  Within each of those folders are sub-folders, labeled &#039;audio&#039;, &#039;video&#039;, &#039;pictures&#039;, &#039;data&#039; and &#039;other&#039;.  Within each of those will also be sub-folders for the extra storage devices (NAS, USB, extra internal drives, etc).  When you attach an extra storage device, you can specify whether the default directory structure should be used for it. Alternatively, you can specify &#039;just make it public&#039; or &#039;make it private&#039;.&lt;br /&gt;
&lt;br /&gt;
Here&#039;s an example.  Let&#039;s say you have 2 users: john and mary.  You connect 3 storage devices:&lt;br /&gt;
# a NAS, for which you specify &#039;use default directory structure&#039;. It is named &#039;Generic Network Storage [50]&#039;&lt;br /&gt;
# a USB drive for which you specify &#039;make it all public&#039;. It is named &#039;USB Drive [51]&#039;&lt;br /&gt;
# a SATA drive for which you choose &#039;make it private for john&#039;. It is named &#039;General Internal HDD [52]&lt;br /&gt;
&lt;br /&gt;
Now let&#039;s say you&#039;re running Windows. Go to Network Neighborhood and find the LinuxMCE Core server.  The directory tree ought to look like this:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
public&lt;br /&gt;
  video&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  audio&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  pictures&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  data&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  other&lt;br /&gt;
    USB Drive [51]&lt;br /&gt;
john&lt;br /&gt;
  video&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  audio&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  pictures&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  data&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  other&lt;br /&gt;
    General Internal HDD [52]&lt;br /&gt;
mary&lt;br /&gt;
  video&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  audio&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  pictures&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  data&lt;br /&gt;
    Generic Network Storage [50]&lt;br /&gt;
  other&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Whether you put your media under video, audio, pictures, data or other is unimportant.  It will be scanned by LinuxMCE anyway. The contents of &amp;quot;General Internal HDD [52]&amp;quot; will be displayed in the folder john/other/General Internal HDD [52]. The contents of USB Drive [51] will be displayed in the folder public/other/USB Drive [51].  When John browses the contents in Network Neighborhood, he will be asked for his username and password. He can then access the content in both the public folder as well as the &amp;quot;john&amp;quot; folders (including General Internal HDD [52]).  When Mary browses the contents with her username and password, she will see both the public and &amp;quot;mary&amp;quot; folders. She will not be able to see anything on General Internal HDD [52], however, since that drive was specified to be private for John.&lt;br /&gt;
&lt;br /&gt;
In the case of John&#039;s private media, it won&#039;t be displayed in the LinuxMCE media browser unless you click &#039;Sources&#039;--&amp;gt;&#039;John&#039;. However you &#039;&#039;can&#039;&#039; see the contents of General Internal HDD [52] (unless you deselect &#039;Sources&#039;--&amp;gt;&#039;Public&#039; from the media browser).  Generic Network Storage [50] would be different, however, since you specified to use the default directory structure for it.  LinuxMCE will have created public directories on Generic Network Storage [50] for public video and public audio, as well as for john&#039;s video and mary&#039;s audio. The media file browser will show only the media that is in the public directories. (The same is true with the Windows Network Neighborhood browser.) &lt;br /&gt;
&lt;br /&gt;
If Generic Network Storage [50] has existing media in the top (root) folder, you won&#039;t see it listed anywhere.&lt;br /&gt;
&lt;br /&gt;
It is generally recommended, therefore, that when you add a new (blank) &amp;quot;extra&amp;quot; storage device, you choose to use the default directory structure on it.  When you rip media to that device, the media can then be made either public or private, and LinuxMCE will automatically put it in the correct folder (audio, video, etc.).&lt;br /&gt;
&lt;br /&gt;
If you connect an extra storage device that already has media on it, however, and that media isn&#039;t already organized in LinuxMCE&#039;s default directory structure, it&#039;s easiest if you simply &#039;make it all public&#039; or &#039;make it all private&#039;. If you were to &#039;use the default directory structure&#039;, you would need to manually move the files from the existing folders into one of the directory folders that LinuxMCE would then create for you.&lt;br /&gt;
&lt;br /&gt;
When you rip files, you have the option of copying them to the Core.  If you rip a CD and make it public, it will be stored in public/audio.  If you go into Network Neighborhood and add a folder under public/audio, you would essentially be adding a folder on the Core. If you add a folder under public/audio/Generic Network Storage [50], you would be adding it to Generic Network Storage [50].&lt;br /&gt;
&lt;br /&gt;
This concept behind drive/network drive management is not the same as the method to which Linux and Windows users are accustomed. In Windows, for example, each network device shows up separately; they are never grouped together.  There is an advantage to the way LinuxMCE manages drives. It&#039;s much simpler to add devices when you&#039;re a novice and don&#039;t understand networking. Further, if you&#039;re using an infrared remote control, you can manage drives with a single &#039;yes&#039; or &#039;no,&#039; click, which is very convenient. Lastly, all your media content is cataloged and presented in the same structure throughout the system, no matter which Media Director you&#039;re using or what room you&#039;re in.&lt;br /&gt;
&lt;br /&gt;
In Windows, by comparison, if you connect a USB drive to a Windows PC in the bedroom, you won&#039;t see that content in the living room unless you 1) open file explorer, 2) create a new network share for it, 3) go into the living room, and 4) create a new mapped network drive there. (That isn&#039;t so easy to do with an infrared remote and without some knowledge of networking.)  Further, you wouldn&#039;t be able to see the media in any other room in the house unless you were to also create mapped network shares in those rooms as well. &lt;br /&gt;
&lt;br /&gt;
With LinuxMCE, when you connect a USB drive, for example, you can &#039;make it all public&#039;; the media will be available everywhere. No other typing is required. With LinuxMCE, instead of managing multiple network shares and mapped drives, you can choose the Core&#039;s public folders in the Network Neighborhood browser from anywhere in the home, without having to know which storage devices the media is actually on.  When you remove a USB drive from a Media Station, that media instantly disappears from the catalog displayed in every room. If you reattach it, it will re-appear.&lt;br /&gt;
&lt;br /&gt;
You can also backup the media securely on the Core. LinuxMCE has built-in [http://en.wikipedia.org/wiki/RAID RAID] 5 (see &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Advanced--&amp;gt;[[RAID]]&#039;&#039;&#039;), so its HDD has similar backup capabilities to an [[NAS]].&lt;br /&gt;
&lt;br /&gt;
To change the name of an extra device, go to the &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Advanced--&amp;gt;Configuration--&amp;gt;[[Devices]]&#039;&#039;&#039; and under the Core you will see listed the HDDs in the core and any connected NAS devices. Under each Media Station you will see the HDDs in that Media Station. All are given default names.  You can change the description, which will also change the folder name.  In the above example, changing &amp;quot;USB Drive [51]&amp;quot; to &amp;quot;Tokyo&amp;quot; means the directory public/other/USB Drive [51] would change to public/other/Tokyo.&lt;br /&gt;
&lt;br /&gt;
In the &#039;&#039;&#039;[[LinuxMCE Admin Website]]--&amp;gt;Files &amp;amp; Media--&amp;gt;[[Media Files Sync]]&#039;&#039;&#039; is listed the files in the system by folder. You can change the cover art and attributes.  If a file is shown with a check box, the file exists both on the local disk as well as in LinuxMCE&#039;s master catalog.  If it has a different icon, then LinuxMCE hasn&#039;t finished cataloging the media; just be patient. It should appear with a check mark soon (depending on how much new media was added). Under Files &amp;amp; Media there is also a cover art scan utility that will find cover art, as well as other attributes (actor, genre, etc.) obtained from Amazon.&lt;br /&gt;
&lt;br /&gt;
====Background details====&lt;br /&gt;
Here&#039;s how it works:  [[UpdateMedia]] is a daemon that constantly scans for media files in the /home/public and the /home/user_xxx folder created for each user. Any added media is cataloged in the pluto_media database File table, and attributes and cover art go into the Attribute and Picture tables.  Under /home/public and /home/users_xxx is a data subfolder which contains the actual video, audio, pictures folders.  (The /home/user_xxx directories themselves contain the system files for each user (like email boxes) as well as the main login for that user (in a &amp;quot;data&amp;quot; subfolder).&lt;br /&gt;
&lt;br /&gt;
Extra devices are mounted as /mnt/device/xxx (where xxx is the device number).  The mount point is the same whether it&#039;s a local drive or not.  For example, USB drive [50] in a Media Station may be mounted as a local device named /mnt/device/50, but is also mounted as a Samba mount on other Media Stations as /mnt/device/50.  The Core and the Media Stations all use the same mount names (/mnt/device/).&lt;br /&gt;
&lt;br /&gt;
Within the /home/public/data and /home/user_xxx/data are symlinks to the physical directories specified by /mnt/device/xxx.  Since the Core and all Media Stations mount the same /home directory (and all have the same /mnt/device mounts), they will all show the same files.  Therefore, if the [[UpdateMedia]] daemon locates the file /home/public/data/audio/Generic Internal Drive [50]/The Beatles/Let it be.mp3, that file will be listed on every Media Station, too.&lt;br /&gt;
&lt;br /&gt;
[[Category: Tutorials]]&lt;/div&gt;</summary>
		<author><name>Juanfe</name></author>
	</entry>
</feed>