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.

Sunday, July 02, 2006

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.

Friday, June 30, 2006

error '8004020e'

OK, the problem with the subscription page was actually solved: the error '8004020e' is actually due to ill-formed "From" email address, which is the email address submitted on the form. Googling gave the answer from
http://www.thescripts.com/forum/thread433129.html

Mostly routine

Most of the time spent in "routine" work of preparing audio material and so on.

1. The old Satellite Pro's floppy drive seems to have given up the ghost. So, I can't rely on typing on that and carrying stuff across on a floppy.

2. Some notes on noise reduction and an interesting result in one case.

For some interviews recorded in the field (in Africa) noise reduction was desirable in some cases. Cool Edit Pro, 69%, followed by noise gate in SoundForge at a threshold just enough to cut off the residual noise. Followed by RMS normalization, of course. In some cases, noise reduction not desirable, as when the background noise is either not constant, or very low, or as in one case, the background noise is very loud, being recorded while travelling in a van. In this case, the noise acts as a sort of prop for the voices - gives the feel of being on location.

3. A problem with the Submit button on our playlist subscription page. The first problem was that after adding the search bar, the form with the submit button was document.form(1) and not document.form(0) as was written in the validation javascript. Some other problem still persists....

4. Must try to get the google analytics javascript to work on "external links" - so that we can do our audio on demand with Coral Cache...

Wednesday, June 21, 2006

authoring dvds using dvedit

Since DVEDIT has the Matrox RT2000 card, it was earlier the only DVD making option. Now software encoders on saispace2 run much faster than the 4x realtime required by Matrox, or are more compatible with other DVD creation SW. So, trying various options.

First, the MPEG2 export only from the Matrox - not recognized by anything other than Sonic DVDit, I think.

Next - the Matrox DV avi export. Fast, and cuts file into 2 GB chunks, useful if using FAT32 drives. Recognized as DV avi by most sw, but the audio is a separate wav file which most sw will need prompting to find. For eg., in Nerovision Express, the audio has to be separately dragged and dropped in the video edit timeline. In Virtualdub, Audio menu, Use wav audio.

MS DV avi export from dvedit seems to be not useful - takes 4x realtime, and probably reencodes.

Tuesday, June 20, 2006

ReactOS

Tried out the ReactOS live Cd. Well, it is truly alpha - didn't recognize dharma's logitech serial mouse. But booted in a jiffy, only 10-20 MB for the entire live CD.

Monday, June 19, 2006

using ethereal

Used ethereal on saispace to check out the mysterious packet bursts from dharma when it boots up. Filters were useful: capture filter
(host not 192.168.2.6) and (host not our-melb-ipaddress )
since a sftp session was in progress.
Display filter would be
ip.addr ne 192.168.2.6
and so on.

Nothing suspicious. Only NTP, multicast router solicitation and antivirus updates.

Linuxjournal has a nice guided tour of ethereal.

Wednesday, June 14, 2006

reinstall on dvedit

Premiere was crashing on DVEDIT, even reinstalling it didn't work. So, decided to reinstall Win2K on it. Installed in another folder without removing the existing installation. Took network and promise ATA card drivers by choosing the oem0.inf and oem1.inf in the old WINNT\inf folder - found with notepad that these were their respective inf files, mentioning Promise and DLink. Windows did the rest, automagically installing the sound card also - ESS 1938.

After reinstall, the stop error and restart problem which I'd posted on PCQ forum is solved - so it was purely a software problem, as suspected. And of course Windows problems are best solved by reinstalls!

Installed WinK SP4 from PCQ Oct 2004 DVD, then Matrox video tools after the display driver.

Tuesday, June 13, 2006

curiosity - or the broken hand-pumping flashlight

Curiosity kills the cat, but in this case, it killed my "hand-pumping flashlight". I'd been given a low-cost one, along with several others. Some were brightly glowing while some needed continuous pumping for any light. Suspected a hidden battery inside. Opened and saw. Yes, there was a battery. But now the flashlight is dead - a resistor broke during surgery!

Saturday, June 10, 2006

a brief look at ftp servers

There was a need for an ftp server to run on Windows Server 2003, with the following specs:

support for SSH2 and SSL with the following basic features:
- Runs as a NT Service (not with ServAny--not as stable)
- work with standard FTP clients
- require a secure connection
- bandwidth throttling per user and per server
- event handling (monitoring for DoS attacks or other suspicious
activities)

- DB user account support
- Lightweight with high perf
- Programmable interfaces in case sites want to automate
- 1/2 domain, 10 account support to start with

Commercial servers are >$200

A list of FTP servers is on
http://en.wikipedia.org/wiki/List_of_FTP_servers

Sourceforge gave some more:

A good example is http://sourceforge.net/projects/wzdftpd
But will probably use SrvAny to run as a service. zFTPServer Suite also looks good....

Filezilla server looks good, too. Not much documentation on the site, but trying it
out, it has

SSL/TLS support
Speed limits
Compression settings
Admin interface

A Brute force banning script is at
http://www.delta-marketing.net/phpBB2/viewtopic.php?t=3

Monday, June 05, 2006

correction to script

Corrected version of script reads

MINUTES=`echo "scale=1; ($MINUTES/15)" | bc -l`
MINUTES=$(printf "%2.0f" $MINUTES)
MINUTES=`echo "scale=0; ($MINUTES*15)" | bc -l`
MINUTES=$(printf "%02d" $MINUTES)

if [ "$MINUTES" = "60" ]
then
HOURS=`echo "scale=0; ($HOURS+1)" | bc -l`
HOURS=$(printf "%02d" $HOURS)
MINUTES=00
fi

if [ "$HOURS" = "24" ]
then
HOURS=00
fi
This has the printf part only if bc is called. Else, sometimes printf gives errors like
 printf: 08: invalid number

disabling or getting around gmail spam filter

