User:Trogod/System0Setup
what's the deal?
2009-07-03 23:20:03.072 lirc init success using configuration file: /home/trogod/.mythtv/lircrc 2009-07-03 23:20:04.114 Specified base font 'medium' does not exist for font clock 2009-07-03 23:20:04.114 Specified base font 'medium' does not exist for font small 2009-07-03 23:20:04.114 Specified base font 'medium' does not exist for font medium 2009-07-03 23:20:04.114 Specified base font 'medium' does not exist for font large
2009-07-03 23:20:04.348 Registering Internal as a media playback plugin. 2009-07-03 23:20:04.559 MonitorRegisterExtensions(0x100, gif,jpg,png) 2009-07-03 23:20:05.012 Failed to run 'cdrecord --scanbus' 2009-07-03 23:20:05.019 Failed to run 'cdrecord --scanbus -dev=ATA' 2009-07-03 23:20:05.022 Failed to run 'cdrecord --scanbus -dev=ATAPI' 2009-07-03 23:20:05.039 MonitorRegisterExtensions(0x40, ogg,mp3,aac,flac)
Contents
Non-default settings
- I had to activate my HDHomeRun's IR receiver, myself
- whenever I reboot, I must
- reactivate the HDHomeRun's IR receiver
- restart the mythtv backend so that it receives HDHomeRun video and IR data over the network
- start LIRCD
- set MythTV frontend > "Utilities / Setup" > Setup > General > page 3 General. The setting is "System Exit key:" I changed it to "Alt-ESC". The default setting of ESC wasn't vey nice because, so often I would accidentally get the "do you really want to exit MythTV?" dialog
- set MythTV frontend > "Utilities / Setup" > Setup > Appearance > page 1 Theme. The setting "Paint Engine:" I changed from "Qt" to "OpenGL". I was hoping my checkboxes would start looking better, but they didn't. In any case, if OpenGL uses the graphics card, then I think it's the better choice.
- set MythTV frontend > "Utilities / Setup" > Setup > Appearance > page 1 Theme. The setting "Qt Style:" I changed to "Platinum" per advice from the mythtv-users mailing list. I believe the idea was that I would be using "Paint Engine: Qt", but I'll keep this setting, anyway.
- set MythTV frontend > "Utilities / Setup" > Setup > TV Settings > General. checked "Change channels immediately without select" my wife wanted this
- set MythTV frontend > "Utilities / Setup" > Setup > TV Settings > General. checked "Allow live TV to move scheduled shows". Wow! this just makes sense to me - why wouldn't this be checked to begin with?
Partitioning
see also File_storage
User:Trogod/System0
I used "fdisk -l" to show me which hard drive is which. I have two (2) drives: an 80 GB and a 1 TB.
I want to partition for multiple MythTV installations, so I can try out different installations and different versions. See
- http://www.linuxforums.org/forum/installation/38347-partitions-multiple-linux-distros.html
- http://digitalmedia.oreilly.com/2005/08/17/myth_tv.html
- http://www.faqs.org/docs/Linux-mini/Partition.html
- http://www.gnu.org/software/parted/manual/parted.html
- "A /home & swap partition you share between all distro's. Then +/- 5 GB (I would say 7 GB is better though, because of the space log files can take) for each distro."
- "Personally I resized my 120 GB hd into a bunch of 13-14 GB partitions that all share the same swap."
80 GB:
- /boot 100 MB -- It must be of type 0x83 "Linux native". -- must be contained within the first 1024 cylinders of the drive
- swap 10 GB -- It must be of type 0x82 "Linux swap".
- / 1 15 GB
- / 2 15 GB
- / 3 15 GB
- home 20 GB
- total 75 GB
1 TB:
- one big JFS partition
command-line:
/dev/sda is my 1TB parted /dev/sda (parted) mklabel gpt
- UPDATE* I have dropped MythDora for now and have gone with MythBuntu, details coming. Short story is that the MythDora installation DVD didn't work on my system although the MythDora LiveCD did -- confusing.
More
$ /usr/bin/mythbackend --version Please include all output in bug reports. MythTV Version : 19961 MythTV Branch : branches/release-0-21-fixes Library API : 0.21.20080304-1 Network Protocol : 40 Options compiled in: linux profile using_oss using_alsa using_jack using_backend using_dbox2 using_dvb using_firewire using_frontend using_hdhomerun using_iptv using_ivtv using_joystick_menu using_libfftw3 using_lirc using_opengl_vsync using_opengl_video using_v4l using_x11 using_xrandr using_xv using_xvmc using_xvmcw using_xvmc_vld using_glx_proc_addr_arb using_bindings_perl using_bindings_python using_opengl using_ffmpeg_threads using_libavc_5_3 using_live
I've had problems getting digital audio over HDMI with my GA-E7AUM-DS2H. I've found some things to try, though.
- need alsa .19?
- http://ubuntuforums.org/showthread.php?t=1068469&highlight=GA-E7AUM-DS2H
- http://www.linkapps.com/hardware/28-ubuntu-digital-audio-with-ga-e7aum-ds2h.html
- http://www.avsforum.com/avs-vb/showthread.php?p=16075943#post16075943
- http://www.avsforum.com/avs-vb/showthread.php?p=16712397#post16712397
- http://www.nvnews.net/vbulletin/showthread.php?t=116286&highlight=ga-e7aum-ds2h+ubuntu+audio&page=3
- similar setup ? http://ubuntuforums.org/showthread.php?t=1116232&highlight=GA-E7AUM-DS2H
- HDMI audio - http://ubuntuforums.org/showthread.php?t=1196063&highlight=GA-E7AUM-DS2H
- HOWTOs - http://ubuntuforums.org/showthread.php?s=f22d25dca38b3f939e9de0abd5fe0e5c&t=751719
- similar problem, I think - https://answers.launchpad.net/ubuntu/+question/68942
- same problem - http://www.nvnews.net/vbulletin/showthread.php?t=116286&page=3
- same problem - http://www.nvnews.net/vbulletin/showthread.php?t=126545
- http://www.nvnews.net/vbulletin/showthread.php?t=97993&page=8
- http://www.xpmediacentre.com.au/community/vista-media-center-software/28786-problem-spdif-passthrough.html
- ALSA documentation of interest
Also, i found some other interesting links...
- x.org modeline fix - http://ubuntuforums.org/showthread.php?t=1116232&highlight=GA-E7AUM-DS2H&page=2
- TiVo remote - http://ubuntuforums.org/showthread.php?t=972341
- keyboard commands - http://www.mythtv.org/docs/mythtv-HOWTO-11.html
- http://www.mythtv.org/wiki/Unofficial_Plugins
- streaming video - http://www.torrentocracy.com/blog/archives/2006/05/streaming_mytht_1.shtml - http://www.mythtv.org/wiki/Transcoding_into_a_3gp_Video
- http://arstechnica.com/apple/news/2008/04/mythtv-now-interfacing-with-iphone-no-jailbreak-required.ars* mp3 radio - http://www.oneweb.co.uk/mythtv/2009/02/automatically-convert-radio-shows-to-mp3-format/
- http://www.mythtv.org/wiki?title=AllensDigitalAudioHowto
- sshfs - http://ubuntuforums.org/showthread.php?t=1090085
- IMDB posters - http://www.oneweb.co.uk/mythtv/2009/02/updated-imdbpl-for-getting-hi-res-movie-posters/
- restarting the frontend
I've noticed that when mythtv starts up, my HDHomeRun isn't detected. There's a discussion at http://www.gossamer-threads.com/lists/mythtv/users/341416 "Unable to send discovery request" "eno: Network is unreachable"
interesting for playing music out of selected speakers: ALSA_upmixing
453 mkdir -p /storage/mythdvd/temp 454 ls -Ftl /storage/ 455 sudo chown -R mythtv:mythtv /storage
Sound Configuration
problem
I'm having trouble configuring my digital audio over HDMI. I've fiddled with the settings, googled for help, looked at http://www.mythtv.org/wiki?title=AllensDigitalAudioHowto, but to no avail :(
While watching live or recorded ATSC TV, I can get stereo-only sound over HDMI and I can get digital (AC3 passthrough) over my optical connection (Toslink S/PDIF), but I can't seem to figure out the AC3-passthrough over HDMI.
I'm using a GIGABYTE GA-E7AUM-DS2H, NVIDIA GeForce 9400. I installed MythBuntu from mythbuntu-9.04-desktop-amd64.iso. I'm using NVIDIA driver 180.44, according to "NVIDIA X Server Settings".
I've connected the HDMI from the motherboard to my TV (Panasonic Viera TH-42PZ80U) and optical Toslink from the TV to my receiver (Sony STR-DE635) (it has only one optical audio input jack).
My Audio settings are: Audio output device: ALSA:hdmi Passthrough output device: Default Max Audio Channels: Stereo Upmix: Passive _ Enable AC3 to SPDIF passthrough _ Enable DTS to SPDIF passthrough _ Aggressive Sound card buffering _ User internal volume controls (none of those are checked)
If I turn on the AC3 and DTS passthrough, I get only noise, a digital, choppy, fluttery noise over HDMI. If I use the optical connection (S/PDIF) and change to "Passthrough output device: ALSA:iec958:{ AES0 0x02 }", the light on my receiver turns on and I get 5.1 audio.
After installing MythBuntu and getting absolutely no audio, I discovered that I had to un-mute "IEC958 1" (I think it was that one) in alsamixer.
My motherboard's BIOS has settings "Onboard Audio Function" and "HDMI Audio", both of which are set to "Auto" (which, according to the "Help", means enabled -- the only other setting is "Disabled").
research
$ aplay -l **** List of PLAYBACK Hardware Devices **** card 0: NVidia [HDA NVidia], device 0: ALC883 Analog [ALC883 Analog] Subdevices: 1/1 Subdevice #0: subdevice #0 card 0: NVidia [HDA NVidia], device 1: ALC883 Digital [ALC883 Digital] Subdevices: 1/1 Subdevice #0: subdevice #0 card 0: NVidia [HDA NVidia], device 3: NVIDIA HDMI [NVIDIA HDMI] Subdevices: 1/1 Subdevice #0: subdevice #0
$ aplay -L front:CARD=NVidia,DEV=0 HDA NVidia, ALC883 Analog Front speakers surround40:CARD=NVidia,DEV=0 HDA NVidia, ALC883 Analog 4.0 Surround output to Front and Rear speakers surround41:CARD=NVidia,DEV=0 HDA NVidia, ALC883 Analog 4.1 Surround output to Front, Rear and Subwoofer speakers surround50:CARD=NVidia,DEV=0 HDA NVidia, ALC883 Analog 5.0 Surround output to Front, Center and Rear speakers surround51:CARD=NVidia,DEV=0 HDA NVidia, ALC883 Analog 5.1 Surround output to Front, Center, Rear and Subwoofer speakers surround71:CARD=NVidia,DEV=0 HDA NVidia, ALC883 Analog 7.1 Surround output to Front, Center, Side, Rear and Woofer speakers iec958:CARD=NVidia,DEV=0 HDA NVidia, ALC883 Digital IEC958 (S/PDIF) Digital Audio Output hdmi:CARD=NVidia,DEV=0 HDA NVidia, NVIDIA HDMI HDMI Audio Output null Discard all samples (playback) or generate zero samples (capture)
$ amixer controls # output sorted by hand numid=1,iface=MIXER,name='Front Playback Volume' numid=2,iface=MIXER,name='Front Playback Switch' numid=3,iface=MIXER,name='Surround Playback Volume' numid=4,iface=MIXER,name='Surround Playback Switch' numid=5,iface=MIXER,name='Center Playback Volume' numid=6,iface=MIXER,name='LFE Playback Volume' numid=7,iface=MIXER,name='Center Playback Switch' numid=8,iface=MIXER,name='LFE Playback Switch' numid=9,iface=MIXER,name='Side Playback Volume' numid=10,iface=MIXER,name='Side Playback Switch' numid=11,iface=MIXER,name='Headphone Playback Switch' numid=12,iface=MIXER,name='Mic Playback Volume' numid=13,iface=MIXER,name='Mic Playback Switch' numid=14,iface=MIXER,name='Front Mic Playback Volume' numid=15,iface=MIXER,name='Front Mic Playback Switch' numid=16,iface=MIXER,name='Line Playback Volume' numid=17,iface=MIXER,name='Line Playback Switch' numid=18,iface=MIXER,name='Mic Boost' numid=19,iface=MIXER,name='Front Mic Boost' numid=20,iface=MIXER,name='Capture Volume' numid=21,iface=MIXER,name='Capture Switch' numid=22,iface=MIXER,name='Capture Volume',index=1 numid=23,iface=MIXER,name='Capture Switch',index=1 numid=24,iface=MIXER,name='Input Source' numid=25,iface=MIXER,name='Input Source',index=1 numid=26,iface=MIXER,name='IEC958 Playback Con Mask' numid=27,iface=MIXER,name='IEC958 Playback Pro Mask' numid=28,iface=MIXER,name='IEC958 Playback Default' numid=29,iface=MIXER,name='IEC958 Playback Switch' numid=30,iface=MIXER,name='IEC958 Default PCM Playback Switch' numid=31,iface=MIXER,name='IEC958 Capture Switch' numid=32,iface=MIXER,name='IEC958 Capture Default' numid=33,iface=MIXER,name='Master Playback Volume' numid=34,iface=MIXER,name='Master Playback Switch' numid=35,iface=MIXER,name='IEC958 Playback Con Mask',index=1 numid=36,iface=MIXER,name='IEC958 Playback Pro Mask',index=1 numid=37,iface=MIXER,name='IEC958 Playback Default',index=1 numid=38,iface=MIXER,name='IEC958 Playback Switch',index=1 numid=39,iface=MIXER,name='PCM Playback Volume'
$ amixer contents numid=34,iface=MIXER,name='Master Playback Switch' ; type=BOOLEAN,access=rw------,values=1 : values=on numid=33,iface=MIXER,name='Master Playback Volume' ; type=INTEGER,access=rw---R--,values=1,min=0,max=64,step=0 : values=61 | dBscale-min=-64.00dB,step=1.00dB,mute=0 numid=11,iface=MIXER,name='Headphone Playback Switch' ; type=BOOLEAN,access=rw------,values=2 : values=on,on numid=39,iface=MIXER,name='PCM Playback Volume' ; type=INTEGER,access=rw---RW-,values=2,min=0,max=255,step=0 : values=245,245 | dBscale-min=-51.00dB,step=0.20dB,mute=0 numid=19,iface=MIXER,name='Front Mic Boost' ; type=INTEGER,access=rw---R--,values=2,min=0,max=3,step=0 : values=0,0 | dBscale-min=0.00dB,step=10.00dB,mute=0 numid=15,iface=MIXER,name='Front Mic Playback Switch' ; type=BOOLEAN,access=rw------,values=2 : values=off,off numid=14,iface=MIXER,name='Front Mic Playback Volume' ; type=INTEGER,access=rw---R--,values=2,min=0,max=31,step=0 : values=0,0 | dBscale-min=-34.50dB,step=1.50dB,mute=0 numid=2,iface=MIXER,name='Front Playback Switch' ; type=BOOLEAN,access=rw------,values=2 : values=on,on numid=1,iface=MIXER,name='Front Playback Volume' ; type=INTEGER,access=rw---R--,values=2,min=0,max=64,step=0 : values=52,52 | dBscale-min=-64.00dB,step=1.00dB,mute=0 numid=4,iface=MIXER,name='Surround Playback Switch' ; type=BOOLEAN,access=rw------,values=2 : values=on,on numid=3,iface=MIXER,name='Surround Playback Volume' ; type=INTEGER,access=rw---R--,values=2,min=0,max=64,step=0 : values=0,0 | dBscale-min=-64.00dB,step=1.00dB,mute=0 numid=7,iface=MIXER,name='Center Playback Switch' ; type=BOOLEAN,access=rw------,values=1 : values=on numid=5,iface=MIXER,name='Center Playback Volume' ; type=INTEGER,access=rw---R--,values=1,min=0,max=64,step=0 : values=0 | dBscale-min=-64.00dB,step=1.00dB,mute=0 numid=8,iface=MIXER,name='LFE Playback Switch' ; type=BOOLEAN,access=rw------,values=1 : values=on numid=6,iface=MIXER,name='LFE Playback Volume' ; type=INTEGER,access=rw---R--,values=1,min=0,max=64,step=0 : values=0 | dBscale-min=-64.00dB,step=1.00dB,mute=0 numid=17,iface=MIXER,name='Line Playback Switch' ; type=BOOLEAN,access=rw------,values=2 : values=off,off numid=16,iface=MIXER,name='Line Playback Volume' ; type=INTEGER,access=rw---R--,values=2,min=0,max=31,step=0 : values=0,0 | dBscale-min=-34.50dB,step=1.50dB,mute=0 numid=18,iface=MIXER,name='Mic Boost' ; type=INTEGER,access=rw---R--,values=2,min=0,max=3,step=0 : values=0,0 | dBscale-min=0.00dB,step=10.00dB,mute=0 numid=13,iface=MIXER,name='Mic Playback Switch' ; type=BOOLEAN,access=rw------,values=2 : values=off,off numid=12,iface=MIXER,name='Mic Playback Volume' ; type=INTEGER,access=rw---R--,values=2,min=0,max=31,step=0 : values=0,0 | dBscale-min=-34.50dB,step=1.50dB,mute=0 numid=21,iface=MIXER,name='Capture Switch' ; type=BOOLEAN,access=rw------,values=2 : values=on,on numid=23,iface=MIXER,name='Capture Switch',index=1 ; type=BOOLEAN,access=rw------,values=2 : values=on,on numid=20,iface=MIXER,name='Capture Volume' ; type=INTEGER,access=rw---R--,values=2,min=0,max=46,step=0 : values=0,0 | dBscale-min=-16.00dB,step=1.00dB,mute=0 numid=22,iface=MIXER,name='Capture Volume',index=1 ; type=INTEGER,access=rw---R--,values=2,min=0,max=46,step=0 : values=0,0 | dBscale-min=-16.00dB,step=1.00dB,mute=0 numid=30,iface=MIXER,name='IEC958 Default PCM Playback Switch' ; type=BOOLEAN,access=rw------,values=1 : values=off numid=26,iface=MIXER,name='IEC958 Playback Con Mask' ; type=IEC958,access=r-------,values=1 : values=[AES0=0x0f AES1=0xff AES2=0x00 AES3=0x00] numid=35,iface=MIXER,name='IEC958 Playback Con Mask',index=1 ; type=IEC958,access=r-------,values=1 : values=[AES0=0x0f AES1=0xff AES2=0x00 AES3=0x00] numid=27,iface=MIXER,name='IEC958 Playback Pro Mask' ; type=IEC958,access=r-------,values=1 : values=[AES0=0x0f AES1=0x00 AES2=0x00 AES3=0x00] numid=36,iface=MIXER,name='IEC958 Playback Pro Mask',index=1 ; type=IEC958,access=r-------,values=1 : values=[AES0=0x0f AES1=0x00 AES2=0x00 AES3=0x00] numid=28,iface=MIXER,name='IEC958 Playback Default' ; type=IEC958,access=rw------,values=1 : values=[AES0=0x04 AES1=0x82 AES2=0x00 AES3=0x02] numid=37,iface=MIXER,name='IEC958 Playback Default',index=1 ; type=IEC958,access=rw------,values=1 : values=[AES0=0x04 AES1=0x00 AES2=0x00 AES3=0x00] numid=29,iface=MIXER,name='IEC958 Playback Switch' ; type=BOOLEAN,access=rw------,values=1 : values=on numid=38,iface=MIXER,name='IEC958 Playback Switch',index=1 ; type=BOOLEAN,access=rw------,values=1 : values=on numid=32,iface=MIXER,name='IEC958 Capture Default' ; type=IEC958,access=r-------,values=1 : values=[AES0=0x04 AES1=0x00 AES2=0x00 AES3=0x00] numid=31,iface=MIXER,name='IEC958 Capture Switch' ; type=BOOLEAN,access=rw------,values=1 : values=off numid=24,iface=MIXER,name='Input Source' ; type=ENUMERATED,access=rw------,values=1,items=3 ; Item #0 'Mic' ; Item #1 'Front Mic' ; Item #2 'Line' : values=0 numid=25,iface=MIXER,name='Input Source',index=1 ; type=ENUMERATED,access=rw------,values=1,items=3 ; Item #0 'Mic' ; Item #1 'Front Mic' ; Item #2 'Line' : values=0 numid=10,iface=MIXER,name='Side Playback Switch' ; type=BOOLEAN,access=rw------,values=2 : values=on,on numid=9,iface=MIXER,name='Side Playback Volume' ; type=INTEGER,access=rw---R--,values=2,min=0,max=64,step=0 : values=0,0 | dBscale-min=-64.00dB,step=1.00dB,mute=0
about my TV
A couple of things I've come across that make me wonder if the Panasonic TH-42PZ80U really can do the passthrough:
in it's manual http://service.us.panasonic.com/OPERMANPDF/TH42PZ80U.PDF, on page 42, I quote "If you connect equipment that has "HDAVI Control 2" (or more) function to the TV with HDMI cable, the sound from DIGITAL AUDIO OUT terminal can be output as multi channel surround."
and, from http://www.amazon.com/Panasonic-Viera-TH-42PZ80U-1080p-Plasma/dp/B00142MUDS/ref=sr_1_1?ie=UTF8&s=electronics&qid=1246951218&sr=8-1 a reviewer (M. Hadeishi "synthetic zero") wrote "Another thing I really like about the set is it passes through Dolby 5.1 sound from the HDMI connector to the optical digital out --- which I then pass into my Logitech Z-5500 THX speakers (an inexpensive way to get surprisingly good home theater sound) --- the Sharp didn't pass through the signal from our PS3 Blu-Ray player. "
My current theory is that the PS3 transmits this HDAVI data and then the TV allows the digital passthrough. HDAVI, however, is only supposed to be for remote-control functions, so this seems rather odd. HDAVI is Panasonic's name for CEC, see http://en.wikipedia.org/wiki/HDMI
Another curious note from page 38 of the manual: "When audio from other equipment connected to this unit via HDMI is output using "DIGITAL AUDIO OUT" of this unit, the system switches to 2CH audio. (When connecting to an AV amp via HDMI, you can enjoy higher sound quality.)"
That contradicts page 42. I guess I'll have to call Panasonic's customer service http://www.panasonic.com/accessibility/aces_cus.asp and see if they can tell me anything...
analysis
I think that my current configuration is sending analog sound through my HDMI somehow. I can only get 2 channels of sound through my HDMI connection.
$ speaker-test -D hw:0,3 -c 2 speaker-test 1.0.18 Playback device is hw:0,3 Stream parameters are 48000Hz, S16_LE, 2 channels Using 16 octaves of pink noise Rate set to 48000Hz (requested 48000Hz) Buffer size range from 64 to 16384 Period size range from 32 to 8192 Using max buffer size 16384 Periods = 4 was set period_size = 4096 was set buffer_size = 16384 0 - Front Left 1 - Front Right Time per period = 5.632911 0 - Front Left ^C $ speaker-test -D hw:0,3 -c 3 speaker-test 1.0.18 Playback device is hw:0,3 Stream parameters are 48000Hz, S16_LE, 3 channels Using 16 octaves of pink noise Channels count (3) not available for playbacks: Invalid argument Setting of hwparams failed: Invalid argument
I saw mention of using plughw, and I was able to send 6 channels through that, but I only heard the front-left and front-right speakers in that test.
$ speaker-test -D plughw:0,3 -c 6 speaker-test 1.0.18 Playback device is plughw:0,3 Stream parameters are 48000Hz, S16_LE, 6 channels Using 16 octaves of pink noise Rate set to 48000Hz (requested 48000Hz) Buffer size range from 64 to 16384 Period size range from 32 to 8192 Using max buffer size 16384 Periods = 4 was set period_size = 4096 was set buffer_size = 16384 0 - Front Left 4 - Center 1 - Front Right 3 - Rear Right 2 - Rear Left 5 - LFE Time per period = 17.580031 0 - Front Left ^C
test with mplayer, from http://www.nvnews.net/vbulletin/showthread.php?t=123616
mplayer -ao alsa:device=hdmi
Hmmm, I just noticed an item named "IEC958 Default PCM Playback Switch" and it seems to be set to 'off'. Maybe if I turn that on.... See man page for amixer, like http://linux.die.net/man/1/amixer
$ amixer cget numid=30 numid=30,iface=MIXER,name='IEC958 Default PCM Playback Switch' ; type=BOOLEAN,access=rw------,values=1 : values=off $ amixer cset numid=30 on numid=30,iface=MIXER,name='IEC958 Default PCM Playback Switch' ; type=BOOLEAN,access=rw------,values=1 : values=on
Turning that on didn't seem to affect HDMI audio.
Optical Audio, Toslink S/PDIF works
- I turned on 'IEC958 Default PCM Playback Switch'
- set MythTV Front end as follows
Audio output device: ALSA:hdmi Passthrough output device: ALSA:iec958:{ AES0 0x02 } Max Audio Channels: Stereo Upmix: Passive X Enable AC3 to SPDIF passthrough X Enable DTS to SPDIF passthrough _ Aggressive Sound card buffering _ Use internal volume controls
I have a file /etc/asound.conf
$ cat /etc/asound.conf pcm.!default { type hw card 0 device 3 }
I've tried altering the MythTV frontend audio settings with and without this file, rebooting when I changed it, and it hasn't seemed to help.
Digital Audio over HDMI still not working
None of these has given me 5.1 audio over my receiver...
Configuring my IR Remote
I have a TiVo Series 2 remote and a One-For-All URC-7800B00 Cinema 7
I downloaded info for my TiVo Series 2 remote from http://lirc.sourceforge.net/remotes/tivo/TIVO_Series_2 - that file mentioned that a setup file for MythTV could be had at http://home.comcast.net/~johnfdeluca/lircrc.txt so I downloaded it, too.
I downloaded an lircrc for the TiVo Series 2 and Mythtv and put it where it seemed it should go:
$ cd ~ $ wget http://home.comcast.net/~johnfdeluca/lircrc.txt $ cd ~/.lirc $ mv mythtv backup-mythtv $ cp ~/lircrc.txt mythtv $ ls -l ~/.lircrc ~/.lirc/mythtv ~/.mythtv/lircrc -rw-r--r-- 1 trogod trogod 6698 2009-07-03 22:51 ~/.lirc/mythtv -rw-r--r-- 1 trogod trogod 296 2009-06-28 23:47 ~/.lircrc lrwxrwxrwx 1 trogod trogod 15 2009-07-03 22:51 ~/.mythtv/lircrc -> ../.lirc/mythtv
$ cd /etc/lirc/ $ sudo mv lircd.conf backup-lircd-conf $ sudo mv /home/trogod/TIVO_Series_2 lircd.conf $ sudo chown root:root lircd.conf
his file didn't work for me because it was for "dvr 1"
464 perl -p -i.bak -e 's/button = 1_/button = /g' mythtv
$ hdhomerun_config discover hdhomerun device 12345678 found at 1.2.3.4 $ hdhomerun_config 12345678 set /ir/target "1.2.3.5:5000 no_clear" $ sudo killall lircd [sudo] password for trogod: lircd: no process killed $ sudo lircd -H udp -d 5000
$ irw 00000000a10cc40b 00 PAUSE Tivo_S2 00000000a10cc40b 01 PAUSE Tivo_S2 00000000a10cc40b 02 PAUSE Tivo_S2 00000000a10c840b 00 PLAY Tivo_S2 00000000a10c840b 01 PLAY Tivo_S2 00000000a10c840b 02 PLAY Tivo_S2 00000000a10c7807 00 CH/PAGE_UP Tivo_S2 00000000a10c7807 01 CH/PAGE_UP Tivo_S2 00000000a10c7807 02 CH/PAGE_UP Tivo_S2 00000000a10cf807 00 CH/PAGE_DOWN Tivo_S2 00000000a10cf807 01 CH/PAGE_DOWN Tivo_S2 00000000a10cf807 02 CH/PAGE_DOWN Tivo_S2 00000000a10c0807 00 TV_POWER Tivo_S2 00000000a10c0807 01 TV_POWER Tivo_S2
461 cd 462 ls 463 mkdir irtemp 464 cd irtemp/ 465 irrecord CINEMA7 466 sudo killall lircd 467 irrecord CINEMA7 468 history 469 history | grep lircd 470 sudo lircd -H udp -d 5000 471 ps auxwww | grep -i lirc 472 irrecord CINEMA7 473 irrecord -H upd -d 5000 CINEMA7 474 irrecord -H udp -d 5000 CINEMA7 475 ls ~ 476 cat ~/restart-backend.txt 477 sudo /etc/init.d/mythtv-backend restart 478 sudo killall lircd 479 irrecord -H udp -d 5000 CINEMA7 480 rm CINEMA7 481 irrecord -H udp -d 5000 CINEMA7 482 rm CINEMA7 483 ls 484 irrecord -H udp -d 5000 CINEMA7 485 rm CINEMA7 486 irrecord -H udp -d 5000 CINEMA7 487 less CINEMA7 488 vi CINEMA7 489 cd .. 490 cd /etc/lirc/ 491 ls -Ftl 492 cp - 493 cp lircd.conf backup2-lircd-conf 494 sudo cp lircd.conf backup2-lircd-conf 495 sudo cat ~/irtemp/CINEMA7 >> lircd.conf 496 sudo bash 497 vi lircd.conf 498 sudo vi lircd.conf 499 history 500 irw
disabling update monitor
July 23 2009 based on info from http://ubuntuforums.org/showthread.php?t=1130181
$ gconftool -g /apps/update-notifier/auto_launch true $ gconftool -s --type bool /apps/update-notifier/auto_launch false $ gconftool -g /apps/update-notifier/auto_launch false
July 25 2009
$ gconftool-2 -a /apps/update-manager autoclose_install_window = true first_run = false show_versions = false remind_reload = true window_size = (664,600) show_details = true launch_time = 1248540255 check_dist_upgrades = true $ gconftool-2 -s --type bool /apps/update-manager/remind_reload false $ gconftool-2 -a /apps/update-manager autoclose_install_window = true first_run = false show_versions = false remind_reload = false window_size = (664,600) show_details = true launch_time = 1248540255 check_dist_upgrades = true
edit Samba
I had to change the /etc/samba/smb.conf to point to the directories on my 2nd drive. I think I didn't set this properly in the initial configuration of mythtv
diff --unified=4 smb.conf-bak smb.conf
--- smb.conf-bak 2009-10-04 01:21:48.000000000 -0700 +++ smb.conf 2009-11-28 21:56:46.000000000 -0800 @@ -9,9 +9,9 @@ security = share [recordings] comment = TV Recordings -path = /var/lib/mythtv/recordings +path = /storage/mythtv/recordings public = yes writable = no create mask = 0777 directory mask = 0777 @@ -19,9 +19,9 @@ force group = nogroup [videos] comment = Videos -path = /var/lib/mythtv/videos +path = /storage/mythtv/videos public = yes writable = yes create mask = 0660 directory mask = 0770 @@ -29,9 +29,9 @@ force group = mythtv [music] comment = Music -path = /var/lib/mythtv/music +path = /storage/mythtv/music public = yes writable = yes create mask = 0660 directory mask = 0770 @@ -39,9 +39,9 @@ force group = mythtv [pictures] comment = Pictures -path = /var/lib/mythtv/pictures +path = /storage/mythtv/pictures public = yes writable = yes create mask = 0660 directory mask = 0770
system crash
July 26, 2009
- My system crashed last night, see User:Trogod/System0KernCrash1
foo
July 30, 2009
- changing log rotation
$ pwd /etc/cron.daily $ diff --unified=3 /home/trogod/sysklogd sysklogd --- /home/trogod/sysklogd 2009-07-30 23:39:44.000000000 -0700 +++ sysklogd 2009-07-30 23:41:15.000000000 -0700 @@ -38,7 +38,7 @@ for LOG in $logs do if [ -s $LOG ]; then - savelog -g adm -m 640 -u ${USER} -c 7 $LOG >/dev/null + savelog -g adm -m 640 -u ${USER} -c 100 $LOG >/dev/null fi done $ pwd /etc/logrotate.d $ diff --unified=3 /home/trogod/mythtv-frontend mythtv-frontend --- /home/trogod/mythtv-frontend 2009-07-30 23:33:51.000000000 -0700 +++ mythtv-frontend 2009-07-30 23:34:07.000000000 -0700 @@ -1,7 +1,7 @@ /var/log/mythtv/mythfrontend.log { daily size=10M - rotate 7 + rotate 52 notifempty copytruncate missingok @@ -10,7 +10,7 @@ /var/log/mythtv/mythwelcome.log { daily size=10M - rotate 7 + rotate 52 notifempty copytruncate missingok $ diff --unified=3 /home/trogod/mythtv-backend mythtv-backend --- /home/trogod/mythtv-backend 2009-07-30 23:34:53.000000000 -0700 +++ mythtv-backend 2009-07-30 23:35:06.000000000 -0700 @@ -1,7 +1,7 @@ /var/log/mythtv/mythbackend.log { daily size=10M - rotate 7 + rotate 52 notifempty copytruncate } $ diff --unified=3 /home/trogod/unattended-upgrades unattended-upgrades --- /home/trogod/unattended-upgrades 2009-07-30 23:36:21.000000000 -0700 +++ unattended-upgrades 2009-07-30 23:36:31.000000000 -0700 @@ -1,5 +1,5 @@ /var/log/unattended-upgrades/unattended-upgrades.log { - rotate 6 + rotate 52 monthly compress missingok
- my mythtbackend crashed today!
2009-07-30 15:00:01.013 Finished recording Hawaii Five-0 "One Born Every Minute": channel 1561 *** glibc detected *** /usr/bin/mythbackend: malloc(): memory corruption (fast): 0x000000000286212f *** ======= Backtrace: ========= /lib/libc.so.6[0x7f0438d28cb8] /lib/libc.so.6[0x7f0438d2c351] /lib/libc.so.6(__libc_malloc+0x98)[0x7f0438d2d828] /usr/lib/libstdc++.so.6(_Znwm+0x1d)[0x7f04395879bd] /usr/lib/libqt-mt.so.3(_ZN7QStringC1EPK5QCharj+0x60)[0x7f043aba99a0] [SNIP]
Here's the crashes I see so far
$ grep -A 1 -B 3 -Hn glibc * mythbackend.log-34127-2009-07-30 15:00:00.841 TVRec(2): Changing from RecordingOnly to None mythbackend.log-34128-2009-07-30 15:00:01.013 Finished recording Guiding Light: channel 1021 mythbackend.log-34129-2009-07-30 15:00:01.013 Finished recording Hawaii Five-0 "One Born Every Minute": channel 1561 mythbackend.log:34130:*** glibc detected *** /usr/bin/mythbackend: malloc(): memory corruption (fast): 0x000000000286212f *** mythbackend.log-34131-======= Backtrace: ========= -- mythbackend.log.1-19704-2009-07-13 06:01:03.385 AFD: Opened codec 0xecd0b0, id(AC3) type(Audio) mythbackend.log.1-19705-2009-07-13 06:01:03.386 AFD: codec AC3 has 2 channels mythbackend.log.1-19706-2009-07-13 06:01:03.392 AFD: Opened codec 0xecd6f0, id(AC3) type(Audio) mythbackend.log.1:19707:*** glibc detected *** /usr/bin/mythbackend: malloc(): memory corruption (fast): 0x00007f8b209c177f *** mythbackend.log.1-19708-======= Backtrace: ========= -- mythbackend.log.3-7269-2009-07-04 00:03:35.814 Scheduled 1 items in 0.4 = 0.21 match + 0.19 place mythbackend.log.3-7270-2009-07-04 00:03:35.829 Reschedule requested for id 0. mythbackend.log.3-7271-2009-07-04 00:03:35.841 Scheduled 1 items in 0.0 = 0.00 match + 0.01 place mythbackend.log.3:7272:*** glibc detected *** /usr/bin/mythbackend: malloc(): memory corruption (fast): 0x00007fc72c2754af *** mythbackend.log.3-7273-======= Backtrace: =========
I decided to implement a script from Status_Monitoring_How_To
$ sudo crontab -l # m h dom mon dow command # # monitor the mythbacked service and restart it if it exists */5 * * * * root /usr/myextras/bin/mythmon || /etc/init.d/mythtv-backend restart $ cat /usr/myextras/bin/mythmon #!/bin/bash # # mythmon # This is run from cron every 5 minutes. # # from http://www.mythtv.org/wiki/Status_Monitoring_How_To # check for mythbackend running ps -C mythbackend > /dev/null && exit 0; # also check for mytv-setup running (it closes the backend) ps -C mythtv-setup > /dev/null && exit 0; # append message to log files ... echo "`date +%Y-%m-%d\ %T.%-3N` mythmon: mythbackend not running!!!" \ >> /var/log/mythtv/mythbackend.log; echo "`date +%Y-%m-%d\ %T.%-3N` mythmon: mythbackend not running!!!" \ >> /var/log/mythtv/mythmon.log exit 1;
added comment to https://bugs.launchpad.net/ubuntu/+source/mythtv/+bug/267274
Today I found my mythbuntu machine had a load of about 21 and there were several mythcommflag jobs running.
I think that the mythmon job had been trying to start my backend every 5 minutes and then the backend would fail (need to check logs about this)
I did a 'sudo killall mythcommflag' and then I rebooted. However, shortly thereafter the machine came under heavy load again. I guess the job queue reinstated the mythcommflag jobs :(
The computer became unresponsive and I had to reboot it by pressing the button on the front panel.
I then changed the job queue to waith 300 seconds before checking the queue "Jog Queue Check frequency (in seconds)". My "CPU Usage" was already set to "Low"
I have disabled my mythmon cron job because it needs to be changed to protect against repeated restarts like that.
I OKd all the system updates. I was asked about updating the smb.conf file but I kept the one that mythbuntu gave me.
I looked over my logs but I didn't see any messages from my mythmon script. maybe it wasn't the problem! I do see tons of messages about starting "commercial flagging" jobs, I just don't see why my shows got broken up into 5-minute segments like they did. I had to spend several minutes going through my recording history to delete all the little pieces it had recorded (mostly less than 5 minute segments) over that last 24 hours.
mytharchive
I decided I'd try out mytharchive. I think this plugin is part of mythbuntu. I don't think mythbuntu helped me set this up when I did my installation. I had to go to the setup screen and set the following: under Media Settings > Archive Files Settings
- Myth Archive Temp Directory: /storage/mytharchive/temp
- Video format: NTSC
- X Always Encode to AC3 - just sounds like a good idea
- X Always Use Mythtranscode - either sounded good or was already there from mythbuntu
- Default Encoder Profile: HQ - sounds like a good idea
In my terminal, I did this:
sudo mkdir -p /storage/mytharchive/temp/ sudo chmod -R a+rwx /storage/mytharchive ls -l /dev/dvd # is a symlink to /dev/sr0 ls -l /dev/sr0 sudo usermod -a -G cdrom mythtv sudo usermod -a -G cdrom trogod
$ ls -l /dev/dvd lrwxrwxrwx 1 root root 3 2009-07-31 23:27 /dev/dvd -> sr0 $ ls -l /dev/sr0 brw-rw----+ 1 root cdrom 11, 0 2009-07-31 23:27 /dev/sr0
Here I could see that the group I needed to add to was "cdrom"
Now, mytharchive ran, but I got some error messsages
/var/lib/python-support/python2.6/MySQLdb/__init__.py:34: DeprecationWarning: the sets module is deprecated from sets import ImmutableSet Using simple_fix_rtl mythburn.py (0.1.20080726-1-fixes) starting up... script path:/usr/share/mythtv/mytharchive/scripts myth share path:/usr/share/mythtv passed job file: /storage/mytharchive/temp/config/mydata.xml passed progress log file: /storage/mytharchive/temp/logs/progress.log mythburn.py (0.1.20080726-1-fixes) starting up... Found 2 CPUs Obtaining MythTV settings from MySQL database for hostname mythbxb temppath: /storage/mytharchive/temp/work logpath: /storage/mytharchive/temp/logs Setting process priority to 17 Processing Mythburn job number 1. Options - mediatype = 0, doburn = 1, createiso = 0, erasedvdrw = 0 savefilename = '' Looking for: /usr/share/mythtv/mytharchive/themes/G.A.N.T./theme.xml Loading font 0, /usr/share/mythtv/FreeSans.ttf size 18 Loading font 1, /usr/share/mythtv/FreeSans.ttf size 15 Loading font 2, /usr/share/mythtv/FreeSans.ttf size 14 wantIntro: 1, wantMainMenu: 1, wantChapterMenu:1, wantDetailsPage: 1 Final DVD Video format will be ntsc There are 1 files to process Pre-processing recording 1: '/storage/mythtv/recordings/1561_20090808170000.mpg' 2009-08-15 23:30:09.481 Opening /storage/mythtv/recordings/1561_20090808170000.mpg Input #0, mpegts, from '/storage/mythtv/recordings/1561_20090808170000.mpg': Duration: 01:59:55.7, start: 44697.153511, bitrate: 12237 kb/s Stream #0.0[0x31]: Video: mpeg2video, yuv420p, 1920x1080 [PAR 1:1 DAR 16:9], 65000 kb/s, 29.97 tb(r) Stream #0.1[0x34](eng): Audio: ac3, 48000 Hz, stereo, 192 kb/s 2009-08-15 23:30:09.509 duration = 7195 2009-08-15 23:30:09.509 Extracting details from: 1561_20090808170000.mpg 2009-08-15 23:30:09.510 chanid: 1561 starttime:2009-08-08T17:00:00 2009-08-15 23:30:09.514 File is a Myth recording. 2009-08-15 23:30:09.514 cutframes = 0 2009-08-15 23:30:09.514 cutduration = 0 streaminfo.xml :- <?xml version="1.0" ?><!DOCTYPE FILEINFO><file cutduration="7195" duration="7195" filename="/storage/mythtv/recordings/1561_20090808170000.mpg" type="mpegts"> <streams count="2"> <video aspectratio="1.77778" bitrate="65000000" codec="mpeg2video" ffmpegindex="0" fps="29.97" height="1080" id="49" start_time="4022.786568" streamindex="0" width="1920"/> <audio bitrate="192000" channels="2" codec="ac3" ffmpegindex="1" id="52" language="eng" samplerate="48000" start_time="4022.743816" streamindex="1"/> </streams> </file> Superman IV: The Quest for Peace Video resolution is 1920 by 1080 ************************************************************* Processing recording 1: '/storage/mythtv/recordings/1561_20090808170000.mpg' ************************************************************* File type is 'mpegts' Video codec is 'mpeg2video' Running mythtranscode --mpeg2 to fix any errors 2009-08-15 23:30:09.700 Using runtime prefix = /usr 2009-08-15 23:30:09.701 Empty LocalHostName. 2009-08-15 23:30:09.707 New DB connection, total: 1 2009-08-15 23:30:09.711 Closing DB connection named 'DBManager0' 2009-08-15 23:30:09.711 Enabled verbose msgs: important 2009-08-15 23:30:09.725 New DB connection, total: 2 Mux rate: 66.26 Mbit/s ICE default IO error handler doing an exit(), pid = 12962, errno = 32 Failed while running mythtranscode to cut commercials and/or clean up an mpeg2 file. Result: 1, Command was mythtranscode --mpeg2 -c 1561 -s 2009-08-08T17:00:00 -o /storage/mytharchive/temp/work/1/newfile.mpg Failed to run mythtranscode to fix any errors File will be re-encoded using profile LP 2009-08-15 23:43:32.812 Opening /storage/mythtv/recordings/1561_20090808170000.mpg Input #0, mpegts, from '/storage/mythtv/recordings/1561_20090808170000.mpg': Duration: 01:59:55.7, start: 44697.153511, bitrate: 12237 kb/s Stream #0.0[0x31]: Video: mpeg2video, yuv420p, 1920x1080 [PAR 1:1 DAR 16:9], 65000 kb/s, 29.97 tb(r) Stream #0.1[0x34](eng): Audio: ac3, 48000 Hz, stereo, 192 kb/s 2009-08-15 23:43:33.021 duration = 7195 2009-08-15 23:43:33.022 Extracting details from: 1561_20090808170000.mpg 2009-08-15 23:43:33.106 chanid: 1561 starttime:2009-08-08T17:00:00 2009-08-15 23:43:33.232 File is a Myth recording. 2009-08-15 23:43:33.232 cutframes = 0 2009-08-15 23:43:33.232 cutduration = 0 streaminfo.xml :- <?xml version="1.0" ?><!DOCTYPE FILEINFO><file cutduration="7195" duration="7195" filename="/storage/mythtv/recordings/1561_20090808170000.mpg" type="mpegts"> <streams count="2"> <video aspectratio="1.77778" bitrate="65000000" codec="mpeg2video" ffmpegindex="0" fps="29.97" height="1080" id="49" start_time="4022.786568" streamindex="0" width="1920"/> <audio bitrate="192000" channels="2" codec="ac3" ffmpegindex="1" id="52" language="eng" samplerate="48000" start_time="4022.743816" streamindex="1"/> </streams> </file> Preferred audio languages eng and eng Video id: 0x31, Audio1: [1] 0x34 (AC3, eng), Audio2: [-1] - 0x-1 (N/A, N/A) Aspect ratio is 16:9 Re-encoding audio and video Using encoder profiles from /usr/share/mythtv/mytharchive/encoder_profiles/ffmpeg_dvd_ntsc.xml Encoding profile (LP) found ffmpeg -threads 2 -v 1 -i "/storage/mythtv/recordings/1561_20090808170000.mpg" -r ntsc -target dvd -b 2344k -s 352x480 -acodec copy -copyts -aspect 16:9 "/storage/mytharchive/temp/work/1/newfile2.mpg" -map 0:0 -map 0:1 FFmpeg version 0.5-svn17737+3:0.svn20090303-1ubuntu6, Copyright (c) 2000-2009 Fabrice Bellard, et al. configuration: --enable-gpl --enable-postproc --enable-swscale --enable-x11grab --extra-version=svn17737+3:0.svn20090303-1ubuntu6 --prefix=/usr --enable-avfilter --enable-avfilter-lavf --enable-libgsm --enable-libschroedinger --enable-libspeex --enable-libtheora --enable-libvorbis --enable-pthreads --disable-stripping --disable-vhook --enable-libdc1394 --enable-shared --disable-static libavutil 49.15. 0 / 49.15. 0 libavcodec 52.20. 0 / 52.20. 0 libavformat 52.31. 0 / 52.31. 0 libavdevice 52. 1. 0 / 52. 1. 0 libavfilter 0. 4. 0 / 0. 4. 0 libswscale 0. 7. 1 / 0. 7. 1 libpostproc 51. 2. 0 / 51. 2. 0 built on Apr 10 2009 23:20:33, gcc: 4.3.3 Seems stream 0 codec frame rate differs from container frame rate: 59.94 (60000/1001) -> 29.97 (30000/1001) Input #0, mpegts, from '/storage/mythtv/recordings/1561_20090808170000.mpg': Duration: 01:59:55.76, start: 44697.153511, bitrate: 12237 kb/s Program 1 Stream #0.0[0x31]: Video: mpeg2video, yuv420p, 1920x1080 [PAR 1:1 DAR 16:9], 65000 kb/s, 29.97 tbr, 90k tbn, 59.94 tbc Stream #0.1[0x34](eng): Audio: ac3, 48000 Hz, stereo, s16, 192 kb/s Assuming NTSC for target. Unknown encoder 'mpeg2video' ************************************************************ ERROR: Failed while running ffmpeg to re-encode video. Command was ffmpeg -threads 2 -v 1 -i "/storage/mythtv/recordings/1561_20090808170000.mpg" -r ntsc -target dvd -b 2344k -s 352x480 -acodec copy -copyts -aspect 16:9 "/storage/mytharchive/temp/work/1/newfile2.mpg" -map 0:0 -map 0:1 ************************************************************ chmod: changing permissions of `/storage/mytharchive/temp/': Operation not permitted Terminated
looks like a similar problem:
- http://www.mythtvtalk.com/forum/installation-issues/11630-need-help-burning-dvd-mythtv.html
- https://bugs.launchpad.net/medibuntu/+bug/269997
It sounds like there's a problem with the version of ffmpeg I have and it's not just me.
kinda scary to install new libraries like that as I don't know how it will affect mythtv. I think I'll get a working backup first!
mythtranscode
After things didn't go so well with mytharchive, I decided to try things manually. I'm using Mythtranscode directly
$ mythtranscode --help Usage: mythtranscode <--chanid <channelid>> <--starttime <starttime>> <--profile <profile>> [options] --mpeg2 or -m: Perform MPEG2 to MPEG2 transcode. --ostream <type> or -e: Output stream type. Options: dvd, ps. --chanid or -c: Takes a channel id. REQUIRED --starttime or -s: Takes a starttime for the recording. REQUIRED --infile or -i: Input file (Alternative to -c and -s) --outfile or -o: Output file --profile or -p: Takes a profile number or 'autodetect' recording profile. REQUIRED --honorcutlist or -l: Specifies whether to use the cutlist. Optionally takes a cutlist as an argument when used with --infile. --inversecut : Specifies a list of frames to keep while cutting everything else out. Only works with --infile. --allkeys or -k: Specifies that the output file should be made entirely of keyframes. --fifodir or -f: Directory to write fifos to If --fifodir is specified, 'audout' and 'vidout' will be created in the specified directory --fifosync : Enforce fifo sync --buildindex or -b: Build a new keyframe index (use only if audio and video fifos are read independantly) --video : Specifies that this is not a mythtv recording (must be used with --infile) --showprogress : Display status info to the stdout --verbose level or -v: Use '-v help' for level info --help or -h: Prints this help statement. $ mythtranscode -v help Verbose debug levels. Accepts any combination (separated by comma) of: all - ALL available debug output most - Most debug (nodatabase,notimestamp) important - Errors or other very important messages general - General info record - Recording related messages playback - Playback related messages channel - Channel related messages osd - On-Screen Display related messages file - File and AutoExpire related messages schedule - Scheduling related messages network - Network protocol related messages commflag - Commercial Flagging related messages audio - Audio related messages libav - Enables libav debugging jobqueue - JobQueue related messages siparser - Siparser related messages eit - EIT related messages vbi - VBI related messages database - Display all SQL commands executed dsmcc - DSMCC carousel related messages mheg - MHEG debugging messages upnp - upnp debugging messages socket - socket debugging messages xmltv - xmltv output and related messages dvbcam - DVB CAM debugging messages media - Media Manager debugging messages idle - System idle messages timestamp - Conditional data driven messages none - NO debug output The default for this program appears to be: '-v important' Most options are additive except for none, all, and important. These three are semi-exclusive and take precedence over any prior options given. You can however use something like '-v none,jobqueue' to get only JobQueue related messages and override the default verbosity level. The additive options may also be subtracted from 'all' by prefixing them with 'no', so you may use '-v all,nodatabase' to view all but database debug messages. Some debug levels may not apply to this program. $ $ ls -Ftl /storage/mythtv/recordings/*20091107* -rw-rw-rw- 1 mythtv mythtv 66412 2009-11-07 20:27 /storage/mythtv/recordings/1301_20091107200000.mpg.png -rw-rw-rw- 1 mythtv mythtv 79663 2009-11-07 04:30 /storage/mythtv/recordings/1561_20091107040000.mpg.png -rw-r--r-- 1 mythtv mythtv 677596556 2009-11-07 04:30 /storage/mythtv/recordings/1561_20091107040000.mpg -rw-rw-rw- 1 mythtv mythtv 75977 2009-11-07 02:00 /storage/mythtv/recordings/1052_20091107010000.mpg.png -rw-r--r-- 1 mythtv mythtv 1472963080 2009-11-07 02:00 /storage/mythtv/recordings/1052_20091107010000.mpg $ ( mythtranscode --verbose important --chanid 1561 -s 20091107040000 --mpeg2 --honorcutlist --outfile /storage/mythtv/videos/testcode.mpg | tee /storage/mythtv/videos/testcode.log ) & [1] 9184 $ 2009-11-30 23:17:01.266 Using runtime prefix = /usr 2009-11-30 23:17:01.303 Empty LocalHostName. 2009-11-30 23:17:01.417 New DB connection, total: 1 2009-11-30 23:17:01.462 Closing DB connection named 'DBManager0' 2009-11-30 23:17:01.462 Enabled verbose msgs: important 2009-11-30 23:17:01.464 New DB connection, total: 2 Mux rate: 2.94 Mbit/s
looking back at Mythtranscode, it says that I should start by creating a cutlist. So, I followed the cutlist instructions (now at Removing Commercials?) and loaded the commercial flagging., then I entered my Mythtranscode command:
$ ( mythtranscode --verbose important --chanid 1561 -s 20091107040000 --mpeg2 --honorcutlist --outfile /storage/mythtv/videos/testcode.mpg | tee /storage/mythtv/videos/testcode.log ) & [1] 9967 $ 2009-11-30 23:37:49.539 Using runtime prefix = /usr 2009-11-30 23:37:49.540 Empty LocalHostName. 2009-11-30 23:37:49.581 New DB connection, total: 1 2009-11-30 23:37:49.585 Closing DB connection named 'DBManager0' 2009-11-30 23:37:49.586 Enabled verbose msgs: important 2009-11-30 23:37:49.588 New DB connection, total: 2 Mux rate: 2.94 Mbit/s
backup
mythconverg_backup.pl
from Database Backup and Restore
$ cat ~/.mythtv/backuprc DBBackupDirectory=/storage/backups/myth/execute
$ ~/mythconverg_backup.pl --verboseon 4 May 2011, I added to my
/etc/cron.daily
$ cd /etc/cron.daily/ $ ls -Ftl total 72 -rwxr-xr-x 1 root root 266 2011-05-04 22:08 mythconverg_backup_cron.sh* -rwxr-xr-x 1 root root 383 2010-10-05 15:25 samba* -rwxr-xr-x 1 root root 15655 2010-10-05 07:15 apt* -rwxr-xr-x 1 root root 189 2010-10-01 05:17 apport* -rwxr-xr-x 1 root root 633 2010-09-08 05:55 apache2* -rwxr-xr-x 1 root root 256 2010-09-08 02:50 dpkg* -rwxr-xr-x 1 root root 293 2010-09-04 23:01 mythvideo* -rwxr-xr-x 1 root root 3594 2010-08-24 13:45 standard* -rwxr-xr-x 1 root root 1335 2010-08-17 11:49 man-db* -rwxr-xr-x 1 root root 1154 2010-08-06 17:36 ntp* -rwxr-xr-x 1 root root 89 2010-08-05 14:29 logrotate* -rwxr-xr-x 1 root root 311 2010-06-20 01:11 0anacron* -rwxr-xr-x 1 root root 502 2010-05-27 02:28 bsdmainutils* -rwxr-xr-x 1 root root 606 2010-03-24 05:35 mlocate* -rwxr-xr-x 1 root root 2149 2009-06-16 06:12 popularity-contest* $ cat mythconverg_backup_cron.sh ###### optimize_mythdb.sh #!/bin/sh OPT_MYTHDB='/home/xxxx/mythconverg_backup.pl --rotate 20' LOG='/var/log/mythtv/mythconverg_backup.log' echo "Started ${OPT_MYTHDB} on `date`" >> ${LOG} ${OPT_MYTHDB} >> ${LOG} echo "Finished ${OPT_MYTHDB} on `date`" >> ${LOG}
so this should run daily, although there won't be much of a log, it'll do. I added the "rotate 20" because I want there to be plenty of time for me to realize something is wrong before a good database backup is lost
25 May 2011 -- I noticed that it hasn't been running!! I little googling came up with http://www.qc4blog.com/?p=996 "script in /etc/cron.daily/ do not run" which mentioned that the script should not have a dot in the filename.
/etc/cron.daily$ date Wed May 25 20:51:30 PDT 2011 /etc/cron.daily$ sudo mv mythconverg_backup_cron.sh mythconverg_backup_cron [sudo] password for troy:
I also put a copy in /etc/cron.weekly
/etc/cron.weekly$ diff ../cron.daily/mythconverg_backup_cron mythconverg_backup_cron 4c4,5 < OPT_MYTHDB='/home/troy/mythconverg_backup.pl --rotate 20' --- > nametag=`date +%j-%y` > OPT_MYTHDB='/home/troy/mythconverg_backup.pl --filename mythconverg-'$nametag'.sql --rotate -1'
27 May 2011 - maybe they aren't running because of underscores in filenames? let's change it and find out...
/etc/cron.daily$ sudo mv mythconverg_backup_cron mythconverg-backup-cron /etc/cron.weekly$ sudo mv mythconverg_backup_cron mythconverg-backup-cron
1 Jun 2011 - update
$ ls -Ftl /etc/*/mythconver* -rwxr-xr-x 1 root root 361 2011-05-29 01:24 /etc/cron.weekly/mythconverg-backup* -rwxr-xr-x 1 root root 301 2011-05-29 01:23 /etc/cron.daily/mythconverg-backup* $ cat /etc/cron.daily/mythconverg-backup #!/bin/sh ###### optimize_mythdb.sh OPT_MYTHDB='/home/troy/mythconverg_backup.pl --directory /storage/backups/myth/ --rotate 20' LOG='/var/log/mythtv/mythconverg_backup.log' echo "Started ${OPT_MYTHDB} on `date`" >> ${LOG} ${OPT_MYTHDB} >> ${LOG} echo "Finished ${OPT_MYTHDB} on `date`" >> ${LOG} $ diff /etc/cron.daily/mythconverg-backup /etc/cron.weekly/mythconverg-backup 4c4,5 < OPT_MYTHDB='/home/troy/mythconverg_backup.pl --directory /storage/backups/myth/ --rotate 20' --- > nametag=`date +%j-%y` > OPT_MYTHDB='/home/troy/mythconverg_backup.pl --directory /storage/backups/myth/ --filename mythconverg-'$nametag'.sql --rotate -1'
using rsync
mysqldump -u root -p --all-databases --extended-insert > /storage/backups/myth/myth.sql.txt $ sudo mkdir /storage/backups sudo mkdir -p /storage/backups/0 sudo rsync --archive --delete-during \ --hard-links --numeric-ids --exclude /proc --exclude /sys \ --exclude /var/tmp --exclude /tmp --exclude /storage \ --exclude /dev --exclude /lib/init/rw \ --exclude /mnt --exclude /cdrom --exclude /media \ / /storage/backups/0/ $ time sudo rsync --archive --delete-during \ --hard-links --numeric-ids --exclude /proc \ --exclude /sys --exclude /var/tmp --exclude /tmp \ --exclude /storage --exclude /dev --exclude /lib/init/rw \ --exclude /mnt --exclude /cdrom --exclude /media / /storage/backups/0/ real 4m47.620s user 0m26.166s sys 0m35.374s $ sudo du -skh /storage/backups/0/* 7.2M /storage/backups/0/bin 41M /storage/backups/0/boot 960K /storage/backups/0/dev 6.6M /storage/backups/0/etc 218M /storage/backups/0/home 0 /storage/backups/0/initrd.img 0 /storage/backups/0/initrd.img.old 363M /storage/backups/0/lib 11M /storage/backups/0/lib32 0 /storage/backups/0/lib64 0 /storage/backups/0/lost+found 0 /storage/backups/0/opt 72K /storage/backups/0/root 10M /storage/backups/0/sbin 0 /storage/backups/0/selinux 0 /storage/backups/0/srv 1.6G /storage/backups/0/usr 1.7G /storage/backups/0/var 0 /storage/backups/0/vmlinuz 0 /storage/backups/0/vmlinuz.old yes, I have a few large log files from a crash ls -Ftlh /storage/backups/0/var/log/mythtv/ total 1.2G -rw-r--r-- 1 mythtv mythtv 1.7M 2009-08-16 01:18 mythbackend.log -rw-rw-r-- 1 trogod mythtv 805K 2009-08-16 01:18 mythfrontend.log -rw-rw-r-- 1 trogod mythtv 75M 2009-08-10 06:49 mythfrontend.log.1 -rw-r--r-- 1 mythtv mythtv 96M 2009-08-10 06:49 mythbackend.log.1 -rw-r--r-- 1 mythtv mythtv 11M 2009-08-03 06:49 mythbackend.log.2 -rw-r--r-- 1 trogod mythtv 160 2009-07-31 23:27 mtd.log -rw-r--r-- 1 mythtv mythtv 26M 2009-07-26 06:34 mythbackend.log.3 -rw-rw-r-- 1 trogod mythtv 401M 2009-07-14 06:32 mythfrontend.log.2 -rw-r--r-- 1 mythtv mythtv 11M 2009-07-08 06:38 mythbackend.log.4 -rw-rw-r-- 1 trogod mythtv 541M 2009-07-07 06:33 mythfrontend.log.3 -rw-r--r-- 1 mythtv mythtv 15M 2009-07-07 06:33 mythbackend.log.5 -rw-rw-r-- 1 trogod mythtv 13M 2009-07-06 06:48 mythfrontend.log.4 -rw-rw-r-- 1 trogod mythtv 0 2009-06-28 17:16 mythwelcome.log
25 May 2011 -- I added cron entries
/etc/cron.weekly$ cat /etc/cron.daily/rsync-backup #!/bin/sh dest='/storage/backups/daily/' OPT_MYTHDB='nice -19 rsync --archive --delete-during --hard-links --numeric-ids --exclude /proc --exclude /sys --exclude /var/tmp --exclude /tmp --exclude /storage --exclude /dev --exclude /lib/init/rw --exclude /mnt --exclude /cdrom --exclude /media / '$dest LOG='/var/log/mythtv/rsync-backup.log' echo "Started ${OPT_MYTHDB} on `date`" >> ${LOG} 2>&1 ${OPT_MYTHDB} >> ${LOG} 2>&1 echo "Finished ${OPT_MYTHDB} on `date`" >> ${LOG} 2>&1 /etc/cron.weekly$ /etc/cron.weekly$ /etc/cron.weekly$ diff /etc/cron.daily/rsync-backup /etc/cron.weekly/rsync-backup 3c3,11 < dest='/storage/backups/daily/' --- > orig='/storage/backups/weekly/' > dest='/storage/backups/past-weekly/' > OPT_MYTHDB='nice -19 rsync --archive --delete-during --hard-links --numeric-ids '$orig' '$dest > LOG='/var/log/mythtv/rsync-backup.log' > echo "Started ${OPT_MYTHDB} on `date`" >> ${LOG} 2>&1 > ${OPT_MYTHDB} >> ${LOG} 2>&1 > echo "Finished ${OPT_MYTHDB} on `date`" >> ${LOG} 2>&1 > > dest='/storage/backups/weekly/'
something else?
not yet
resize partition
I had to resize the boot partititon. I decided to use gparted
- http://www.dedoimedo.com/computers/gparted.html#mozTocId133810
- http://www.gnu.org/software/parted/manual/parted.html
My problem is the boot partition, I want to make it larger because the built-in system-update software seems to be leaving behind a lot of large files.
Here's the version I have
$ mythbackend --version Please include all output in bug reports. MythTV Version : 19961 MythTV Branch : branches/release-0-21-fixes Library API : 0.21.20080304-1 Network Protocol : 40 Options compiled in: linux profile using_oss using_alsa using_jack using_backend using_dbox2 using_dvb using_firewire using_frontend using_hdhomerun using_iptv using_ivtv using_joystick_menu using_libfftw3 using_lirc using_opengl_vsync using_opengl_video using_v4l using_x11 using_xrandr using_xv using_xvmc using_xvmcw using_xvmc_vld using_glx_proc_addr_arb using_bindings_perl using_bindings_python using_opengl using_ffmpeg_threads using_libavc_5_3 using_live $ uname -a Linux xxxxx 2.6.28-17-generic #58-Ubuntu SMP Tue Dec 1 21:27:25 UTC 2009 x86_64 GNU/Linux
and here's my disk info:
$ df -h Filesystem Size Used Avail Use% Mounted on /dev/sdb3 15G 5.5G 8.6G 39% / tmpfs 868M 0 868M 0% /lib/init/rw varrun 868M 356K 867M 1% /var/run varlock 868M 0 868M 0% /var/lock udev 868M 156K 868M 1% /dev tmpfs 868M 0 868M 0% /dev/shm lrm 868M 2.5M 865M 1% /lib/modules/2.6.28-17-generic/volatile /dev/sdb1 89M 53M 32M 63% /boot /dev/sdb4 20G 489M 19G 3% /home /dev/sda1 932G 839G 93G 91% /storage
so, you can see that my /boot paritition is small. I'm thinking of enlarging it quite a bit. Hmmm, according to http://art.ubuntuforums.org/showthread.php?t=1632250 I could have a problem if my swap partition is right 'behind' my boot partition? will I have this problem?
$ sudo fdisk -l WARNING: GPT (GUID Partition Table) detected on '/dev/sda'! The util fdisk doesn't support GPT. Use GNU Parted. Disk /dev/sda: 1000.2 GB, 1000204886016 bytes 255 heads, 63 sectors/track, 121601 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Disk identifier: 0x00000000 Device Boot Start End Blocks Id System /dev/sda1 1 121602 976762583+ ee GPT Disk /dev/sdb: 80.0 GB, 80060424192 bytes 255 heads, 63 sectors/track, 9733 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Disk identifier: 0x000830e8 Device Boot Start End Blocks Id System /dev/sdb1 * 1 12 96358+ 83 Linux /dev/sdb2 13 1257 10000462+ 82 Linux swap / Solaris /dev/sdb3 1258 3216 15735667+ 83 Linux /dev/sdb4 3217 5827 20972857+ 83 Linux $ sudo parted -l Model: ATA Hitachi HDT72101 (scsi) Disk /dev/sda: 1000GB Sector size (logical/physical): 512B/512B Partition Table: gpt Number Start End Size File system Name Flags 1 17.4kB 1000GB 1000GB jfs Model: ATA SAMSUNG SP0822N (scsi) Disk /dev/sdb: 80.1GB Sector size (logical/physical): 512B/512B Partition Table: msdos Number Start End Size Type File system Flags 1 32.3kB 98.7MB 98.7MB primary ext2 boot 2 98.7MB 10.3GB 10.2GB primary linux-swap 3 10.3GB 26.5GB 16.1GB primary ext3 4 26.5GB 47.9GB 21.5GB primary ext3
I made a backup before I booted into the gparted live CD
$ sudo mkdir /storage/backups/2 $ time sudo rsync --archive --delete-during \ > --hard-links --numeric-ids --exclude /proc \ > --exclude /sys --exclude /var/tmp --exclude /tmp \ > --exclude /storage --exclude /dev --exclude /lib/init/rw \ > --exclude /mnt --exclude /cdrom --exclude /media / /storage/backups/2/ real 8m15.161s user 0m45.683s sys 1m1.908s
I think I did it! and I think it worked! Here's my new partition info:
$sudo fdisk -l WARNING: GPT (GUID Partition Table) detected on '/dev/sda'! The util fdisk doesn't support GPT. Use GNU Parted. Disk /dev/sda: 1000.2 GB, 1000204886016 bytes 255 heads, 63 sectors/track, 121601 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Disk identifier: 0x00000000 Device Boot Start End Blocks Id System /dev/sda1 1 121602 976762583+ ee GPT Disk /dev/sdb: 80.0 GB, 80060424192 bytes 255 heads, 63 sectors/track, 9733 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Disk identifier: 0x000830e8 Device Boot Start End Blocks Id System /dev/sdb1 * 1 157 1256416+ 83 Linux Partition 1 does not end on cylinder boundary. /dev/sdb2 157 1257 8840192 82 Linux swap / Solaris /dev/sdb3 1258 3216 15735667+ 83 Linux /dev/sdb4 3217 5827 20972857+ 83 Linux $sudo parted -l Model: ATA Hitachi HDT72101 (scsi) Disk /dev/sda: 1000GB Sector size (logical/physical): 512B/512B Partition Table: gpt Number Start End Size File system Name Flags 1 17.4kB 1000GB 1000GB jfs Model: ATA SAMSUNG SP0822N (scsi) Disk /dev/sdb: 80.1GB Sector size (logical/physical): 512B/512B Partition Table: msdos Number Start End Size Type File system Flags 1 32.3kB 1287MB 1287MB primary ext2 boot 2 1287MB 10.3GB 9052MB primary linux-swap 3 10.3GB 26.5GB 16.1GB primary ext3 4 26.5GB 47.9GB 21.5GB primary ext3
My system still boots normally and MythTV runs normally. I don't seem to notice any difference. Great!! Next, I'll be upgrading my Mythbuntu installation...
Upgrade Mythbuntu
I believe I want the 64-bit version
curl -O http://osuosl.cdimages.mythbuntu.org/mythbuntu-10.10-desktop-amd64.iso
FIXME add info about installation from CD-ROM
mount hard drive
since, during installation, I had disconnected my hard drive (1 TB) that contained all my recordings, now I have to add the mounting info manually. I found these instructions: https://help.ubuntu.com/community/InstallingANewHardDrive which I was happy to have as they are geared to ubuntu. Here's what I did
$ sudo lshw -C disk [sudo] password for xxxx: *-disk description: ATA Disk product: Hitachi HDT72101 vendor: Hitachi physical id: 0.0.0 bus info: scsi@0:0.0.0 logical name: /dev/sdb version: ST6O serial: STF604MR28XYLP size: 931GiB (1TB) capabilities: gpt-1.00 partitioned partitioned:gpt configuration: ansiversion=5 guid=54c30723-c1d2-4b74-9770-b060636c91d6 *-cdrom description: DVD-RAM writer product: DVD RW AD-7200A vendor: Optiarc physical id: 0.0.0 bus info: scsi@1:0.0.0 logical name: /dev/cdrom logical name: /dev/cdrw logical name: /dev/dvd logical name: /dev/dvdrw logical name: /dev/scd0 logical name: /dev/sr0 version: 1.09 capabilities: removable audio cd-r cd-rw dvd dvd-r dvd-ram configuration: ansiversion=5 status=nodisc *-disk description: ATA Disk product: SAMSUNG SP0822N physical id: 0.1.0 bus info: scsi@1:0.1.0 logical name: /dev/sda version: WA10 serial: S06QJ10L223809 size: 74GiB (80GB) capabilities: partitioned partitioned:dos configuration: ansiversion=5 signature=000830e8
so, yes, my hard drive shows up (the Hitachi)
$ sudo mkdir /storage
I had named it "/storage" before, so I'm sticking with that...
the instructions were to add this line to /etc/fstab
/dev/sdb1 /media/mynewdrive ext3 defaults 0 2
according to 'man fstab', the "0" is a message to 'dump' that this disk should _not_ be dumped and the "2" is a message to 'fsck' that this is not a boot drive
$ cp -pr /etc/fstab fstab-backup $ ls -Ftl /etc/fstab -rw-r--r-- 1 root root 955 2011-03-26 22:04 /etc/fstab $ sudo vi /etc/fstab $ diff fstab-backup /etc/fstab 16a17,19 > # manually added 26 Mar 2011 by TDG > /dev/sdb1 /storage jfs defaults 0 2 > $ sudo mount -a $ ls /storage/ backups mytharchive mythdvd mythtv
yes!
Oh... I just found this (http://ubuntuforums.org/showthread.php?t=1347704)
$ sudo blkid [sudo] password for xxxx: /dev/sda1: UUID="d5b9a6b5-8be1-4e62-bcdb-e30525ed6c7f" TYPE="ext2" /dev/sda2: UUID="25f8fb9e-d2f9-4297-a7ec-7dbff4729eb0" TYPE="swap" /dev/sda3: UUID="92a77430-e47f-4023-85db-c4547dc12515" TYPE="ext3" /dev/sda4: UUID="4c6658bb-2044-4733-aff2-1adf511f834d" TYPE="ext3" /dev/sdb1: UUID="a54e92bb-d3dd-4a7e-aca5-f0b70e930d40" TYPE="jfs"
restore old database
OK, next I want to do Database_Backup_and_Restore#Database_Restore First, I copied my old "backuprc" file
$ cp -pr /storage/backups/4/home/tdg/.mythtv/backuprc ~/.mythtv/. $ ls -a ~/.mythtv/ . .. backuprc config.xml mysql.txt themecache
I downloaded the latest mythconverg_restore.pl script and did
$ ./mythconverg_restore.pl --drop_database --create_database --filename mythconverg-1214-20110326203137.sql.gz
Successfully restored backup.
looks good!
change hostname
also, I must've mistyped my desired hostname, so I changed in manually (I have a bad feeling about this.
$ sudo vi /etc/hostname
permissions
I had problems deleting episodes
$ less /var/log/mythtv/mythbackend.log [SNIP] 2011-03-27 14:14:10.412 Error deleting '/storage/mythtv/recordings/1284_20110326190000.mpg' could not open eno: Permission denied (13)
discovered that I had some permissions issues. Here's a sample of the directory listing:
drwxrwxrwx 2 avahi-autoipd messagebus 24576 2011-03-27 20:12 livetv/ drwxrwxrwx 2 avahi-autoipd messagebus 163840 2011-03-27 20:12 recordings/ drwxrwxrwx 14 avahi-autoipd messagebus 16384 2011-03-03 22:34 videos/ drwxrwxrwx 10 avahi-autoipd messagebus 4096 2010-11-20 09:24 pictures/ drwxrwxrwx 2 avahi-autoipd messagebus 56 2010-01-17 14:05 music/
So, I executed these commands:
$ sudo chown -R mythtv:mythtv livetv/ recordings/ videos/ pictures/ music/ posters/ $ sudo chmod g+rw livetv/ recordings/ videos/ pictures/ music/ posters/
see also http://www.gossamer-threads.com/lists/mythtv/users/449966 'Permission problems'
changes to samba
/storage is the mount point for my drive (1 TB) where I want to keep recordings. I had disconnected it during installation of mythbuntu so that it wouldn't get erased.
$ cd /etc/samba $ sudo cp -pr smb.conf smb.conf.bak1 $ cat /etc/samba/smb.conf | sed -e 's/\/var\/lib/\/storage/g' > ~/smb2 $ sudo cp /home/xxxx/smb2 . $ sudo mv smb2 smb.conf $ diff smb.conf smb.conf.bak1 13c13 < path = /storage/mythtv/recordings --- > path = /var/lib/mythtv/recordings 23c23 < path = /storage/mythtv/videos --- > path = /var/lib/mythtv/videos 33c33 < path = /storage/mythtv/music --- > path = /var/lib/mythtv/music 43c43 < path = /storage/mythtv/pictures --- > path = /var/lib/mythtv/pictures
jamu.log
less -S /var/log/syslog
Apr 6 20:17:02 myth-bob CRON[8149]: (root) CMD ( cd / && run-parts --report /etc/cron.hourly) Apr 6 20:17:06 myth-bob CRON[8148]: (CRON) error (grandchild #8149 failed with exit status 1)
head -n 1000 /etc/cron.hourly/*
su mythtv -c "/usr/bin/python /usr/share/mythtv/mythvideo/scripts/jamu.py -MW >> '/var/log/mythtv/jamu.log' 2>&1"
less -S /var/log/mythtv/jamu.log
! Warning: MythTV (episodeimagedir) directory (/home/aa/.mythtv/MythVideo/Screenshots) does not exist. ! Warning: MythTV (fanartdir) directory (/home/aa/.mythtv/MythVideo/Fanart) does not exist. ! Warning: MythTV (bannerdir) directory (/home/aa/.mythtv/MythVideo/Banners) does not exist.
later...
! Error: The (fanartdir) directory (/home/aa/.mythtv/MythVideo/Fanart) must be read/writable for Jamu to function. ! Error: The (bannerdir) directory (/home/aa/.mythtv/MythVideo/Banners) must be read/writable for Jamu to function.
$ chmod a+rwx /home/aa/.mythtv/MythVideo/* $ ls -Ftl /home/aa/.mythtv/MythVideo/ total 12 drwxrwxrwx 2 4096 2011-04-06 21:06 Banners/ drwxrwxrwx 2 4096 2011-04-06 21:06 Fanart/ drwxrwxrwx 2 4096 2011-04-06 21:06 Screenshots/
lircd
I want my remote working, again! When I installed the new mythbuntu, there wasn't an option for HDHomeRun to setup a remote control. I had to do things myself.
$ sudo apt-get install lirc Reading package lists... Done Building dependency tree Reading state information... Done Suggested packages: lirc-modules-source lirc-x The following NEW packages will be installed: lirc 0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded. Need to get 657kB of archives. After this operation, 2,769kB of additional disk space will be used. Get:1 http://us.archive.ubuntu.com/ubuntu/ maverick/main lirc amd64 0.8.7~pre3-0ubuntu1 [657kB] Fetched 657kB in 5s (127kB/s) Preconfiguring packages ... Selecting previously deselected package lirc. (Reading database ... 122738 files and directories currently installed.) Unpacking lirc (from .../lirc_0.8.7~pre3-0ubuntu1_amd64.deb) ... Processing triggers for man-db ... Processing triggers for hal ... Regenerating hal fdi cache ... Processing triggers for ureadahead ... ureadahead will be reprofiled on next reboot Setting up lirc (0.8.7~pre3-0ubuntu1) ...
I copied .lirc/, .lircrc from my backup and made the symlink .mythtv/lircrc -> ../.lircrc
$ cat .lircrc #Custom lircrc generated via mythbuntu-lirc-generator #All application specific lircrc files are within ~/.lirc include ~/.lirc/mythtv include ~/.lirc/mplayer include ~/.lirc/xine include ~/.lirc/vlc include ~/.lirc/xmame include ~/.lirc/xmess include ~/.lirc/totem include ~/.lirc/elisa
I looked at /etc/init.d/lirc and /usr/share/doc/lirc/README.Debian and file:///usr/share/doc/lirc/html/configure.html to figure out that I needed to edit /etc/lirc/hardware.conf See also Silicondust HDHomeRun
$ diff --unified=3 /etc/lirc/hardware.conf-old /etc/lirc/hardware.conf --- /etc/lirc/hardware.conf-old 2011-03-28 06:39:38.000000000 -0700 +++ /etc/lirc/hardware.conf 2011-04-06 21:45:13.000000000 -0700 @@ -7,7 +7,8 @@ REMOTE_DEVICE="" REMOTE_SOCKET="" REMOTE_LIRCD_CONF="" -REMOTE_LIRCD_ARGS="" +REMOTE_LIRCD_ARGS="-r -H udp -d 5000" +# the -r is from http://www.mythtv.org/wiki/Hulu_Desktop_Integration #Chosen IR Transmitter TRANSMITTER="None" @@ -19,7 +20,7 @@ TRANSMITTER_LIRCD_ARGS="" #Enable lircd -START_LIRCD="false" +START_LIRCD="true" #Don't start lircmd even if there seems to be a good config file #START_LIRCMD="false"
To check that things were working, I
- ran sudo /etc/init.d/lirc start
- ran irw
I got this output
% sudo /etc/init.d/lirc start * Loading LIRC modules [ OK ] * Starting remote control daemon(s) : LIRC [ OK ]
now my remote is working correctly with the front end!! :)
I think I want irexec to run
$ less /etc/lirc/lircrc /etc/lirc/lircrc: No such file or directory $ sudo touch /etc/lirc/lircrc $ !603 sudo /etc/init.d/lirc start * Loading LIRC modules [ OK ] * Starting remote control daemon(s) : LIRC [ OK ] * Starting execution daemon: irexec [ OK ]
added irexec to my startup as per https://help.ubuntu.com/community/LIRC#irexec and Setting_A_Button_On_Your_Remote_To_Restart_mythfrontend
new hard drive
I'm worried that my current drive (1 TB) for /storage is going bad, so I want to replace it with a new drive (2 TB). My case doesn't have room for both, so I want to prepare the new drive while it is in an external hard drive enclosure. I am trying to connect to it via USB...
$ sudo parted -l Model: ATA SAMSUNG SP0822N (scsi) Disk /dev/sda: 80.1GB Sector size (logical/physical): 512B/512B Partition Table: msdos Number Start End Size Type File system Flags 1 32.3kB 1287MB 1287MB primary ext2 boot 2 1287MB 10.3GB 9052MB primary linux-swap(v1) 3 10.3GB 26.5GB 16.1GB primary ext3 4 26.5GB 47.9GB 21.5GB primary ext3 Model: ATA Hitachi HDT72101 (scsi) Disk /dev/sdb: 1000GB Sector size (logical/physical): 512B/512B Partition Table: gpt Number Start End Size File system Name Flags 1 17.4kB 1000GB 1000GB jfs Error: /dev/sdc: unrecognised disk label
I installed gparted
$ sudo apt-get install gparted Reading package lists... Done Building dependency tree Reading state information... Done The following extra packages will be installed: libcairomm-1.0-1 libglibmm-2.4-1c2a libgtkmm-2.4-1c2a libpangomm-1.4-1 libsigc++-2.0-0c2a Suggested packages: xfsprogs reiserfsprogs reiser4progs jfsutils yelp kpartx dmraid The following NEW packages will be installed: gparted libcairomm-1.0-1 libglibmm-2.4-1c2a libgtkmm-2.4-1c2a libpangomm-1.4-1 libsigc++-2.0-0c2a 0 upgraded, 6 newly installed, 0 to remove and 13 not upgraded. Need to get 2,186kB of archives. After this operation, 8,798kB of additional disk space will be used. Do you want to continue [Y/n]? y Get:1 http://us.archive.ubuntu.com/ubuntu/ maverick/main libsigc++-2.0-0c2a amd64 2.2.4.2-1 [39.2kB] Get:2 http://us.archive.ubuntu.com/ubuntu/ maverick/main libglibmm-2.4-1c2a amd64 2.25.5-0ubuntu1 [380kB] Get:3 http://us.archive.ubuntu.com/ubuntu/ maverick/main libcairomm-1.0-1 amd64 1.8.4-3 [48.6kB] Get:4 http://us.archive.ubuntu.com/ubuntu/ maverick/main libpangomm-1.4-1 amd64 2.26.2-1 [58.7kB] Get:5 http://us.archive.ubuntu.com/ubuntu/ maverick/main libgtkmm-2.4-1c2a amd64 1:2.20.3-1 [1,190kB] Get:6 http://us.archive.ubuntu.com/ubuntu/ maverick-updates/main gparted amd64 0.6.2-1ubuntu1.1 [470kB] Fetched 2,186kB in 35s (61.0kB/s) Selecting previously deselected package libsigc++-2.0-0c2a. (Reading database ... 123022 files and directories currently installed.) Unpacking libsigc++-2.0-0c2a (from .../libsigc++-2.0-0c2a_2.2.4.2-1_amd64.deb) ... Selecting previously deselected package libglibmm-2.4-1c2a. Unpacking libglibmm-2.4-1c2a (from .../libglibmm-2.4-1c2a_2.25.5-0ubuntu1_amd64.deb) ... Selecting previously deselected package libcairomm-1.0-1. Unpacking libcairomm-1.0-1 (from .../libcairomm-1.0-1_1.8.4-3_amd64.deb) ... Selecting previously deselected package libpangomm-1.4-1. Unpacking libpangomm-1.4-1 (from .../libpangomm-1.4-1_2.26.2-1_amd64.deb) ... Selecting previously deselected package libgtkmm-2.4-1c2a. Unpacking libgtkmm-2.4-1c2a (from .../libgtkmm-2.4-1c2a_1%3a2.20.3-1_amd64.deb) ... Selecting previously deselected package gparted. Unpacking gparted (from .../gparted_0.6.2-1ubuntu1.1_amd64.deb) ... Processing triggers for man-db ... Processing triggers for desktop-file-utils ... Processing triggers for hicolor-icon-theme ... Setting up libsigc++-2.0-0c2a (2.2.4.2-1) ... Setting up libglibmm-2.4-1c2a (2.25.5-0ubuntu1) ... Setting up libcairomm-1.0-1 (1.8.4-3) ... Setting up libpangomm-1.4-1 (2.26.2-1) ... Setting up libgtkmm-2.4-1c2a (1:2.20.3-1) ... Setting up gparted (0.6.2-1ubuntu1.1) ... Processing triggers for libc-bin ... ldconfig deferred processing now taking place
then
$ sudo gparted
gparted shows me /dev/sdc is 1.82 TiB -- that's it!! I chose /dev/sdc from GParted > Devices, then I chose Partition > New
No partition table found on device /dev/sdc A partition table is required before partitions can be added. To create a new partition table choose the menu item: Device --> Create Partition Table. [OK]
I did so
WARNING: This will ERASE ALL DATA on the ENTIRE DISK /dev/sdc Default is to create an MS-DOS partition table. > Advanced [Cancel] [Apply]
so i did [Apply]
gparted shows the 1.82 TiB as "unallocated". I again chose Partition > New
Minimum size: 1 MiB Maximum size: 1907728 MiB Free space preceding MiB: 1 Create as: Primary Partition New size (MiB): 1907728 File system: ext2 Free space following (MiB): 0 Label: Align to: MiB [Cancel] [Add]
Hmmm, I better revisit some GParted documentation before I go further...
oh my /storage uses gpt partition table, not msdos, let's do that again:
WARNING: This will ERASE ALL DATA on the ENTIRE DISK /dev/sdc Default is to create an MS-DOS partition table. > Advanced Select new partition table type: gpt [Cancel] [Apply]
I again chose Partition > New
Minimum size: 1 MiB Maximum size: 1907728 MiB Free space preceding MiB: 1 Create as: Primary Partition New size (MiB): 1907728 File system: ext2 Free space following (MiB): 0 Label: Align to: MiB [Cancel] [Add]
still couldn't choose jfs. Based on http://forums.whirlpool.net.au/archive/916089 I think I have to boot from my live cd for gparted-live-cd-0.8.0-1
OK, I downloaded gparted-live-cd-0.8.0-5, burned it to CD, booted from it and formatted the new drive as JFS. The drive was connected via USB when I did that See System 0 Maintenance
While the machine was shut down, I switched from USB to eSATA and booted up. Because of the maintenance, I had to deal with that menu (forgot what it's called) but it's something about boot recovery or some such :(
Anyway, the eSATA interface seems to work....
$ sudo parted -l [sudo] password for xxxx: Model: ATA SAMSUNG SP0822N (scsi) Disk /dev/sda: 80.1GB Sector size (logical/physical): 512B/512B Partition Table: msdos Number Start End Size Type File system Flags 1 32.3kB 1287MB 1287MB primary ext2 boot 2 1287MB 10.3GB 9052MB primary linux-swap(v1) 3 10.3GB 26.5GB 16.1GB primary ext3 4 26.5GB 47.9GB 21.5GB primary ext3 Model: ATA Hitachi HDT72101 (scsi) Disk /dev/sdb: 1000GB Sector size (logical/physical): 512B/512B Partition Table: gpt Number Start End Size File system Name Flags 1 17.4kB 1000GB 1000GB jfs Model: ATA SAMSUNG HD204UI (scsi) Disk /dev/sdc: 2000GB Sector size (logical/physical): 512B/512B Partition Table: gpt Number Start End Size File system Name Flags 1 1049kB 2000GB 2000GB jfs
Next, mount the drive... ref http://www.jarrodgoddard.com/linux-web-hosting/mounting-an-external-usb-drive-in-linux
$ sudo mkdir /newstore $ sudo mount /dev/sdc1 /newstore $ ls /newstore/ $ df -h Filesystem Size Used Avail Use% Mounted on /dev/sda3 15G 2.9G 12G 20% / none 871M 260K 870M 1% /dev none 877M 0 877M 0% /dev/shm none 877M 348K 877M 1% /var/run none 877M 0 877M 0% /var/lock /dev/sda1 1.2G 38M 1.1G 4% /boot /dev/sdb1 932G 918G 14G 99% /storage /dev/sda4 20G 628M 19G 4% /home /dev/sdc1 1.9T 234M 1.9T 1% /newstore $
next is the rsync command...
$ sudo rsync -av /storage/ /newstore [sudo] password for xxxxx:
while that's going on... Seems like this will be helpful to have...
$ sudo ls -aFlR /storage/ > ls-storage-original.txt