Results 1 to 8 of 8

Thread: .jar "is not marked as executable." -this creates problems for newbies.

  1. #1
    Join Date
    Feb 2008
    Beans
    189

    .jar "is not marked as executable." -this creates problems for newbies.

    Soooo I try to open a .jar file (Java program). I get this:

    Quote Originally Posted by xubuntu
    The file '/media/8A07-A343/PERSONALFILES/drjava-beta-20110822-r5448.jar' is not marked as executable. If this was downloaded or copied from an untrusted source, it may be dangerous to run. For more details, read about the executable bit.
    So I can't just run the file by double-clicking it. I try to "mark the file as executable" but this is on my NTFS-formated hard drive so I can't mark it as executable. So in order to make it run I must use the command line:

    Code:
    java -jar drjava-beta-20110822-r5448.jar
    Problem solved, i got it open. Buttttttttt.... I talked to a few friends at school who just got Ubuntu and were trying to open .jar's but had never used the commandline before.

    So basically the problem here is that the system doesn't want to open jar's that aren't marked executable. This is stupid and prevents newcomers to Ubuntu from just opening .jar files because they don't have the right Linux know-how. The system should just put up a message that says "You are about to open a Java program. Only open this program if you trust the source it was downloaded from. Proceed? "
    Looking for a Terminal Emulator that's fun to use? Try out this program I wrote!

  2. #2
    Join Date
    Mar 2011
    Location
    Pizza Hut
    Beans
    1,203
    Distro
    Kubuntu 12.10 Quantal Quetzal

    Re: .jar "is not marked as executable." -this creates problems for newbies.

    What's one of the largest causes of viruses in Windows? Button-happy users who click before they read. Making it so the user manually sets the file as executable forces them to think about what they're doing, and thus reduces viruses. The fact that you had to use the command line for this is because it was on an NTFS partition, it's a much better choice to use an ext* or other made-for-UNIX File system. Then you can easily mark it as executable via GUI (yes, I know this is not always possible, it's not that implausible. I do it just fine.).
    Ubuntu user #35115 - Linux user #555707 - My Ubuntu Wik page
    Join the Ubuntu Forums' IRC room (#ubuntuforums on irc.freenode.net)!

  3. #3
    Join Date
    Feb 2008
    Beans
    189

    Re: .jar "is not marked as executable." -this creates problems for newbies.

    Quote Originally Posted by dniMretsaM View Post
    The fact that you had to use the command line for this is because it was on an NTFS partition, it's a much better choice to use an ext* or other made-for-UNIX File system.

    I can't use ext, this is a drive that has to be readable by Windows machines. I have to use NTFS because it's 500GB, too big for FAT. Basically, I just want that box to display a little more information for clueless newbies, it's a bit mystifying as-is.
    Last edited by yanom; September 25th, 2011 at 04:36 PM.
    Looking for a Terminal Emulator that's fun to use? Try out this program I wrote!

  4. #4
    Join Date
    Nov 2007
    Location
    .mx
    Beans
    305
    Distro
    Ubuntu

    Re: .jar "is not marked as executable." -this creates problems for newbies.

    Quote Originally Posted by yanom View Post
    I can't use ext, this is a drive that has to be readable by Windows machines. I have to use NTFS because it's 500GB, too big for FAT. Basically, I just want that box to display a little more information for clueless newbies, it's a bit mystifying as-is.
    The best place to report such things would be Ubuntu Brainstorm.

    Also, there are ext2/3 (not sure about 4) drivers for windows.
    Shamelessly plugging my GLog! (GeekLog) in every post I can
    If your problem is solved, please do take the time to mention it and Mark the Thread as Solved!

  5. #5
    Join Date
    Dec 2009
    Beans
    4,926

    Re: .jar "is not marked as executable." -this creates problems for newbies.

    This issue here has really nothing to do with whether or not a given jar file is marked as executable or not. The issue here is something called cautious-launcher which Ubuntu adds to jar execution to protect users from themselves. One can argue that it's pointless since the user ( like yourself ) will always find a way around it.

    One method is the way you posted. Another way is to create your own file association that removes cautious-laucher from the command sequence:

    In Xubuntu:
    Right click a *.jar file > Open with other application > Use a custom command:

    In the box enter: java -jar
    Last edited by Morbius1; September 25th, 2011 at 10:57 PM.

  6. #6
    Join Date
    Feb 2008
    Beans
    189

    Re: .jar "is not marked as executable." -this creates problems for newbies.

    Quote Originally Posted by Morbius1 View Post
    This issue here has really nothing to do with whether or not a given jar file is marked as executable or not. The issue here is something called cautious-launcher which Ubuntu adds to jar execution to protect users from themselves. One can argue that it's pointless since the user ( like yourself ) will always find a way around it.

    One method is the way you posted. Another way is to create your own file association that removes cautious-laucher from the command sequence:

    In Xubuntu:
    Right click a *.jar file > Open with other application > Use a custom command:

    In the box enter: java -jar
    I know. but others don't.
    Looking for a Terminal Emulator that's fun to use? Try out this program I wrote!

  7. #7
    Join Date
    Jun 2011
    Location
    The Shadow Gallery
    Beans
    6,827

    Re: .jar "is not marked as executable." -this creates problems for newbies.

    Quote Originally Posted by yanom View Post
    I know. but others don't.
    and others trash there machines all the time.

    There are lots of things that dont work the same as in other OS, thats cos this it not those OS.
    Feel Free to Bitcoin Tip: 135Rp4pwwYTHEJ4u8bxKaDQiC91N9LUoV2

    Backtrack - Giving machine guns to monkeys since 2006
    Kali-Linux - Adding a grenade launcher to the machine guns since 2013

  8. #8
    Join Date
    Apr 2010
    Location
    England
    Beans
    3,286

    Re: .jar "is not marked as executable." -this creates problems for newbies.

    Tell them to copy the file into their home folder, then mark it as executable. That's probably the easiest solution for "newbies".
    http://xkcd.com/293/
    There are 10 kinds of people in this world: Those who understand ternary, those who don't, and those who confuse it with binary.

Tags for this Thread

Bookmarks

Posting Permissions

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