The gmail spam filter was marking mail from our Jo'berg playout server as spam - maybe since it was from a dynamic ip. Marking as NOT SPAM did not work for mails which came later. Making a filter with an "Add flag" for the sender From address worked! No longer sent to SPAM folder.

Saturday, June 03, 2006

port forwarding

And for port forwarding, followed the steps given in
http://www.portforward.com/english/routers/port_forwarding/Huawei/Smartax-MT-841/BitTorrent.htm

router screenshot

Here's a screenshot:

My collegue wanted to get internet access for 3-4 machines using a BSNL DATAONE Huawei router which already had 4 LAN ports.They were doing PPPoE dialout from individual machines; this wouldn't work with more than one machine at any one time.

Set up dialling out from the router similar to the BSNL DATAONE ADSL HOWTO

Except that the layout was different. Had to add a NEW PVC-7 - change its VPI/VCI:->0/35 after first changing PVC-0's value which was earlier 0/35 and hence causing a conflict. Most important - SAVE ALL button at the bottom did the rebooting of router. Maybe I'll put in screenshots later. And I'll need to help them with port forwarding for one of the machines to use Bittorrent.

Friday, June 02, 2006

gmail problem and google analytics invite

Gmail is crashing my Mozilla - Mozilla 1.6 - Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.6) Gecko/20040115
Just after the Loading... sign appears on the left, stops responding. Probably some Javascript issue. Working OK with Opera, Konqueror (with limited functionality), etc.

Got a google analytics invite. Thought I'd add it to this site, but www.radiosai.org has priority.

Wednesday, May 31, 2006

dynamics processing is different

Dynamics processing in Sound Forge sounds different from the filter present in Cool Edit Pro. For long I've stayed with a particular setting:

But putting the same settings in SF doesn't give the same results - the waveform is more flattened, and sounds more squashed, too. Preliminary tweaking with attack and release times didn't help. SF version is pretty old - 4.5. For that matter, the Cool Edit Pro 1.1 is old too - latest is Adobe Audition 2.

made shoutstats work again

After the upgrade on krishna, shoutstats was not updating the graphs. I'd suspected all along it was because rrdtool was not installed. Yesterday wanted to kill some time, so poked around krishna, found only librrdtool was installed, rrdtool itself was not, and was not available in the CD repository. rpmfind.net is your friend. Added the relevant ftp site there, and hey presto. (This skips the hour or so of dependency hell trying to download each package individually, not knowing what package contains the dependency (RRDp) - it was perl-rrdtool - and so on. Also took an hour to download the filelist from the slow rpmfind.net ftp site.)

Then I'd to go into the update.php and index.php and remove the hardcoded paths to rrdtool - probably added by us on the old krishna. Once that was done, working fine.

Tuesday, May 30, 2006

highlight announcements timings rounding off

Modified our bash shell script to round off the highlight announcements timings to 15 minute intervals:

MINUTES=`echo "scale=1; ($MINUTES/15)" | bc -l`
MINUTES=$(printf "%2.0f" $MINUTES)
MINUTES=`echo "scale=0; ($MINUTES*15)" | bc -l`

if [ "$MINUTES" = "60" ]
then
HOURS=`echo "scale=0; ($HOURS+1)" | bc -l`
MINUTES=00
fi

if [ "$HOURS" = "24" ]
then
HOURS=00
fi

MINUTES=$(printf "%02d" $MINUTES)
HOURS=$(printf "%02d" $HOURS)
#this gets them the leading zeros

Earlier code was

MINUTES=`printf %02d $(echo "scale=0; ($MINUTES/5)*5" | bc -l)`

This only rounds DOWN to the nearest multiple of 5.
Never rounds up correctly.
(Edit for the leading zeros code: 1st June)

Monday, May 29, 2006

validated feeds - finally!

Finally got the podcast feeds right, got them validated with feedvalidator.org

podcast php coding

Worked a bit more towards the podcast. Generating html from php code running locally.

It took nearly 4 hours to debug the http HEAD in php to get the filesizes - the library from http://lwest.free.fr/doc/php/lib/net_http_client-en.html
had a bug in that the HEAD function was also calling a ProcessBody function: since the HEAD did not return a body, the ProcessBody was waiting till the socket timed out or something like that, 150 seconds for each successful call! Also, the Debug variable needed some tweaking.

Later, the xml had a few bugs to iron out - <itunes:category> had to be one of the pre-defined ones, guid couldn't be repeated, publish date was not RFC 822 compliant, had to do string replace for space characters to %20...

Friday, May 26, 2006

added Panasonic dvsd codec

Downloaded the free Panasonic dvsd VFW codec so that VirtualDub can work with video captured with Microsoft Windows MovieMaker. The filter chain needs deinterlace first...

Saturday, May 20, 2006

underscore not allowed in hostname with squid

Well, the title says it all. A URL with underscores in the hostname part works with a "direct connection", but not through squid.

Workaround: Escape codes are given in places like this - http://www.dragonwinds.com/resources/html-codes.shtml are not enough - they are meant for the HTML.

http://www.squid-cache.org/mail-archive/squid-users/200208/0565.html
has a discussion on it and says that you need to recompile squid for it to work with underscores.

MX records not being served by ADSL router

We were not getting our automated mails from Jo'burg playout server after going on the ADSL line: earlier it was on their LAN.

Found lots of hostname not found errors in /var/log/maillog

host -t MX gmail.com was not returning anything, while
host -A MX gmail.com was working.

cat /etc/resolve.conf gave

nameserver 192.168.1.1
search localdomain

So the ADSL router was specifically blocking -t MX! Added a working dns server, BSNL's nameserver 61.1.96.69, after checking
host -t MX gmail.com 61.1.96.69 was working fine.

After /sbin/service network restart
when I did
cat /etc/resolve.conf

I again found it had gone back to
nameserver 192.168.1.1
search localdomain

