Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

This may sound weird, but I got this idea and I would love to put it in practice. I have an USB flash drive that I carry with me everytime, and I would like to create a system to make my Ubuntu only start IF that flash USB is connected, just like a key that turns on a car (the login screen should appear only if the "key" is connected - I would have to put my password too). This will be a great improvement on my computer's system (and would also be kind of fun).

It would be also nice to have more than one "key", in case a flash drive gets broken...

So, the question is, is this possible? If yes, how can I make it?

share|improve this question
I don't have a solution, but I have seen this somewhere before. So I can assure you that this is possible. I can't exactly remember how it was done. Though I think it was something like it only displayed Ubuntu on Grub if your USB was installed, or something along those lines. – Gilgamesh Apr 29 '12 at 21:13
It would be awesome to have something like this... Hope someone come up with a solution! :D – joelalmeidaptg Apr 29 '12 at 21:15

I did a thorough Google search and can't find the solution that I had saw months back, I apologise, but I did find something similar that may or may not work. I admit, that I don't know too much about Grub or whether or not you can use this for your purposes, but it does seem likely to work.

This link takes you to a page that describes how to create a GRUB Rescue USB

It is basically designed just for a situation that your Grub breaks. However, if I am correct, if you somehow manage to delete the Ubuntu entry from your pre-existing grub after creating it (assuming you Dual-boot) then starting up your PC will not show Ubuntu, unless you plug in your new USB that will boot-up the Grub that displays your Ubuntu install.

I know that this is risky, so I would recommend you wait till someone clarifies whether my idea works or not. If no one replies, then go ahead and ask on an Ubuntu forum.

Good luck, and I hope I haven't inconvenienced you with this idea. I'm not too knowledgeable when it comes to Grub.

share|improve this answer
Do you think it would be "possible" to test this under VirtualBox? That way I could try everything without fear of breaking something. – joelalmeidaptg Apr 29 '12 at 21:30
I would guess that it's a good possibility of working under VB. Give it a try, but I would recommend you take the idea to people on forums. That way you wouldn't need to waste time on something that may not even work. – Gilgamesh Apr 29 '12 at 21:33
@nirpius reported the desired behavior as a problem, on the answer may give you a hint. – waltinator Apr 29 '12 at 22:42

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.