| The Colonel is dead, long live The Colonel
|
30.06.09
|
My home studio is now fully functional... finally. I couldn't install Hardy from the live disk because the keyboard didn't work, midi didn't work in my Intrepid realtime kernel and the Jaunty realtime kernel was über crashy -- hanging every twenty minutes or so and requiring a hard restart. Instead of waiting for the karmic release, I decided to go for broke and compile my own custom kernel, which wasn't nearly as daunting as it sounds.
First, I downloaded the 2.6.29-5 kernel image and headers from here and the matching realtime patch for the kernel here into /usr/src/ as root (type sudo su into a terminal). I changed directories into /usr/src and extracted the kernel archive with the command "tar xjvf linux-2.6.29.5.tar.bz2", created a symbolic link called linux with the command "ln -s linux-2.6.29.5 linux" and changed directories into /usr/src/linux/. Then I patched the kernel with the command "bzip2 -dc /usr/src/patch-2.6.29.5-rt22.bz2 | patch -p1". Then I cleaned up the build directory, copied my old config file into the kernel root directory with "make clean && cp /boot/config-'uname-r' ./.config" and opened the config dialogue with "make menuconfig". The only things I configured for the kernel were: - Changed to full preemption in general setup
- Changed timing to 1000
- Disabled the Xen/paravirtualization stuff in Processor type and features (I found the kernel wouldn't compile otherwise)
Then I compiled with the command "CONCURRENCY_LEVEL=3 fakeroot make-kpkg --initrd --append-to-version=-custom1 kernel_image kernel_headers" because my system is dual core. After compilation was finished, I changed directory to /usr/src and installed the resulting debs with "dpkg -i linux-headers-2.6.29.5-rt22-custom2_2.6.29.5-rt22-custom2-10.00.Custom_amd64.deb" then "dpkg -i linux-image-2.6.29.5-rt22-custom2_2.6.29.5-rt22-custom2-10.00.Custom_amd64.deb". I was then able to reboot flawlessly into my new kernel... but wait! There was no fucking sound!
Since I had to kill pulseaudio to get sound to work before I had compiled the new kernel, I figured that was the culprit. I was able to make pulse functional (apps wouldn't freeze when there was a sound event) using this thread, but I still couldn't hear anything. Now this is where the magic happened: I updated to Jaunty from Intrepid and voila! Everything worked! I don't know what the problem was with the kernel before, but it's hummin' now. Zero xruns, jack, midi, no crashes (fingers crossed) and my sound works fine. So the moral of the story is -- if you're not afraid to get your hands dirty and potentially upgrade or completely reinstall ubuntu, then compiling your own kernel isn't really as bad as it sounds. Here are the sites I used to figure all this crap out:
Use the sources if you won't take my word for it, but don't blame me if you mess up your system. Good luck!
|
| |
| Ubuntu-Studio Midi and “The Colonel”
|
24.06.09
|
I took a few major steps in building my home studio with linux as the OS – and I’ve run into a couple major hurdles. I found the installation of my new M-Audio Delta 66 soundcard to be relatively painless. I did research first to ensure it would work and it worked pretty much out of the box. The Omnibox that I bought with it worked pretty well too. Ubuntu Studio has drivers installed by default and a mixer that works really well to route the signals. It took me a little while to figure out that I had the wrong volume sliders turned all the way down but after that it worked really well. I was able to use Ardour to route the signal from my guitar or mic out to an external effects box, sample audio from movies, manipulate recorded .wav files using Rezound etc.
My heartache came when I tried using my new keyboard as a midi trigger. It worked fine in Windows but no matter what I did, I couldn’t get a signal to register in any of the three softsynths I tried (Qsynth, Zynaddsubfx, or Alsa Modular Synth) or the two diagnostic programs I tried (aseqdump or kmidimon). I finally realized that my problem wasn’t the hardware, jack or the midi interface – it was the kernel. I knew the Intrepid kernel was buggy, but I hadn’t had any significant problems until now, except for the system hanging every time I tried to power down (which wasn’t that much of a problem because I rarely power down). This is a major problem. I want to use my keyboard to trigger softsynths but when I boot into the generic kernel I get an xrun every few second. I am loathe to reinstall Hardy since I just downgraded to Intrepid from a terrible Jaunty experience. I guess all I can do is hope that they fix the real time kernel in Karmic Koala. Or… use Windows?
|
| |
| Kinetic Aftermath
|
21.05.09
|
KC and I have returned (recovered) from our four day foray to Montreal for the Kinetic Music Festival. We didn't get in until late Thu so we missed the first night and by many accounts the best act of the festival: Memmaker. Friday was spent on a terrace in Old Montreal before hitting the club earlier than I've ever been to a club (6pm) to seen DYM, a Toronto band that I was really looking forward to. They were fairly mediocre live. The highlight of the Fri night were Aesthetic Perfection, God Module and when Grendel's computer crashed TWICE during their set. Grendel's performance made me realize that if I'm creating music, I want to create music that I can actually play live instead of pretending, like Ashlee Simpson.
We were at the bar for eight full hours on Fri night, so Sat was mostly spent sleeping, helped by the fact there was a torrential downpour for most of the day. We went to a pretty good Sushi restaurant on Sat night, Jun-i. We didn't spend much of Sat night at the festival, since it was all Noise, which is actually a subgenre of a subgenre and one we don't really care for. The one band we did catch all of, Noisex, I actually did like. The rest of Saturday night was spent at a really shady bar down the street from the main venue until the bitter, bitter end of the night.
Sunday was cold. We went to brunch at a restaurant called Le Pois Penché, which was a pretty mediocre meal with good ambiance. Sunday night we spent most of the night at the club again, fuelled on Red Bull at this point. The biggest surprise of the night was Das Ich, a band that I never really cared for musically, but that were the most entertaining of the entire weekend. It was good to hear Icon of Coil play live again, but it's fairly obvious that Andy LaPlegua isn't into the music anymore and that he'd probably rather be doing something else.
Monday morning was really... really painful. After three eight-hour booze fests and no sleep getting up for a 9:00 flight was excruciating. It really was a great festival. Although they ran out of beer, the music was excellent, the sound was great and Montreal is a really great city. We're going back next year.
|
| |
| TDK Holdings in Edmonton
|
08.05.09
|
Allow me to rant. I needed to rent an apartment in Edmonton recently and found some really nice places advertised by TDK Holdings. TDK Holdings acts as a liaison between condo owners and potential tenants. I'd say they're a property management company but that would be far too generous, because from my experience of their amateurish approach, they have no idea what "manage" actually means.
Problem number one: With a package that was supposed to include all of my utilities, my cable didn't work. I called TDK Holdings a number of times and eventually talked to the "cable expert" who stumbled through some troubleshooting that turned out to be not at all helpful. Eventually after taking it upon myself to solve the problem I determined that they hadn't paid the cable bill.
Problem number 2: We lost hot water once every month or two. And not for a half an hour. For most of the day.
Problem number 3. When our dog was making too much noise, the TDK Holdings "property manager" called my wife, who didn't actually live in Edmonton, called my work but did not call me, the tenant and owner of the dog, in order to resolve the problem. This kind of catty, duplicitous way of dealing with a problem grinds my gears.
Problem number 4. The "property manager" called by work and basically called me a deadbeat for not paying the rent instead of doing the job of a property manager and collecting the rent. I actually called them when I realized they hadn't collected the rent that month, told them that I would leave a cheque in the apartment, which apparently whomever I spoke to completely forgot. Two weeks later the TDK Holdings "property manager" instead of calling me, which is what any normal person would do, called my work to complain. Again.
Problem number 5.The final straw was when we agreed they'd send me a receipt for any cleaning fees after I moved out. The TDK Holdings property manager made the agreement and then told me the landlord "changed her mind" and now, no receipt. Very unprofessional.
I'm a landowner. I've got a really professional property management company in Toronto. TDK Holdings is NOT a professional management company. Knowing what I know now, if I were a landlord or a tenant in Edmonton considering dealing with them, I'd think again.
|
| |
| Finally finished updating
|
27.04.09
|
I finally fixed Mediatomb. I turns out that the config.xml file is incomplete. It says that you need to uncomment the "redsonic.com" line, but in reality you not only need to uncomment it, you need to change "redsonic" to "http://www.redsonic.com". After that, my DSM-750 behaved totally differently... and mostly in good ways. Subtitles were enabled, the sync issues I had with .avi files were gone, I could play .flac files and I was able to play .mkv files without transcoding after a bit of fuckery (although I honestly don't know what I did -- waiting/maybe restarting the DSM-750?). The only problem I had was that somehow that line affects how the DSM-750 reads my sql database and Video and Playlists are no longer listed. I need to browse the "PC directory" to play videos.
I also finally took the time to fix some of the problems I was having with compiz and my realtime kernel, which were surprising all solved by updating to ubuntu jaunty jackalope. For some reason compiz wouldn't run properly on my realtime kernel which I use for programming music. I'd also randomly crash Xorg when I clicked on the right Desktop of my two monitor setup and I had a memory leak somewhere since my RAM kept creeping and creeping. I (hesitantly) updated to Jaunty yesterday. Most of my updates on ubuntu have required a lot of work to reconfigure/jerry rig the monitor setup, grub bootloader etc that's it's a big pain in the ass. But I have to say the update to jaunty was the easiest yet. The update itself took a couple of hours, but all I had to do was edit menu.lst in grub, and use "Display" in preferences to configure my monitors instead of configuring Xorg directly last time which took hours instead of minutes and ended up being fairly unstable.
I'd also like to take this opportunity to announce the Ludditology Network: www.ludditology.org . I'm now running an irc server now in addition to the ftp, webcam and pictures script. Drop by to channel #cybermod at irc.ludditology.org.
|
| |
| D-link DSM-750 and mediatomb
|
05.04.09
|
I think I'm finally finished setting up my wireless home network. I've got the Desktop, laptop and a wireless media server. The Desktop is an ssh, ftp and upnp server and has redundant 1 tera external hds that are backed-up weekly using rsync and cron. I've got the ftp server mostly for remote access using windows -- for example when I want to get a file from my computer at home and I'm at a friend's place. The primary hd is shared on the LAN via samba so that I've got access to the full tera of storage space from my crappy 60 gig laptop.
I bought a D-Link DSM-750 wireless media server and so far I'm fairly pleased at how it has worked out. I'm using Mediatomb as the upnp server, which took a little tweaking so that I could transcode Matroska (.mkv) files using ffmpeg on the fly (although the literature says they're supposed to be supported). Take a look at my Mediatomb config file here. I also tweaked the import script so that the Video and picture files are organized similar to the directories in which they're stored. My import.js script is here. My main problems so far have been the occasional and temporary loss of connection from the router and some sync issues when I play .avi files.
The final element I finished this week is to set my webcams to email a photo to my blackberry whenever there's movement in the house while we're gone using an app called Motion. Motion also acts a a webserver for the cams so that if my work firewall wasn't so restrictive, I could periodically check in on the house in real time from my blackberry web browser.
|
| |
| Saving streaming media
|
01.03.09
|
After a couple of hours I think I've finally figured out how to save pretty much every type of online media. Of course, the easiest way is to go into your temporary folder (on linux it's //tmp/) while firefox is still open and just copy the file into a more permanent location. I then used ffmpeg to convert the file from flash to mpg. However, I found that this doesn't work for rtmp flash files.
I spent the next few hours finding a way to download the feed by pulling the rtmp url out of the source code using firebug which didn't work; I tried a couple of firefox add-ons like Download helper which didn't work; and then I tried a Windows freeware app called Orbit downloader which didn't work either. Finally, I found a solution: Replay A/V for Windows. Although I'm running Windows as a virtual install on my linux machine Replay worked just fine. It took me a couple of tries to realize that I wouldn't be able to see the feed while Replay is capturing it -- I could only tell it was working because the file size was increasing. And transcoding the file from .flv to .mpg hasn't worked perfectly either yet (the recording speeds up in sections) but I think it's likely a problem with my processor speed. Either that or I need to change the framerate or bitrate when I transcode.
So, if you've got windows, get Replay A/V. If you've got linux, get VMWare and then get Replay A/V to be able to save that last, pesky flash file to your hard drive.
|
| |
| SSH tunneling using a remote server as proxy
|
08.02.09
|
Here's the situation: You're on your laptop and can't browse the web because of a well-meaning but overly restrictive filtering proxy (or firewall). With this method, if you can use ssh to connect to a remote machine from your laptop, you can "tunnel" your browser traffic through this connection to bypass a content filter. Disclaimer: Filters are normally set up for a good reason and bypassing yours may make you subject to administrative or legal action. On the other hand, sometimes they're repressive and unethical (China for example) which is why I feel justified in writing this tutorial. For this example we'll use two computers: laptop (local) and desktop (remote) with both running ubuntu or a similar linux distro.
First, you'll require ssh on both machines and tinyproxy on the desktop. To install ssh on both:
To install tinyproxy on desktop:
sudo apt-get install tinyproxy
Important point: If you don't have one already, you need to change to a VERY secure password to use ssh. Your computer will be accessible to anyone on the internet and a weak password will allow a black-hat hacker to gain root access on your machine using a dictionary or brute force attack (this is very, very bad).
I found it helpful to change the listening port on tinyproxy (optional)
sudo gedit /etc/tinyproxy/tinyproxy.conf
so it looks like:
#
# Port to listen on.
#
Port 6000
To affect the changes you need to restart tinyproxy
sudo /etc/init.d/tinyproxy restart
Now on the laptop, you'll need to setup your ssh tunnel. Install Gnome SSH Tunnel Manager:
sudo apt-get install gstm
Now we need to configure the ssh tunnel:
- Open the GUI by clicking Applications->Internet->gSTM.
- Then click on "Add" and enter a name such as "Home".
- In the "LOGIN" field, enter the username of the superuser again.
- In the "HOST" field, enter the ip address of the desktop.
To the right of the "Port Redirection" field click on "Add" and in the popup menu change the fields as follows:
- The "Type" field should be "local"
- The "Port" field should be "7777"
- The "To host" should be "localhost" and
- The "To Port" should be "6000".
- Click "OK" and "OK" again.
Click on "Home" and "Start" and enter the password for the superuser which will start the ssh tunnel to your desktop.
Now you just have to configure your web browser (or torrent software, or any other service) to use the tunnel. For Firefox:
- Click on "Edit->Preferences".
- Select the "Advanced" tab and click on the "Settings" button.
- Tick the "Manual proxy configuration" box.
- For "HTTP Proxy" enter "localhost" and for "Port" enter "7777".
- Tick the box "use this proxy server for all protocols".
- Click on OK.
Voila! Now all of the packets for firefox are encrypted using the ssh and sent on the ssh port (number 22), evading any pesky filters.
This method could also be used for more questionable and probably illegal aims, such as not paying for wireless internet access by tunneling around a proxy that blocks only port 80; or to avoid bandwidth throttling on ISPs that do deep packet inspection for torrent traffic -- Which in no way do I endorse. So, I hope this helped and please use it ethically.
|
| |
| Hack Thyself
|
07.02.09
|
I got the winter issue of 2600: The Hacker Quarterly from the newsstand last week. There are some really good articles. Namely, there's a great article on how to bypass internet filters by either using the Google cached pages or using your own proxy server. With that advice, I've created my own free, no-add proxy server (at right) which you are welcome to use as long as my bandwidth doesn't go off the charts. There's also a great article on forensic data recovery using foremost and how to obtain an anonymous secure shell. This latter article led me to a couple of great sites:
- Hushmail - This is a free, very secure email service that allows you to send encrypted emails with your web browser.
- Bshellz - You can get a free, anonymous Debian Unix Shell account here. The only drawback is that you need to log on to an IRC channel once a week or your account gets deleted.
- HTS - This is a pretty good site for legally testing your ability. Their IRC channel is a waste of time though. It's filled with barely literate 12 year olds that trade insults all day. Inane.
|
| |
| The Golden Globes
|
12.01.09
|
KC knows a lot about movies. We watch a lot of them. So I don't mind placing bets on the Golden Globes for her, even though there's not much action on special markets like that so the odds tend to be kinda screwy. Last year it didn't work out. Out of the four or five categories we bet on we didn't win one. But this year I placed bets on five categories for her and she picked the winnner in all five... Including some long shots like Colin Farrel for In Brugge. Even with only the minimum bet on each category we won more than 50 bucks. Which goes to make back half of what I lost betting on soccer recently. Maybe I should stick to movies.
|
| |
| VLC: The solution
|
07.12.08
|
So I was able to downgrade to VLC 0.8.6 on an AMD64 intrepid install using the following method:
Download the following three packages (click here for a link to the page where I found them):
Then remove conflicting newer packages:
sudo apt-get remove vlc vlc-nox vlc-data
Then install the older versions using GDebi Package installer (right click the files you just downloaded and select the first option) is this order:
- libvlc0
- vlc-nox
- vlc_0.8.6
And voila! Back to normal. No Qt, no hanging, no problem.
|
| |
|
|
Download
|
|