Found this by googling 'resolv.conf updated from network restart':
http://linux.cudeso.be/linuxdoc/tweaky_net.php
saying
When you are connecting to a network that's using a DHCP-server, it's possible
that the settings you have placed in /etc/resolv.conf are overwritten
everytime you receive a DHCP-lease. You can prevent this by adding the
following line to /etc/sysconfig/network-scripts/ifcfg-eth0
PEERDNS=no

So I added that, then did
/sbin/service network restart

Then cat /etc/resolv.conf gave
search localdomain
nameserver
nameserver

and
host -t MX gmail.com gave
gmail.com mail is handled by 10 alt1.gmail-smtp-in.l.google.com.
gmail.com mail is handled by 10 alt2.gmail-smtp-in.l.google.com.
gmail.com mail is handled by 50 gsmtp163.google.com.
gmail.com mail is handled by 50 gsmtp183.google.com.
gmail.com mail is handled by 5 gmail-smtp-in.l.google.com.

So now seems good. And I got a test mail too.

Friday, May 19, 2006

recovering from partial uploads and MD5

At least on our Jo'burg playout server, where bandwidth is scarce and http outgoing is allowed:

wget -c http://krishna.radiosai.org/filename

And later verify the MD5 hashes with

openssl dgst -md5 filename

Thursday, May 18, 2006

known bugs in our database scripts

1. If first few letters of previous item are the same, and if both items are of the same category, second item will not be listed in the schedule.

Fix - change the comparison code... TBD

2. If previous day's playlist has an item at exactly $CHANGE_OVER_TIME , schedule generation php page will complain "SIGNATURE TUNE NOT FOUND"

Fix - manually change the time of the offending item by one second...

3. Sarva dharma bhajan handling - schedule shows two listings, one with zero duration, esp for Prasanthi Mandir bhajans.

Fix - ??

Wednesday, May 17, 2006

Acer Travelmate 242x - getting sound to work on Linux

Just followed the instructions given by the Troubleshoot button in drakconf's 'Hardware' section:

lspcidrake -v | fgrep AUDIO for which driver is used by default:
it was i810_audio

changed to that driver.

found aumix was not installed. Installed it.

Found alsa was not running in runlevel 5. Made it run in drakconf 'Services'.

Restarted machine, opened kmix, made sure sound not muted and put to 50% volume, working fine.

Linux on Acer Travelmate 2423NWXCi - 242x probably

Current complaints with the default install of Mandrake 10:

1. Touchpad needs clicking on the buttons for left and double click - click and double-click on the touchpad itself doesn't work.

2. No sound.

3. No battery meter, other power control stuff.

LAN works, Wireless LAN and WinModem may not, but I'm currently not using them.

Tuesday, May 16, 2006

audio on demand

Implementing audio on demand or podcasting - made a template page by hand - PB is now on the job to generate the page from our local SGH database with php...

Monday, May 15, 2006

dynamic dns

In addition to the usual work of making playlists, recording from MD etc, today C from WS rang up - configuring the playout server to use an ADSL line with dynamic IP.

Using a free domain from changeip.com, wrote a one line script to do the dns updates:


wget "https://www.changeip.com/update.asp?u=$USERNAME&p=$PASSWORD&cmd=update&set=1&offline=0"


Using http didn't work - it was being set to the ISP's proxy IP. Thankfully https worked. Put it in the cron to run hourly.

Thursday, May 11, 2006

quick and dirty DVD writing

found that there was NeroVision Express already on my system, using which I could drag and drop some 640 x 480 mpg files from dig cam and make a DVD....

AVICodec

Used Avicodec from http://avicodec.duby.info on BKM's recommendation - quite good, supports a wide variety of formats, gives info about the file + codec used + resolution etc

Tuesday, May 09, 2006

adventures with fsck

Copying files with "Roxio Restore" on XP - system hangs if any other app tries to access DVD drive. And left a corrupted file on /dev/hda1 - /mnt/WinF, ext3.

On boot in Linux, "check forced" "try manual fsck" at some point, and it was taking a looooong time - thought it hung. So, booted with Mandrake CD1, "rescue" at boot prompt, got a shell, mounted the root partition, edited /etc/fstab to comment out mounting /dev/hda1, deleted the corrupted files, booted normally. Then man fsck, gave

fsck -t ext3 /dev/hda1

The filesytem still had errors.

Corrected the errors when it asked, finished in around 15 minutes or less. Phew!

experiments with download service

On May 4th, did some experiments with download service - asp pages which will pop up download dialogs and cloak the actual filenames instead of directly serving the mp3 file with an http request. Also, capable of serving up multiple files by popping up multiple dialogs! Based on the ASP101 script at http://www.asp101.com/articles/jason/filedownloadlist/default.asp

Have to think of how much to automate - asp pages being generated by php querying our local database - how much to leave manual...

The dark side of google

Some of the disadvantages of Google Adsense - a bad experience narrated at http://business.timesonline.co.uk/article/0,,13129-2123601,00.html

Monday, May 08, 2006

link checking sw

Tried out various link checking sw for finding broken links quickly and easily.

http://www.dead-links.com/ was using HTTP HEAD , so was getting FORBIDDEN responses for most of our htm pages - issue with IIS not giving 200 response for anything other than .asp or .html or something like that....


http://validator.w3.org/checklink
had the same problem.

JCheckLinks - I couldn't get it to work due to my lack of Java app installing experience.

Linklint - appeared too complex!

http://www.unixdaemon.net/delicious_checker.html - meant for Del.icio.us links specifically, and needs certain PERL modules....

Finally ended up using Xenu's Link Sleuth - relatively fast and uncluttered, on Windows (Sathya). Of course, radiosai.org has more broken links in PA and Journals which I have no intention to correct now, so have to choose preferences carefully...

PB's contrib - Phplist auto date subject and message

Added date placeholder in subject /admin/sendemaillib

$cached[$messageid]["subject"] = $message["subject"];
if($cached[$messageid]["subject"]== "(no subject)")
{
$system_date_now = date("dS F Y");
$cached[$messageid]["subject"] = "Sai Inspires - " .
$system_date_now ." from Prashanti Nilayam";
}

