Friday, November 01, 2013

more details of Reaper-BUTT broadcast setup

My post on the setup for live broadcasts using Jack OS X was a bit skimpy on the Reaper setup details. These screenshots below tell the story of the setup on the Reaper side.

I've got sends going to a full-mix recording track as well as the broadcast track, so that I can use them without interruption even when I 'solo' any of the tracks to listen to that mic - the 'solo' happens by muting all other tracks in the mix which goes to the headphone (outputs 1-2). The mix which is recorded goes to outputs 3-4. I also have another Jack setup where output 4 gets a compressed signal from the broadcast channel below - which could be sent to the video team, for example.


On this broadcast track, I have a high pass filter to cut out rumble, knee at 100 Hz, an aggressive compressor, and the insert from Jack. The insert's return is used as input for BUTT using Jack routing.


Sunday, October 20, 2013

VLC-based Warp-on-the-fly player from Paul Bourke - mini review

Paul has now released the VLC-based Warp-on-the-fly player. Here was my mini-review for the beta test done on Oct 4.

As Paul mentions, there are some performance issues. Relatively low bitrate / lower resolution files are OK. The sample1.mov file  - 1280x1280, 6.4 Mbps with avc1 codec - plays smoothly. A 2K file I encoded with Xvid codec, 9.8 Mbps, plays at something like 15 fps, with more frames being dropped where the scenes are more complex. Seems to be CPU limited in my case, so people with beefier CPUs should be OK. Mine is an Athlon 64 X2 dual core processor at 1.9 GHz, with Nvidia Geforce 9100 M Graphics.
CPU usage -

1280x1280, 6.4 Mbps with avc1 codec with warp - 55% with beginning peak of 75%

1280x1280, 6.4 Mbps with avc1 codec without warp - 40%

2048 x 2048 Xvid codec, 9.8 Mbps with warp - hits 99, 100%, hence frames dropped to 15 fps or so.

2048 x 2048 Xvid codec, 9.8 Mbps without warp - 65%, with peaks of 75% for complex scenes.

Another issue for me is that the snapshot feature, or the convert feature, does not capture the warped file, but instead captures the input frame. Perhaps there is some setting which I should do in order to capture / export the warped frames from this player? If I can get the capture / export working, then the performance issues will be moot......

Sureyyasoft Shira Player mini review

Tried out the Shira Player from Sureyyasoft - a player modified from a Stellarium base. At first it crashed, the developer sent me a shader file to put in the data folder, after which it works. Interestingly, it does on the fly warping of fisheye movies using the spheric mirror distortion built into Stellarium. But as mentioned in my previous post on Stellarium, the output image quality when warped is not so great, especially when I use image capture and compare with the other warping tools.

Image obtained from the avisynth plugin, using Flipvertical():

Image obtained from Shiraplayer:


Additionally, there seems to be some sort of up-down flipping involved: Flipvertical() was used in the avisynth script to get a similar image.

Update: Newer version of Shiraplayer with these issues solved, discussed here.

Saturday, October 19, 2013

infection on Studio network

Our IP address was blacklisted on the CBL due to an infection of one of the machines. Apparently CBL detected a trojan on our network, trying to connect to other machines via UDP. So, even though our network was not sending spam, CBL blacklisted the ip address. 

First, PB changed the IP address of outgoing http and connections other than mail, to another ip address which he had available. Then, CBL blacklisted the new ip, with the additional info that no spam was detected, only the presence of the trojan:

IP Address x.y.z.a is listed in the CBL. It appears to be infected with a spam sending trojan, proxy or some other form of botnet.
It was last detected at 2013-10-17 11:00 GMT (+/- 30 minutes), approximately 16 hours, 30 minutes ago.
This IP address is infected with, or is NATting for a machine infected with the ZeroAccess botnet, also known as Sirefef. More information can be found from Wikipedia. It is most often used for bitcoin mining or click fraud, but as it contains a downloader portion, it can do anything.
If this IP address is a NAT gateway, it should be possible to find which computer on your internal network is infected by implementing a filter on your firewall to detect and log attempts to send UDP packets to the Internet with a destination port number of 16471. 

