Page 1 of 2 12 LastLast
Results 1 to 10 of 14

Thread: Can't make file executable

  1. #1
    Join Date
    Aug 2011
    Beans
    3

    Can't make file executable

    I can't make file executable. When I try to change it through the right click/properities/permissions/allow executing file as program, it seems it's ok for a while and after a approximately a second, the box is empty again. When I try it through terminal, at won't give me any error, but the file still isn't executable.
    I try to use google, but I can't find any way to solve this problem.
    Thank you for your time and sorry for my english.

  2. #2
    Join Date
    Jan 2008
    Beans
    211

    Re: Can't make file executable

    Quote Originally Posted by kecal.op View Post
    I can't make file executable. When I try to change it through the right click/properities/permissions/allow executing file as program, it seems it's ok for a while and after a approximately a second, the box is empty again. When I try it through terminal, at won't give me any error, but the file still isn't executable.
    I try to use google, but I can't find any way to solve this problem.
    Thank you for your time and sorry for my english.
    When i had the same problem i first changed the ownership and then tried.
    Code:
     sudo chown $USER <file path>
    sudo +x <filepath>
    should do the trick.

  3. #3
    Join Date
    Nov 2010
    Location
    India
    Beans
    Hidden!

    Re: Can't make file executable

    Hi
    No need to change user to make file as execute.
    Just do this

    Code:
    sudo chmod +x filename
    all the best
    Dont miss anything even it is small. one small pin is enough to bring down a man.


  4. #4
    Join Date
    Dec 2009
    Beans
    6,776

    Re: Can't make file executable

    I don't use Wubi but are you trying to make a file on the host ( i.e., Windows ) directory executable?

    That's not going to work. You can't chmod or chown a Windows file as they have no Linux permission bits to change.

    If you're trying to change it to executable so something runs in Wine then you're in luck: http://ubuntuforums.org/showthread.php?t=1747138

  5. #5
    Join Date
    Aug 2011
    Beans
    3

    Re: Can't make file executable

    I try to do what you say and still it saying it's not marked as executable.
    I write this
    Code:
    sudo chown tlauli /media/Data/Download/Minecraft/minecraft.jar
    (I have similar problem before, too, it's not fault of minecraft)
    write password a then try to change the executability by
    Code:
    sudo chmod +x /media/Data/Download/Minecraft/minecraft.jar
    And still nothing. :-\ The case of letters is correct.

    EDIT: raja.genupula: Like I wrote in my first post, that comand does nothing.
    Morbius1:In windows that file is an "executable jar file". And if I understand correctly to link that you posted, they try to solve a problem with opening the file with wine. But I don't want to open it with wine, just normaly with sun java or opemJDK java.
    Last edited by kecal.op; September 25th, 2011 at 07:55 PM.

  6. #6
    Join Date
    Dec 2009
    Beans
    6,776

    Re: Can't make file executable

    Same problem with a jar, same culprit ( cautious-launcher ), same solution:

    Change the file association:
    Right click an *.jar file and select Properties -> Open With -> Add -> Use a custom command > type in:
    Code:
    java -jar
    In the "Open With" tab mark the "jar" you added as the default .

  7. #7
    Join Date
    Nov 2009
    Location
    North Vancouver
    Beans
    Hidden!
    Distro
    Edubuntu 14.04 Trusty Tahr

    Re: Can't make file executable

    See this howto to mount the partition in a way that makes the file executable: http://ubuntuforums.org/showthread.php?t=1604251

  8. #8
    Join Date
    Dec 2009
    Beans
    6,776

    Re: Can't make file executable

    Crikey, exe's and jar's don't have to be set as executable to run in Linux. It's a file association problem caused by cautious-launcher.

    Here, I'll prove it to you. In a terminal run the following command with the jar file that's not executable:

    Code:
     java -jar /media/Data/Download/Minecraft/minecraft.jar
    It may not run because of something wrong with that jar file but you will not get an error telling you it's not executable.

  9. #9
    Join Date
    Sep 2011
    Beans
    39

    Re: Can't make file executable

    i'm facing a similar problem and
    sudo chmod +x filename
    is not helping

  10. #10
    Join Date
    Nov 2009
    Location
    North Vancouver
    Beans
    Hidden!
    Distro
    Edubuntu 14.04 Trusty Tahr

    Re: Can't make file executable

    Quote Originally Posted by Morbius1 View Post
    Crikey, exe's and jar's don't have to be set as executable to run in Linux. It's a file association problem caused by cautious-launcher.

    Here, I'll prove it to you. In a terminal run the following command with the jar file that's not executable:

    Code:
     java -jar /media/Data/Download/Minecraft/minecraft.jar
    It may not run because of something wrong with that jar file but you will not get an error telling you it's not executable.
    That may be - but the original post asks how to make a file executable. I think Wormzy's HowTo is a must read for anyone dual booting.

    Either way... it's not worth getting all excited over.

Page 1 of 2 12 LastLast

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
  •