Now, though the mail is created and sent as "no subject", the users get the mail with subject Sai Inspires - 04th May 2006 from Prashanti Nilayam and so on.

Update on Date: 21/05/2006 8:38 am:
Changed the date placeholder in subject and message ( in file
/admin/sendemaillib)

Replaced the function date("dS F Y") with date("jS F Y")

d Day of the month, 2 digits with leading zeros01 to 31
jDay of the month without leading zeros1 to 31
Replaced the format output from
Sai Inspires - 07th May 2006 from Prashanti Nilayam
to
Sai Inspires - 7th May 2006 from Prashanti Nilayam

PB's contrib - making processqueue cron work

Did the following to set the cron to work for phplist processqueue...

To check the error messages in cron piped the message to log.txt
31 17 * * * /home/apachemails/phplist -pprocessqueue > log.txt

Got the following message:
[apachemails@krishna ~]$ cat log.txt
PHPlist version 2.10.2 (c) 2000-2006 Tincan Ltd, http://www.phplist.com

Error: USER environment variable is not defined, cannot do access check.
Please make sure USER is defined.

>From google got the following solution:
http://www.tequilafish.com/2005/11/17/phplist-with-crontab-user-environment-variable-is-not-defined/

This happens because when a crontab executes, the *$USER* variable is not
set. We must set it in our script. So open up the phplist file and add the
following:
USER=youusername
export USER

The entire file should now look like this:
CONFIG=/path/to/phplist/config/config.php
export CONFIG

USER=yourusername
export USER

/path/to/php /home/yourusername/path/to/phplist/admin/index.php $*

Note that you also must set the *$commandline_users* variable in your *
config/config.php*:
$commandline_users = array("yourusername");

With all of that in place, you can automate your queue and bounce processing
with a crontab like this (adjust your paths accordingly):
# Suppress crontab emails
MAILTO=""

# Process phplist queue daily, every half hour
0,30 * * * * /home/yourusername/phplist -pprocessqueue

# Process phplist bounces once a day, 5am
0 5 * * * /home/yourusername/phplist -pprocessbounces
In our case:
USER=apachemails
export USER

now the cron works fine :)

Wednesday, May 03, 2006

out of station!

All these days I was out of station, so no posts for a month! Anyway now I'll start with PB's description of how he got PhpList working.... after finishing more urgent work.

Friday, April 07, 2006

Watching ads

Watching the ads google is serving up - quite interesting - the way in which Google sends the ads based on context...

Google Adsense - automated replies

To get started on this site, I'd filled in the form linked from Blogger.com. First rejected because I used an initial instead of surname, then because there was the counter link to webstats4u ... (and maybe the links to http://www.avamail.com/faq.shtml and http://www.scambusters.ws/ too) After removing them and replying to the mail, which looked suspiciously machine generated, got a confirmation. And when I replied saying thanks, I got confirmation that it's an automated system and not "Leo" -

Hi,

Thanks for responding. I'm glad I was able to help you with your AdSense
application.

For additional questions, we suggest you visit our AdSense Support site at
https://www.google.com/support/adsense . If you're unable to find an
answer to your question on our site, please feel free to reply to this
email.

Sincerely,

Leo
The Google AdSense Team

Saturday, April 01, 2006

Busy days

Somewhat busy, with less time at the comp, so fewer posts. But many things have been going on, which I'll post retrospectively.

Schedule is: get up at 5, bathe wash etc till 6, then either read or write or grab 40 winks and eat an apple for breakfast till 6.30. Then in Mandir till 9.45-10. Similarly in the evenings 2.30 to 6. Because KVR is out of station and I'm moral support for KBR managing the PA.

The heat is exhausting. Getting just 3 hours at SSSST to do all the day's Radio Sai work is very limiting, too.

The most recent new development is the Acer Laptop - Travelmate 2420 series, Widescreen 14 inch TFT, Celeron 1.5 GHz with 512 MB RAM and 40 GB HDD. Using it to record stuff in Mandir, recording onto the portable 2.5 inch external USB HDD using the Extigy as source.

The other development was the spending of several hours with PB setting up PhpList for their Sai Inspires emails. Quite involved. And does not really behave linearly during testing. Bounce testing etc was quite chancy and frustrating - works sometimes and not sometimes. Posted some of the observed behaviour on Phplist forum too. Hopefully in real world conditions it will work properly... Since they want to send very fancy emails with photos embedded, each of their messages is made as a separate template in PhpList.

Saturday, March 25, 2006

blogger by email

Since blogger post gateway doesn't accept emails with jpg attachements, not too useful for Sai Inspires.

If it was just ignoring the jpgs it would have been OK, but it actually bounces, with "post failed". Of course, the text-only option is available with phplist...

Testing mail2blog - only attached html, no text in mail.

Dear Reader,
 
Loving Sairam from the Heart2Heart Team.
 
How important is gratitude? You will know that when you read Swami's message today.


Did you read
"The Most Precious Gift...
the Avatar's Time
"?


Click here to read now
.

 

Sai Inspires - 25th March 2006

Image

 

Always be grateful, even for a small help.  Do not be ungrateful;  ingratitude is utter cruelty.  Any help received should be reciprocated to the extent possible.  Hurting someone who has helped you will result in your losing your eyesight.  It is only through the radiance of the sun that you see things, and the sun withdraws its radiance from those who commit the sin of ingratitude.  This is the suffering that an ungrateful person has to undergo.  Therefore, we should always be grateful and return help for help, to the utmost extent possible.

-  Divine Discourse, 6th May 2002.

First and foremost, you should show gratitude to your parents, love them and respect them. - Baba

Tell a Friend about Sai Inspires


With Love and Regards,
"Heart2Heart"
RadioSai's e-Journal Team,
In Sai Service.
 
