Thursday, June 16, 2011

importing SGH M CDs into local database

Found that only upto SGH M 244 has been imported into SGH database. PB reported that after shifting to the Dell servers, the script that imports the cd into the database failed as it had some gui components in it and not just command line. Checking the code, found the following and modified:

1. The script mount_cd.sh had a call to the binary message
which basically just displays a message to insert the cd. I have made this into an echo statement.

2. After that, main.sh had a call to the binary question

That also I turned into an echo statement.

3. Next, check_if_all_mp3.sh called the binary error
That also I changed to a simple echo statement. Then a call to question, which I turned to echo and read.

4. Next call to error and question come from main.sh which I again changed to echo and read.

5, Next came check_if_cd_entered.sh which had calls to error which I changed to echo.

6. Next, check_bc_entry.sh had a call to broadcastcenter, but it had already been commented out.

Importing worked after this.

Tuesday, June 14, 2011

colinux instabilities and D drive

There were some issues with our streams skipping files, and the problem seemed to be on the filesystem of stream.radiosai.org. Stopping the webserver on stream.radiosai.org which referenced files on the D drive seemed to solve the issue. PB did some research, and said the following:

Yes, the issue could be the windows file system size or its way of dealing with long file names. But the failure in reading might even be due to Colinux. Windows has never complained in sending the data to Colinux but CoLinux always complains in not able to read the data. The Colinux change log does mention about I/O errors.


Was going through this link on Working with File Systems which says:

If you use a large number of files in an NTFS folder (300,000 or more), disable short-file name generation, especially if the first six characters of the long file names are similar.

Every time you create a file with a long file name, NTFS creates a second file entry that has a similar 8.3 short file name. A file with an 8.3 short file name has a file name containing 1 to 8 characters and a file name extension containing 1 to 3 characters. The file name and file name extension are separated by a period.

If you have a large number of files (300,000 or more) in a folder, and the files have long file names with the same initial characters, the time required to create the files increases. The increase occurs because NTFS bases the short file name on the first six characters of the long file name. In folders with more than 300,000 files, the short file names start to conflict after NTFS uses all the 8.3 names that are similar to the long file names. Repeated conflicts between a generated short file name and existing short file names cause NTFS to regenerate the short file name from 6 to 8 times.

To reduce the time required to create files, use the fsutil behavior set disable8dot3 command to disable the creation of 8.3 short file names. (You must restart your computer for this setting to take effect.) For more information about disabling 8.3 short file names, see “MS-DOS-Readable File Names on NTFS Volumes” later in this chapter.

If you want NTFS to generate 8.3 names, improve performance by using a naming scheme in which long file names differ at the beginning of the name instead of at the end.


But again, disabling 8.3 filenames systemwide seemed a bit drastic, and could lead to other unexpected problems elsewhere. So, for now we have not done the disabling.

wifi radios for radiosai

Since WorldSpace broadcasting stopped, a lot of queries about ways to listen without a computer. Found that wifi radios are quite cheap in US and UK, but almost double the price in India.

This one, for eg. is around Rs. 4.5k in the UK while in India, the listings start from 10k. Other cheaper options in India other than mobile phones are products like this Asus box for around 6k. What you have to look for in products which allow you to listen to Internet radio stations is: do they allow you to enter custom stations - if yes, then you are safe. Otherwise, do they use the Reciva online database - if yes, then also it is safe, since Sai Global Harmony all streams are listed in Reciva. If the player uses a custom database and does not allow you to enter your own stations, then you may not be able to listen to SGH with such a player.

Monday, June 13, 2011

buffering on server

Was listening to radiosai on my mobile today with wifi for long periods while lying on bed, made the following interesting observations.

1. The changeover actually happened at around 6.32 as heard on the stream, but the shoutcast server went into the interruption music for more than ten minutes more, till the signature tune finally came, around 6.44. Meaning the stream is buffered by 14 minutes due to the two servers?

2. By afternoon, the delay was around 7 minutes - The dd which was supposed to get over at 2.41 was heard to end at 2.48. So somehow the buffering delay was reduced ?!

Friday, June 10, 2011

BSNL online directory enquiry

BSNL online directory enquiry has become centralized, has changed location and needs City to be entered. For Puttaparthi, City needs to be Penukonda. Not too intuitive!

Wednesday, June 08, 2011

adjustments for mirrordome

We had some minor adjustments done to improve the looks of our fulldome projection.

  • Moving the mirror up by a few inches more now allows us to bring the horizon a bit lower in the front area of the tilted dome of the theatre.

  • Moving the projector laterally left-right corrected the tilt in the reflected image, where earlier the left side of the reflected image was around a foot higher than the right side - for this, we moved the projector physically to the right.

  • Moving the projector towards and away from the mirror, and adjusting the zoom setting allowed us to reduce the shadow area right above the mirror. Covering a larger area on the mirror makes the shadow smaller and vice-versa.

  • Using the Bright mode instead of Custom mode in the projector, the colours are a bit better though the brightness levels are quite lower. This has to be further tuned.

Wednesday, June 01, 2011

couple of queries of email migration

Today, V had a question: if he deletes a group in Google Apps, will it take 5 days for him to create a user id with the same name. It turns out the answer is no.

http://www.google.com/support/forum/p/Google+Apps/thread?tid=31213ea23239c903&hl=en

When you delete the group, you should be able to recreate a user of the same name immediately. The 5 day wait period only occurs when you delete a user and try to recreate a user of the same name. Deleting a group or email alias does not lock out that address for 5 days like it does when deleting a user.
Also, Google Apps seemed to have removed the online IMAP migration tool from within the Domain control panel. So the email migration has to be done using the Google Apps Migration for Microsoft Exchange utility .

Once you install it, the setup is like the screenshot for migration from gmail:



In case it asks you for changing the consumer key, you have to log in to google apps as webmaster and copy-paste the new key.

The users csv file should be of the form
user1@domain.in#user1password_of_domain.in, google_apps_user1

(Please note that the @google.apps.domain is not required for the second field.)

Unfortunately, this tool takes a lot of bandwidth, needs the computer to be on all the time it runs, and is much slower for gmail to gapps migrations than the online IMAP migration tool. A sample run is:

Info:Start local time is: 2011:06:01 13:56:12
Info:Migration start local time is: 2011:06:01 13:56:12
Start: Now migrating user=**********
Start: Migrating Email for store=**********
Start: Migrating 105 messages from Folder [Gmail]/All Mail for store=**********
In progress: Migrated 100 out of 105 messages from folder [Gmail]/All Mail for user.
Success: Migrated 105 messages from folder [Gmail]/All Mail for store=

snip....

Info:Migration end local time is: 2011:06:01 14:25:19
Info:End local time is: 2011:06:01 14:25:19

So it took half an hour for 100 mails.

upload problems persist

As noted at the end of this previous post, upload problems persist with sftp. When using GUI tools like filezilla and gftp, we can see that sometimes the server drops the connection, then the tool reconnects and resumes the upload. filezilla is much faster than gftp, but has support for key-based auth under Settings only in later versions which are not available for the particular OS on saiwaves. Runs OK on WinXP.

Sometimes, when using sftp and it stalls, if we kill the process, then the file at stream.radiosai.org becomes orphaned or something like that. If we delete the file, then also the file appears in ls. After a day or two it disappears on its own - probably when the process times out or something like that.

Saturday, May 07, 2011

ftp disc quota full

There was some issue with uploading to sssorg3 ftp. Most probably it was due to over-quota.
Removed more than 5 GB of material, restarted vsftpd - now able to upload files to sssorg3.

Friday, April 29, 2011

setting up headless mac mini server

PB got a Mac Mini server for installing Apple Remote Desktop and remotely administering studio machines. But he did not get a monitor with it, and it had only HDMI and Apple mini display ports, along with HDMI to DVI-D. So, the plan was to use remote login to the server also.

Did initial installation using a borrowed Apple Cinema Display from the video studio, which had an Apple mini display port cable. Apparently Apple's "Allow Remote Management" opens up a vnc server. So, standard VNC clients can be used to connect. On Developer, installed tightvnc since it has the nice option of scaling Desktop to fit window.

