Results 1 to 8 of 8

Thread: My goal: start a Java GUI application on boot, locked down

  1. #1
    Junior Member
    Join Date
    Nov 2006
    Posts
    3

    My goal: start a Java GUI application on boot, locked down

    I have a customer that needs a bunch of PCs that will do only one thing: run a specific Java GUI (Swing in this case) app. They need a full running JVM. There are probably ways of setting up Windows XP disks that will auto-run a JAR and be locked down, but Knoppix is better, right? Right! There's also a cost factor; they don't want to spend an extra $150 or whatever per PC for an XP license, and XP isn't stable, and they don't want people to be able to install software on these, and they don't want hard drives in them, so there are many reasons why going for a Linux live cd is best.

    So... here are what I have identified as the needs:

    1. It needs to boot up without prompting for options. There are no choices here!

    2. It needs to go straight into X, but no KDE etc.

    3. Of course it needs to configure its network, just as normal, so the app can access its main app server.

    4. Ideally it wouldn't even have a window manager at all, because we don't want any menus or options or other stuff on the screen. When they want to shut it off they will just turn the computer off, so there shouldn't even be a "shutdown" button.

    5. It needs to just launch straight into the Java application, running it from the JAR. It could get that app from a JAR on the CD, or it could fetch it from a URL, either way is fine. I'm planning that when I upgrade the app for them I'll burn a dozen new CDs and distribute it that way.

    6. This is written in Java 1.6, so I'll need to be able to install the JRE. This is probably the easiest part.

    Of course I'm thinking of Knoppix because it has the best hardware detection, auto network config, etc, but what I'm trying to do is a lot more limited than what Knoppix itself does. For starters I don't even need a window manager.

    Thanks for any suggestions.

  2. #2
    Junior Member
    Join Date
    Nov 2006
    Posts
    3
    Let me just say, getting Java 6 installed and keeping the ISO small enough to go on a CD is NOT EASY! I'm guessing that all the other packages on here are very carefully tuned for size.

    I am getting the hang of debs and manipulating all this and I even made up a deb of Java 6, but now this thing is getting big. I deleted KDE, Firefox, OpenOffice, etc, and I'm still getting a 1000mb ISO. I need to figure out a few more things to get rid of.

    One thing I'm doing that is helpful is I can run this whole thing on bochs instead of having to burn a CD. I know I could probably run it on vmware but I don't have vmware. Is there some kind of qemu command I could use to run an ISO? I also have Xen which is built in to Suse, but I have no idea how to use it.

    As for Java itself I found that it is quite easy to start X without a window manager, and just launch right into Java. I use a JDesktopPane instead of a window manager; Java effectively has its own WM.

  3. #3
    Senior Member registered user
    Join Date
    Dec 2004
    Posts
    168
    Hi JavaDude,
    .
    I wonder if you were able to finish your CD. If you have, have your made it available for download or would you share your scripts and "cooking" notes?
    .
    thanks
    albretch

  4. #4
    Junior Member
    Join Date
    Nov 2006
    Posts
    3
    I started removing stuff (like all of KDE etc) from the standard Knoppix disk to try to make enough space. It was quite tedius to trim all that out and it didn't get me to where I wanted to go, namely to have enough space for my Java app, the 1.6 JRE, and also a Windows JRE installer, all on the same disk. I want all of these things so I can use it to hand out to customers so they can run it by either rebooting the machine, or by having everything there ready to install on their Windows machines. Well there isn't enough space on a CD, so that's not possible.

    So my revised strategy is I'm going to start with the Knoppix CD image, don't delete anything, add whatever I need, and then burn it onto a DVD. All new computers ship with DVDs so this is a good option.

    Oh getting it to auto-boot into a Java application, without even starting X, is easy to do. I need to look back through my files to see how I did it. I did mofify the Knoppix startup script and you can pass in arguments to the X server when you start it, so it runs a command instead of a window manager. Obviously that's what you want to do. Then in your Java code, make it use a JDesktopFrame, and make it size itself to the max screen size, and you'll have a desktop frame that has no decorations, running without a window manager at all, so you have complete control of the desktop within Java. It's cool! I can't see why anyone would do an embedded app any other way, and with putting it onto a bootable disk, it takes away all of the support issues.

  5. #5
    Junior Member
    Join Date
    Apr 2011
    Posts
    1
    Di you find your notes on auto-booting into Java application? Could you post them here please.

  6. #6
    Junior Member
    Join Date
    Aug 2011
    Posts
    1
    Ditto. I'm quite interested in doing something like this, too.

  7. #7
    You guys are in luck: I just did just this with Lua OS (lua.org) :]

    The Java app is started automatically. It's not locked though, you can still go to the Knoppix desktop. Which is fine for me, there may be many reasons to do that. I definitely don't wanna lock the user out of that. Just start the Lua OS desktop as the default.

    The resulting CD image is about 500 MB, so it fits on a CD. And there's a lot of opportunity for making this even smaller.

    Check my remastering guide for more info: luaos.net/pages/mastering.php
    Last edited by Clinton; 09-09-2011 at 07:35 PM. Reason: to change url

  8. #8
    Junior Member
    Join Date
    Oct 2012
    Posts
    1

    Code

    Hi,

    Would it be possible for you to share your code?

    I would really like to start a java app without a window manager

