LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware
User Name
Password
Linux - Hardware This forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?

Notices


Reply
  Search this Thread
Old 10-31-2005, 03:24 PM   #16
GrueMaster
Member
 
Registered: Aug 2005
Location: Oregon
Distribution: Kubuntu.
Posts: 848

Rep: Reputation: 30

I have two different memory sticks from Sandisk (an older 256M and a newer 128M). The 128M works flawlessly, but the 256M only works in newer installations. It could be a timing issue with the usb-storage driver for your particular install, or it could be the device itsself. My 256M would actually hang my laptop until I reformatted it with a windows utility I found from HP. Now it works ~80% of the time. The biggest problem with memory sticks is that they really have a wide range of tolerances to the USB standards. Another thing I think is more directed at the usb-storage driver, I believe Windows uses a far more generic device driver, whereas usb-storage tries to customize it's device init routine for each device (I need to look at this more closely).

One thing that I found helpful is the hotplug scripts. Not all distros have them installed (or even make them available).

My biggest problem is with multicard readers (CF, SD, etc). They will show up as a drive for each slot, even if it is empty. Mine has to be unplugged and plugged back in every time I put the CF card in.

Also, in Windows, when you want to remove a device, Windows will actually shut it down first. I haven't seen this in Linux yet (although I am researching it in my spare time).
 
Old 10-31-2005, 03:25 PM   #17
NetRAVEN5000
Member
 
Registered: May 2005
Distribution: Ubuntu 9.04
Posts: 320

Rep: Reputation: 30
Maybe hotplug isn't working properly. Or maybe the hotplug daemon doesn't run automatically.
 
Old 11-02-2005, 11:31 AM   #18
ronald-be
Member
 
Registered: Aug 2004
Location: Belgium
Distribution: debian 5.02
Posts: 73

Rep: Reputation: 15
Hello GrueMaster,

Mine is a Sandisk too : a 1024 MB. The automatic shutdown in windoze is not true in W2K : u have to use "unplug or eject hardware" and select the stick. U can realize the same under linux with the command "umount <device name>". If u don't trust it, use "sync" before that. Will try the same USB-port on a digital camera to test the hot-plug. Module "usb-storage" is loaded I checked that...

Greetings,

Ronald
 
Old 11-02-2005, 12:21 PM   #19
GrueMaster
Member
 
Registered: Aug 2005
Location: Oregon
Distribution: Kubuntu.
Posts: 848

Rep: Reputation: 30
The "Safely remove device" function under Windows is what I was referring to. It auto-syncs the device, then sends it a suspend command. I has spent a little (very little at this point) time researching how this is done so that I can replicate it. Having to sync, then umount is tedious, and not very "newbie" friendly. Without sync/shutdown, it is too easy to correupt the data on it.

As to hotplug, it is a program or scipt called by the kernel if hotplugging is enabled in the kernel (default is yes). The kernel will make a user level call to the program /sbin/hotplug if it exists. Currently, it is a series of shell scripts that execute based on the device plugged in. Not all distributions have it installed or available, but it is designed to be easily configured. You only need to add your device id to the usb.usermap file to specify a setup script to be called when that device id is detected. The iRiver MP3 player ifp_gui is a good example of this. It includes a script to make the device rw for users. Other scripts automatically create a subdirectory under either /mnt or /media with either the drive label (if you have labeled it) , or as the device type (usbstorage, removable, etc).

Tobin
 
Old 11-02-2005, 04:08 PM   #20
Alan Lakin
Member
 
Registered: Sep 2002
Location: Wallington, Surrey, UK
Distribution: Ubuntu, Android phone
Posts: 119

Original Poster
Rep: Reputation: 15
What distro are you using? There will be a file somewhere down the /etc/.... tree. In Slackware it is /etc/rc.d/rc.modules. I simply uncomment the appropriate driver and save the file. At boot this file is executed and all of the uncommented modules are loaded.
 
Old 11-02-2005, 04:33 PM   #21
GrueMaster
Member
 
Registered: Aug 2005
Location: Oregon
Distribution: Kubuntu.
Posts: 848

Rep: Reputation: 30
Mandriva has an rc.modules that loads all modules in /etc/modules.preload. The problem is, there are a lot of devices out there that don't have kernel driver support, and don't need it either. There are a lot of devices that are supported in user land by libusb and other libraries. The hotplug utility just makes it easier to configure and use these (like automounting, etc).

For usb memory sticks that use the UMS (Usb Mass Storage) specification, the usb-storage driver is the correct one to use.
To see if your particular device is supported, check this listing:
http://www.qbik.ch/usb/devices/showd...=0&w=t&s=v&d=a
 
Old 11-10-2005, 05:53 AM   #22
Ephracis
Senior Member
 
Registered: Sep 2004
Location: Sweden
Distribution: Ubuntu, Debian
Posts: 1,109

Rep: Reputation: 50
I am having troubles with hotplug. Or the problem is that I don't know how to use it. I am using Debian Sarge and my usb stick works great. I plug it in and mount it, I use the user attribute in fstab and so on. I then added an icon to the desktop (KDE) that points to the usb location. What I want to do now is use the hotplug so I don't need to mount it by hand every time I plug it in. Is it also possible to edit the icon-thing in Desktop so that it changes icon when it is mounted/umounted?
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Missing memory in USB stick, flash memory, removable hd etc bamboo_spider Linux - Newbie 3 06-14-2006 05:39 PM
USB Memory Stick coal-fire-ice Mandriva 11 12-09-2004 11:59 PM
USB Memory Stick Link_420 Linux - Hardware 2 11-19-2004 01:09 AM
usb memory stick amadkow Linux - Newbie 4 06-14-2004 05:21 PM
USB Memory Stick jmdlcar Linux - Hardware 1 01-09-2004 07:03 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware

All times are GMT -5. The time now is 01:55 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration