Sunday, July 30, 2006

Some web-design work

Radio Sai schedule page has been updated:

1. Calendar with Show | Hide
2. Link to play web stream
3. Link to today's schedule
4. Cookie remembers not just country but also the radiostation: AfriStar, AsiaStar or Web

Major coding by RK.

Saturday, July 29, 2006

Mod-Rewrite for IIS

A very nice open source ISAPI filter, helps in doing all sorts of server-side stuff like blocking based on referer:
http://www.iismods.com/url-rewrite/examples.htm

Friday, July 28, 2006

redirecting with http headers

Just a single line in the file,
<meta HTTP-EQUIV="REFRESH" content="0; url=http://whatever.i.want/">

Thursday, July 27, 2006

Setting up the playlist creation system

Trying to duplicate the playlist creation system on a laptop - Acer TravelMate 2423.

1. Installed Mandrake 10 for max compatibility, ease of porting apps from desktop. Also make user sgh.

2. Installed apache2, mod-php, php-mysql, php-pgsql, phppgadmin

3. Had to make the sgh user and db. Struggled a bit, finally saw the README.mdk in /usr/share/doc/postgresql-server-7.4.1/ -
After you installed the packages, here is the procedure to
start quickly but nicely.

1- Become root user on your machine. (su)
2- Become postgres user. (su postgres)
3- Create a user (createuser)
4- Be sure that the postmaster is running (service postgresql status)
5- Logout from the postgres and the root account.
6- Test it. (psql -U [username])
This will fail, saying FATAL sgh database does not exist. You have do do an extra step before step 6 - run
createdb
as user sgh.

Directly trying to run phppgadmin fails. This is because the default install of postgres will not allow connects on port 5432 - it allows only connects with the local UNIX sockets. So, psql will work, phppgadmin will not, till you modify the pg_hba.conf in /var/lib/pgsql/ -
# TYPE  DATABASE    USER        IP-ADDRESS        IP-MASK           METHOD

local all all ident sameuser
host all all 127.0.0.1 255.255.255.255 trust
and also pg_hba.conf says,
#Also, remember TCP/IP connections are only enabled
# if you enable "tcpip_socket" in postgresql.conf

So, accordingly, changed false to true: tcpip_socket = true in postgresql.conf and did
service postgresql restart
Voila! netstat -a shows
tcp 0 0 *:postgres *:* LISTEN

Now phppgadmin works. Agreed that this is not suitable for multi-user systems... (the trust all users part). Changing to md5 instead of trust, restarted postgresql, instantly stopped stuff from working. Problem was that the password had not been set. Easiest way - first enable the trust connection, then in phppgadmin, User Admin in the system tables - edit the sgh user, add the appropriate password, and now the md5 authentication works. Otherwise, while creating the user, createuser -P will prompt for the new user's password.

OK, how about inserting the existing database from the database dump? For a refresher, the commands were
pg_dump sgh > sghdbdump.txt 
psql -d sgh -f sghdbdump.txt
But it gave an error,
language "plpgsql" does not exist
HINT: You need to use "createlang" to load the language into the database.

And createlang plpgsql says
createlang: language installation failed: ERROR: could not access file "$libdir/plpgsql": No such file or directory. Checking out locate plpgsql and whereis plpgsql did not find it. So, will consult PB and Google on installing it.

Monday, July 24, 2006

Analytics working!

I'd not checked the Google Analytics results on radiosai.org except by looking at the site overlay. On the site overlay, the "external links" to the pls and asx files were showing zero hits. But taking a look at the Content Performance report, the hits have been counted! Maybe it's an issue with GA's site overlay - will try to ask them. Meanwhile, I can go ahead with Coral cache and on-demand!

Saturday, July 22, 2006

initial trouble with the Pilot

Initially, the Pilot did not show any display, even after reset, hard reset and new alkaline batteries. Then just on a whim opened the back "memory gate" just to look at the innards, and the display came on. Maybe the reset button had got stuck or something. After that it has been working just fine.