In Cyberoam, System -> Diagnostics -> Connection List tab,  port number of 16471 was seen in the destination section. That machine was cleaned up using Norton Power Eraser as recommended by CBL. Issue resolved for now.

Thursday, October 10, 2013

beware of distributed brute-forcing

An interesting article about distributed brute-forcing by bad guys - 

https://bsdly.blogspot.com/2013/10/the-hail-mary-cloud-and-lessons-learned.html

So, for SSH we can use key-based auth for protection, and it would be safer to use two-factor auth for other things like wordpress.

Wednesday, October 09, 2013

connecting to our ssh server via mobile internet

Due to various power outage issues in the region, I've had to fall back on ConnectBot to connect to our servers. The ip addresses for Airtel 2G seem to be all over the place, as given at https://as.robtex.com/as45609.html#bgp

So, instead of white-listing all the ip ranges 106.0.0.0/8, 223.0.0.0/8, 27.0.0.0/8, 171.0.0.0/8, 182.0.0.0/8, and so on, just added our Voxel server's key to authorized_keys, and added its ip to the allowed range.

Took me an extra ten minutes to do this. First,
host media.radiosai.org
gave me the wrong ip address to allow - the Cloudflare CDN's ip address! Then, the copy-paste of the id_rsa.pub added newlines, so I got errors like error: key_from_blob: can't read
as seen in /var/log/messages of the server. Removed the unnecessary newlines, got it working - there is no need to restart sshd when adding keys. 

Monday, October 07, 2013

saiwaves not booting - manual boot choice needed

With all the power issues we face, we've had to shutdown our servers quite a number of times. saiwaves refused to come up - and the following was PB's solution.

These links helped....



use F11 - Boot Menu  
In the boot menu select Hard Drive C: 
then select Slot 2 (Virtual Disk)

Saturday, October 05, 2013

Cloudflare optimizations break javascript

Our web-based audio player seemed to have broken all of a sudden. Strange symptoms - working on Safari, but not on Chrome or IE or Firefox. Checking the source, found some Cloudflare injected code. Tried pausing cloudflare, that solved the issue. Then found that Cloudflare optimizations are known to break javascript, jquery and so on. Turned off optimizations, made the settings CDN only, modified the rules for media.radiosai.org also to omit the optimizations, then all is well.

The search box on every page of radiosai.org also had broken due to the javascript issues - removing Cloudflare optimizations solved that issue also. 

Friday, October 04, 2013

saving a video with effects applied via vlc

In my previous post, I failed to save a video with effects. But now, this page showed me how to do it. The gui-based method is:

  1. Show all settings (and not Simple) from Tools -> Preferences -> Interface settings
  2. In Preferences, under Stream Output -> Sout -> Transcode, choose appropriate filter
  3. From main menu, Media -> Convert/Save
  4. Add input files, and choose Convert at bottom convert/save drop-down.
  5. After doing required conversion, Tools -> Preferences -> Reset Preferences
Unfortunately, this method did not work out of the box with the vlc-based warp player made by Paul Bourke - the filter is not explicitly shown.

Monday, September 30, 2013

Windows solution for warping - avisynth filter

Cross-posted on small_planetarium yahoo group.

Glad to announce yet another Windows solution for warping. This is an implementation as an avisynth plugin called Planetarium, which is listed at

