Unable to mount usb drives.

Stuff that plugs in via USB, FireWire, eSATA, PS/2, etc.

Unable to mount usb drives.

Postby sixtydoses » 15 Nov 2009, 14:58

Hi,

I have some problems in mounting my thumb drives and usb external hdd. Previously I've used FreeBSD 5 and 6.x, and I've never(hardly) encountered problems in accessing usb drives.

Currently my system is running on FreeBSD 7.2-RELEASE-p3, and the error that appeared on dmesg:

Code: Select all
drm0: [ITHREAD]
uhub1: port 8, set config at addr 2 failed
uhub1: device problem (TIMEOUT), disabling port 8
uhub1: port 8, set config at addr 2 failed
uhub1: device problem (TIMEOUT), disabling port 8


This doesn't happen all the time though. At times it'll work, I can mount it, but error will occur when I start transferring some big files. Error appeared:

Code: Select all
da0 at umass-sim0 bus 0 target 0 lun 0
da0: <Kingston DataTraveler 2.0 PMAP> Removable Direct Access SCSI-0 device
da0: 40.000MB/s transfers
da0: 7636MB (15638528 512 byte sectors: 255H 63S/T 973C)
GEOM_LABEL: Label for provider da0s1 is msdosfs/KINGSTON.
umass0: BBB reset failed, TIMEOUT
umass0: BBB reset failed, TIMEOUT
umass0: BBB reset failed, TIMEOUT
umass0: BBB reset failed, TIMEOUT
umass0: BBB reset failed, TIMEOUT



But, sometimes, it simply worked beautifully. It gets mounted by itself, pops up thunar and display the its content. File transfer went smoothly. All's good. Guess those were some of my lucky moments. I did try to reboot my system everytime my bsd went apeshit, hoping that things will work after a fresh boot up, but still no luck.

Any idea on how to fix this?

Thanks in advance.
User avatar
sixtydoses
Member
 
Posts: 400
Joined: 18 Nov 2008, 15:21
Location: Near my dentist.

Postby aragon » 15 Nov 2009, 19:46

sixtydoses wrote:Any idea on how to fix this?

Entirely new USB stack in FreeBSD 8.0. Try upgrade.
aragon
Giant Locked
 
Posts: 2031
Joined: 16 Nov 2008, 17:04
Location: Cape Town, South Africa

Postby sixtydoses » 30 Nov 2009, 06:35

Thanks aragon, sorry it took me a while to reply back.

Previously I upgraded to 8.0-PRERELEASE (I put in the wrong releng tag), it didn't work, so I upgraded again to 8.0-Release. Still, it didn't work. I've been googling around but guess I failed to get my usb drive to work.

dmesg when I plug in my Kingston thumb drive:
Code: Select all
ugen1.2: <vendor 0x0951> at usbus1
umass0: <vendor 0x0951 product 0x1607, class 0/0, rev 2.00/1.10, addr 2> on usbus1
umass0:  SCSI over Bulk-Only; quirks = 0x0000
umass0:4:0:-1: Attached to scbus4
xptioctl: pass driver is not in the kernel
xptioctl: put "device pass" in your kernel config file
(probe0:umass-sim0:0:0:0): AutoSense Failed
da0 at umass-sim0 bus 0 target 0 lun 0
da0: <Kingston DataTraveler 2.0 PMAP> Removable Direct Access SCSI-0 device
da0: 40.000MB/s transfers
da0: 7636MB (15638528 512 byte sectors: 255H 63S/T 973C)
(da0:umass-sim0:0:0:0): READ(10). CDB: 28 0 0 0 0 1 0 0 1 0
(da0:umass-sim0:0:0:0): CAM Status: SCSI Status Error
(da0:umass-sim0:0:0:0): SCSI Status: Check Condition
(da0:umass-sim0:0:0:0): ILLEGAL REQUEST asc:24,0
(da0:umass-sim0:0:0:0): Invalid field in CDB
(da0:umass-sim0:0:0:0): Unretryable error
GEOM: da0: partition 1 does not end on a track boundary.
(da0:umass-sim0:0:0:0): READ(10). CDB: 28 0 0 ee 9f 80 0 0 4 0
(da0:umass-sim0:0:0:0): CAM Status: SCSI Status Error
(da0:umass-sim0:0:0:0): SCSI Status: Check Condition
(da0:umass-sim0:0:0:0): ILLEGAL REQUEST asc:24,0
(da0:umass-sim0:0:0:0): Invalid field in CDB
(da0:umass-sim0:0:0:0): Unretryable error
ugen1.2: <vendor 0x0951> at usbus1 (disconnected)
umass0: at uhub1, port 2, addr 2 (disconnected)
(da0:umass-sim0:0:0:0): lost device
(da0:umass-sim0:0:0:0): removing device entry