To see the complete schedule of today's RadioSai programmes, click here.
Visit us at www.radiosai.org to know more about RadioSai and our e-Journal "Heart 2 Heart".


Quick Links:
 
1. Subscribe to Sai Inspires here, to unsubscribe mail us at h2h@radiosai.org.
2. For ‘Thought for the Day’ as written in Prasanthi Nilayam today, Click here.
3. ‘Heart to Heart’, our monthly e-journal : Read, Download pdf, see Archives.
5. Listen to RadioSai here.

Tuesday, March 21, 2006

post about printing on dot matrix

I'd posted this on the PCQuest forum:
http://forums.pcquest.com/forum/viewtopic.php?t=3459
Recently I had the need to print some stuff with a dot matrix printer (TVS MSP 345) which happens to be "Epson compatible". I wanted to print with the built-in fonts, which are clearer and also print faster. So, I first prepared my pages with a text editor (kwrite) with proper formatting and then applied the extra binary formatting with a hex editor (khexedit). This basically consisted of adding the required control codes (like compressed mode, emphasise text, etc) at the relevant places.

Notes:
1. The printer took 8 spaces for tabs, had to adjust the text editor accordingly.
2. I'd set the default printer to a "Raw/No driver" printer driver in cups. Probably this is not necessary.
3. My print command was cat filename.txt > /dev/lp0 - I had to do this as root, there may be better ways to do this.
4. Epson codes were obtained after googling, from http://webpages.charter.net/dperr/links/esc_p83.htm
A note about these codes is that you need to send the ESC character for some of them, and not for others. For example, for form feed you just need to send 0c (HEX) while for select condensed mode you need to send 1b 0f (HEX).

money making schemes

Sometime I've got to bust some money making schemes - like these..
http://www.avamail.com/faq.shtml and
http://www.scambusters.ws/
Probably some sort of review of such things will be useful for folks. Save them from wasing time and money. Just in case they really work also!

Edit: removed the links since they are "undesirable neighbourhoods" and may cause Google adsense to boycott me!

Sunday, March 19, 2006

added MX records

Added MX records for saispace and krishna, both pointing to krishna, with Plesk.

corrections to postfix config

My earlier postfix post omitted another correction I had to make from the linuxquestions link: the virtual file needs the domain name first, then followed by mail ids relating to that domain. Eg
/etc/postfix/virtual:
virtual.domain anything (right-hand content does not matter)
postmaster@virtual.domain postmaster
user1@virtual.domain address1
user2@virtual.domain address2, address3


And with the configuration accepting local mails, it was creating some sort of problem with local addresses lookup. So, commented out the
mydestination = $myhostname, localhost.$mydomain, localhost
line. It still accepts mails from localhost for local accounts. Then added the actual hostname to the virtual domains, with stuff like mails to apache etc being sent to me!

Saturday, March 18, 2006

finishing the postfix configuration

In an earlier post I'd written about the postfix configurations for virtual domain-based forwarding. Actual implementation had a few extra steps - needing some googling to remove two errors caught with
tail -f /var/log/mail/errors

One more mystery solved was why nmap was showing port 25 as closed - postfix was listening only on the loopback interface - localhost.
inet_interfaces = all
solved that.

First I thought just copying the main.cf from the older server was the reason. But even replacing it with the main.cf.dist with appropriate modifications didn't solve the problem.

The first one was
 fatal: connect #11 to subsystem private/proxymap: Connection refused

and the other, later, was
 fatal: connect #11 to subsystem private/scache: Connection refused

Deleting the proxymap socket (present in /var/spool/postfix/private ) only changed the error to file not found.
mksock gave file not found - the mksock util was not in the system at least with that name...
Finally adding

proxy_read_maps = $local_recipient_maps
local_recipient_maps = unix:passwd.byname

removed the first error and gave the second one. This one was finally removed by later adding
smtp_connection_cache_on_demand = no
One more thing I'd overlooked was the differing postfix versions needing different commands to update the alias database and the virtual database. This is actually mentioned in the small text at the bottom of the linuxquestions link in small print. Anyway, for the record, they are
postalias /etc/postfix/aliases
and
postmap /etc/postfix/virtual
respectively...

Friday, March 17, 2006

two ways of going back in time

One is the wayback machine for seeing older websites and the other is www.oldversion.com for downloading older versions of software.

Thursday, March 16, 2006

blog with access control or email grabbing scam?

Interesting site submitted by A, will have to see if it is legit. Collaboration featues including access control.

Update: It's legit all right - Google has taken it over and registration is temporarily down!

Tuesday, March 14, 2006

local processing of AWStats history files

As I'd mentioned in an earlier post, I wanted to generate static reports with AWStats with its history files generated elsewhere. Finally found the solution by reading the perl source code - the program actually prints out the options if none are supplied at command line! Simply add -month=MM -year=YYYY ...

block jpg in pop3

Now the requirement is to block certain mime types ... will fetchmail do it? Have to check up.

Monday, March 13, 2006

procedure for saicast update - uploading the video file

1. Upload the video files to saicast - Mediaroot - SaiCast - OnDemand

2. Open the video in gmplayer, pause at appropriate place(s), take snapshot(s) with ksnapshot, attach in mail and send to Prof G for him to update, including the mms://urlofvideo.wmv

procedure for saicast update - creating the video file

1. Video source either as mpg (VideoCD) or MiniDV

  • VideoCD source grab to hard disk as .mpg file using VCDGear
  • MiniDV cappture to hard disk, now firewire is available, so Premiere can be used.
  • Composite RCA connector capture also possible with VirtualDub.

2. Add www.radiosai.org logo with VirtualDub

  • Use the resize filter with Bicubic option to get final size 320x240 with cropping as desired
  • Use the logo filter for the watermark, with WHITE.BMP as the logo image and "Use alpha channel from another image", logoMASK.bmp
  • Use Video->Compression Huffyuv codec before saving avi.