lazy or very clever?

Yesterday I mentioned "lazy ISPs" blocking entire domains instead of the 17 sites GOI wanted blocked. But maybe they were not lazy? Maybe they just wanted to let everyone know that sites were being blocked without getting their hands wet?

Friday, July 21, 2006

Lots of stuff to post

1. Floppy drive on the Satellite Pro (1996 vintage) failed, so I couldn't type stuff there and get it to office for posting. But now doing so using an old Palm Pilot - version 1 - with 1 MB RAM and serial port cradle - syncing it at the room with the provided Pilot Desktop SW and here on JPilot.

2. Blogspot.com domain was blocked by Govt of India! Actually by lazy ISPs. And now back again. Wrote to our Prez about it in the heat of the moment.

3. Finally posted on pcq forum about the "CPU util" in their HDD banchmarking.

4. Planetarium system down! "Home in progress" doesn't go off. Troubleshooting, checking out the "ATM CLR" signal.

5. DMACS conference - and had to redraft a poster paper (in fact two papers) since my name had been added as a co-author.

6. Edited the Malayalam in the Wikipedia post made by A - with the help of online transliteration by www.writeka.com .

Monday, July 17, 2006

BluePulse

Interesting concept for content delivery to mobiles. Found via bluepulseblog on Blogger's 'blogs of note'.

Monday, July 10, 2006

javascript errors

Seeing that Radiosai.org pages are showing Javascript errors when viewed in IE (or Maxthon, which uses IE engine):
Line:2
Char:1
Code:0
Error:Invalid character

Line:712
Char:1
Code:0
Error:Object expected
This second one corresponds to the Urchin javascript for Google Analytics. Some reassurance - the same error is appearing in Blogger too!

lots o'work

1. DVD encoding going on in the background while I do audio work. DVDIt had some PAL-NTSC problem or something of that kind. Also, quality of the Matrox encoder is poorer than the 2-pass encoder which ships with NeroVision Express which I've got bundled with the DVD writer! So, Matrox DV export, taken to NeroVision Express, write to hard disk folder. Repeat for next episode when ready. Finally use DVDShrink in Re-Author mode to put all the files together in one DVD.

2. Interesting use for the "scientific filter" in SoundForge - 15,500 Hz noise due to interference from CC TVs in Mandir in live recordings easily removed - 15500 to 16500 band stop applied - 4th order or something. Another surprising use was to cut 5 kHz to 16 kHz in one of the Africa interviews. The noise vanished, leaving the voices surprisingly untouched. Sibilants are present above 16k also, and the rest are below 5k...

Thursday, July 06, 2006

Auto Trim-Crop in SF and Premiere's sound problem

Today's aha moment was with Auto Trim/Crop in Sound Forge. Saves time spent in "donkey work".

Yesterday, found the Premiere sound problem (no sound output when playing Matrox AV files in RT2000 system DVEDIT) was due to my forgetfulness while installing - needed to connect a cable from the RT2000 card to sound card's aux input - or use the break-out box's RCA connectors.

Wednesday, July 05, 2006

checking out groupware

PB wanted to implement some sort of online work assignment. Collaboration sw / Groupware / ticketing systems... We looked at php based systems - eGroupWare, phpGroupWare and HelpCORE. We might go in for one of the last two.

Saturday, July 01, 2006

broadcast ping

Spent a lot of time last evening investigating pings from x.y.z.15 - PB was called by V saying .15 is replying to pings, it is some machine in your network. At first, I suspected some machine in CG's studio; then krishna. Checking out ifconfig on krishna, x.y.z.15 was the broadcast address on our subnet! Our subnet mask was 255.255.255.248, so it follows...

Pinging from a NATed machine gets a reply only from the gateway. Pinging from the machine with x.y.z.n address gets replies from all machines in subnet - other than windows machines, of course, which don't respond to broadcast pings.