Friday, 6 January 2012

CMS evals

I've put Joomla! and WordPress up on my home server for evaluation. I really should start using some freebie external as a muster point if my home server goes down.

Saturday, 7 November 2009

Via iGoogle

makes it a lot easier

Saturday, 17 January 2009

Netbeans

Couldn't get gwt deployed with eclipse, so trying netbeans. Couldn't add my (already-installed) tomcat to netbeans so wiped the lot - tomcat and netbeans - and started over.

Re-installation of netbeans, got same GTK reports as first attempt:


slm@fuji:/downloads/netbeans$ ./netbeans-6.5-ml-linux.sh
Configuring the installer...
Searching for JVM on the system...
Extracting installation data...
Running the installer wizard...

(:9282): Gtk-WARNING **: Attempting to add a widget with type GtkButton to a GtkComboBoxEntry (need an instance of GtkEntry or of a subclass)

(:9282): Gtk-CRITICAL **: gtk_widget_realize: assertion `GTK_WIDGET_ANCHORED (widget) || GTK_IS_INVISIBLE (widget)' failed

(:9282): Gtk-CRITICAL **: gtk_paint_box: assertion `style->depth == gdk_drawable_get_depth (window)' failed

(:9282): Gtk-CRITICAL **: gtk_paint_box: assertion `style->depth == gdk_drawable_get_depth (window)' failed
slm@fuji:/downloads/netbeans$

Of course, once I RTFM, I see that tomcat doesn't go in by default, you have to customize the installation, so re-installed again. Now I see that glassfish has swiped the 8080 port, no mention of where tomcat will sit [8084 iirc].

Having shut down netbeans, tomcat is no longer running. Re-installation of tomcat using Synaptic - no manager, examples or docs :(

Sunday, 4 January 2009

Google Site

My site on Google is guaranteed to be up but I haven't really figured out how best to drive it yet

tomcat re-installation

I now see log entries. Somehow I seem to have wound up with two mixed-up installations on fuji, and couldn't see any log traffic in response to my call log(string) in MusicServiceImpl.xmmsCmd.

I brutally re-installed tomcat and it's now working.

Use Eclipse, projectCreator and applicationCreator. Forget about Cypal - Ockham would NOT be amused.

Compile using Music-compile (generated by applicationCreator).

Deployment is by running script deploy.sh which implements

Deploying RPC

:

rsync -avz /home/slm/proging/eclipse/JEE/music/www/net.dnsdojo.slm.music.Music/ /var/lib/tomcat6/webapps/music/

if [ ! -d /var/lib/tomcat6/webapps/music/WEB-INF/ ]
then
echo "/var/lib/tomcat6/webapps/music/WEB-INF/ does not exist (creating)"
mkdir /var/lib/tomcat6/webapps/music/WEB-INF/
else
echo "/var/lib/tomcat6/webapps/music/WEB-INF/ exists"
fi

if [ ! -d /var/lib/tomcat6/webapps/music/WEB-INF/classes/ ]
then
echo "/var/lib/tomcat6/webapps/music/WEB-INF/classes/ does not exist (creating)"
mkdir /var/lib/tomcat6/webapps/music/WEB-INF/classes/
else
echo "/var/lib/tomcat6/webapps/music/WEB-INF/classes/ exists"
fi
if [ ! -d /var/lib/tomcat6/webapps/music/WEB-INF/lib/ ]
then
echo "/var/lib/tomcat6/webapps/music/WEB-INF/lib/ does not exist (creating)"
mkdir /var/lib/tomcat6/webapps/music/WEB-INF/lib/
else
echo "/var/lib/tomcat6/webapps/music/WEB-INF/lib/ exists"
fi

rsync -avz /home/slm/proging/eclipse/JEE/music/bin/ /var/lib/tomcat6/webapps/music/WEB-INF/classes/
cp /home/slm/proging/eclipse/JEE/music/web.xml /var/lib/tomcat6/webapps/music/WEB-INF/
cp /opt/gwt-linux/gwt-servlet.jar /var/lib/tomcat6/webapps/music/WEB-INF/lib/

J2EE, .NET

And Geronimo. And JBoss. There's a lot to consider here.

Tomcat 6 by itself is a lightweight solution. It does not come with all the JEE features and additional packages found in JBoss and Geronimo, but also doesn't require much memory and runs fast even on smaller servers.
my j2ee notebook on iGoogle contains notes and links

Saturday, 3 January 2009

GWT + Servlet - working!

Late last night I was able to press a button in a browser and Pink Floyd paused, resuming on a subsequent button-press.

Yay! GWT front-end working into Java Servlet back-end over RPC. In Eclipse I could even set a breakpoint in the servlet implementation.

Fine and dandy in the debug environment. Can't deploy. Am using tomcat6.

Now deployed, I think I had web.xml wrong, also didn't spot the need to put a path of folders under web-inf/classes (see tomcat docs).

Now I'm getting runtime exception:

03-Jan-2009 11:16:49 org.apache.catalina.core.ApplicationContext log
SEVERE: Exception while dispatching incoming RPC call
com.google.gwt.user.server.rpc.UnexpectedException: Service method 'public abstract int net.dnsdojo.slm.music.client.MusicService.togglePlay(int[])' threw an unexpected exception: java.security.AccessControlException: access denied (java.io.FilePermission <> execute)

Putting this in tomcat's policy.d/50local.policy fixed the exception:


grant codeBase "http://fuji.slm.dnsdojo.net:8080/music/*" {
permission java.io.FilePermission "/usr/bin/xmms2", "execute";
};

but now I have some server error, no info, try replacing exec call with sysout.

Found this excellent guide to using stdout from java runtime exec:

Executing Unix command from java : problem

Friday, 2 January 2009

life without tunes

No house music here. Not since removing pulseaudio. I read to do this (clash with alsa?) to get sound working on YouTube vids. xmms - 2?

Good command-line support. How about a GWT front-end? What's already available? xmms2swi is a php client but tomcat log shows it fails to get through to the daemon.

Tuesday, 30 December 2008

Round-up

pda: can't get the sample GWT app to run. Suspect I'm lacking java runtime support. Java support on mobile is not same as on desktop. Trying installing Opera - insufficient space... nightmare. Opera installed and I now have GWT on WM5 but Opera needs a lot of ram. Moving the cache - which can be done through opera:config (but you have to scroll down a long way).

tomcat: you don't need tomcat to support client side javascript, however you do need a web server. Apache httpd does fine.

The following URLs work fine from fuji:
  • http://localhost:8080/examples/jsp/
  • http://fuji.slm.dnsdojo.net:8080/examples/jsp/
  • http://fuji.slm.dnsdojo.net:8080/sw/StockWatcher.html
  • http://www.slm.dnsdojo.net/content/tech/gwt/tests/StockWatcher.html
Haven't yet figured how to deploy my static site into local tomcat, don't expect a big deal here though.

Firefox crashing A LOT

Could it be a java problem?

Tomcat

I thought I was going to have problems debugging Java webapp but no, it was Tomcat installation.

BTW: having rebooted, let's see if synce:/// still works or not. Something wrong with usb. After swapping to a direct connection to avoid problems with hub, syslog gets:

Dec 30 09:50:55 fuji kernel: [ 2321.307330] eth1: unregister 'rndis_host' usb-0000:00:1d.7-6.1, RNDIS device
Dec 30 09:51:27 fuji kernel: [ 2354.060022] usb 4-2: new low speed USB device using uhci_hcd and address 18
Dec 30 09:51:28 fuji kernel: [ 2354.920022] usb 4-2: new full speed USB device using uhci_hcd and address 19
Dec 30 09:51:29 fuji kernel: [ 2355.179328] usb 4-2: configuration #1 chosen from 1 choice
Dec 30 09:51:29 fuji kernel: [ 2355.282171] eth1: register 'rndis_host' at usb-0000:00:1d.3-2, RNDIS device, 80:00:60:0f:e8:00
Dec 30 09:51:33 fuji kernel: [ 2359.603206] nm-system-setti[6412]: segfault at 14 ip b7fe5ce9 sp bf9078c0 error 4 in libnm-settings-plugin-ifupdown.so[b7fe0000+8000]

sometime later, without my intervention (but i think maybe pda wet to sleep)

Dec 30 10:01:33 fuji kernel: [ 2960.048051] usb 4-2: USB disconnect, address 19
Dec 30 10:01:33 fuji kernel: [ 2960.051348] eth1: unregister 'rndis_host' usb-0000:00:1d.3-2, RNDIS device
Dec 30 10:03:09 fuji kernel: [ 3056.140020] usb 4-2: new full speed USB device using uhci_hcd and address 20
Dec 30 10:03:10 fuji kernel: [ 3056.331472] usb 4-2: configuration #1 chosen from 1 choice
Dec 30 10:03:10 fuji kernel: [ 3056.468597] eth1: register 'rndis_host' at usb-0000:00:1d.3-2, RNDIS device, 80:00:60:0f:e8:00
Dec 30 10:06:29 fuji gvfsd-synce[16622]: GVFS-CRITICAL: g_mount_spec_set_with_len: assertion `value != NULL' failed