3. Use the saved profile 350_100_20 with Windows Media Encoder to convert avi to wmv - DO NOT overwrite this file! Choose CANCEL if it asks if you want to save this file at the end!

4. Edit the saved append.bat files appropriately and add begin and end segments to the video using wmvappend.exe.
In case adding the 350_100_20 begin and end files crashes, use separate files for 350, 100 and 20 kbs as given in next step. Ensure profiles match for files being appended!

5. Split the multi-audience file into separate 350, 100 and 20 kbs files using Windows Media Stream Editor.

6. Add appropriate metadata with Windows Media File Editor, in the same format as previous files.

Best Freeware Lists

More good stuff from digg - These two lists would be quite useful. Esp right now the firewall and Image stitcher are relevant...

Saturday, March 11, 2006

Making 16 hours of video into 1 DVD of DivX with FairUseWizard

Specific instructions for making 16 hours of video into 1 DVD of DivX

1. Choose encoding speed ESS in the bottom drop down in the first page
2. In the page after choosing the specific chain to encode,
(a) Adjust cropping if required using AutoSet on a frame which has no dark parts near the edges
(b) Check "include subpictures" and choose appropriate language for subtitles
(c) If required, crop the end credits by scrolling to the end of the part and clicking "Set credits start"

3. Use auto detect in the next page to choose the proper interlacing settings

4. In the final page,
(a) Check "Two pass" - better quality
(b) Move the Encoding speed slider 75% to the right for quality
(c) Choose size as 175 MB if you have 24 parts - 175 x 24 = 4200, enough space to spare for small extras etc
This is equivalent to approx 700 kBitsps which will be shown in brackets below.
(d) Choose the largest video resolution which is available after "Show only preferred resolutions" is checked.
(e) Defer processing (enqueue) if you want to run a batch job with many files.
(f) Defer even project processing if you want to run multiple projects as batch with iso files as sources for some of them.

added caching nameserver

Installed the caching nameserver rpm, which installed bind as a dependency on saispace2, leading to much faster browsing response in general.

Friday, March 10, 2006

NAT on Linux instead

Trying out the stuff in the previous post...

RR's Windows machine has some problems with the "Routing and Remote Access" - it seems to automatically change from Red to Green, and when Red, says "Don't have permissions to access" even as admin - some misconfig or virus or what?

Also, the example firewall was not allowing outgoing connects from the proxy thru the external interface. In retrospect, probably I should've created a rule mentioning the external ip address, and allowing all outgoing. Just and allowing all protocols and all ports did not work, since it was just the reverse of the rule saying all IP traffic Block.

So, doing the NATing for POP on the Linux proxy, adding to /etc/sysconfig/iptables

*nat
:OUTPUT ACCEPT [0:0]
:PREROUTING ACCEPT [0:0]
:POSTROUTING ACCEPT [0:0]
-A POSTROUTING -s 192.168.x.z -o eth1 -j MASQUERADE
-A POSTROUTING -s 192.168.x.y -o eth1 -j MASQUERADE

and needs

echo "1" > /proc/sys/net/ipv4/ip_forward

of course...

Thursday, March 09, 2006

AWStats older stats

Nettigritty just saves the older AWStats database txt files - doesn't save the html reports. Trying to generate reports locally ... following this onlamp tutorial. But the documentation and the FAQ are lacking in direct info on how to do what I want - convert the AWStats txt database into monthly reports...

Update: Read the code, dude - found the simple solution there...

Wednesday, March 08, 2006

Why the 500 GB drive didn't install on the PowerMac G5

Google saved the day with this report in xlr8yourmac.com


Notes on Seagate 7200.9/500GB drive P/Ns with SSC disabled
- (from a drive db report)

" In the course of researching a hard drive purchase, I got the following information from Seagate presales support:

"All Seagate 7200.9 SATA drives with the Part Numbers that end in the suffix -301 have SSC enabled and are not compatible with the Apple controllers. (as mentioned previously here - SSC (Spread Spectrum Clocking) is not compatible with the Mac onboard SATA. Seagate also has a PC/windows utility to disable this but not a Mac version of it.-Mike)

All other suffixes other than -301 on the Part Numbers are compatible ( -302, -303,-401, -402 etc).

Here is a list of part number with SSC disabled for ST3500641AS:
9BD148-302
9BD148-303
9BD148-401"

Tuesday, March 07, 2006

checking out zoneedit.com

Tried out (with a login as webmaster at rs ) zoneedit.com for forwarding sssihl.edu.in emails. But zoneedit also needs their dns servers to be made authoritative before the domain becomes live...

Monday, March 06, 2006

how to use ipsec "firewall" on Win2K

More stuff to check out - this article is pretty detailed...

This one has a downloadable registry file...

All this is if natting is enabled, as given in microsoft's site...

Sunday, March 05, 2006

Six headed Linux machine

Nice idea - using extra graphics cards and USB kb/mice - article via digg.

using krishna to forward mails to sssihl

Reading http://wiki.linuxquestions.org/wiki/Mail_forwarding_domains
seeing if krishna can be used for the sssihl mail forwarding...

Changes to main.cf:

1. #inet_interfaces = $myhostname, localhost
2. the changes as given in the wiki page above, ie.

1 /etc/postfix/main.cf:
2 virtual_alias_domains = example.com ...other hosted domains...
3 virtual_alias_maps = hash:/etc/postfix/virtual
4
5 /etc/postfix/virtual:
6 postmaster@example.com postmaster
7 joe@example.com joe@somewhere
8 jane@example.com jane@somewhere-else
9 # Uncomment entry below to implement a catch-all address

10 # @example.com jim@yet-another-site 11 ...virtual aliases for more domains...


3. Opening port 25 on krishna's firewall

Wednesday, March 01, 2006

strip CRLF

Had to strip CRLF (or maybe just CR or LF - whatever) from PB's contribution because Blogger was changing all of them to <BR> tags! and even in the edit mode was not showing them as <BR> tags! Sometime I've to check out the methods given in the post I got by googling: a comp.os.linux.misc thread.

