Back End





edit SideBar

Back End
Implemented by
Hastur, Cyclops

Back end

  • Record and playback on DVB-T
  • DVB-T (Freeview)
  • Simultaneous record and playback
  • Media sharing

Hardware

Back-end


Operating Systems


Data Partitioning

  • Separate metadata and library trees allows some clients to collect metadata

Single Volume

  • Each MEDIATYPE has separate library and metadata trees
  • Data trees are grouped for export using "bind" mounts
  • Matches nfs export concept

Logical Volumes Option

  • Each MEDIATYPE has a logical volume, lv-MEDIATYPE
  • Each lv-MEDIATYPE has separate library and metadata trees
  • Trees are grouped for export using normal mounts
  • Requires a resizeable filesystem (i.e. not XFS)

File Permissions

Users

media-centreDefault ownerrw all media

Groups

GroupRolePermissions
mc-musicPlays musicro music lib
mc-videosPlays videosro video lib
mc-moviesPlays moviesro movies lib
mc-photosShows photosro photos lib
mc-tvPlays recordingsro recordings
mc-gamesPlays gamesro game roms lib
mcadm-musicManages musicrw music library
mcadm-videosManages videosrw video library
mcadm-moviesManages moviesrw movie library
mcadm-photosManages photosrw photo library
mcadm-tvManages recordingsrw recordings
mcadm-gamesManages gamesrw game roms lib
  • All media files have owner permissions "rwx"
  • All media files have group (ACL mask) permissions "rwx"
  • All media files have other permissions "---"
  • All MEDIATYPE files have named group "mcadm-MEDIATYPE" permissions "rw-"
  • All MEDIATYPE files have named group "mc-MEDIATYPE" permissions "r--"
  • All MEDIATYPE directories have default ACLs? reflecting the above permissions

Example Configuration

/etc/passwd

media-centre:x:3000:3000:Media Centre:/nonexistent:/usr/sbin/nologin

Example /etc/group

mc-movies:x:3003:mythtv,mediatomb,admin1,user1
mc-music:x:3001:mythtv,mediatomb,mpd,admin1,user1
mc-photos:x:3007:mythtv,admin1,user1
mc-tv:x:3009:mythtv,mediatomb,admin1,user1
mc-videos:x:3002:mediatomb,admin1,user1
mcadm-movies:x:3006:,admin1
mcadm-music:x:3004:mpd,admin1
mcadm-photos:x:3008:,admin1
mcadm-tv:x:3010:,admin1
mcadm-videos:x:3005:,admin1
mc-users:x:3011:admin1,user1

Example ACL (getfacl /mnt/media/movies)

# file: library
# owner: media-centre
# group: mcadm-movies
user::rwx
group::---
group:mc-movies:r-x
group:mcadm-movies:rwx
mask::rwx
other::---
default:user::rwx
default:group::r-x
default:group:mc-movies:r-x
default:group:mcadm-movies:rwx
default:mask::rwx
default:other::---

User Contributed Files

  • All users have a $user/shared-media directory with write permission
  • $user/shared-media ACLs? allow access by mediasys groups
  • mediasys/users/$user is a symlink to $user/shared-media
  • CIFS requires wide links = yes for the mediasys share.
  • Not compatible with NFS.

Data Export

  • A single shared tree for mediasys
  • Each MEDIATYPE library and metadata directory is mapped into the single tree.
  • Shares per MEDIATYPE writeable by the admin group for that MEDIATYPE.

Example fstab

/etc/fstab

# Media mounts
/dev/vg-media/home        /home   ext4    defaults,noatime,nosuid,noauto,acl      0       0
/dev/vg-media/media       /mnt/media  ext4    defaults,noatime,nosuid,noauto,acl      0       0
# Export mounts
/mnt/media/movies/library /export/mediasys/movies/library none bind,noauto    0       0
/mnt/media/movies/metadata /export/mediasys/movies/meta none bind,noauto      0       0
/mnt/media/music/library /export/mediasys/music/library none bind,noauto      0       0
/mnt/media/music/metadata /export/mediasys/music/meta none bind,noauto        0       0
/mnt/media/tvshows/library /export/mediasys/tvshows/library none bind,noauto  0       0
/mnt/media/tvshows/metadata /export/mediasys/tvshows/meta none bind,noauto    0       0
/mnt/media/recordings /export/mediasys/recordings none bind,noauto    0       0
/mnt/media/photos/library /export/mediasys/photos/library none bind,noauto    0       0
/mnt/media/photos/metadata /export/mediasys/photos/meta none bind,noauto      0       0

