[SOLVED] How to execute a .sh file in an NTFS partition?

Forum Forums New users New Users and General Questions [SOLVED] How to execute a .sh file in an NTFS partition?

Tagged: 

  • This topic has 9 replies, 7 voices, and was last updated Apr 4-2:49 am by kaye.
Viewing 10 posts - 1 through 10 (of 10 total)
  • Author
    Posts
  • #29252
    Member
    kaye

      Hello Friends

      I was just wondering if it’s possible in antiX to execute a .sh file in an NTFS partition.

      For example, I downloaded the latest SuperTuxKart game from https://supertuxkart.net/Main_Page and saved it in an NTFS partition which I use for storing all kinds of files (documents, pics, music, etc.)

      I get this when trying to run the game from the terminal:

      $ sudo sh ./run_game.sh
      Running 64-bit version...
      ./run_game.sh: 15: ./run_game.sh: /media/my-ntfs-partition/supertuxkart/supertuxkart-1.0-linux/supertuxkart-1.0-linux/bin-64/supertuxkart: Permission denied

      It seems I can only play the game if it’s in the /home/user directory.

      I kind of prefer to save the game in the NTFS partition and run it from there.

      Is this not possible?

      The /etc/fstab entry for the NTFS partition is:

      /dev/sda1 label=my-ntfs-partition UUID=0C8F6A4424CD0148 /media/my-ntfs-partition ntfs-3g auto,exec,uid=1000,gid=users,dmask=002,fmask=113,users 0 0

      I know some of you may discourage what I’m after, but let’s just say I may want to learn a way around it, for learning’s sake.

      Thank you!

      • This topic was modified 3 years, 1 month ago by kaye.
      #29253
      Member
      fatmac
        Helpful
        Up
        0
        ::

        Looks like NTFS is mounted as your user ID, (1000), will it run if you leave out sudo?

        (Otherwise, I’ll guess it is a permissions problem with the NTFS filesystem.)

        Linux (& BSD) since 1999

        #29254
        Anonymous
          Helpful
          Up
          0
          ::

          read man mount.ntfs then edit the fstab entry and specify a more permissive fmask value.

          Here’s a quick ‘splainer: https://superuser.com/questions/1271534/file-permissions-correct-ntfs-mount-option

          #34288
          Member
          kaye
            Helpful
            Up
            0
            ::

            Hi. It’s been months and I still don’t get it. It’s all very confusing to me. Sorry.

            #34290
            Forum Admin
            rokytnji
              Helpful
              Up
              0
              ::

              Edit: screwed up post.

              For example, I downloaded the latest SuperTuxKart game from https://supertuxkart.net/Main_Page and saved it in an NTFS partition which I use for storing all kinds of files (documents, pics, music, etc.)

              I save stuff in /data ext3 before a install. I don’t dual boot so ntfs is not needed. Since too complicated. You might want to re think on on how you install or save files system wise.

              https://www.cyberciti.biz/faq/debian-ubuntu-linux-auto-mounting-windows-ntfs-file-system/

              • This reply was modified 3 years, 1 month ago by rokytnji.

              Sometimes I drive a crooked road to get my mind straight.
              Not all who Wander are Lost.
              I'm not outa place. I'm from outer space.

              Linux Registered User # 475019
              How to Search for AntiX solutions to your problems

              #34292
              Forum Admin
              anticapitalista
                Helpful
                Up
                0
                ::

                If you want the latest supertuxkart, I can put it in our repos.

                Philosophers have interpreted the world in many ways; the point is to change it.

                antiX with runit - leaner and meaner.

                #34296
                Member
                kaye
                  Helpful
                  Up
                  0
                  ::

                  Based on your answers, I guess there’s nothing I can do? Would converting the partition from ntfs to fat32 help? What about creating an ext4 partition just for executables?

                  I’m sorry if it seems confusing but this is what I remember being able to do in another distro:

                  For example, the Tor Browser. And the Soundwire app. I’m not 100% sure but I think I was able to run these two from an ntfs partition.

                  That’s all I’m asking.

                  Right now if I have to run Tor Browser, obviously first I have to download Tor from their website. Then I extract it somewhere. If I extract it to an ntfs partition, it won’t run. If I extract it to /home/user, it will run. (I think extracting it to / directory is ok too?)

                  By the way, in Debian, after downloading supertuxkart from its website, I extracted it to an ntfs partition and I can run it from there.

                  This really isn’t all that important to me but I was wondering if it’s possible in antiX.

                  Thank you!

                  #34318
                  Forum Admin
                  Dave
                    Helpful
                    Up
                    0
                    ::

                    As skidoo states your mask values are set incorrectly. Therefore all your files when mounted are mounted without the executable flag. This is good for a general storage drive but not a program drive. You may be able to set the executable flag by running the command
                    chmod 775 /media/my-ntfs-partition/supertuxkart/supertuxkart-1.0-linux/supertuxkart-1.0-linux/bin-64/supertuxkart
                    Or right clicking on that file in a file manager and selecting permissions. Then set the executable flag there.

                    Computers are like air conditioners. They work fine until you start opening Windows. ~Author Unknown

                    #34320
                    Member
                    fungalnet
                      Helpful
                      Up
                      0
                      ::

                      Do you have ntfs-3g installed? I believe the correct fstab mounting for ntfs-3g is just uuid=xxxxxxx ntfs-3g /media/yourntfsmountingpoint default 0 0
                      The other configuration is for plain ntfs mounting.
                      If you don’t have ntfs-3g installed then your system will not know how to mount the partition properly.
                      Windows would never be able to do anything with linux binaries anyway, so I would split a piece of the partition and convert it to ext4. If you install supertuxcart the executables should have been either in /usr/bin or /usr/local/bin or maybe /opt. You seem to have installed it from a tarball from upsource, I would guess.

                      #34324
                      Member
                      kaye
                        Helpful
                        Up
                        0
                        ::

                        Hello Friends! I’m the OP. I think this is what works for me. In /etc/fstab , I edited the line in question to this one:

                        UUID=6C7729577B56EBD0 /media/kaye/data ntfs-3g auto,uid=1000,gid=users,umask=0,dmask=0,fmask=0,users,exec 0 0

                        I can run both SuperTuxKart and Tor Browser from that partition. Both were downloaded from their respective websites, then extracted to that partition, then I was able to run them. I am also able to save a LibreOffice Calc file in that partition.

                        What do you think? Is there anything in that line that would cause problems? Do I need to edit it further?

                        Thank you!

                      Viewing 10 posts - 1 through 10 (of 10 total)
                      • You must be logged in to reply to this topic.