Results 1 to 11 of 11
  1. #1
    nwboy74 is offline Member
    Join Date
    Oct 2008
    Posts
    45
    Rep Power
    0

    Unhappy Communicate between Windows and UNIX

    I am trying to come up with a solution to allow users on Windows machines to access the file system on our UNIX machines at work. The UNIX boxes are not webservers, but are accessible via XManager (or other such terminal emulator). I basically need to create a form that will gather information from the UNIX file-system, present it in a user-friendly format, and submit changes.

    I tried having the user start a java program using Swing to open a new window, but it disrupts the xterm sessions. I tried using an applet, but applets don't have privileges to access the file system; also I don't know how to make the applet available to everyone since there isn't a url they can go to. I could possibly run a server on the unix box that listens on a particular port, but not sure how to connect or how to get the client program loaded onto the user's pc. Help?

  2. #2
    Norm's Avatar
    Norm is offline Moderator
    Join Date
    Jun 2008
    Location
    Eastern Florida
    Posts
    17,874
    Rep Power
    25

    Default

    If its Swing that is a problem, have you tried the older AWT?
    It'll be a lot simpler GUI it that's not important.
    If the program on Unix is a server for the Windows users, does it need a GUI?

  3. #3
    serjant's Avatar
    serjant is offline Senior Member
    Join Date
    Jun 2008
    Location
    Ukraine,Zaporozhye
    Posts
    487
    Rep Power
    7

    Default

    Do you access the UNIX machine with root rights?

  4. #4
    serjant's Avatar
    serjant is offline Senior Member
    Join Date
    Jun 2008
    Location
    Ukraine,Zaporozhye
    Posts
    487
    Rep Power
    7

    Default

    Usually i access my UNIX server with root rights,that enables me to do everything on the system.

  5. #5
    nwboy74 is offline Member
    Join Date
    Oct 2008
    Posts
    45
    Rep Power
    0

    Default

    Actually, it's looking more and more like AWT is the problem. Since Swing is built on AWT, I can't use either. In all fairness, it's the interaction between xterm and AWT. I just don't know how to solve it.

  6. #6
    serjant's Avatar
    serjant is offline Senior Member
    Join Date
    Jun 2008
    Location
    Ukraine,Zaporozhye
    Posts
    487
    Rep Power
    7

    Default

    Can you try not to make an AWT Frame,try to make a JFrame and see what happens.ok?

  7. #7
    Norm's Avatar
    Norm is offline Moderator
    Join Date
    Jun 2008
    Location
    Eastern Florida
    Posts
    17,874
    Rep Power
    25

    Default

    I just don't know how to solve it.
    Do you need any GUI at all?

  8. #8
    nwboy74 is offline Member
    Join Date
    Oct 2008
    Posts
    45
    Rep Power
    0

    Default

    The same thing happens if I try JFrame or Frame. Apparently, sun is aware of the issue and have supposedly addressed it. It has something to do with AWT loading a certain libraries in a particular order.

    XToolkit on Solaris/Linux

    Starting with release J2SETM 5.0, AWT has been re-implemented on the Solaris and Linux platforms. The new Toolkit implementation provides the following advantages:
    • Removes the dependency on Motif and Xt libraries.
    • Interoperates better with other GUI Toolkits.
    • Provides better performance and quality.

    The new Toolkit (XToolkit) is the default on Linux in J2SE 5.0. Solaris will continue to use the MToolkit (Motif-based Toolkit) as the default in J2SE 5.0, but eventually will be replaced with XToolkit.

    Explicitly Setting the Toolkit

    You can explicitly set the toolkit for an applet or application using an environment variable or a system property. Keep in mind that the environment variable overrides the system property.

    Setting the toolkit for an application:

    Using an environment variable. This needs to be set before starting the VM.
    csh:
    setenv AWT_TOOLKIT XToolkit #selects the XToolkit
    setenv AWT_TOOLKIT MToolkit #selects the MToolkit

    ksh/bash:
    export AWT_TOOLKIT=XToolkit
    export AWT_TOOLKIT=MToolkit

    Unfortunately, what they've suggested does not work for me. I'm assuming because I don't have XToolkit as part of my runtime environment.

  9. #9
    nwboy74 is offline Member
    Join Date
    Oct 2008
    Posts
    45
    Rep Power
    0

    Default

    I need some sort of user interface that will allow me to display a list of files and have users be able to "check" off which ones they want included. Sure, I could go one-by-one through each file and ask "Do you want to include this file?", but that's monotonous, especially for a large list.

  10. #10
    nwboy74 is offline Member
    Join Date
    Oct 2008
    Posts
    45
    Rep Power
    0

    Default

    It seems that my problem is with XManager 2.0, the program we use to grab an xterm session. Unfortunately, I don't think my company is willing to invest in XManager 3.0 to fix my problem.

  11. #11
    Norm's Avatar
    Norm is offline Moderator
    Join Date
    Jun 2008
    Location
    Eastern Florida
    Posts
    17,874
    Rep Power
    25

    Default

    How about a mini HTTP server without a GUI that uses a browser for communications with the user via localhost. Let the browser handle the GUI.

Similar Threads

  1. [SOLVED] Swing and Unix
    By nwboy74 in forum AWT / Swing
    Replies: 9
    Last Post: 11-05-2008, 03:04 AM
  2. Replies: 0
    Last Post: 10-31-2008, 08:07 PM
  3. how to run java app on windows in a cron like on unix
    By rockie12 in forum Advanced Java
    Replies: 7
    Last Post: 05-23-2008, 02:39 PM
  4. Communicate vb.NET with Java
    By cachi in forum Advanced Java
    Replies: 1
    Last Post: 08-02-2007, 01:41 AM
  5. Replies: 1
    Last Post: 07-06-2007, 06:21 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
  •