Learning ASP

For the last few days, I'm carrying around "Sams Teach Yourself ASP 3.0 in 21 days". Things to note:

<%= %> is shortcut for Response.Write

Default language is VBScript, tho JScript and even Python are supported....

Very useful set of VBScript built-in functions, esp for string processing and date processing.

Saturday, February 25, 2006

SERVER UPGRADE - LOG (Feb 2006) - from PB


*********contributed by PB**********************

krishna.radiosai.org (REDHAT 9) to krishna.radiosai.org (MANDRIVA 2006)

Why the shift?

Required new versions of mysql and php to implement the mail list (Phplist) to work.

Possible solutions:

1. Upgrade the mysql and php on the old server.

This had upgrade problems on the old server

2. Configure a new server and forward the request to the page through url redirect.

This was best if the directed url was a public ip.

3. Configure a new server and forward the request to the page through reverse proxy.

This had problems in installing mod_proxy_html on the old server. It rewrites HTML links into a proxy's address space i.e. href pointing to ./files would resolve to http://proxy_address/files.

4. Upgrade the server.

Finally choose to upgrade.

Major Changes:


Old Server
New Server
mysql-server-3.23.54a-11.i386.rpm
mysql-4.1.12-3mdk
php-4.2.2-17.i386.rpmapache-mod_php-2.0.54_5.0.4-4mdk
httpd-2.0.40-21.i386.rpm apache-conf-2.0.54-12mdk
postfix-1.1.11-11.i386.rpm postfix-2.2.5-7mdk
vsftpd-1.1.3-8.i386.rpmvsftpd-2.0.3-1mdk

Installation Steps:

Got a system having the same hardware configuration as the old one (except the display and ethernet cards)

Chose Mandriva 2006 DVD installation

Partitioned the drive (80GB Drive)

filesystem Mounted On Size
/dev/hda1 / 3.7 GB
/dev/hda3 /var 9.2 GB
/dev/hda4 /usr 9.2 GB
/dev/hda6 /tmp 942 MB
/dev/hda7 /home 50 GB

After partition, installation asks "You have the option to copy the contents of dvd to the hard drive before installation. It will then continue from the hard drive and the packages will remain available once the system is fully installed." (Check - copy the whole DVD checkbox)

After installation of required packages, added few other packages that were not in the DVD.

vsftpd-2.0.3-1mdk.i586.rpm (ftp server that supports virtual users) db3-utils-3.3.11-19mdk.i586.rpm (required for vsftpd password generation) libdb3.3-3.3.11-19mdk.i586.rpm (required for db3-utils)
mysql-administrator-1.1.6-linux-i386.tar.gz phplist-2.10.2 (Mailing list server) lame (required for automatic mp3 encoding) librrd (required for shoutstats)


Did a Mandriva update through the Mandriva Control Center (command: mcc)

Transferred required files from the old server


sgh, office, root, webroot
.ssh folders
crontabs (root and sgh)
postfix configuration files (needed slight modificaiton to point correct installation path)
dump of database records from the old server
firewall iptables configuration files
vsftpd (copy all the required files) db3-utils was required here.
icecast server files

Configured the mysql databases through mysql-administration (/root/mysql-administration/bin/mysql-administration)

Restored the dump of database records from the old server.

Ran Nessus to check for security holes. Fixed the following:

ServerTokens Prod (/etc/httpd/conf/httpd.conf) uninstalled mailman

Changed the hardisk in the old server to the new one.

Configured the network.

Enabled ipv4 packet forwarding using the Mandrake Control Center (cmd: mcc) Network Sharing.
This enables ip masquerading. The file /proc/sys/net/ipv4/ip_forward should be set to 1 for this to happen.

Uninstalled shorewall (mandrake firewall)


Restarted network and iptables

Installed nmap and ethereal

Stopped/started services on boot (through Mandrake Control Center).


Present disk stats


Mounted On Size Free
/ 3.7 GB 3.2 GB
/var 9.2 GB 6.6 GB
/usr 9.2 GB 6.6 GB
/tmp 942 MB 878 MB
/home 50 GB 31 GB

Things to do:

Phplist (already running) to be customized, fine tuned and tested.
Take backup of files ( towrite24kbps to cds)
Write scripts to show the disk stats and database backup
Check for updates monthly (security updates, bug fixes, normal updates)
Clear hardisk regularly (office/sgh)
Automate the start of icecast on boot.
Install nessus

Things to remember:

Icecast location - /usr/local/icecast/bin/icecastmysql-administration location - /root/mysql-administrator/bin/mysql-administrator (admin passwd is same as su) Download files location(rpms,tgz,source files) - /root/Download

*********contributed by PB**********************

Wednesday, February 22, 2006

Bounty!

Yet another problem with running an only Linux shop - Transcend Jetflash mem sticks. Don't mount on Linux due to some sort of super-floppy partition, it seems. This problem has been around for quite a few years now. Anybody ready to fix it? I can give a 128 MB Transcend Jetflash mem stick + equivalent amount in cash as bounty!

Monday, February 20, 2006

backup script

Made some simple backup scripts for the Postgres database with

pg_dump sgh > sghdbdump

and an sftp script in cron to copy it to krishna.

The dump file is plain text and currently around 50 MB.

For some reason, the method given in this earlier post for automatic ssh login is not working for another account in krishna. I wonder why. Somewhere some typo or something?

Saturday, February 18, 2006

sssihl.edu.in mail problem solved

It was because of external hosting, I suppose - mailboxes were not working, but forwarding works fine. So, most probably, that will be what we will do. (With reference to this post...)

places to upload

Interesting link from A - list of places to upload files like rapidshare.de - the link is
http://digital-binary-review.blogspot.com/2006/02/where-to-upload-your-files.html

Friday, February 17, 2006

mail server problems