Similar Threads

  1. Custom Kernel - boot locked up
    By keeger in forum Customising & Remastering
    Replies: 7
    Last Post: 02-07-2008, 04:08 PM
  2. Replies: 1
    Last Post: 07-07-2007, 10:45 PM
  3. Cannot start application from desktop (hdd-install)
    By mkjtravel in forum Hdd Install / Debian / Apt
    Replies: 2
    Last Post: 10-30-2004, 05:02 AM
  4. start single application
    By irsirius in forum Customising & Remastering
    Replies: 3
    Last Post: 10-25-2004, 07:00 PM
  5. Very slow to open a new window or start an application
    By eric2 in forum General Support
    Replies: 4
    Last Post: 01-27-2004, 11:54 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


Netac 256GB SSD 2.5'' SATA III 6Gb/s Internal Solid State Drive 500MB/s PC/Latop picture

Netac 256GB SSD 2.5'' SATA III 6Gb/s Internal Solid State Drive 500MB/s PC/Latop

$24.42



ADATA Ultimate Series SU630 Internal SSD 240GB SATA III 2.5

ADATA Ultimate Series SU630 Internal SSD 240GB SATA III 2.5" 3D QLC 520MBps

$27.99



1TB 7mm 2.5in SSD SATA III PC Internal Hard Drives Solid State Drive High Speed picture

1TB 7mm 2.5in SSD SATA III PC Internal Hard Drives Solid State Drive High Speed

$35.88



Netac 240GB SSD 2.5'' SATA III 6Gbp/s Internal Solid State Drive 500MB/S picture

Netac 240GB SSD 2.5'' SATA III 6Gbp/s Internal Solid State Drive 500MB/S

$27.94



Kingston 240GB SSD SATA III 2.5” Solid State Drive 240 GB HDD Disk picture

Kingston 240GB SSD SATA III 2.5” Solid State Drive 240 GB HDD Disk

$29.90



Samsung - 980 PRO 1TB PCIe Gen 4 x4 NVMe Gaming Internal Solid State Drive picture

Samsung - 980 PRO 1TB PCIe Gen 4 x4 NVMe Gaming Internal Solid State Drive

$159.99



1TB SanDisk X400 TLC SATA 3 6Gb/s 2.5

1TB SanDisk X400 TLC SATA 3 6Gb/s 2.5" 7mm SED Internal SSD SERVER SYSTEM PULL

$59.99



Kioxia (Toshiba) 256GB/512GB PCIe NVMe M.2 2230 30mm SSD picture

Kioxia (Toshiba) 256GB/512GB PCIe NVMe M.2 2230 30mm SSD

$21.99



ADATA Ultimate Series SU650 Internal SSD 120GB SATA III 2.5

ADATA Ultimate Series SU650 Internal SSD 120GB SATA III 2.5" 3D NAND 520MBps

$21.99



ADATA Ultimate Series SU740 Internal SSD 500GB SATA III 2.5

ADATA Ultimate Series SU740 Internal SSD 500GB SATA III 2.5" 3D NAND 520MBps

$44.99