i think that gvfsd report coincides with opening nautilus into the device or its storage card.

Anyway: hitting the app from desktop works ok, but from the mobile it doesn't.

Why can't I get into Tomcat admin? Because the bloody lines are commented out by default in tomcat-users.xml.

Notice also that the docs speak of conf/ but if you look in /etc/tomcat6 you find the configs right there. Suspect this is because, looking in the installation root (see main page) conf is a symlink to /etc/tomcat6

Monday, 29 December 2008

GWT experimentation

In at the deep end...

Java in Eclipse on GWT

Starting point Google Code

PDA Wars

PDAs: love 'em, hate 'em, but we're stuck with them...

Tried to get sync working with synce on linux, haven't been able to browse through the usb connection since. The PDA gets no IP. Some configuration had to change for the synce attempt to disable. Can't figure what it was. Maybe having the pda connected to the wrong mini-usb didn't help. There are 3 to choose from.

In between transcoding mythtv output - a whole different saga - I managed to reboot fuji and now I find that synce:/// in nautilus actually works. IIRC, fuji is runing intrepid:

Linux fuji 2.6.27-9-generic #1 SMP Thu Nov 20 21:57:00 UTC 2008 i686 GNU/Linux

Well, I tried and failed to get a photo in here of the inside of the pda. Some issue in blogger by the look of it.

Now synce:/// is failing, the pda is discharging despite being on usb - which isn't getting an IP on USB because there's no server within reach.

So, browser access from the pda isn't as smooth as I'd like but it does work. Better get something ready to test... (Java/Eclipse/GWT)