Results 1 to 3 of 3

Thread: cp file to mSATA (universal disk format) resulting in I/O error depending on file name characters(?)

  1. #1
    Join Date
    Apr 2015
    Location
    Berlin
    Posts
    35

    Default cp file to mSATA (universal disk format) resulting in I/O error depending on file name characters(?)

    Hi,

    I cannot do rsync or cp on my external mSATA. It results in an input/output error. I'm testing two files where the error appears but it seems related to the file name characters not to the file itself which is strange. I did

    Code:
    cp --preserve --verbose --force  '/home/andreas/Dokumente/Musik/Aufnahmen/Auf in den Osten – Let’s Go East!.rtf' '/run/media/andreas/UDF-Externe-Festplatte/Musik/Aufnahmen'
    cp: cannot create regular file `...': Input/output error
    Code:
    cp --preserve --verbose --force  '/home/andreas/Dokumente/Musik/Aufnahmen/Auf in den Osten – Let’s Go East!.txt' '/run/media/andreas/UDF-Externe-Festplatte/Musik/Aufnahmen'
    no error

    The strange issue is, when I manually interchange and rename both file extensions (.rtf renamed to .txt and .txt renamed to .rtf) on the source device then the identical errors happens: .txt gets copied but .rtf not, although .txt is actually the original rich text file and .rtf is the original text file.

    Any hints or solutions or (debug) ideas to look at? Thank you.

    Code:
    hdparm -I /dev/sdb
    /dev/sdb:
    
    ATA device, with non-removable media
            Model Number:       Samsung SSD 850 EVO mSATA 1TB           
            Serial Number:      S33FNX0H600788J     
            Firmware Revision:  EMT41B6Q
            Transport:          Serial, ATA8-AST, SATA 1.0a, SATA II Extensions, SATA Rev 2.5, SATA Rev 2.6, SATA Rev 3.0
    Standards:
            Used: unknown (minor revision code 0x0039) 
            Supported: 9 8 7 6 5 
            Likely used: 9
    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: 1953525168
            Logical  Sector size:                   512 bytes
            Physical Sector size:                   512 bytes
            Logical Sector-0 offset:                  0 bytes
            device size with M = 1024*1024:      953869 MBytes
            device size with M = 1000*1000:     1000204 MBytes (1000 GB)
            cache/buffer size  = unknown
            Form Factor: unknown (0x0006]
            Nominal Media Rotation Rate: Solid State Device
    Capabilities:
            LBA, IORDY(can be disabled)
            Queue depth: 32
            Standby timer values: spec'd by Standard, no device specific minimum
            R/W multiple sector transfer: Max = 1   Current = 1
            DMA: mdma0 mdma1 mdma2 udma0 udma1 udma2 udma3 udma4 udma5 *udma6 
                 Cycle time: min=120ns recommended=120ns
            PIO: pio0 pio1 pio2 pio3 pio4 
                 Cycle time: no flow control=120ns  IORDY flow control=120ns
    Commands/features:
            Enabled Supported:
               *    SMART feature set
                    Security Mode feature set
               *    Power Management feature set
               *    Write cache
               *    Look-ahead
               *    Host Protected Area feature set
               *    WRITE_BUFFER command
               *    READ_BUFFER command
               *    NOP cmd
               *    DOWNLOAD_MICROCODE
                    SET_MAX security extension
               *    48-bit Address feature set
               *    Device Configuration Overlay feature set
               *    Mandatory FLUSH_CACHE
               *    FLUSH_CACHE_EXT
               *    SMART error logging
               *    SMART self-test
               *    General Purpose Logging feature set
               *    WRITE_{DMA|MULTIPLE}_FUA_EXT
               *    64-bit World wide name
                    Write-Read-Verify feature set
               *    WRITE_UNCORRECTABLE_EXT command
               *    {READ,WRITE}_DMA_EXT_GPL commands
               *    Segmented DOWNLOAD_MICROCODE
               *    Gen1 signaling speed (1.5Gb/s)
               *    Gen2 signaling speed (3.0Gb/s)
               *    Gen3 signaling speed (6.0Gb/s)
               *    Native Command Queueing (NCQ)
               *    Phy event counters
               *    READ_LOG_DMA_EXT equivalent to READ_LOG_EXT
                    DMA Setup Auto-Activate optimization
                    Device-initiated interface power management
               *    Asynchronous notification (eg. media change)
               *    Software settings preservation
                    Device Sleep (DEVSLP)
               *    SMART Command Transport (SCT) feature set
               *    SCT Write Same (AC2)
               *    SCT Error Recovery Control (AC3)
               *    SCT Features Control (AC4)
               *    SCT Data Tables (AC5)
               *    reserved 69[4]
               *    DOWNLOAD MICROCODE DMA command
               *    SET MAX SETPASSWORD/UNLOCK DMA commands
               *    WRITE BUFFER DMA command
               *    READ BUFFER DMA command
               *    Data Set Management TRIM supported (limit 8 blocks)
    Security: 
            Master password revision code = 65534
                    supported
            not     enabled
            not     locked
            not     frozen
            not     expired: security count
                    supported: enhanced erase
            2min for SECURITY ERASE UNIT. 8min for ENHANCED SECURITY ERASE UNIT. 
    Logical Unit WWN Device Identifier: 5002538d4101e28b
            NAA             : 5
            IEEE OUI        : 002538
            Unique ID       : d4101e28b
    Device Sleep:
            DEVSLP Exit Timeout (DETO): 50 ms (drive)
            Minimum DEVSLP Assertion Time (MDAT): 30 ms (drive)
    Checksum: correct
    I did format the mSATA by https://github.com/JElchison/format-udf with no errors like this:
    Code:
    ./format-udf.sh sdb 'UDF-Externe-Festplatte'
    Last edited by Infinite_Dao; 09-Feb-2017 at 18:05. Reason: no double spaces in cp

  2. #2
    Join Date
    Apr 2015
    Location
    Berlin
    Posts
    35

    Default Re: cp file to mSATA (universal disk format) resulting in I/O error depending on file name character

    well, guess l have to give the answer myself: I could not solve this issue. My intend was to have a drive that can be read on all computers. I tried:
    • mkudffs --utf8 --blocksize="512" --udfrev=0x0250 --lvid="UDF-Externe-Festplatte" --vid="UDF-Externe-Festplatte" --media-type=hd "/dev/sdb"
      • it got me read only access

    • mkudffs --utf8 --blocksize="512" --udfrev=0x0201 --lvid="UDF-Externe-Festplatte" --vid="UDF-Externe-Festplatte" --media-type=hd "/dev/sdb"
      • worked partially but same errors as above, could not get any detailed information on “could not create regular file ... input/output error”
      • tried to access file name limits to check issues:
        • getconf NAME_MAX /dev/sdb
        • 255
        • getconf PATH_MAX /dev/sdb
        • 4096

      • have no clue why these input/output errors repeatedly occurred



    Eventually I decided to format the external drive again:
    • gparted /dev/sdb
      • 1 small volume ntfs (to have an ext4 Windows reader there)
      • 1 large volume ext4



    Now the drive works smoothly on Linux but I have no instant access on other computers.

    I wonder if anyone managed to get universal disk format working without problems especially with long file names or non ASCII characters.

  3. #3
    Join Date
    Nov 2009
    Location
    West Virginia Sector 13
    Posts
    15,646

    Default Re: cp file to mSATA (universal disk format) resulting in I/O error depending on file name character

    NTFS name restriction are different and more restrictive then Linux file systems in general. I suspect you reached some limit on NTFS or the Linux drivers could not handle the name mangle. General rule to keep all OS happy is don't use space in files name use underscore. On NTFS all names are mangled down to the old 8.3 DOS format so first dozen or so letters should be different to avoid confusion to the mangle routines

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •