LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   newbie: do i -really- have to reboot when switching usb ??? (https://www.linuxquestions.org/questions/linux-newbie-8/newbie-do-i-really-have-to-reboot-when-switching-usb-271809/)

sirpelidor 12-30-2004 03:27 AM

newbie: do i -really- have to reboot when switching usb ???
 
Hi, I'm running Linux kernel 2.4.22 on a older PC (PIII 600) and it has 2 usb ports with it.
1 usb port is connected with a webcam, the other one is connected with a printer.

it seems like to me whenever I wanna switch from printer usb port to a digitial camera usb port, my linux won't recongize it. i need to "reboot" the system first before it noticed my d-cam....

did I mis-config something??? thought usb port suppose to be respond in real time.


p.s: this kernel is come from mdk 9.2, and yes... i will move to kernel 2.6 when i have more free time :P

thank you

darkleaf 12-30-2004 04:00 AM

Nope you don't have to there's a program called hotplug that does this.

sirpelidor 12-30-2004 04:27 AM

ok, so i need to compile kernel for hotplug first right? or hotplug is a "program" that doesn't require kernel?

scuzzman 12-30-2004 05:03 AM

kernel 2.6.9 has really good hotplug support, and the 2.6.10 it's supposed to be even better
might want to consider a patch or even recompile
if not, you could try inserting but, but i'm not suer how to do that

beanerjo 12-30-2004 05:18 AM

Try
Code:

# modprobe -r usb-storage
# modprobe usb-storage

or try different device names, eg /dev/sdb1 instead of /dev/sda1, etc, for mounting.

scuzzman 12-30-2004 05:18 AM

Isn't there a hotplug module as well?

darkleaf 12-30-2004 09:45 AM

There's a hotplug program but I think it needs the hotplug kernel options as well. The package is just called "hotplug". The kernel options are under hotpluggable device IIRC in the device drivers part.

beanerjo 12-30-2004 05:09 PM

hotplug isn't a module. It's a set of programs that detect usb, pci, etc, and load necessary modules. Personally, I don't use the program but just insert working modules (which I know work because I know my hardware). I am quite sure you already have "hotplug" because you can use your printer and camera. Back to your original question of avoiding rebooting, why don't you just try unloading and loading usb-storage (or trying /dev/sdb1, /dev/sdc1, ...)?

zorba4 01-04-2005 04:43 PM

Hotplug is a rpm, you probably have to install it first. It is not in Mandrake 9.2 minimal install, you have to install it.
Also install usbview, it's rather useful when you plug and unplug USB things.
Also do "tail -f /var/log/syslog" while disconnect/reconnecting things, very useful infos.


All times are GMT -5. The time now is 06:24 AM.