Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - royw

Pages: 1 ... 15 16 [17] 18
242
Developers / HOWTO local authoritive dns with dhcp updates
« on: February 03, 2008, 11:29:28 pm »
Howdy,

I was wanting an authoritative name server for my local intranet.  I also wanted any dynamic IP's to be visible to the name server.  The name server included with linuxmce is configured as a recursive name server.  Here's the changes I did to configure my core'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.

I named my intranet "wright.local".  Using a "local" top level domain (TLD) is recommended for private intranets.  Some may prefer to use "lan".  You do not want to use any of the standard TLDs like "com", "net", "org",...

I used the core's default intranet addresses, 192.168.80.0/24 with the core at 192.168.80.1.

I've attempted to verbosely document each config file.  :)

The directions for adapting the config files are included in the named.conf file.

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  :)

So start with creating two directories:
Code: [Select]
  sudo mkdir /etc/bind.new
  sudo mkdir /etc/dhcp3.new

Now copy the contents of the original directories:
Code: [Select]
  sudo cp -arp /etc/bind/* /etc/bind.new
  sudo cp -arp /etc/dhcp3/* /etc/dhcp3.new

Also create a new resolve.conf file:
Code: [Select]
  sudo touch /etc/resolv.conf.new

Then add/change the config files below. 

To create a key for use in rndc.key and dhcpd.conf:
Code: [Select]
  sudo dnssec-keygen -a HMAC-MD5 -b 256 -n user rndc

now get the key from the private file:
Code: [Select]
  sudo cat Krndc.*.private
  Private-key-format: v1.2
  Algorithm: 157 (HMAC_MD5)
  Key: 3+GnSWV5FKxcUu57k7QFxbpvv/xr4fXj2wBVGtdGifI=
  Bits: AAA=

now cut the key which is to the right of "Key: " and paste where needed (replace "<paste your key here>" with the key in the config files).  So an example using the above key would look like:
Code: [Select]
key "linuxmce-dhcp" {
        algorithm hmac-md5;
        secret "<paste your key here>";
};

becomes:
Code: [Select]
key "linuxmce-dhcp" {
        algorithm hmac-md5;
        secret "3+GnSWV5FKxcUu57k7QFxbpvv/xr4fXj2wBVGtdGifI=";
};

Make the logging directory:
Code: [Select]
  sudo mkdir /var/log/named
  sudo chown bind:bind /var/log/named
  sudo chmod 755 /var/log/named

Change all the file permissions per instructions in named.conf. 

Double check everything.   ::)

Then when you are feeling lucky, rename the original directories and then rename the new directories to take there place:
Code: [Select]
  sudo mv /etc/bind /etc/bind.original
  sudo mv /etc/bind.new /etc/bind
  sudo mv /etc/dhcp3 /etc/dhcp3.original
  sudo mv /etc/dhcp3.new /etc/dhcp3
  sudo mv /etc/resolve.conf /etc/resolve.conf.original
  sudo mv /etc/resolve.conf.new /etc/resolve.conf

Finally restart the bind and dhcpd services:
Code: [Select]
  sudo rndc reload
  sudo /etc/init.d/dhcp3-server restart

Check the syslog for any errors:
Code: [Select]
  grep named /var/log/syslog
  grep dhcpd /var/log/syslog

Here's the config files.

/etc/bind/named.conf
Code: [Select]
// This is the primary configuration file for the BIND DNS server named.
//
// This configuration supports an authoritative local zone (wright.local on
// 192.168.80.0/24) and allows DHCP to update the local zone. 
// To customize to your setup:
// 1) replace "wright.local" with your internal domain name.
// 2) edit db.wright.local.zone and db.wright.local.rev and replace
//    my static names/addresses with your network's static names/addresses.
//    Make sure to increment the serial number of any file edited. 
//    Note, format of serial number is:  YYYYMMDDNN where YYYY is year,
//    MM is month, DD is day, NN is update number for that day (i.e., 01,
//    02, 03,...)
// 3) rename db.wright.local.zone to match your domain name.
// 4) rename db.wright.local.rev to match your domain name.
// 5) If you changed the internal network IP from the LinuxMCE default of
//    192.168.80.0/24, then replace "192.168.80" with your network
//    ip and replace it's reverse "80.168.192" wity your network ip's
//    reverse.
//
// Please read /usr/share/doc/bind9/README.Debian.gz for information on the
// structure of BIND configuration files in Debian, *BEFORE* you customize
// this configuration file.
//
// If you are just adding zones, please do that in /etc/bind/named.conf.local
//
// references:
// http://www.arda.homeunix.net/dnssetup.html
// http://www.madboa.com/geek/soho-bind/
//
// notes:
// 1) The following command should be ran about twice a year to keep
//    the root servers current:
//      dig @a.root-servers.net . ns > /etc/bin/db.root
//    Root name servers don’t change very often so updating this file more
//    than twice a year is probably overkill. Frequent updates also put undo
//    load on the root name servers; they have enough to do as it is.
//
// 2) File permissions:
//    /etc/bind/named.conf   root:root   644
//    /etc/bind/rndc.key     root:bind   640
//    /etc/bind/rndc.conf    root:root   600
//    /etc/resolv.conf       root:root   644
//    /etc/bind              root:bind   775, chmod g+s => drwxrwsr-x
//    /etc/dhcp3             root:root   755
//    /etc/dhcp3/dhcpd.conf  root:root   644
//
// Manually Updating Zone Files
// 1. Use rndc to stop BIND.
//      sudo rndc stop
// 2. Remove any .jnl files from the zone file directory.
//      sudo rm /etc/bind/*.jnl
// 3. Edit the zone files as necessary. Make sure to increment the serial
//    number of any file edited.  Note, format of serial number is:
//    YYYYMMDDNN where YYYY is year, MM is month, DD is day, NN is update
//    number for that day (i.e., 01, 02, 03,...)
// 4. Start BIND using its startup script.
//      sudo /etc/init.d/bind9 start


// secret must be the same as in /etc/bind/rndc.conf
include "/etc/bind/rndc.key";

// access control list used to limit queries to local net
acl "internal-net" { 192.168.80/24; 127.0.0.1; };

controls {
    inet 127.0.0.1 allow { any; } keys { "rndc-key"; };
};

include "/etc/bind/named.conf.options";

// The single dot (.) is the root of all DNS namespace, so
// this zone tells named where to start looking for any
// name on the Internet
zone "." IN {
type hint;
file "/etc/bind/db.root";
};

// local intranet zones and reverse zones
// intranet is wright.local and 192.168.80.0/24
// the DHCP servers is on linuxmce-dhcp
// an optional second nameserver would be on linuxmce-ns2

zone "wright.local" IN {
type master;
file "/etc/bind/db.wright.local.zone";
// both allow-update and update-policy can enable DHCP updates,
// but update-policy allows more control over what kinds of
// updates DHCP can perform on a zone.
// allow-update { none; };
update-policy { grant linuxmce-dhcp subdomain wright.local. A TXT; };
// allow-transfer { key "linuxmce-ns2"; };
// notify on zone transfers
notify yes;
};

zone "80.168.192.in-addr.arpa" IN {
type master;
file "/etc/bind/db.wright.local.rev";
// allow-update { none; };
update-policy { grant linuxmce-dhcp subdomain 80.168.192.in-addr.arpa. PTR TXT; };
// allow-transfer { key "linuxmce-ns2"; };
notify yes;
};

// be authoritative for the localhost forward and reverse zones, and for
// broadcast zones as per RFC 1912 (http://www.ietf.org/rfc/rfc1912.txt)

// Where the localhost hostname is defined
zone "localhost" IN {
// a master type means that this server needn't look
// anywhere else for information; the localhost buck
// stops here.
type master;
file "/etc/bind/db.local";
// don't allow dynamic DNS clients to update info
// about the localhost zone
allow-update { none; };
};

// Where the 127.0.0.0 network is defined
zone "127.in-addr.arpa" IN {
type master;
file "/etc/bind/db.127";
allow-update { none; };
};

zone "0.in-addr.arpa" IN {
type master;
file "/etc/bind/db.0";
allow-update { none; };
};

zone "255.in-addr.arpa" IN {
type master;
file "/etc/bind/db.255";
allow-update { none; };
};


// Include logging config file
include "/etc/bind/logging.conf";

// zone "com" { type delegation-only; };
// zone "net" { type delegation-only; };

// From the release notes:
//  Because many of our users are uncomfortable receiving undelegated answers
//  from root or top level domains, other than a few for whom that behaviour
//  has been trusted and expected for quite some length of time, we have now
//  introduced the "root-delegations-only" feature which applies delegation-only
//  logic to all top level domains, and to the root domain.  An exception list
//  should be specified, including "MUSEUM" and "DE", and any other top level
//  domains from whom undelegated responses are expected and trusted.
// root-delegation-only exclude { "DE"; "MUSEUM"; };

include "/etc/bind/named.conf.local";

/etc/bind/named.conf.options
Code: [Select]
options {
// tell named where to find files mentioned below
directory "/var/cache/bind";

// file that contains the process id when bind is running
pid-file "/var/run/bind/run/named.pid";

// enable statistics
statistics-file "/var/named/named.stats";
zone-statistics yes;

dump-file "/var/named/named.dump";

// If there is a firewall between you and nameservers you want
// to talk to, you might need to uncomment the query-source
// directive below.  Previous versions of BIND always asked
// questions using port 53, but BIND 8.1 and later use an unprivileged
// port by default.
// query-source address * port 53;

// If your ISP provided one or more IP addresses for stable
// nameservers, you probably want to use them as forwarders. 
// Uncomment the following block, and insert the addresses replacing
// the all-0's placeholder.

// The forwarders option tells BIND to not use iterative queries itself
// for information it doesn’t already know about but to forward a
// recursive query to the name servers specified instead.
include "/etc/bind/named.conf.forwarders";

// conform to RFC1035
auth-nxdomain no;

// on a multi-homed host, you might want to tell named
// to listen for queries only on certain interfaces
listen-on-v6 { any; };
listen-on { "internal-net"; };

// to allow only specific hosts to use the DNS server:
allow-query { "internal-net"; };

// sets BIND’s default behaviour to refuse all zone transfers.
// Without setting this option, anyone can transfer any zone.
allow-transfer { none; };

// do not generate notify messages for all zones on a restart.
// override for authorative zones
notify no;
};

/etc/bind/logging.conf
Code: [Select]
logging {

channel default_file {
file "/var/log/named/default.log" versions 3 size 5m;
severity dynamic;
print-time yes;
};
channel general_file {
file "/var/log/named/general.log" versions 3 size 5m;
severity dynamic;
print-time yes;
};
channel database_file {
file "/var/log/named/database.log" versions 3 size 5m;
severity dynamic;
print-time yes;
};
channel security_file {
file "/var/log/named/security.log" versions 3 size 5m;
severity dynamic;
print-time yes;
};
channel config_file {
file "/var/log/named/config.log" versions 3 size 5m;
severity dynamic;
print-time yes;
};
channel resolver_file {
file "/var/log/named/resolver.log" versions 3 size 5m;
severity dynamic;
print-time yes;
};
channel xfer-in_file {
file "/var/log/named/xfer-in.log" versions 3 size 5m;
severity dynamic;
print-time yes;
};
channel xfer-out_file {
file "/var/log/named/xfer-out.log" versions 3 size 5m;
severity dynamic;
print-time yes;
};
channel notify_file {
file "/var/log/named/notify.log" versions 3 size 5m;
severity dynamic;
print-time yes;
};
channel client_file {
file "/var/log/named/client.log" versions 3 size 5m;
severity dynamic;
print-time yes;
};
channel unmatched_file {
file "/var/log/named/unmatched.log" versions 3 size 5m;
severity dynamic;
print-time yes;
};
channel queries_file {
file "/var/log/named/queries.log" versions 3 size 5m;
severity dynamic;
print-time yes;
};
channel network_file {
file "/var/log/named/network.log" versions 3 size 5m;
severity dynamic;
print-time yes;
};
channel update_file {
file "/var/log/named/update.log" versions 3 size 5m;
severity dynamic;
print-time yes;
};
channel dispatch_file {
file "/var/log/named/dispatch.log" versions 3 size 5m;
severity dynamic;
print-time yes;
};
channel dnssec_file {
file "/var/log/named/dnssec.log" versions 3 size 5m;
severity dynamic;
print-time yes;
};
channel lame-servers_file {
file "/var/log/named/lame-servers.log" versions 3 size 5m;
severity dynamic;
print-time yes;
};


category lame-servers {
lame-servers_file;
};
category dnssec {
dnssec_file;
};
category dispatch {
dispatch_file;
};
category update {
update_file;
};
category network {
network_file;
};
category queries {
queries_file;
};
category unmatched {
unmatched_file;
};
category client {
client_file;
};
category notify {
notify_file;
};
category xfer-out {
xfer-out_file;
};
category xfer-in {
xfer-in_file;
};
category resolver {
resolver_file;
};
category config {
config_file;
};
category security {
security_file;
};
category database {
database_file;
};
category general {
general_file;
};
category default {
default_file;
};
};

/etc/bind/rndc.conf
Code: [Select]
options {
default-server  localhost;
default-key     "rndc-key";
default-port 953;
};

server localhost {
key     "rndc-key";
};

key "rndc-key" {
algorithm       hmac-md5;
secret "<paste your key here>";
};

/etc/bind/rndc.key
Code: [Select]
key "rndc-key" {
        algorithm hmac-md5;
        secret "<paste your key here>";
};

key "linuxmce-dhcp" {
        algorithm hmac-md5;
        secret "<paste your key here>";
};

key "linuxmce-ns2" {
        algorithm hmac-md5;
        secret "<paste your key here>";
};

/etc/bind/db.wright.local.zone
Code: [Select]
;
; BIND data file for wright.local
; ref. http://www.redhat.com/docs/manuals/linux/RHL-9-Manual/ref-guide/s1-bind-zone.html
;
$TTL 86400 ; time to live : 86400s = 1 day
; Start Of Authority record, proclaims important authoritative information
; about a namespace to the nameserver.
@               IN SOA  dcerouter.wright.local        roy@wright.org (
                2008013101      ;serial (YYYYMMDDNN where N = 01,02,03,...)
                10800           ;refresh (3 hours)
                7200            ;retry (2 hours)
                36000000        ;expire (10,000 hours = 416 2/3 days)
                86400)          ;default minimum ttl
;
; NameServer record, which announces the authoritative nameservers for a particular zone.
;
                IN NS   dcerouter.wright.local.
;
; Address records specify an IP address to assign to a name
;
dcerouter       IN A            192.168.80.1
dad-kubuntu     IN A            192.168.80.21
royw-gentoo IN A 192.168.80.20
;
; Canonical name records, maps one name to another.
;
linuxmce        IN CNAME        dcerouter

/etc/bind/db.wright.local.rev
Code: [Select]
;
; BIND reverse data file for wright.local
; ref. http://www.redhat.com/docs/manuals/linux/RHL-9-Manual/ref-guide/s1-bind-zone.html
;
$ORIGIN 80.168.192.in-addr.arpa.
$TTL 86400 ; time to live : 86400s = 1 day
; Start Of Authority record, proclaims important authoritative information
; about a namespace to the nameserver.
@               IN SOA  dcerouter.wright.local        roy@wright.org (
                2008013101      ;serial (YYYYMMDDNN where N = 01,02,03,...)
                10800           ;refresh (3 hours)
                7200            ;retry (2 hours)
                36000000        ;expire (10,000 hours = 416 2/3 days)
                86400)          ;default minimum ttl
;
; NameServer record, which announces the authoritative nameservers for a particular zone.
;
                IN NS   dcerouter.wright.local.
;
; PTR — PoinTeR record, designed to point to another part of the namespace.
;
1               IN PTR  dcerouter.wright.local.
21              IN PTR  dad-kubuntu.wright.local.
20 IN PTR royw-gentoo.wright.local.

/etc/dhcp3/dhcpd.conf
Code: [Select]
option domain-name-servers 192.168.80.1;
authoritative;

option routers 192.168.80.1;
option subnet-mask 255.255.255.0;

# lease IPs for 1 day, maximum 1 week
default-lease-time 86400;
max-lease-time 604800;

# dynamic DNS updates
ddns-updates on;
ddns-update-style interim;
ddns-domainname "wright.local.";
ddns-rev-domainname "in-addr.arpa.";
ddns-ttl 14400;

# don't let clients modify their own A records
ignore client-updates;

key "linuxmce-dhcp" {
algorithm       hmac-md5;
secret "<paste your key here>";
};

zone wright.local {
primary 192.168.80.1;
key "linuxmce-dhcp";
}

zone 80.168.192.in-addr.arpa {
primary 192.168.80.1;
key "linuxmce-dhcp";
}


option space pxelinux;
option pxelinux.magic code 208 = string;
option pxelinux.configfile code 209 = text;
option pxelinux.pathprefix code 210 = text;
option pxelinux.reboottime code 211 = unsigned integer 32;

subnet 192.168.80.0 netmask 255.255.255.0 {
next-server 192.168.80.1;
filename "/tftpboot/pxelinux.0";
option pxelinux.reboottime = 30;

option domain-name "wright.local";
option domain-name-servers 192.168.80.1;
option routers 192.168.80.1;

default-lease-time 86400;
max-lease-time 604800;
pool {
allow unknown-clients;
range 192.168.80.129 192.168.80.254;
}
}

# PXE booting machines
group {
next-server 192.168.80.1;
filename "/tftpboot/pxelinux.0";
option pxelinux.reboottime = 30;

}

# regular machines
group {
}

# CORE (1) has bad mac address:


/etc/resolv.conf
Code: [Select]
domain wright.local
nameserver localhost

I'm not sure where to go from here.  Is there enough desire to make this a feature in LinuxMCE?  If so, how?

Have fun,
Roy

243
Users / Re: Can't play commercial DVD's (dvdcss is installed)
« on: February 03, 2008, 04:23:46 am »
I saw another page in the wiki that mentions installing libdvdread3 via sudo apt-get install, but it asks for my sudo password - of course I don't know what it is..

By default you use the "linuxmce" account with a password of "linuxmce".  So when you sudo, you use the same password "linuxmce" (of course without the quotes).

Also try ripping an older dvd, some of the newer ones are causing trouble. 

Also search the forum on the recent post on setting the dvd region.  That might help.

Have fun,
Roy

244
Installation issues / Re: 0710B3 media file sync not seeing nfs share
« on: February 02, 2008, 01:29:25 am »
The /usr/pluto/bin/StorageDevices_Symlinks.sh is adding the symlink to /home/public/data/other/NFS Share [36].  Currently trying to see why the share's public directory is added there.  For example here's a path to a video file:

/home/public/data/other/NFS\ Share\ \[36\]/public/data/videos/Comedy/Splash.dvd

Also I can now set/change attributes using Media File Sync, but interestingly .id3 files do not show up on the share...

Have fun,
Roy

245
Installation issues / Re: 0710B3 media file sync not seeing nfs share
« on: January 31, 2008, 10:49:47 pm »
Thank you, I'll give it a look see.

I may have found the root issue - when I set up the nfs share I had created  a linuxmce user on the nfs server then squashed all user access to use this account.  This caused the dcerouter to see the files as belonging to 1002:users, which is probably preventing access.  On the internal drive, the dcerouter uses linuxmce:public.  So  tonight I'll remove squashing and see what happens.

I'm curious how everyone else is solving the uid/gid synchronization problem.  Are y'all running an ldap server & pam-ldap, or setting the uid 1000 to linuxmce on all servers, or what?

Thank you,
Roy

246
Installation issues / 0710B3 media file sync not seeing nfs share
« on: January 31, 2008, 02:27:57 am »
Howdy,

I finally added a second drive to my core then replaced 0710B2 with 0710B3 amd64.  The new installation went smooth (the plutohome.com/new_installation.php scripts did timeout).  I was nicely prompted on which hard drive to install on.  During install the second drive was discovered and mounted as an internal drive.  Everything I had working previously checked out.

So on to adding a new feature, mounting an nfs share.  Interestingly the autodiscovery would find cifs shares but did not discover the nfs share.  So simply added the share from pluto admin, Advanced, Configuration, Devices.

The share does show up under /mnt/device/36 and I can rip dvd to it and I can play the video from it.  Interestingly, when choosing the file to play, the UI1 screen with the Play, Close, Delete button has the file location as: "File: Disk #2".

When I go to pluto admin, Files & Media, Media Files Sync, I can not find the nfs share.  I can find the second hard disk under /home/public/data/videos/Internal HDD-CORE(sdb1)[35].  That's where I would expect a symlink to /mnt/device/36.

Any hints on what is responsible for creating the symlink? 

TIA,
Roy

247
Developers / Re: Threaded GSDRuby Beta Ready! (c/w PLCBUS bidi support)
« on: January 28, 2008, 09:42:50 pm »
- does anyone know of any source how to learn Ruby and your code efficiently ?

The definitive and very readable book is "Programming Ruby, The Pragmatic Programmers' Guide" by Dave Thomas.  The older release of the book is available online at http://www.ruby-doc.org/docs/ProgrammingRuby/

The ruby language site is http://www.ruby-lang.org/en/

A nice quick reference (once you learn the language) is: http://www.zenspider.com/Languages/Ruby/QuickRef.html

And finally the API docs are at: http://www.ruby-doc.org/

If you decide to look into Rails, then start with Dave Thomas' "Agile Web Development with Rails".  Rails itself is an excellent example on how to use Ruby.

Have fun,
Roy

248
Developers / Re: Threaded GSDRuby Beta Ready! (c/w PLCBUS bidi support)
« on: January 27, 2008, 11:03:47 pm »
regarding my log():
ok, I originally wrote the log() routine when I started ruby..
I ran into problems displaying XML in the log.
Then, later, I ran into problems displaying Object.inspect in the log..
out of much frustration, that is what I ended up with, and as long as it worked (ie displayed what I needed it to) I left it.
ERb (at least in linuxmce) doesn't like displaying <object>. I tries to parse it.
Even in the code window, when you want to make a String='<?xml version="1.0"?>', when you save it, you get String=''
The debug calls are just them.  debug.  they can be removed.

You might want to try something like:

require 'cgi'

puts CGI.escapeHTML(line)

that will escape html characters ('<' => '&lt;', '&' => '&amp;',...)

Have fun,
Roy

249
Developers / Re: Threaded GSDRuby Beta Ready! (c/w PLCBUS bidi support)
« on: January 27, 2008, 12:29:34 pm »
Howdy,

I took a look at your code more as a curiosity of how ruby is being used in LinuxMCE than in actually using the feature.  I thought I'd give you a few comments in a friendly code review style.

* you might consider using rdoc style comments.  That will make publishing the API easier.

* naming choices are good, long names

* mixed constant naming, sometimes all uppercase, sometimes mixed (camel) case (ex: NotReady = 1).  Convention is constant object references should be all uppercase with underscores.  Camelcase is used for class and module names.

* a few methods are a little high on the line count, but mostly because of all the good logging calls.

* Your log() methods have me a little confused.  Why all the putc calls?  Wouldn't something like the following accomplish the same?

Code: [Select]
def log(line)
  File.open("/var/log/pluto/" + device_.devid_.to_s + "_Generic_Serial_Device.log", "a") do |logfile|
  logfile.puts '(***)' + line.to_s.gsub('<',' ')
  end
end

* in several debug methods you use this construct:

Code: [Select]
  work = label + ":"
  for c in 1..text.length
    work += padhex("%X" %text[c-1]) + ' '
  end

string concatenations are usually costly.  It might be better to append to an array then join to a string:

Code: [Select]
  array = []
  for c in 1..text.length
    array << padhex("%X" %text[c-1])
  end
  work = label + ':' + array.join(' ')

but then again, these are in debug methods so performance is probably not an issue.  :-)

* in gsdcommand() I'm not sure what the return value will be when the case statement hit's one of the when statements that don't have a block.  For example, what will be returned when @gsdcommand is 'REPORT ONLY ON PULSE'?  You might need an extra return statement at the bottom of the method.

* Sometimes the really long cases can be replaced with a hash lookup.  For example, in gsdcommand, you may want to play with something like:

Code: [Select]
FUNCTIONS = {'ALL UNIT OFF' => Proc.new {@gsdparams[10] = '0';return 48},
               'ALL LTS ON' => Proc.new {@gsdparams[10] = '1';return 48},
               #...
              }

def gsdcommand #returns DCE EVENT!! and compiles params
  p = FUNCTIONS[CommandFunctions[@gsdcommand]]
  p.call unless p.nil?
  return 0
end

But then again, the big case statement is probably more readable.  :-)

Overall, very nice looking code.  :-)

Have fun,
Roy

250
Developers / Re: Graphical view on pluto_main
« on: January 26, 2008, 07:07:16 am »
Howdy,

Not sure how useful this is to others, but I wrote a script that reads the structure of a mysql database and then generates a mindmap for viewing with FreeMind 0.9.0 Beta 15 (http://freemind.sourceforge.net/wiki/index.php/Main_Page).  The script runs on 0710B2 without any additional requirements.

The script is at:

  http://roy.wright.org/linuxmce/mysql2mm.rb

An example mindmap (ok, it's pluto_media database 0710B2)  is at:

  http://roy.wright.org/linuxmce/pluto_media.mm

Basically what this shows you is the linkage of foreign keys to primary keys, with the assumption that FK_name is linked to PK_name.  The script probably needs a little more smarts here.  Also each table description is attached as a note to the table's node.

One thing I like about the mindmaps is being able to collapse what I'm not interested in.  Also it's nice to just add notes as I'm working.

Have fun,
Roy

251
Developers / Re: What's the difference between EK_MediaType 3 & 5?
« on: January 25, 2008, 08:09:43 pm »
Is there a Mantis bug reporting the failure to set the DVD's media type? Because though your workaround is useful, the underlying bug really should be fixed.

I think not setting FK_FileFormat is probably a bug as the ripper should know the source media.  To set FK_MediaSubType which describes content (TV Shows, Movies, Home Videos,...) will take user intervention, probably a change to the UI to prompt the user.  So I'll file two bugs.

you can do some experimenting, but I believe if the media type is set to DVD, then the DVD menu options will be avaiable when that media is played.

That makes sense.  Thank you. I'll investigate this and if a DVD has a menu but the EK_MediaType is being set to LinuxMCE video file, then I'll open a bug for it.

FYI here's some commands from this investigation:

Find missing FK_FileFormat or missing FK_MediaSubType:

  mysql> select Path,Filename,FK_FileFormat,FK_MediaSubType from File where IsDirectory = '0' and Path like '/home/public/data/videos%' and (FK_FileFormat is null or FK_MediaSubType is null);

Set missing FK_FileFormat to DVD (DVD == 2):

  mysql> update File set FK_FileFormat = '2' where IsDirectory = '0' and Path like '/home/public/data/videos%' and FK_FileFormat is null;

Set missing FK_MediaSubType to Movies (Movies == 2):

  mysql> update File set FK_MediaSubType = '2' where IsDirectory = '0' and Path like '/home/public/data/videos%' and FK_MediaSubType is null;


Thank you,
Roy

252
Developers / What's the difference between EK_MediaType 3 & 5?
« on: January 25, 2008, 08:24:01 am »
Howdy,

When a dvd is ripped, by default FK_FileFormat and FK_MediaSubType are not set.  It's kind of a pain to manually use pluto_admin to set them, so am working on a script to automate it.  While doing so I've noticed that the EK_MediaType is sometimes 3 and sometimes 5 (LinuxMCE DVD or LinuxMCE video file).  This got me to wondering what it should be, LinuxMCE DVD because it's a .dvd file or is LinuxMCE DVD suppose to mean a dvd disc in a player?  I searched the wiki and the forums and didn't find any enlightenment.


$ mysql
mysql> use pluto_media;
mysql> select Path,Filename,EK_MediaType from File where IsDirectory = '0' and Path like '/home/public/data/videos%' and FK_FileFormat is null;
+------------------------------------------+-------------------------------------------------+--------------+
| Path                                     | Filename                                        | EK_MediaType |
+------------------------------------------+-------------------------------------------------+--------------+
| /home/public/data/videos/Action          | The Art of War.dvd                              |            3 |
| /home/public/data/videos/Action          | Last Man Standing.dvd                           |            3 |
| /home/public/data/videos/Action          | Fair Game.dvd                                   |            3 |
| /home/public/data/videos/Comedy          | Operation Petticoat.dvd                         |            5 |
| /home/public/data/videos/Comedy          | Scooby-Doo 2  Monsters Unleashed  WS .dvd       |            5 |
| /home/public/data/videos/Comedy          | Support Your Local Sheriff.dvd                  |            3 |


FYI, these were all rip'ed with 0710B2. 

Thank you,
Roy

253
Users / Re: Core/Media Director keeps crashing
« on: January 15, 2008, 10:04:27 am »
Howdy,

I was experiencing the same type of total lock up.  Real pain as this would stop routing the LAN to the internet.  Basically the system would lock up somewhere between 4 hours and 5 days.  Originally with 0704, but problem remained after upgrading to 0710B2.  I could not find any indication of a problem in the logs.  Thinking it might be thermal related, I changed the airflow direction of my blow hole case fan (actually only fan) in my Zalman 135 case.  The fan is right above the CPU fan.  Originally I had the CPU fan blowing down and the case fan blowing up (exhausting).  I changed it so both are blowing down.  Currently at 10 days up time.  Keeping my fingers crossed.

HTH,
Roy


254
Users / Re: HELP! How do I add a media director for diskless boot?
« on: January 14, 2008, 08:33:02 am »
Howdy,

I hit the same problem this evening when trying to add an old Sony VAIO as an MD.  These are the steps I think I took to get it working on 0710B2:

1) At the bottom of the Wizards|Media Directory page there is a button: "Setup Diskless MD *".  Press it and wait for the script it runs to complete.

2) reload the router. 

3) Finally boot your PXE MD.

The boot is pretty slow, but you should have lot's of messages scrolling.  Eventually you'll get to the AV setup wizard.

Now on to figuring out how to let the diskless MD have 1280x768 display resolution...   :)


HTH,
Roy

255
Users / Re: trouble reading new dvds
« on: January 12, 2008, 09:34:26 pm »
I've found one disk that seems to have the problem described:

  Rush Hour 3
  New Line 2-Disc Platinum Series
  disc 1

Both LCME 0710B2 and K3b report CSS key problem.

HTH,
Roy

Pages: 1 ... 15 16 [17] 18