Can log in with ssh or vnc. For vnc, two passwords - a vnc password, and then the user password on the server. The former similar to saiwaves, the latter similar to the router.

For using the Remote Desktop tool, I believe each client needs to have the Remote Management Enabled, under System Preferences -> Sharing.
http://www.ehow.com/how_7192487_enable-apple-remote-desktop.html

Later, registered some of the studio machines' Applecare Protection Plans: googling "Register Applecare Protection Plan" gets this registration page, where once you have an Apple Id, you only need the Applecare serial number, which is inside the product box, and the serial number of the hardware. For the Macs, this is under Apple menu -> About this Mac -> More info -> Serial number (Hardware).

Friday, April 22, 2011

Logmein possible conflict with RealPlayer

R had a funny problem - his video was not playing in full-screen mode any more. He said the only change to his system was to install Logmein. Anyway, he did a system restore to uninstall Logmein, and the full screen videos also got restored.

Wednesday, April 20, 2011

backups

Cleaned up the backup scripts on saiwaves and krishna, made them functional.
  1. Corrected db pw on the script on krishna's cron
  2. Corrected IP address on the script on saiwaves's cron
  3. Added scp with -r option to copy over the krishna backups to saiwaves.
Krishna takes around 5 minutes to do the backup with gz option. Saiwaves takes around 20 seconds to do its backup. File copying takes around the same times. SI db backup file after gz is around 1 GB. Uncompressed sgh db is around 200 MB.

Monday, April 18, 2011

problems with disc full on web server

Media.radiosai.org (and other websites on fs1 ) web services stopped - on logging in with remote desktop, found D: was full. Emptying recycle bin got 1 GB freed. Wanted to free up more (by moving and archiving old log files) after a restart.

After initiating a restart, the machine did not cleanly restart even after 20 minutes. Checking, found it was pinging. Logged in to fs1 using Computer Management console from fs3 using Action -> Connect to another computer, found that some services were running, like file sharing, but some were not, like remote desktop, IIS and so on. Checked the Eventlog - there was an extra shutdown initiation, after I had initiated the shutdown:

4:34 - I initiated shutdown.
4:39 - The process svchost.exe has initiated a shutdown etc. No title for this reason could be found. Reason code 0x80070020

this was the last entry. So, I moved out some more log files from D: to make 4 GB free, then did
shutdown /r /m \\sea-fs1 /d 1:1
(as given at this technet article)

This time it worked, after restart things seem to be working.

some graphic card drivers allow custom resolutions

Changed the desktop resolution on Developer to match the native resolution of the Viewsonic 1937 which is 1440 x 900.

Since it was not listed, I went to NVidia Control Panel -> Change Resolution -> Customize and added this resolution.

remote desktops on the mac

Microsoft Remote Desktop client is directly available for Mac, installed it. Preferences are saved using the File -> Edit a Connection setting.

For tunnelled VNC, ssh provides multiple tunnels using the -L option, with the syntax
ssh -L 10000:localhost:8080 -L 10001:localhost:8081 name@hostname.com
where 10000 and 10001 are the local ports and 8080 and 8081 the ports on the remote machine.

Checking out VNC clients, Chicken of the VNC and Chicken are recommended by many, but did not work for me, probably because they don't support the tight option? Finally opted for using the browser based client, by going to
http://localhost:58xx for display xx. For this, ports 58xx and 59xx should both be tunnelled.

Sunday, April 17, 2011

live broadcast from the Mac

CPU power is abundant on the Macbook Pro, so exploring ways of delivering live broadcast stream directly from the same machine being used for mixing. The Shoutcast DSP is available, but appears to need an input from a file - live streaming disabled? Streaming directly from Reaper is possible only on Windows, since it uses a dll file and there is no Mac port. Then found this thread of posts about BUTT (Broadcast Using This Tool) and Soundflower.


