# Sometimes stops see usb-devices.



## goshanecr (Apr 26, 2010)

Hi all! I have FreeBSD 8.0 i386. And regular appears that problem:
1. I'm insert USB Flash drive
2. */var/log/messages*

```
Apr 26 18:42:57 serv root: Unknown USB device: vendor 0x0930 product 0x6545 bus uhub2
Apr 26 18:42:57 serv kernel: ugen0.4: <Kingston> at usbus0
Apr 26 18:42:57 serv kernel: umass1: <Kingston DataTraveler 112, class 0/0, rev 2.00/1.10, addr 4> on usbus0
Apr 26 18:42:57 serv kernel: umass1:  SCSI over Bulk-Only; quirks = 0x0000
Apr 26 18:42:58 serv kernel: umass1:1:1:-1: Attached to scbus1
Apr 26 18:42:59 serv kernel: (probe0:umass-sim1:1:0:0): TEST UNIT READY. CDB: 0 0 0 0 0 0 
Apr 26 18:42:59 serv kernel: (probe0:umass-sim1:1:0:0): CAM status: SCSI Status Error
Apr 26 18:42:59 serv kernel: (probe0:umass-sim1:1:0:0): SCSI status: Check Condition
Apr 26 18:42:59 serv kernel: (probe0:umass-sim1:1:0:0): SCSI sense: UNIT ATTENTION asc:28,0 (Not ready to ready change, medium may have changed)
Apr 26 18:42:59 serv kernel: da1 at umass-sim1 bus 1 scbus1 target 0 lun 0
Apr 26 18:42:59 serv kernel: da1: <Kingston DataTraveler 112 PMAP> Removable Direct Access SCSI-0 device 
Apr 26 18:42:59 serv kernel: da1: 1.000MB/s transfers
Apr 26 18:42:59 serv kernel: da1: 7650MB (15667200 512 byte sectors: 255H 63S/T 975C)
Apr 26 18:43:00 serv kernel: GEOM: da1: partition 1 does not end on a track boundary.
```
3. I'm try to mount it

```
mount_msdosfs -L ru_RU.UTF-8 -D CP866 /dev/da1s1 /mnt/flash
```
 ... and nothing happens. mount - commant not stops by CTRL+C, it stops only if i remove USB Flash and that's log messages after removing:
4. */var/log/messages*

```
Apr 26 18:43:51 serv kernel: ugen0.4: <Kingston> at usbus0 (disconnected)
Apr 26 18:43:51 serv kernel: umass1: at uhub2, port 4, addr 4 (disconnected)
Apr 26 18:43:51 serv kernel: (da1:umass-sim1:1:0:0): lost device
Apr 26 18:43:51 serv kernel: (da1:umass-sim1:1:0:0): Invalidating pack
Apr 26 18:43:51 serv kernel: g_vfs_done():da1s1[READ(offset=7368704, length=4096)]error = 6
Apr 26 18:43:51 serv kernel: (da1:umass-sim1:1:0:0): Synchronize cache failed, status == 0xa, scsi status == 0x0
Apr 26 18:43:51 serv kernel: (da1:umass-sim1:1:0:0): removing device entry
```

After that my system not see any usb devices (nothing appears in /var/log/messages or console when i'm plug usb), all work only after reboot. I think that problem maybe in 

```
Apr 26 18:43:00 serv kernel: GEOM: da1: partition 1 does not end on a track boundary.
```
 but how fix that?

*KERNEL.CONF*

```
cpu             I686_CPU
ident           SERV

options         IPDIVERT
options         DUMMYNET

options         IPFIREWALL
options         IPFIREWALL_FORWARD
options         IPFIREWALL_VERBOSE
options         IPFIREWALL_VERBOSE_LIMIT=10

options         NETGRAPH
options         NETGRAPH_BPF
options         NETGRAPH_PPTPGRE
options         NETGRAPH_MPPC_ENCRYPTION

options         DEVICE_POLLING

device          sound
device          snd_hda
###############################################################################
options         SCHED_ULE               # ULE scheduler
options         PREEMPTION              # Enable kernel thread preemption
options         INET                    # InterNETworking
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         MSDOSFS                 # MSDOS 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 (sgtty)
options         COMPAT_FREEBSD4         # Compatible with FreeBSD4
options         COMPAT_FREEBSD5         # Compatible with FreeBSD5
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         PRINTF_BUFR_SIZE=128    # Prevent printf output being interspersed.
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         MAC                     # TrustedBSD MAC Framework
options         FLOWTABLE               # per-cpu routing cache

# To make an SMP kernel, the next two lines are needed
options         SMP                     # Symmetric MultiProcessor Kernel
device          apic                    # I/O APIC

# CPU frequency control
device          cpufreq

# Bus support.
device          acpi
device          pci

# ATA and ATAPI devices
device          ata
device          atadisk         # ATA disk drives
options         ATA_STATIC_ID   # Static device numbering

# SCSI peripherals
device          scbus           # SCSI bus (required for SCSI)
device          da              # Direct Access (disks)
device          pass            # Passthrough device (direct SCSI access)

# 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

device          pmtimer

device          miibus          # MII bus support
device          age             # Attansic/Atheros L1 Gigabit Ethernet
device          nfe             # nVidia nForce MCP on-board Ethernet
device          rl              # RealTek 8129/8139

# Wireless NIC cards
device          wlan            # 802.11 support
options         IEEE80211_AMPDU_AGE # age frames in AMPDU reorder q's
options         IEEE80211_SUPPORT_MESH  # enable 802.11s draft support
device          wlan_wep        # 802.11 WEP support
device          wlan_ccmp       # 802.11 CCMP support
device          wlan_tkip       # 802.11 TKIP support
device          wlan_amrr       # AMRR transmit rate control algorithm
device          ral             # Ralink Technology RT2500 wireless NICs.
device          ralfw

# Pseudo devices.
device          loop            # Network loopback
device          random          # Entropy device
device          ether           # Ethernet support
device          tun             # Packet tunnel.
device          pty             # BSD-style compatibility pseudo ttys
device          gif             # IPv6 and IPv4 tunneling
device          faith           # IPv6-to-IPv4 relaying (translation)
device          firmware        # firmware assist module

device          bpf             # Berkeley packet filter

# USB support
device          ohci            # OHCI PCI->USB interface
device          ehci            # EHCI PCI->USB interface (USB 2.0)
device          usb             # USB Bus (required)
device          uhid            # "Human Interface Devices"
device          ukbd            # Keyboard
device          umass           # Disks/Mass storage - Requires scbus and da
device          ums             # Mouse
```


----------



## jb_fvwm2 (Apr 27, 2010)

I ran across this issue today.
...
Upon insert, if bright letters appear at a console, it is detected, correct?

```
camcontrol rescan all
mount -t msdosfs /dev/da0 /mnt_fat32  # probably wont work then
mount -t msdosfs /dev/da0s1 /mnt_fat32 # may work
#  Most of the time, the first mount command "prepares " the
#  second mount command to work. To test, 
cd /mnt_fat32 && ls 
#  or
df -aH
```
Or even the device could be "loose" and needs a tighter fit.


----------