http://www.avisynth.nl/users/vcmohan/
My short review: Takes around 40 sec for video to load into virtualdub using level=7 (documentation is athttp://www.avisynth.nl/users/vcmohan/Planetarium/Planetarium.html )
On my machine, rendering proceeds at nearly 2 fps as against 3 seconds per frame taken by jpgwarper (the older Windows solution at http://www.lochnessproductions.com/software/imgwarper/iww.html )
There is a slight difference in anti-aliasing quality, which I have to explore with different "level" settings.
Where this can be useful: for situations where a pre-rendered video is needed, like playing back from a Blu-ray player instead of a PC and so on. 

http://groups.yahoo.com/neo/groups/small_planetarium/conversations/messages/2434 )

Saturday, September 28, 2013

occasional smb connection issues at studio

Occasionally, the Linux smb share becomes inaccessible, not seen in the list of shares, to some of the Mac users in the Studio.

Solution: When not able to save to the shared folder, do the following:

Open Finder.
Choose Go Menu, Connect to Server.
Type smb://
in the server address box. 

Click connect. When it asks to connect as what user, choose the Guest option. Then you will be able to open the shared folders on that machine.

Friday, September 13, 2013

using connectbot on Android

ConnectBot is an Android SSH client which runs on older versions of Android also. It could import the RSA key pair once I copied it to memory card from my Linux desktop's .ssh directory. In order to use Ctrl, Esc, Func and arrow keys, it uses the trackball.

ESC = press trackball twice
CTRL = press trackball once.

Tab = CTRL + i

Function key - CTRL + number

Arrow keys = move trackball right/left/up/down

vlc preliminary trials - fail

Paul Bourke mentioned that a VLC plugin for warping is under development. Tried out exporting a filtered video using VLC as given at this forum thread,
https://forum.videolan.org/viewtopic.php?t=55449&f=14

Unfortunately, the output doesn't seem to have the filter applied. Code used was
vlc -I dummy stellarium_movie.avi -v --video-filter="wave" --file-caching="20000"  --sout="#transcode{vcodec=mp4v,vb=8192,scale=1,
deinterlace, audio-sync,acodec=mp4a,ab=128, channels=2}:duplicate{dst=standard{access=file,mux=ts,dst=test\output3wave.mpg}}"


I tried --vout-filter also, as given in the forum, but no go. Output video does not have the filter applied.

vlc -I dummy stellarium_movie.avi -v --vout-filter="wave" --file-caching="20000"  --sout="#transcode{vcodec=mp4v,vb=8192,scale=1,
deinterlace,audio-sync,acodec=mp4a,ab=128, channels=2}:duplicate{dst=standard{access=file,mux=ts,dst=test\output3wave.mpg}}"


Edit: Solution is here.

Friday, August 30, 2013

reviving the old Mac as an internet radio

This is going to be a long post.

It all started with the idea of using the old mac as an internet radio. As its screen had become damaged and showed up scratches, and it was underpowered for most tasks, this seemed a good idea. The final solution was to enable booting to console by installing a base install from mini cd of Ubuntu 12.04 and running a script on login. Network connectivity via the built-in ethernet port. Efforts to use a USB wifi adapter were not successful in the sense that the wifi was not reliable, would come up sometimes and not at other times. This post will chronicle the entire story.

Final working solution:

The internal CD drive was not reading. So the easiest way to upgrade to a new distro, booting from CD, could not be used. An external USB CD drive was also not recognized as a CD to boot from, by pressing C at boot time. The netboot procedure for using a Windows machine as TFTP server was used, with the files needed for the netboot being listed at the bottom of this page. For Ubuntu 12.04 Precise Pangolin, the PPC netboot files are at http://ports.ubuntu.com/dists/precise/main/installer-powerpc/current/images/powerpc/netboot/

For doing the netboot, after setting up tftpd with the required files as above, the Mac needs to be booted into open firmware by pressing Alt+Command+o+f at boot, and the command
  boot enet:0
needs to be entered at the Open Firmware prompt. The Ubuntu netboot installer works, but stops at "getting installer components" with a blank screen, and continues after 15 minutes! The whole base install takes an hour or so, downloading required files online took around 15 minutes with our 2 Mbps shared link.

The machine was made to auto-login to the user shell by editing /etc/init/tty1.conf. An interactive bash shell script was the choice for running the "radio" - a simple bash case statement with a while loop asking for input to change streams. Changing streams by killall mpg123 followed by the relevant mpg123 stream-url. This was made to start on boot by putting it in .bash_profile. Then the system boots up and starts playing in 90 seconds.

