LinuxQuestions.org
Share your knowledge at the LQ Wiki.
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 01-23-2007, 09:08 AM   #1
Pakhomov
LQ Newbie
 
Registered: Jan 2007
Posts: 6

Rep: Reputation: 0
My Flash is die. May be not?


Hello, All!

I have USB Flash A-DATA PD4 2Gb. I copied all data in my notebook and umounted it. After I plug in notebook for writing. But flash is not recognized as disk (dmesg output):

usb 4-2: new high speed USB device using ehci_hcd and address 4
usb 4-2: configuration #1 chosen from 1 choice
scsi1 : SCSI emulation for USB Mass Storage devices
usb-storage: device found at 4
usb-storage: waiting for device to settle before scanning
scsi 1:0:0:0: Direct-Access USB 2.0 Flash Disk 0.00 PQ: 0 ANSI: 2
sda: too big for this kernel. Use a kernel compiled with support for large block devices.
SCSI device sda: 0 512-byte hdwr sectors (0 MB)
sda: Write Protect is off
sda: Mode Sense: 00 00 00 00
sda: assuming drive cache: write through
sd 1:0:0:0: Attached scsi removable disk sda
sd 1:0:0:0: Attached scsi generic sg0 type 0
usb-storage: device scan complete

Were with worked flash:

usb 4-2: new high speed USB device using ehci_hcd and address 2
usb 4-2: configuration #1 chosen from 1 choice
scsi0 : SCSI emulation for USB Mass Storage devices
scsi 0:0:0:0: Direct-Access USB 2.0 Flash Disk 0.00 PQ: 0 ANSI: 2
SCSI device sda: 4030464 512-byte hdwr sectors (2064 MB)
sda: Write Protect is off
SCSI device sda: 4030464 512-byte hdwr sectors (2064 MB)
sda: Write Protect is off
sda: sda1
sd 0:0:0:0: Attached scsi removable disk sda
sd 0:0:0:0: Attached scsi generic sg0 type 0


I download from A-DATA site utility for formating flash disk for Windows. It recognized and I formated flash as 2Gb disk. After Linux can see USB storage device, but only 211Mb (10% full capacity).
I try use fdisk. My flash were (H/S/C) 255/63/250, but now only 255/63/25.
I try formated flash by A-DATA utility again. But it recognize my flash as 211Mb disk.
How I can return my 2Gb capacity?
 
Old 01-23-2007, 02:30 PM   #2
dracolich
Senior Member
 
Registered: Jul 2005
Distribution: Slackware
Posts: 1,274

Rep: Reputation: 63
A couple of ideas come to mind:

1. From linux, format it as ext2 and see what capacity you get. I think the command is mkfs.ext2

2. Possibly the mbr is incorrect. Not invalid, but incorrect. From linux, "zero" the device using "dd if=/dev/zero of=/dev/device" without quotes and replace device with the drive's actual device node (sda, sdb,...) Then from Windows use the format utility. Or from linux try to use fdisk or cfdisk to create the partition and use mkfs.fat to format it.
 
Old 01-24-2007, 07:23 AM   #3
Pakhomov
LQ Newbie
 
Registered: Jan 2007
Posts: 6

Original Poster
Rep: Reputation: 0
mkfs.ext2 - capacity 211Mb only.

# dd if=/dev/zero of=/dev/sda
dd: writing to `/dev/sda': No space left on device
412673+0 records in
412672+0 records out
211288064 bytes (211 MB) copied, 187.579 seconds, 1.1 MB/s

# fdisk -l /dev/sda

Disk /dev/sda: 211 MB, 211288064 bytes
16 heads, 32 sectors/track, 806 cylinders
Units = cylinders of 512 * 512 = 262144 bytes

Device Boot Start End Blocks Id System
/dev/sda1 * 1 832 212976 6 FAT16
Partition 1 has different physical/logical endings:
phys=(830, 15, 32) logical=(831, 15, 32)


For such new usb flash disk:
# fdisk -l /dev/sda

Disk /dev/sda: 2063 MB, 2063597568 bytes
255 heads, 63 sectors/track, 250 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System
/dev/sda1 * 1 251 2015200+ 6 FAT16
Partition 1 has different physical/logical endings:
phys=(249, 254, 63) logical=(250, 225, 39)


If I change number of heads/sectros/cylinders to 255/63/250 by fdisk (in expert mode) then after unplug/plug usb device I have 255/63/25 only.

Oh!
 
Old 01-26-2007, 08:21 PM   #4
teckk
LQ Guru
 
Registered: Oct 2004
Distribution: Arch
Posts: 5,137
Blog Entries: 6

Rep: Reputation: 1826Reputation: 1826Reputation: 1826Reputation: 1826Reputation: 1826Reputation: 1826Reputation: 1826Reputation: 1826Reputation: 1826Reputation: 1826Reputation: 1826
I beleive you need to DD or format the partition.
That would be something like.
Code:
dd if=/dev/zero of=/dev/sda1 bs=512
If you are using windows to format it then just plug it in and windows will take care of it. I would format it FAT not ext3. It says it is now FAT16, that's because it is only 2GB.

Or you can Fdisk,Cfdisk it and then format it FAT.

How are you trying to mount the drive now in Linux? Should be something like
Code:
mount -t vfat /dev/sda1 /mounting/point
The output of dmesg says it is sda1
 
  


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
FLASH FLASH XP Home and Samba Fix FLASH FLASH zollodav Linux - Networking 1 02-19-2006 01:16 AM
LXer: Open source must die die die LXer Syndicated Linux News 0 01-28-2006 08:16 PM
Die Miva, Die! Apache Woes, Cannot kill Miva linchat Linux - Software 3 09-16-2005 08:03 PM
Die, lotus notes, die (sorry for ranting) slackist General 10 01-10-2005 10:42 AM
Die Caps lock Die! tfdml37 Linux - General 1 06-26-2004 02:00 AM

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

All times are GMT -5. The time now is 12:12 PM.

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