1

I'm not 100% sure where the problem is... udev or gnome or ...

Backstory:

I have an "IronKey". I have a udev rule that allows my IronKey to plug into my machine. After I've plugged it in, I go to the gnome desktop, select "Places" / "IronKey" , and it mounts the Ironkey file system into /media/IronKey I can then run the /media/IronKey/linux/ironkey program, go to the gnome desktop, select "Places" / "Ironkey USB", and it mounts the secured file system into /media/Ironkey USB

Problem:

My co-worker has a newer IronKey. When he plugs it in, he goes to the gnome desktop, selects "Places" / "IronKey Unlocker" , and then gnome mounts the Ironkey file system into /media/IronKey Unlocker He can then run the /media/IronKey Unlocker/linux/ironkey program, go to the gnome desktop, select "Places" / "KINGSTON", and it mounts the secured file system into /media/KINGSTON

We have a bunch of scripts that depend on the IronKey being located in /media/IronKey and /media/Ironkey USB . How can I tell udev or gnome or whatever that

  • When it mounts /media/IronKey Unlocker, it should create a symlink to /media/IronKey
  • When it mounts /media/KINGSTON, it should create a symlink to /media/Ironkey USB
  • When it unmounts /media/IronKey Unlocker, it should remove the symlink to /media/IronKey
  • When it unmounts /media/KINGSTON, it should remove the symlink to /media/Ironkey USB
hymie
  • 424
  • 2
  • 11
  • I think it would be better to alter the scripts, so that they can work regardless of where the media gets mounted. If you don't do this now, you'll have to do it later when you upgrade to a more modern Linux distribution and find that the USB drives are no longer mounted in `/media` at all, but in `/run/media/`! – Michael Hampton Oct 12 '16 at 18:07
  • @MichaelHampton -- I appreciate your answer, but there are an awful lot of scripts that need to be updated, and there is a complex process for getting permission to update them. Adjusting system-level activities is much easier. – hymie Oct 12 '16 at 18:35
  • That's... bizarre. The far riskier action is much easier to get approved? – Michael Hampton Oct 12 '16 at 18:42
  • @MichaelHampton -- Turns out I was wrong. These scripts are not covered under the process I thought they were. I'm going to try this route. Thanks for the tip. – hymie Oct 14 '16 at 14:23

0 Answers0