This is the old SliTaz forum - Please use the main forum.slitaz.org

How to eject USB Flash?
  • LexeiiLexeii July 2010
    I use SliTaz-3.0.
    I read the topics:
    1. Unable to unmount CD driver on Tux
    2. I can't use the CD/DVD drive for audio/video as tux ...

    My question is similar.
    PCManFM can only unmount the file system.
    To eject the USB Flash (and power it off, like in windows), I write in terminal:
    tux@slitaz:~$ su
    Password: root
    root@slitaz:/home/tux# eject /dev/sdb

    Is it a way to add command «Eject» to flash drive context menu in PCManFM, like in CD-ROM?
  • ChristopheChristophe July 2010
    right click to unmount the flash drive.
    I believe this will sync the fs first, as exepcted, but did not check.
  • ChristopheChristophe July 2010
    right click on the flash drive name in the left window then unmount it
  • LexeiiLexeii July 2010
    Oh, Christophe! There is no "eject" item in context menu for flash and ordinar drives! Have you one? If it was so simple, I will not ask a question, I'm not so stupid. Context menu have only mount and unmount items. Only cd/dvd have eject.
    And yes, filesystem is sync before unmount - LED blinks.
    Whats wrong?
  • ChristopheChristophe July 2010
    Not sure I understand your point.
    Once the the fs is unmounted you can safely unplug it. This is similar to the XP's eject. Just a different name.
  • LexeiiLexeii July 2010
    It's not different name, it's different action. Real eject I was describe in first post. Maybe I find answer in PCManFM's sources...
  • ChristopheChristophe July 2010
    please explain what else you expect. Eject litterally means take off the device, after umounting it. For a CDROM it should open the tray. For a USB Flash you have to take it off manually but I still do not see the difference.
  • LexeiiLexeii July 2010
    Hmm... Eject for removable media (USB Flash) powers it off.
  • seawolfseawolf July 2010
    Does this help? (Obviously substituting the '1-2' with the actual ID of the USB device in question)

    => http://www.linuxquestions.org/questions/linux-hardware-18/how-to-power-off-usb-port-613304/#post3620777

    I also saw:
    => http://www.mjmwired.net/kernel/Documentation/usb/power-management.txt#123

    But, line 136 says that suspend is no longer supported. In fact, the .../power/level file does not exist on my 2.6.34 kernel. Perhaps a patch could be made to put the old code back in...
    => http://www.mjmwired.net/kernel/Documentation/usb/power-management.txt#136
    This may or may not be why it isn't there.

    I wonder if PCManFM can be extended with extra menu items, like Nautilius...? That way the eject command could be issued quite easily.

    Just a couple of thoughts, hope it helps & sorry if it's totally useless!
  • LexeiiLexeii July 2010
    Thank You, Ben, for answer.
    Unfortunately, this is «more programmer's way», than I can understand.

    In my request (PCManFM HAL eject) Google often tells me how to configure PolicyKit. But SliTaz don't use them.

    Search in progress...
This discussion has been closed.
← All Discussions

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Sign In Apply for Membership

SliTaz Social