spent a lot of time trying to configure mail for sssihl.edu.in with 1and1.com - the user interface is somewhat restrictive. Have configured the mx record to point to the records given by
host -t MX sssihl.edu.in ns41.1and1.com

(also host -a sssihl.edu.in ns41.1and1.com)

so the mail servers are mx00.1and1.com and mx01. Pointing from Plesk to these mail servers, still mails to the account I created are bouncing with 550 won't relay to xxxxx@sssihl.edu.in

Maybe the mail servers need time?

Software KM switch?

PB sent me this nice link to Synergy - To share a single mouse and keyboard between multiple computers with different operating systems. May have been useful in the days of working on Dharma and Saispace, but now with Saispace2 most of the time, not so relevant to me. But interesting concept.

PB is changing over krishna.radiosai.org to a new machine, migration work going on. Checked the new one with Nessus yesterday.

Tuesday, February 14, 2006

LiveSupport

Interesting link sent in by PB - LiveSupport.

Runs a radio station in a way similar to ours, but with the SW running on the playout server also. Searches etc are based on mp3 metadata in the files.

Monday, February 13, 2006

AutoGK's niche

Finally AutoGK finds its niche - where there are read errors, tho DVDDecrypter can make iso files, FairUse Wizard hangs at the point where there are CRC errors. AutoGK carries on just fine, using the IFO mode and extracting to VOB files with DVDDecrypter.

Saturday, February 11, 2006

Podcast solution with asp?

This script seems a good solution for audio on demand with downloading instead of streaming.

Fair Use Wizard seems to have a bug? Split Chapters

Fair Use Wizard seems to have a bug: a DVD with a single program chain of duration 2:08 with three chapters of roughly 40 minutes each, when ripped with the option 'Split chapters' and total filesize 540 MB, gave 2 files of 180 MB and one of 70 MB, and also the 3 files were of 37 minutes duration! Doing the rip without the 'Split chapters' option => proper file, no more problems.

Friday, February 10, 2006

Fair Use Wiz timing

Seeing its logs, Fair Use Wizard has taken roughly 1.5 times real time for approx 700 kbits per sec video encoding with the internal XvidD codec. From ISO file. The indexing was done earlier, approx 5 min per 2 hour DVD.

Thursday, February 09, 2006

http://www.drs2006.com/manuals/faq/plsasx.html gives info about pls and asx files in one place. But the pls files' titles are still not being reflected on Xmms, and the filenames are being shown. Probably since Xmms doesn't support Version 2 pls files? Maybe I have to tweak the server settings to not show the filenames?

Server being a relay automatically shows the origin server's title setting. If it is not a relay? Have to try out and see locally.

asx files working with shoutcast

Finally! asx playlists for shoutcast on demand files are working even for mp3s with spaces in filename.

The actual problem was not that the filename had spaces in it, but WMplayer can't play mp3s of size below 4 seconds! Tests with larger files are working.

Tuesday, February 07, 2006

added counter

Added a counter to this, from Webstats4U

for printing mails

Or in general for exporting mails from KMail - make a folder, make it an mbox folder, copy the required mails to it. If the folder is made in the top level, it is seen directly in ~/.Mail

Eudora can open the mbox file directly as it is its native format - just copy it to Eudora's Mail folder.

Or use MHonArc to convert to html first.

Just an aside - tho these posts only talk about the exciting stuff, most of the time is spent in audio processing, making playlists etc...

Monday, February 06, 2006

changed line in /etc/sysconfig/clock (in Mandrake 10) to read

UTC=false

so that the clock shows correct time in IST in XP (dual boot) also.

easier way to make Windows Media Player play shoutcast streams

In case you can host your own files and just need to point those with Windows Media players to a shoutcast stream, making an asx file works:

and the syntax of the asx file is simply



<asx version="3.0">
<entry>
<ref href="http://stream.radiosai.org:8000/">
</entry>
</asx>



Unfortunately I've lost the link which showed multiple files.
Now when I try these asx files with links to files
(Shoutcast streaming on demand)
it works with filenames with no spaces,
but not for filenames with spaces...

Thursday, February 02, 2006

Experimenting with audio on demand

Both Shoutcast and Icecast do audio on demand. Shoutcast even makes a pls file on the fly. But we would like to have our own pls files, with more than one file in the playlist, since we would like to have the announcement and then the programme. Following the pls file format,
[playlist]
NumberOfEntries=2
File1=http://stream.radiosai.org:8000/content/file1.mp3
File2=http://stream.radiosai.org:8000/content/file2.mp3

Is working. But content has to be a folder, can't be a shortcut. What about soft links and hard links? Googling
found this google answer
and searching sysinternals got junction


And that works!

Does not allow downloading using right-click and save-as with browsers, either.

But playing in Windows Media Player? Googling
gave this nice link.

But it has two problems: Plays only the first file for files without spaces in them, (of course, that's what it's coded for!) and doesn't play files with spaces (%20) in them since WMP converts the %20 to spaces!

Tried from command-line with
wmplayer "filename with spaces.mp3"
wmplayer "filename%20with%20spaces.mp3"
wmplayer filenamewithoutspaces.mp3
wmplayer "filenamewithoutspaces.mp3"

Only the last two work.

Wednesday, February 01, 2006

Provisional requirements for Web Schedule display

1. Display earlier days' schedule using clickable calendar - so, having a MySQL backend instead of the current Access mdb file makes sense - otherwise the mdb file will become bigger and bigger...
2. Update with an uploadable csv file, automagically delete entries older than a month old (if necessary).
3. Look and feel of current site, but tables could look better.


Other fancy ideas
1. Linking to audio on demand?? Ideas on implementing??
2. Automagically linking to relevant Prasanthi Bulletin page
3. Better way of presenting the categories than the current method?
4. Does the BBC look good?

Hyperscore

Wired News has an interesting story about Hyperscore - interesting midi creation tool. Free version can make songs 30 sec long for use as ringtones etc. Of course, when we have Yamahas and Korgs with midi cables and skilled players, why bother....