Samba/CIFS

  • Requires username/password

Example Configuration

/etc/smb.conf

[mediasys]
   path=/export/mediasys
   browseable = yes
   writable = yes
   mangled names = no
   follow symlinks = yes # for per-user shared-media
   wide links = yes  # for per-user shared-media
   valid users = mythtv,@mc-users

[homes]
   path=/home/%S
   comment = Home Directories
   browseable = no
   writable = yes
   create mask = 0700
   directory mask = 0700
   valid users = %S
   mangled names = no

# Administrative shares - not browseable by default
[movies]
   path=/mnt/media/movies
   browseable = no
   writable = yes
   mangled names = no
   valid users = @mcadm-movies

...

NFS

Read-only Exports (without security)

/etc/exports

/export/mediasys  192.168.0.0/24(ro,fsid=0,sync,no_subtree_check)
/export/mediasys/movies/library   192.168.0.0/24(ro,nohide,sync,no_subtree_check)
/export/mediasys/movies/meta      192.168.0.0/24(ro,nohide,sync,no_subtree_check)
/export/mediasys/tvshows/library  192.168.0.0/24(ro,nohide,sync,no_subtree_check)
/export/mediasys/tvshows/meta     192.168.0.0/24(ro,nohide,sync,no_subtree_check)
/export/mediasys/music/library    192.168.0.0/24(ro,nohide,sync,no_subtree_check)
/export/mediasys/music/meta       192.168.0.0/24(ro,nohide,sync,no_subtree_check)
/export/mediasys/photos/library   192.168.0.0/24(ro,nohide,sync,no_subtree_check)
/export/mediasys/photos/meta      192.168.0.0/24(ro,nohide,sync,no_subtree_check)

Permissions fixes for NFSv3?

/export/mediasys 192.168.0.0/24(ro,fsid=0,sync,no_subtree_check,all_squash,anongid=3000)
/export/mediasys/movies/library 192.168.0.0/24(ro,nohide,sync,no_subtree_check,anongid=3003)
...
mount -t nfs4 -o ro media: /mnt/media

Capture Cards

Linux Chipset Support

ivtv Driver supported hardware

DVB-T

CardHDSD tunersDVB-T tunersPriceNotes
Nova-T-PCIYes01£28 EbuyerSupported
Nova-T-500Yes02£55 EbuyerUSB bridge device; not fully supported
Pinnacle PCTV DVB-T Pro PCINo02£56 scanNo support
DViCO FusionHDTV Dual DigitalYes02  
AverTV? DVB-T A771   £35 SpecialTech 
AverTV? DVB-T A777Yes01Supplier??Replaces A771
TerraTec? Cinergy 2400i PCI-E 02 No support yet
Compro VideoMate? DVB-T200 PCIYes01  

CAMs?


DVD Encoding

Profiles

High Quality Compressed

  • H.264 video
  • AC3? audio
  • mp4 container
  • ~2GB

High Quality Raw


Notes

  • Hardware or software encoding?
    • Hard enc more expensive, Soft enc needs more powerful CPU
  • Does a software encoder require encoding to MPEG2??
    • Yes, or some other codec
  • Can a software encoder encode to something else in Realtime?
    • DivX?, Xvid, H.264 check processor requirements
  • MPEG-4 encoders
    • Hauppauge HVR-4000 does H.264
  • Front end may need up to 1GB RAM to store MythTV? UI elements for 1080p displays
  • VIA UniChromePro? graphics may eventually be capable of H.264 acceleration with XvMC?
  • VIA & nVidia cards can accelerate decoding of MPEG2?
Recent Changes (All) | Edit SideBar Page last modified on 23 January 2019, at 01:18 PM UTC Edit Page | Page History
Powered by PmWiki