Make a autorun USB that executes a shell script on the USB drive?


Recommended Posts

how do i make a autorun usb that executes a shell script? this would be only for my system so if there is something i have to enable, no problem (i imagine sumthing like this disabled for security reasons)

i believe the shell used wud be either ash or busybox. i think its busybox but cant confirm.

thank u.

Ok, I'm no expert by any means, but surely creating an autorun.inf script on the USB stick will mean that when you plug it in to a computer the script will run?

EDIT: I should probably specify that the file needs to be called "autorun.inf" if you want it to automatically run. Any other name won't do the same thing.

EDIT 2: Whoops, I forgot to check the forum. autorun.inf may not work on Linux. Let me check it out.

EDIT 3: Ok. Apparently by default Linux doesn't come with an autorun option. You can download an application that will create the autorun command though. Look here.

You can place a file named "autorun" on the root of the usb stick and you'll be prompted when you plug the usb drive. I didn't get it to actually run though, it craps with an "error autorunning" (maybe I'm doing something wrong).

Anyway you won't get the script to start automatically that way. If you need a script to run from the USB when plugged without prompting you'll have to define udev rules, something like what's explained here: http://www.panticz.de/node/629

This topic is now closed to further replies.
  • Recently Browsing   0 members

    • No registered users viewing this page.
  • Posts

    • Prices have been unchanged for a looooong time, so really, it's time for a new price bracket, no matter how annoying it is. AAA titles just cost too much to develop these days. Personally, though, I tend to play mostly indie titles that are much lower priced and usually are far better games anyway.
    • Personally I don't usually play most games enough to justify paying £75 / $100 for a single game. I recently got a Switch 2 which came bundled with Mario Kart World, due to some discount codes I worked out I paid approx. £30 for Mario Kart World getting it bundled with the console. If I had paid £75 for Mario Kart World I'll be honest I would have been very disappointed with it. The big open world is essentially empty and lacking any real content, the changes to go GP mode mean you only really do one lap in most races... compared to Mario Kart 8 which has pretty much always been available for around £40 you have to ask why the game is almost double the cost? Look at all the content available in a Forza Horizon game compared to Mario Kart. For £30 I feel the game is ok, its not bad, however its not amazing either.
    • It was just a copy pasta from his other replies...
    • I think that the last game I bought on day-one was something like Ghost of Tsushima. I've come to realise that I don't have enough time (or sometimes inclination) to game as much as I used to, and I've got plenty of games to keep me occupied if I do decide to play. So I don't see the need to buy a game when it first releases - I wait until it goes on sale. If I'm really excited about a game and the price is under £50 then I would consider it, but anything over that price point gets ignored until the price comes down.
    • For the foreseeable that is your choice. I'm interested tom try one, my wife was very pleased because one she is anti-social and driver chat annoys her and two more seriously there is a long history of drivers abusing women, it's rare, but it happens and more than it should. Sometimes she needs to get a late taxi and she says it may make her feel safer.
  • Recent Achievements

    • Apprentice
      Wireless wookie went up a rank
      Apprentice
    • Week One Done
      bukro earned a badge
      Week One Done
    • One Year In
      Wulle earned a badge
      One Year In
    • One Month Later
      Wulle earned a badge
      One Month Later
    • One Month Later
      Simmo3D earned a badge
      One Month Later
  • Popular Contributors

    1. 1
      +primortal
      603
    2. 2
      ATLien_0
      281
    3. 3
      +FloatingFatMan
      179
    4. 4
      Michael Scrip
      151
    5. 5
      Steven P.
      111
  • Tell a friend

    Love Neowin? Tell a friend!