dmesg when I plugged in my external usb hdd:
Code: Select all
ugen1.2: <vendor 0x04b4> at usbus1
ugen1.2: <vendor 0x04b4> at usbus1 (disconnected)


I do have device pass in my kernel and I've uninstalled libusb and recompiled hal.

Code: Select all
[root@meh /usr/src/sys/amd64/conf]# kldstat -v | grep pass
      12 pass
[root@meh /usr/src/sys/amd64/conf]# kldstat -v | grep usb
      264 usbus/uhub
      262 uhub/usb_linux
      259 ohci/usbus
      258 uhci/usbus
      257 ehci/usbus
      256 at91_udp/usbus
      255 uss820/usbus


Appreciate any help offered.

Thanks!
User avatar
sixtydoses
Member
 
Posts: 400
Joined: 18 Nov 2008, 15:21
Location: Near my dentist.

Postby winrid » 30 Nov 2009, 20:00

I have a similar issue.
Code: Select all
[winrid@pcbsd ~]$ camcontrol rescan all
Re-scan of bus 0 was successful Re-scan of bus 1 was successful Re-scan of bus 2 was successful Re-scan of bus 3 was successful Re-scan of bus
4 was successful Re-scan of bus 5 was successful Re-scan of bus 6 was successful Re-scan of bus 7 returned error 0x39"


And with my USB drive in:
Code: Select all
#camcontrol devlist
<Generic USB SD Reader 1.00>       at scbus0 target 0 lun 0 (pass0,da0)
<Generic USB CF Reader 1.01>       at scbus0 target 0 lun 1 (pass1,da1)
<Generic USB SM Reader 1.02>       at scbus0 target 0 lun 2 (pass2,da2)
<Generic USB MS Reader 1.03>       at scbus0 target 0 lun 3 (pass3,da3)
<LG CD-RW CED-8080B 1.04>          at scbus2 target 0 lun 0 (cd0,pass4)
<LITE-ON DVDRW LH-20A1L BL05>      at scbus6 target 0 lun 0 (cd1,pass5)

Running FreeBSD 7.2-Stable. It won't detect my drive plugged in, could someone just help me get that fixed? I know how to mount drives, but the issue is there is none to mount even if plugged in!
winrid
Junior Member
 
Posts: 1
Joined: 30 Nov 2009, 19:53

Postby jb_fvwm2 » 30 Nov 2009, 20:45

I made a post Nov 2008 (search "rescan") that listed
four commands to mount [something]. Have those 4 been
tried in these intance(s)?
jb_fvwm2
Senior Member
 
Posts: 1503
Joined: 16 Nov 2008, 19:19

Postby sixtydoses » 04 Dec 2009, 22:08

Sorry for the late reply. I've tried to mount it manually last time but it just failed miserably.

Code: Select all
[root@meh /usr/home/meh]# camcontrol rescan all
Re-scan of bus 0 was successful
Re-scan of bus 1 was successful
Re-scan of bus 2 was successful
Re-scan of bus 3 was successful
Re-scan of bus 4 was successful


Code: Select all
[root@meh /usr/home/meh]# camcontrol devlist   
<ASUS DVD-E616P3 1.05>             at scbus1 target 0 lun 0 (cd0,pass0)
<TSSTcorp CDDVDW SH-S202J SB01>    at scbus1 target 1 lun 0 (cd1,pass1)
<Kingston DataTraveler 2.0 PMAP>   at scbus4 target 0 lun 0 (da0,pass2)
User avatar
sixtydoses
Member
 
Posts: 400
Joined: 18 Nov 2008, 15:21
Location: Near my dentist.

Postby sixtydoses » 05 Dec 2009, 09:31

I added [CMD=" "]options NETGRAPH[/CMD] and [CMD=" "]device udbp[/CMD] in my kernel, rebuild and reinstall it and as a result I got a 10 seconds of joy seeing my Kingston usb stick finally appeared on my screen :)

But then I encountered a different error when I tried to mount it:

Code: Select all
DBus error org.gtk.Private.RemoteVolumeMonitor.Failed: An operation is already pending


And another error:

Code: Select all
Unable to mount "KINGSTON":

Did not receive a reply. Possible causes include: the remote application did not send a reply, the message bus security policy blocked the
reply, the reply timeout expired, or the network connection was broken


I removed the .hal-mtab file and got it mounted by right clicking the Kingston device image and click on 'Mount'. But then I couldn't unmount it. Even using the command line.

So I decided to shut down my box for a bit, and start it up again. And am back to square one :(

Output of dmesg:

Code: Select all
xptioctl: pass driver is not in the kernel
xptioctl: put "device pass" in your kernel config file
(probe0:umass-sim0:0:0:0): AutoSense Failed
da0 at umass-sim0 bus 0 target 0 lun 0
da0: <Kingston DataTraveler 2.0 PMAP> Removable Direct Access SCSI-0 device
da0: 40.000MB/s transfers
da0: 7636MB (15638528 512 byte sectors: 255H 63S/T 973C)
GEOM: da0: partition 1 does not end on a track boundary.


When I tried to mount:

Code: Select all
[root@meh /usr/src/sys/amd64/conf]# mount_msdosfs /dev/da0 /media/
mount_msdosfs: /dev/da0: Invalid argument



Here's my custom kernel, am I missing anything?


Code: Select all
cpu             HAMMER
ident           MEH


options         SCHED_ULE               # ULE scheduler
options         PREEMPTION              # Enable kernel thread preemption
options         INET                    # InterNETworking
options         SCTP                    # Stream Control Transmission Protocol
options         FFS                     # Berkeley Fast Filesystem
options         SOFTUPDATES             # Enable FFS soft updates support
options         UFS_ACL                 # Support for access control lists
options         UFS_DIRHASH             # Improve performance on big directories
options         UFS_GJOURNAL            # Enable gjournal-based UFS journaling
options         MD_ROOT                 # MD is a potential root device
options         NFSCLIENT               # Network Filesystem Client
options         NFSSERVER               # Network Filesystem Server
options         NFS_ROOT                # NFS usable as /, requires NFSCLIENT
options         NTFS                    # NT File System
options         MSDOSFS                 # MSDOS Filesystem
options         CD9660                  # ISO 9660 Filesystem
options         PROCFS                  # Process filesystem (requires PSEUDOFS)
options         PSEUDOFS                # Pseudo-filesystem framework
options         GEOM_PART_GPT           # GUID Partition Tables.
options         GEOM_LABEL              # Provides labelization
options         COMPAT_43TTY            # BSD 4.3 TTY compat [KEEP THIS!]
options         COMPAT_IA32             # Compatible with i386 binaries
options         COMPAT_FREEBSD6         # Compatible with FreeBSD6
options         COMPAT_FREEBSD7         # Compatible with FreeBSD7
options         SCSI_DELAY=5000         # Delay (in ms) before probing SCSI
options         KTRACE                  # ktrace(1) support
options         STACK                   # stack(9) support
options         SYSVSHM                 # SYSV-style shared memory
options         SYSVMSG                 # SYSV-style message queues
options         SYSVSEM                 # SYSV-style semaphores
options         P1003_1B_SEMAPHORES     # POSIX-style semaphores
options         _KPOSIX_PRIORITY_SCHEDULING # POSIX P1003_1B real-time extensions
options         KBD_INSTALL_CDEV        # install a CDEV entry in /dev
options         HWPMC_HOOKS             # Necessary kernel hooks for hwpmc(4
options         AUDIT                   # Security event auditing
options         COMPAT_LINUX32
options         LINPROCFS
options         LINSYSFS
options         IPFIREWALL
options         IPDIVERT
options         NETGRAPH

# Make an SMP-capable kernel by default
options         SMP                     # Symmetric MultiProcessor Kernel

# CPU frequency control
device          cpufreq

# Bus support.
device          acpi
device          pci

# Floppy drives
device          fdc

# ATA and ATAPI devices
device          ata
device          atadisk         # ATA disk drives
device          ataraid         # ATA RAID drives
device          atapicd         # ATAPI CDROM drives
device          atapifd         # ATAPI floppy drives
device          atapicam
options         ATA_STATIC_ID   # Static device numbering

# SCSI Controllers
device          ahc             # AHA2940 and onboard AIC7xxx devices
options         AHC_REG_PRETTY_PRINT    # Print register bitfields in debug
                                        # output.  Adds ~128k to driver.
device          ahd             # AHA39320/29320 and onboard AIC79xx devices
options         AHD_REG_PRETTY_PRINT    # Print register bitfields in debug
                                        # output.  Adds ~215k to driver.

# SCSI peripherals
device          scbus           # SCSI bus (required for SCSI)
device          ch              # SCSI media changers
device          da              # Direct Access (disks)
device          sa              # Sequential Access (tape etc)
device          cd              # CD
device          pass            # Passthrough device (direct SCSI access)
device          ses             # SCSI Environmental Services (and SAF-TE)


# atkbdc0 controls both the keyboard and the PS/2 mouse
device          atkbdc          # AT keyboard controller
device          atkbd           # AT keyboard
device          psm             # PS/2 mouse
device          kbdmux          # keyboard multiplexer
device          vga             # VGA video card driver

device          splash          # Splash screen and screen saver support

# syscons is the default console driver, resembling an SCO console
device          sc
device          agp             # support several AGP chipsets

# Serial (COM) ports
#device         sio             # 8250, 16[45]50 based serial ports
device          uart            # Generic UART driver

# Parallel port
device          ppc
device          ppbus           # Parallel port bus (required)
device          lpt             # Printer
device          plip            # TCP/IP over parallel
device          ppi             # Parallel port interface device


# PCI Ethernet NICs.
device          em              # Intel PRO/1000 adapter Gigabit Ethernet Card
device          ixgb            # Intel PRO/10GbE Ethernet Card

# PCI Ethernet NICs that use the common MII bus controller code.
# NOTE: Be sure to keep the 'device miibus' line in order to use these NICs!
device          miibus          # MII bus support
device          nfe             # nVidia nForce MCP on-board Ethernet
device          rl              # RealTek 8129/8139

# Pseudo devices.
device          loop            # Network loopback
device          random          # Entropy device
device          ether           # Ethernet support
#device         sl              # Kernel SLIP
#device         ppp             # Kernel PPP
device          tun             # Packet tunnel.
device          pty             # Pseudo-ttys (telnet etc)
device          md              # Memory "disks"
device          gif             # IPv6 and IPv4 tunneling
device          faith           # IPv6-to-IPv4 relaying (translation)
device          firmware        # firmware assist module

# The `bpf' device enables the Berkeley Packet Filter.
# Be aware of the administrative consequences of enabling this!
# Note that 'bpf' is required for DHCP.
device          bpf             # Berkeley packet filter


# USB support
device          uhci            # UHCI PCI->USB interface
device          ohci            # OHCI PCI->USB interface
device          ehci            # EHCI PCI->USB interface (USB 2.0)
device          usb             # USB Bus (required)
device          udbp            # USB Double Bulk Pipe devices
device          uhid            # "Human Interface Devices"
device          ukbd            # Keyboard
device          ulpt            # Printer
device          umass           # Disks/Mass storage - Requires scbus and da
device          ums             # Mouse


# USB Serial devices
device          uftdi           # For FTDI usb serial adapters


# FireWire support
device          firewire        # FireWire bus code
device          sbp             # SCSI over FireWire (Requires scbus and da)
device          fwe             # Ethernet over FireWire (non-standard!)
device          fwip            # IP over FireWire (RFC 2734,3146)
device          dcons           # Dumb console driver
device          dcons_crom      # Configuration ROM for dcons



Anyone has the slightest idea about this? Should I try rebuilding my world?

Thanks.
User avatar
sixtydoses
Member
 
Posts: 400
Joined: 18 Nov 2008, 15:21
Location: Near my dentist.

Postby Beastie » 05 Dec 2009, 10:01

Disable/stop DBus and HAL ([cmd=#]/usr/local/etc/rc.d/dbus forcestop[/cmd], repeat but with hald instead of dbus) and try mounting manually.

Don't mount using mount_msdosfs. Use mount and specify the filesystem with the -t option, e.g.:
[cmd=#]mount -t msdosfs -o longnames /dev/da0 /mnt[/cmd]
May the source be with you!
Beastie
Senior Member
 
Posts: 1862
Joined: 28 Mar 2009, 11:27
Location: /dev/earth0

Postby sixtydoses » 05 Dec 2009, 11:25

Thanks Beastie. I tried that but I don't know what happened suddenly my computer hangs so I had to reboot. I plugged in my usb stick again and it automagically mounted by itself (dbus and hald are still running).

Back when I was still using FreeBSD 7.x, I used to have problems when transferring huge files from my usb stick to my pc. But just now I tried to transfer a number of files, one of it is almost 4gb worth of size, and all was good. Perfect. Wonderful. I don't even know how to describe my feelings right now :r

I don't feel like plugging it out, but oh well, let me just play around with it and see if the mojo stays.

dmesg output:

Code: Select all
ugen1.2: <Kingston> at usbus1
umass0: <Kingston DataTraveler 2.0, class 0/0, rev 2.00/1.10, addr 2> on usbus1
umass0:  SCSI over Bulk-Only; quirks = 0x0000
umass0:4:0:-1: Attached to scbus4
xptioctl: pass driver is not in the kernel
xptioctl: put "device pass" in your kernel config file
(probe0:umass-sim0:0:0:0): TEST UNIT READY. CDB: 0 0 0 0 0 0
(probe0:umass-sim0:0:0:0): CAM Status: SCSI Status Error
(probe0:umass-sim0:0:0:0): SCSI Status: Check Condition
(probe0:umass-sim0:0:0:0): UNIT ATTENTION asc:28,0
(probe0:umass-sim0:0:0:0): Not ready to ready change, medium may have changed
(probe0:umass-sim0:0:0:0): Retrying Command (per Sense Data)
da0 at umass-sim0 bus 0 target 0 lun 0
da0: <Kingston DataTraveler 2.0 PMAP> Removable Direct Access SCSI-0 device
da0: 40.000MB/s transfers
da0: 7636MB (15638528 512 byte sectors: 255H 63S/T 973C)
GEOM: da0: partition 1 does not end on a track boundary.
User avatar
sixtydoses
Member
 
Posts: 400
Joined: 18 Nov 2008, 15:21
Location: Near my dentist.

Postby sixtydoses » 06 Dec 2009, 09:28

The mojo stays! Just 98% of it though :P

Well I can mount my usb stick now with no problem, either as root or non root. It won't get mounted automagically like before, but I can live with that :)

Thanks a lot everyone :e
User avatar
sixtydoses
Member
 
Posts: 400
Joined: 18 Nov 2008, 15:21
Location: Near my dentist.

Postby sixtydoses » 06 Dec 2009, 09:37

Oh I forgot to mention that if I were to mount it as non-root, it'll take a while to get it mounted. Prolly about 7 - 10 minutes. Not sure why though.
User avatar
sixtydoses
Member
 
Posts: 400
Joined: 18 Nov 2008, 15:21
Location: Near my dentist.


Return to Peripheral Hardware

Who is online

Users browsing this forum: No registered users and 0 guests