To prevent sleep when lid closed, used the tip given at http://mrob.com/pub/ibook.html and put a plastic CD case between the lid and the bottom half.

Ease of shut-down - the Ctrl-Al-Delete method given here was adapted, editing /etc/inittab and changing the shutdown -r to shutdown -h to halt the system instead of reboot on Ctrl-Alt-Del. On the Mac keyboard, the keypress for del needs Fn+Delete, since Backspace is labelled as Delete.

Mis-steps:

In hindsight, the final result above could have been accomplished in around 10 minutes' time. Instead, a week was spent in various explorations. Many things were learnt, which are listed below.

Initially, the idea was to upgrade the running Ubuntu 8.04 LTS to 12.04, so that the newer kernel would have built-in support for the USB wifi device. Upgrade from 8.04 to 10.04 went off OK, via
#apt-get update
#apt-get upgrade
#apt-get dist upgrade
#do-upgrade-release

But 10.04 to 12.04 failed.

At this point, I'd tried to get a console-only install by removing all X related stuff. The tasksel method did not work, nor did apt-get remove ubuntu-desktop. But using wildcards and aptitude, removed ~ngnome , ~nxorg and so on, till finally the system booted to a simple bash shell and no X. Getting a list of all installed packages would sometimes be useful.

Perhaps this was because of not doing the
#apt-get update ? Software sources were manually changed archive.ubuntu.com/ubuntu to ports.ubuntu.com , and then doing the above,  do-release-upgrade worked. But at the end of the install, some errors were reported, and on reboot, the system went into a loop and refused to boot. Single user recovery console was the only working option, and ifupdown etc seemed to be borked. So, a fresh install was attempted.

USB disk install as given at https://help.ubuntu.com/community/Installation/FromUSBStick did not work. But then, it was done using the mini.iso, and that page says mini older than 13 does not boot from USB. Then the netboot option mentioned at the top of this post was tried, and worked.

Several times when the Mac was booted without an ethernet connection, the date and time were off. Apparently these iBooks don't have a BIOS battery, and only use a capacitor and the main battery. The capacitor as well as the main battery seem to be dead in this case. Resetting PMU and PRAM etc did not help.

Possibly due to the power constraints of the USB 1.1 port on this iBook, sometimes booting with the DWA-131 USB wifi adapter would cause repeated errors scrolling by every second, complaining unable to enumerate usb device on port 1 - connecting via a USB hub stopped this issue. After the driver was detected, removing the hub also did not cause this problem to recur.

In this case, lsusb showed the appropriate device name, and checking the driver for it, googled 07d1:3303 D-Link System DWA-131 wireless n nano adapter linux and found the driver was
https://wiki.debian.org/rtl819x
also googled 07d1:3303 D-Link System DWA-131 wireless n nano adapter ubuntu and found via
http://ubuntuforums.org/archive/index.php/t-1392153.html
that the command to be used to connect via wifi is iwconfig and not ifconfig.

Also, found that on listing drivers, lsmod was listing the driver rtl819x as loaded, so probably it should work.

So, did
#apt-get install wireless-tools
and tried to connect, as given at this post - in that page, in the "Make it a script" section, perhaps the first line should be ifconfig wlan0 up

Anyway, tried it, did not work. Finally found via this thread that iwconfig works only for WEP, and that wpa-supplicant has to be used for WPA. Tried the methods given here, did not work, so tried to install ubuntu desktop. This was in Ubuntu 13.10 - but starting X was causing a segmentation fault. Even after googling and trying to remove other errors, and following the steps given here, X still seg-faulted when a window manager was installed.

So, went back to 12.04 to try the procedure given at this post to load X - but before doing the X install, thought of trying to connect with commandline using wicd and found this post. This method succeeded! Except in the last line, it was dhclient wlan0 and not dhcpd wlan0 in my case.
# ifconfig wlan0 up  
# iwconfig wlan0 essid "my_network"  
# wpa_supplicant -B -iwlan0 -c/etc/wpa_supplicant.conf  
# dhclient wlan0

Then used this method to make it come up at boot, editing /etc/network/interfaces. But the wifi connection was erratic. Sometimes would not connect at all on boot. Sometimes would connect if the time was set using open firmware with
decimal dev rtc 09 34 13 28 08 2013 set-time
but sometimes not. Would sometimes connect if ethernet cable was connected, sometimes not. Tried going to WEP instead of WPA, and it seemed to work as per the iwconfig method given above, and seemed to connect OK even when the time was off, even when ethernet was off. But a cold reboot the next day showed that the wifi connection was still erratic, and so wired was the way to go.

Testing the networks with wicd, needed to enter wlan0 in Preferences of wicd-curses as per this post.

mpg123 failed to open module  etc errors as non-root user. Installed alsa, rebooted, fixed.
#apt-get install alsa alsa-tools

Then, choosing amixer set Master 45 seems to be a good volume level to set.

After all this, needed to install ntpd, otherwise time is off
https://help.ubuntu.com/10.04/serverguide/NTP.html


Wednesday, August 21, 2013

blogger post editor broken on IE 8

Probably part of Google's "older browsers not supported" campaign. The post editor seems to be working only in html mode and not in compose mode when using IE 8. Tried clearing cache, still no go. So finally it's time to say goodbye, I suppose, and use Opera or Chrome instead, as a secondary browser. Or I can post like this, using email.

Saturday, August 17, 2013

youtube video to mp3

There are quite a few services offering conversion of youtube videos to mp3. vidtomp3.com did a reasonably good job, doing an hour long video in less than 10 minutes. Ad supported, of course. Some other sites have size limits, this one seems to be free of duration restrictions.

Thursday, August 15, 2013

DD links and bug in Description form

While adding links to the Descriptions for Divine Discourses found that the form for adding Descriptions which we use internally has some bugs, with erratic behaviour for filenames which have spaces and or other characters. Have alerted PB on this. Meanwhile, the links were added without quotes, since the form again needs special treatment for quotes, and various bash csv export scripts may misbehave with quotes. I was pleasantly surprised to find that even target=_blank works without quotes.

Thursday, August 01, 2013

mysql db table repair for phplist

As a follow-up to this earlier post on table repair, PB suggested the following:
He found that the following one line command checks, repairs and optimizes all the databases.

 mysqlcheck -u root -p --auto-repair -c -o --all-databases

This could be used  in situations where we are not sure of which tables have crashed or needs repair.....

easily importing Nokia contacts into other apps with vcf support

Guest post from V:

Create a back up of contacts using application on the Nokia phone. By default it will be saved as Backup000.NBF. The extension looks strange, but the file is similar to an archived file like .zip

Open Backup000.NBF using any archive manager and navigate to /predefhiddenfolder/backup/WIP/32/contacts Extract the folder containing all contacts as .vcf files to another location

Open Terminal and navigate to the folder containing the .vcf files. [Alternate method: sudo apt-get install nautilus-open-terminal adds a right-click “Open Terminal” option into the Nautilus File Manager in Ubuntu.]

Once inside the folder on Terminal, use: cat *.vcf > combined.vcf to combine all .vcf files into a single file.

This file can now be easily imported into Google Contacts or any other application that accepts .vcf files

Edit: There is one more elaborate method of VCF multiple contact import given at http://www.allaboutsymbian.com/forum/showthread.php?p=488142

Wednesday, July 31, 2013

sharing audio links - sharethis custom link

One of the requests from our listeners was an easy way to share audio links. Exploring the different ways to share, found that sharethis.com does support custom urls and custom text, as given in their documentation. But directly plugging this into the Download.php page would make it a bit ugly, with a separate email for each download link. Something better needs to be designed.