I have a WD 3Tb USB3 disk that I cannot mount by UUID or ID. When I plug in the disk, KDE doesn’t automount it, /dev/disk/by-uuid/ doesn’t show the disk at all, and /dev/disk/by-id/ does show the disk but there is no ID for the partition itself.
Just tried on Ubuntu 12.04 server and it works perfectly there, the UUID is recognized etc… I even tried to generate a new UUID with tune2fs but it didn’t change anything. I need to get it to mount by UUID or ID for an rsync backup script.
dmesg
[32462.575019] usb 2-1: new high-speed USB device number 2 using ehci-pci
[32462.693257] usb 2-1: New USB device found, idVendor=1058, idProduct=1230
[32462.693262] usb 2-1: New USB device strings: Mfr=2, Product=3, SerialNumber=1
[32462.693264] usb 2-1: Product: My Book 1230
[32462.693267] usb 2-1: Manufacturer: Western Digital
[32462.693269] usb 2-1: SerialNumber: 574343344530303233313233
[32462.693538] usb-storage 2-1:1.0: USB Mass Storage device detected
[32462.693599] scsi10 : usb-storage 2-1:1.0
[32463.696904] scsi 10:0:0:0: Direct-Access WD My Book 1230 1050 PQ: 0 ANSI: 6
[32463.698910] sd 10:0:0:0: Attached scsi generic sg2 type 0
[32463.700523] scsi 10:0:0:1: Enclosure WD SES Device 1050 PQ: 0 ANSI: 6
[32463.700573] ses 10:0:0:1: Attached Enclosure device
[32463.700662] ses 10:0:0:1: Attached scsi generic sg3 type 13
[32463.703393] ses 10:0:0:1: Failed to get diagnostic page 0x8000002
[32463.703397] ses 10:0:0:1: Failed to bind enclosure -19
[32463.704640] sd 10:0:0:0: [sdb] Spinning up disk...
[32464.705007] ..........ready
[32473.975810] sd 10:0:0:0: [sdb] 732558336 4096-byte logical blocks: (3.00 TB/2.72 TiB)
[32473.977055] sd 10:0:0:0: [sdb] Write Protect is off
[32473.977059] sd 10:0:0:0: [sdb] Mode Sense: 53 00 10 08
[32473.978304] sd 10:0:0:0: [sdb] No Caching mode page found
[32473.978307] sd 10:0:0:0: [sdb] Assuming drive cache: write through
[32473.979307] sd 10:0:0:0: [sdb] 732558336 4096-byte logical blocks: (3.00 TB/2.72 TiB)
[32473.981801] sd 10:0:0:0: [sdb] No Caching mode page found
[32473.981804] sd 10:0:0:0: [sdb] Assuming drive cache: write through
[32474.084204] sdb: sdb1
[32474.085935] sd 10:0:0:0: [sdb] 732558336 4096-byte logical blocks: (3.00 TB/2.72 TiB)
[32474.090805] sd 10:0:0:0: [sdb] No Caching mode page found
[32474.090808] sd 10:0:0:0: [sdb] Assuming drive cache: write through
[32474.090812] sd 10:0:0:0: [sdb] Attached SCSI disk
[32504.838022] usb 2-1: reset high-speed USB device number 2 using ehci-pci
sudo /usr/sbin/parted -l
Model: ATA WDC WD1001FALS-0 (scsi)
Disk /dev/sda: 1000GB
Sector size (logical/physical): 512B/512B
Partition Table: msdos
Number Start End Size Type File system Flags
1 1049kB 106MB 105MB primary ntfs type=07
2 106MB 315GB 314GB primary ntfs type=07
3 315GB 1000GB 686GB extended boot, lba, type=0f
5 315GB 323GB 8588MB logical linux-swap(v1) type=82
6 323GB 431GB 107GB logical ext4 type=83
7 431GB 1000GB 570GB logical ext4 type=83
Model: WD My Book 1230 (scsi)
Disk /dev/sdb: 3001GB
Sector size (logical/physical): 4096B/4096B
Partition Table: msdos
Number Start End Size Type File system Flags
1 1049kB 3001GB 3001GB primary type=83
(why no file system shown on the usb disk? it’s ext4 and it works when mounted with /dev/sdb1…)
Can you please next time copy thepropmt, the command, the output and the next prompt in one sweep between the CODE tags. We now have only the output and a story on how you probably generated it.
I do not know exactly where to start in analyzing this, but what triggers me is that you say you use tune2fs, but you never explained or proved that there is a file system of a type that can be handled by tune2fs (ext2/3/4) on the one partition you have.
My suspicion is that there is no file system at all there. This would explain:
that fuse2fs does not do what you want;
there is no UUID at all for the file system detected by udev and thus several symlink entries are not created in /dev/disk/;
there is no popup from KDE asking you what to do with the file system.
It’s been a while since I got the HD so I cannot remember exactly how it is created BUT there is data in it, and it works.
I’ll have to create the partition table and partition again, I guess.
Also I just tried this with an ext4 8gb flash drive and it works, so it’s probably the partition table that’s the fault.
On 2014-03-08 19:26, Daliz wrote:
>
> ^ okay that would explain it.
>
> It’s been a while since I got the HD so I cannot remember exactly how it
> is created BUT there is data in it, and it works.
> I’ll have to create the partition table and partition again, I guess.
Unfortunately, I don’t think it is possible to keep the data in place.
You will have to back it up somewhere else, create totally new GPT
partition table, create filesystem, recover data from backup.
> Also I just tried this with an ext4 8gb flash drive and it works, so
> it’s probably the partition table that’s the fault.
It is a strange thing you do not get a message in the log related to
this. I’m very surprised that the MBR table says it contains a 3000 GB
partition, I thought it was impossible. Maybe some tools can handle it,
and some can not.
–
Cheers / Saludos,
Carlos E. R.
(from 13.1 x86_64 “Bottle” at Telcontar)
With a 512B sector size, you cannot have MBR partitioning on a disk that large. But the disk has 4K logical sector size, which should allow going to around a 16T disk before the LBA addresses exceed 32 bits.
On 2014-03-08 21:56, nrickert wrote:
>
> robin_listas;2629386 Wrote:
>> I’m very surprised that the MBR table says it contains a 3000 GB
>> partition, I thought it was impossible.
>
> That’s not a problem, I think.
>
> With a 512B sector size, you cannot have MBR partitioning on a disk that
> large. But the disk has 4K logical sector size, which should allow
> going to around a 16T disk before the LBA addresses exceed 32 bits.
That could be, but read this paragraph in the wikipedia:
+++···························
While the MBR layout (and also the protective MBR layout) was defined
around a sector size of 512 bytes per sector, the actual sector size can
be larger on various media such as MO disks or hard disks with Advanced
Format. Extra space in the MBR typically remains unused.
If the actual size of the disk exceeds the maximum partition size
representable using the legacy 32-bit LBA entries in the MBR partition
table, the recorded size of this partition is clipped at the maximum,
thereby ignoring the rest of disk. This amounts to a maximum reported
size of 2 TiB, assuming a disk with 512 bytes per sector (see 512e). It
would result in 16 TiB with 4 KB sectors (4Kn), but since many older
operating systems and tools are hard-wired for a sector size of 512
bytes or are limited to 32-bit calculations, exceeding the 2 TiB limit
would cause serious compatibility problems.
···························+±
So, what I think is that some tools simply can not work with such a
partition table.
I got recently a new disk, 3 TB size. It has 4 KB sectors (512 logical).
I initially formatted it as MBR with gparted. It attempted to do it, but
at some point of the process it bailed out and said it was impossible
(When creating the filesystem, I think).
Maybe Ubuntu has a toolchain that allows it, whereas openSUSE does not :-?
–
Cheers / Saludos,
Carlos E. R.
(from 13.1 x86_64 “Bottle” at Telcontar)
If you were to mount that 3T disk in an external drive container, and access it via USB, you would probably find that it has a logical sector size of 4K. Or, at least, that’s my experience with a 1T disk.
On 2014-03-09 02:16, nrickert wrote:
>
> robin_listas;2629417 Wrote:
>> I got recently a new disk, 3 TB size. It has 4 KB sectors (512 logical).
>> I initially formatted it as MBR with gparted. It attempted to do it, but
>> at some point of the process it bailed out and said it was impossible
>> (When creating the filesystem, I think).
>
> If you were to mount that 3T disk in an external drive container, and
> access it via USB, you would probably find that it has a logical sector
> size of 4K. Or, at least, that’s my experience with a 1T disk.
Let me see! You got me curious.
On a USB dock:
gdisk:
Found valid GPT with protective MBR; using GPT.
Disk /dev/sde: 5860533168 sectors, 2.7 TiB
Logical sector size: 512 bytes
fdisk:
Disk /dev/sde: 3000.6 GB, 3000592982016 bytes, 5860533168 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes <===
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk label type: dos
hdparm -I /dev/sde
Configuration:
Logical max current
cylinders 16383 16383
heads 16 16
sectors/track 63 63
--
CHS current addressable sectors: 16514064
LBA user addressable sectors: 268435455
LBA48 user addressable sectors: 5860533168
Logical Sector size: 512 bytes
Physical Sector size: 4096 bytes
Logical Sector-0 offset: 0 bytes
device size with M = 1024*1024: 2861588 MBytes
device size with M = 1000*1000: 3000592 MBytes (3000 GB)
smartctl -a /dev/sde
Sector Sizes: 512 bytes logical, 4096 bytes physical
Directly via internal SATA dock:
fdisk:
Disk /dev/sde: 3000.6 GB, 3000592982016 bytes, 5860533168 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes <===
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk label type: dos
gdisk:
Found valid GPT with protective MBR; using GPT.
Disk /dev/sde: 5860533168 sectors, 2.7 TiB
Logical sector size: 512 bytes
hdparm -I /dev/sde
Configuration:
Logical max current
cylinders 16383 16383
heads 16 16
sectors/track 63 63
--
CHS current addressable sectors: 16514064
LBA user addressable sectors: 268435455
LBA48 user addressable sectors: 5860533168
Logical Sector size: 512 bytes
Physical Sector size: 4096 bytes
Logical Sector-0 offset: 0 bytes
device size with M = 1024*1024: 2861588 MBytes
device size with M = 1000*1000: 3000592 MBytes (3000 GB)
Only fdisk is fooled, the rest of the tools keep saying the same things.
I see above there is something there named “LBA48” which can address
them all. Is that the normal LBA we use?
–
Cheers / Saludos,
Carlos E. R.
(from 13.1 x86_64 “Bottle” at Telcontar)
Notice the notation under gdisk “Found valid GPT with protective MBR; using GPT” this generally means the disk was created using the “new” GUID partitioning. protective MBR is a flag set so that “older” programs that use MBR partioning will not destroy the data on the disk. The disk probably was formated on a “UEFI” system.
nrickert was correct about the final version of MBR being able to recognize disks up to 16 TB in size. This was done by using a combination of logical sector size of 512 bytes and physical sector size of 4096 bytes.
> Notice the notation under gdisk “Found valid GPT with protective MBR;
> using GPT” this generally means the disk was created using the “new” GUID
> partitioning. protective MBR is a flag set so that “older” programs
> that use MBR partioning will not destroy the data on the disk. The disk
> probably was formated on a “UEFI” system.
Most emphatically was not! I formatted it on this same BIOS only
machine, using parted, and the internal docker (sata).
> nrickert was correct about the final version of MBR being able to
> recognize disks up to 16 TB in size. This was done by using a combination
> of logical sector size of 512 bytes and physical sector size of 4096
> bytes.
Well, it seems that openSUSE does not support this.
On 2014-03-09 04:26, nrickert wrote:
>
> Your disk enclosure must be fancier than mine. It is presumably
> handling the buffering for 512B logical sectors.
I bought that one a year ago. It is a Sharkoon sata quickport XT.
Supports both 2.5" and 3.5" hard disks, using either USB 2 or eSATA.
Inexpensive and practical. The only problem is that smartctl does not
like it.
–
Cheers / Saludos,
Carlos E. R.
(from 13.1 x86_64 “Bottle” at Telcontar)
Thanks for the replies everyone, this is most informative.
A little update: In hopes of converting the partition table to GPT (see: http://rodsbooks.com/gdisk/mbr2gpt.html) I started gdisk. It told me that GPT partition table cannot be created because the partition table and partition would overlap. Therefore I had to shrink and move the partition (took 52 hours with all the data lol) to the right. After that, started gdisk, chose write partition table and exit.
Now gdisk says that there is a healthy GPT partition table with a “protective MBR”. OS13.1 still does not recognize the partition, but it can be mounted manually (using “/dev/sdX1…”).
Also GParted seems to recognize it just fine, and also shows there’s a GPT partition table.
I cannot copy/paste terminal outputs right now because I’m not at home, but I will later. In the meantime, please share if you have ideas.
Sorry, but this is contradictory information. When there is a device file for it (/de/sdX1), “OS 13.1” (in fact the kernel) did detect the device and interpreted the partition table and udev created those device files.
(with the device connected of course and when you are sure it is sdb), so we can see for ourselves what is created by udev? We are mostly non-believers and only trust the system.
Daliz wrote:
> Sorry, I meant KDE does not pop up the new filesystem notification, and
> it does not show up in /dev/disk/by-uuid/ or /dev/disk/by-id/.
>
> So it can only be mounted by ‘sudo mount /dev/sdb1 /media/whatever’.
It would be interesting to see the kernel output when it detects the
disk (from dmesg)
hkt@desktop:~> sudo /usr/sbin/parted -l
root's password:
Model: ATA WDC WD1001FALS-0 (scsi)
Disk /dev/sda: 1000GB
Sector size (logical/physical): 512B/512B
Partition Table: msdos
Number Start End Size Type File system Flags
1 1049kB 106MB 105MB primary ntfs type=07
2 106MB 315GB 314GB primary ntfs type=07
3 315GB 1000GB 686GB extended boot, lba, type=0f
5 315GB 323GB 8588MB logical linux-swap(v1) type=82
6 323GB 431GB 107GB logical ext4 type=83
7 431GB 1000GB 570GB logical ext4 type=83
Model: WD My Book 1230 (scsi)
Disk /dev/sdb: 3001GB
Sector size (logical/physical): 4096B/4096B
Partition Table: gpt
Number Start End Size File system Name Flags
1 90.0GB 3001GB 2911GB Linux filesystem
gdisk:
hkt@desktop:~> sudo /usr/sbin/gdisk /dev/sdb
GPT fdisk (gdisk) version 0.8.7
Partition table scan:
MBR: protective
BSD: not present
APM: not present
GPT: present
Found valid GPT with protective MBR; using GPT.
Command (? for help):
GParted shows ext4 partition like it should be and I have also “checked” it using GParted and also with e2fsck (same thing I suppose). They report no errors.
It is clear that the disk is detected by th system and that udev makes the dvice special file for the device (/dev/sdb and all the five symbolic links in /dev/disk/by-* to it).
It is also clear that the system does not detect a partition. There is no symlinks to /dev/sdb1. But you say (but do not show!) that you can do:
sudo mount /dev/sdb1 /media/whatever
Again you should not say things like
So it can only be mounted by ‘sudo mount /dev/sdb1 /media/whatever’.
withhout proving it by posting the relevant computer text.
Can you please show it and also
ls -l /dev/sdb*
gdisk also does see a GPT table, but no partitions. Which is in line with what the system thinks.
parted (which I do not realy know, never used it) is contradictory and finds a partitions in the GPT.
That is realy strange. Why does gdisk intrprete the GPT different from all others?