In my initial trials, I was not able to get the hang of it, how exactly to use Soundflower to route the audio to both the US-1641 hardware outs as well as the virtual out to BUTT. Trying to create an Aggregate Device as suggested in Applications -> Utilities -> Audio Midi Setup.app - found that the US-1641 cannot be aggregated with other devices due to latency and driver issues. Thought about putting a physical cable from one of the Tascam US-1641 outputs to the built-in input of the Mac, and then googled virtual cable mac audio to come across Jack OS X.

With Jack's virtual inserts, I don't even need to use up an extra physical output. Jack is configured with 16 in and 4 out, mapped to the physical interfaces on the US-1641. Reaper uses the Jack Router as audio device, everything comes in automatically in the correct tracks. Had to restart Reaper once when it was first set up, that's all. Unmapped the physical inputs from BUTT's virtual inputs so that it receives only from the Insert from Reaper.



Edit: Just some caveats:
  1. Tascam US-1641 control panel needs to have inputs 3-4 made digital outs manually every time after booting.
  2. Order of startup is important. JackPilot - Jack - Butt - Reaper - Routing window - Load Saved routing setup is the order that seems to work fine.

Friday, April 15, 2011

uploads problems hopefully solved now

My previous post about a checklist to solve the upload problems was just a stab in the dark. And turns out it did not work - even when there was no network traffic, uploads would stall and stop. Then I thought there might be some problem with DHCP server assigning IPs which are supposed to be static to random machines. Checked out the DHCP pool, that was all right.


Then, Googling found this post about MTUs. Did sudo /sbin/ifconfig eth0 mtu 1490 on our local machine. Trying an upload, still the same problem. Then tried setting mtu on Colinux with ifconfig eth0 mtu 1490 and that seemed to help Colinux.


This page has a ping test, for seeing what MTU you need, and for the Windows machine, even ping krishna.radiosai.org -f -l 1480


gave fragmentation - so thought 1400 would be a safe number.


But the Windows machine needed a reboot after setting MTU - set with regedit http://support.microsoft.com/kb/900926 for finding which id is which network adapter, http://support.microsoft.com/kb/314053 After doing this, and the reboot, made the changes on Colinux permanent by adding mtu 1400 to /etc/network/interfaces for eth0. And now things seem to be fine, with 2 minute uploads for 10 MB files.



This page has more about the possible reason for this: Path MTU discovery defeated by ICMP packet blocking, and fragmentation also being not allowed.



Edit: Unfortunately the problem persists. So, have to think about other solutions.

Thursday, April 14, 2011

using google transliterate for Hindi when not installed

Got copy-paste to work even on a machine where 'complex fonts' were not installed, using the tips given at this forum post:

This is happenning because applications such as "Google Indic Transliteration" use hindi font mangal. Though windows xp comes preinstalled with Mangal Hindi font, one need to ENABLE Hindi (asian layout) support through Control Panel to able to edit documents in Unicode Hindi font like Mangal. Legacy Hindi fonts like Krutidev do not need this configuration.
Editing a word doc using mangal font won't be possible until asian language support is configured.
You can overcome this problem through one of the following way:
1. Use WORDPAD instead of MS WORD.
2. copy hindi text from "Google Indic Transliteration" and paste it on the word doc now change the font of pasted text to "Arial Unicode MS" if you have one installed.
3. install indic from XP Control Panel -> Regional and Language Options -> Languages -> Install files for complex script and right-to-left languages (including thai). For editing you need to goto Details... and add Hindi (or other indian language) keyboard layout.

Wednesday, April 13, 2011

adding a domain to phplist

Added the top-level domain mobi to phplist as given at this post, in the admin/commonlib/lib/userlib.php file.

Tuesday, April 12, 2011

bounce processing cleanup

Once again, bounce processing had stopped on phplist. My hunch is that this happens due to mails sent at times when bounce processing is supposed to take place - if the processing fails during the batch, then the next time the spool file is left in a way that processing fails again. So, as usual, the mitigation is to do the following as root:

rm /var/mail/the_relevant_spool_file touch /var/mail/the_relevant_spool_file
chown the_relevant_account:mail /var/mail/the_relevant_spool_file
chmod 660 /var/mail/the_relevant_spool_file


Once this is done, bounces are processed - if checking is necessary, can run the commandline process if a cron scheduled bounce process is at least half an hour away.