[SOLVED] FC29 + Ryzen + AsusTek PRIME X370-PRO: USB woes again
FedoraForum.org - Fedora Support Forums and Community
Results 1 to 6 of 6
  1. #1
    Join Date
    Dec 2012
    Location
    santa barbara, CA
    Posts
    1,195
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    FC29 + Ryzen + AsusTek PRIME X370-PRO: USB woes again

    Hey guys,

    I have been having these very annoying USB problems, which show up suddenly, and then a dnf-upgrade later disappear, only to reappear after yet another update.
    The problem manifests itself usually when connecting external USB hard drives, and copying a truckload of data to either an internal HD, or sending it through the network to some other machine.

    example /var/log/messages this morning:
    Code:
    [ 7242.618002] usb 2-3: new SuperSpeed Gen 1 USB device number 4 using xhci_hcd
    [ 7242.634732] usb 2-3: New USB device found, idVendor=0411, idProduct=02c2, bcdDevice= 1.25
    [ 7242.634735] usb 2-3: New USB device strings: Mfr=1, Product=2, SerialNumber=3
    [ 7242.634736] usb 2-3: Product: HD-PCFSU3-A
    [ 7242.634737] usb 2-3: Manufacturer: BUFFALO
    [ 7242.634738] usb 2-3: SerialNumber: 0040496490405438
    [ 7242.640009] usb-storage 2-3:1.0: USB Mass Storage device detected
    [ 7242.640120] scsi host10: usb-storage 2-3:1.0
    [ 7243.682229] scsi 10:0:0:0: Direct-Access     BUFFALO  Portable HDD     0000 PQ: 0 ANSI: 3
    [ 7243.682632] sd 10:0:0:0: Attached scsi generic sg5 type 0
    [ 7243.683280] sd 10:0:0:0: [sdg] Very big device. Trying to use READ CAPACITY(16).
    [ 7243.683708] sd 10:0:0:0: [sdg] 7814037168 512-byte logical blocks: (4.00 TB/3.64 TiB)
    [ 7243.683712] sd 10:0:0:0: [sdg] 4096-byte physical blocks
    [ 7243.684760] sd 10:0:0:0: [sdg] Write Protect is off
    [ 7243.684764] sd 10:0:0:0: [sdg] Mode Sense: 73 00 10 08
    [ 7243.685788] sd 10:0:0:0: [sdg] Write cache: enabled, read cache: enabled, supports DPO and FUA
    [ 7243.686601] sd 10:0:0:0: [sdg] Very big device. Trying to use READ CAPACITY(16).
    [ 7243.831987]  sdg: sdg1
    [ 7243.833387] sd 10:0:0:0: [sdg] Very big device. Trying to use READ CAPACITY(16).
    [ 7243.835769] sd 10:0:0:0: [sdg] Attached SCSI disk
    [ 7270.945650] Buffer I/O error on dev dm-11, logical block 851705861, lost async page write
    [ 7300.130039] Aborting journal on device dm-11-8.
    [ 7300.130133] Buffer I/O error on dev dm-11, logical block 1545, lost sync page write
    [ 7300.130143] JBD2: Error -5 detected when updating journal superblock for dm-11-8.
    [ 7332.395977] Buffer I/O error on dev dm-11, logical block 0, lost sync page write
    [ 7332.395996] EXT4-fs (dm-11): I/O error while writing superblock
    [ 7332.396001] EXT4-fs error (device dm-11): ext4_journal_check_start:61: Detected aborted journal
    [ 7332.396004] EXT4-fs (dm-11): Remounting filesystem read-only
    [ 7332.396087] Buffer I/O error on dev dm-11, logical block 0, lost sync page write
    [ 7332.396094] EXT4-fs (dm-11): I/O error while writing superblock
    [ 7344.166254] usb 2-3: USB disconnect, device number 4

    At the moment my inxi says:
    Code:
    System:    Host: nova Kernel: 5.2.11-100.fc29.x86_64 x86_64 bits: 64 compiler: gcc v: 8.3.1 Desktop: Xfce 4.13.3 
               Distro: Fedora release 29 (Twenty Nine) 
    Machine:   Type: Desktop Mobo: ASUSTeK model: PRIME X370-PRO v: Rev X.0x serial: <filter> UEFI: American Megatrends v: 4801 
               date: 04/25/2019 
    Memory:    RAM: total: 31.40 GiB used: 2.60 GiB (8.3%) 
               Array-1: capacity: 256 GiB note: check slots: 4 EC: None max module size: 64 GiB note: est. 
               Device-1: DIMM_A1 size: 8 GiB speed: 2133 MT/s type: DDR4 
               Device-2: DIMM_A2 size: 8 GiB speed: 2133 MT/s type: DDR4 
               Device-3: DIMM_B1 size: 8 GiB speed: 2133 MT/s type: DDR4 
               Device-4: DIMM_B2 size: 8 GiB speed: 2133 MT/s type: DDR4 
    CPU:       Topology: 6-Core model: AMD Ryzen 5 2600 bits: 64 type: MT MCP arch: Zen+ rev: 2 L2 cache: 3072 KiB 
               flags: avx avx2 lm nx pae sse sse2 sse3 sse4_1 sse4_2 sse4a ssse3 svm bogomips: 81437 
               Speed: 1375 MHz min/max: 1550/3400 MHz Core speeds (MHz): 1: 1511 2: 1467 3: 1529 4: 1517 5: 1375 6: 1356 7: 1539 
               8: 1546 9: 1496 10: 1389 11: 1371 12: 1481
    I have tried switching it from black, to blue, to green, even to an orange/red USB port to no avail, it's always the same issue. Even plugging the drive to an external powered USB hub.

    Now, plugging the USB hard drive to a blue port in my very oldish Asus Mini-PC, and copying the same data out of the drive from there gives no errors whatsoever.
    ....


    EDIT: lsusb on the affected machine:
    Code:
    Bus 006 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
    Bus 005 Device 006: ID 047d:1020 Kensington Expert Mouse Trackball
    Bus 005 Device 005: ID 05ac:024f Apple, Inc. 
    Bus 005 Device 004: ID 046d:c52f Logitech, Inc. Unifying Receiver
    Bus 005 Device 003: ID 05e3:0610 Genesys Logic, Inc. 4-port hub
    Bus 005 Device 002: ID 05e3:0610 Genesys Logic, Inc. 4-port hub
    Bus 005 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
    Bus 004 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
    Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
    Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
    Bus 001 Device 002: ID 0a12:0001 Cambridge Silicon Radio, Ltd Bluetooth Dongle (HCI mode)
    Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

    EDIT#2: /var/log/messages on my mini-PC which works fine:
    Code:
    [5497925.403116] usb 2-1: new SuperSpeed Gen 1 USB device number 2 using xhci_hcd
    [5497925.417695] usb 2-1: New USB device found, idVendor=0411, idProduct=02c2, bcdDevice= 1.25
    [5497925.417710] usb 2-1: New USB device strings: Mfr=1, Product=2, SerialNumber=3
    [5497925.417721] usb 2-1: Product: HD-PCFSU3-A
    [5497925.417728] usb 2-1: Manufacturer: BUFFALO
    [5497925.417735] usb 2-1: SerialNumber: 0040496490405438
    [5497925.428531] usb-storage 2-1:1.0: USB Mass Storage device detected
    [5497925.429292] scsi host2: usb-storage 2-1:1.0
    [5497926.473533] scsi 2:0:0:0: Direct-Access     BUFFALO  Portable HDD     0000 PQ: 0 ANSI: 3
    [5497926.476544] sd 2:0:0:0: Attached scsi generic sg1 type 0
    [5497933.188167] sd 2:0:0:0: [sdb] Very big device. Trying to use READ CAPACITY(16).
    [5497933.190033] sd 2:0:0:0: [sdb] 7814037168 512-byte logical blocks: (4.00 TB/3.64 TiB)
    [5497933.190050] sd 2:0:0:0: [sdb] 4096-byte physical blocks
    [5497933.191659] sd 2:0:0:0: [sdb] Write Protect is off
    [5497933.191671] sd 2:0:0:0: [sdb] Mode Sense: 73 00 10 08
    [5497933.192591] sd 2:0:0:0: [sdb] Write cache: enabled, read cache: enabled, supports DPO and FUA
    [5497933.194822] sd 2:0:0:0: [sdb] Very big device. Trying to use READ CAPACITY(16).
    [5497933.312283]  sdb: sdb1
    [5497933.316183] sd 2:0:0:0: [sdb] Very big device. Trying to use READ CAPACITY(16).
    [5497933.321225] sd 2:0:0:0: [sdb] Attached SCSI disk
    [5497959.084686] usb 2-1: USB disconnect, device number 2
    [5497959.088826] sd 2:0:0:0: [sdb] Synchronizing SCSI cache
    [5497959.089254] sd 2:0:0:0: [sdb] Synchronize Cache(10) failed: Result: hostbyte=DID_NO_CONNECT driverbyte=DRIVER_OK
    [5497959.340655] usb 2-1: new SuperSpeed Gen 1 USB device number 3 using xhci_hcd
    [5497959.355306] usb 2-1: New USB device found, idVendor=0411, idProduct=02c2, bcdDevice= 1.25
    [5497959.355366] usb 2-1: New USB device strings: Mfr=1, Product=2, SerialNumber=3
    [5497959.355375] usb 2-1: Product: HD-PCFSU3-A
    [5497959.355382] usb 2-1: Manufacturer: BUFFALO
    [5497959.355388] usb 2-1: SerialNumber: 0040496490405438
    [5497959.358253] usb-storage 2-1:1.0: USB Mass Storage device detected
    [5497959.361531] scsi host2: usb-storage 2-1:1.0
    [5497960.395006] scsi 2:0:0:0: Direct-Access     BUFFALO  Portable HDD     0000 PQ: 0 ANSI: 3
    [5497960.397275] sd 2:0:0:0: Attached scsi generic sg1 type 0
    [5497960.398095] sd 2:0:0:0: [sdb] Very big device. Trying to use READ CAPACITY(16).
    [5497960.398680] sd 2:0:0:0: [sdb] 7814037168 512-byte logical blocks: (4.00 TB/3.64 TiB)
    [5497960.398694] sd 2:0:0:0: [sdb] 4096-byte physical blocks
    [5497960.399518] sd 2:0:0:0: [sdb] Write Protect is off
    [5497960.399534] sd 2:0:0:0: [sdb] Mode Sense: 73 00 10 08
    [5497960.404436] sd 2:0:0:0: [sdb] Write cache: enabled, read cache: enabled, supports DPO and FUA
    [5497960.406035] sd 2:0:0:0: [sdb] Very big device. Trying to use READ CAPACITY(16).
    [5497960.424037]  sdb: sdb1
    [5497960.425698] sd 2:0:0:0: [sdb] Very big device. Trying to use READ CAPACITY(16).
    [5497960.427557] sd 2:0:0:0: [sdb] Attached SCSI disk
    [5497968.533083] EXT4-fs (dm-3): mounting ext3 file system using the ext4 subsystem
    [5497969.249152] EXT4-fs (dm-3): recovery complete
    [5497969.251816] EXT4-fs (dm-3): mounted filesystem with ordered data mode. Opts: (null)
    Last edited by bobx001; 8th September 2019 at 01:57 PM.
    "monsters John ... monsters from the ID..."
    "ma vule teva maar gul nol naya"

  2. #2
    Join Date
    Jun 2005
    Location
    Montreal, Que, Canada
    Posts
    6,229
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)

    Re: FC29 + Ryzen + AsusTek PRIME X370-PRO: USB woes again

    First of all, your bios appears to be way out of date.
    UEFI:American Megatrends v: 4801 Was 4801 the original released bios for your mother board? My first released bios was 4207.
    My current version is 5204. I expect that your bios has been updated since you have the motherboard.

    Are you boosting cpu clock to get more out of the system?

    I would strongly suggest you get a copy of a good memchk tool. MX-18 Linux, when you boot, offers a memtest program that you could let run a few hours. It really tests out a system's ram

    From what you are describing, I am not sure it is an application design problem.

    Do you have smart tools installed. Check out both your source and target drives for hardware errors. What may appear as USB problem may be a backup drive problem
    Leslie in Montreal

    Interesting web sites list
    http://forums.fedoraforum.org/showth...40#post1697840

  3. #3
    Join Date
    Dec 2012
    Location
    santa barbara, CA
    Posts
    1,195
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: FC29 + Ryzen + AsusTek PRIME X370-PRO: USB woes again

    Frankie,

    you seem to be onto something. The drive does have problems and reverts to "read/only" mode after input/output errors.
    The reason I was not seeing this on the old mini-PC is that I wasn't getting there, cuz it is too slow. I let it run overnight, and it did finally do the same thing.

    I have now anyway updated to the latest BIOS on the Asustek mobo: UEFI: American Megatrends v: 5216 date: 09/02/2019

    What I have decided to do now is to rsync the drive, and every time it finds a file with errors, I move all **other** (except the failed one) files in that folder to a temp folder, and I rename that folder to "failed file inside", and rename the temp folder as original, and keep rsyncing withtout the failed folders. Hopefully it will finalize eventually, and I will then grab that dead drive and convert it into another coaster or survival-kit mirror.
    "monsters John ... monsters from the ID..."
    "ma vule teva maar gul nol naya"

  4. #4
    Join Date
    Jun 2005
    Location
    Montreal, Que, Canada
    Posts
    6,229
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)

    Re: FC29 + Ryzen + AsusTek PRIME X370-PRO: USB woes again

    Frankie here.
    I wrote a program that might be helpful for you. It does the following...
    Code:
    <-------------HASH--------------------->|<-----Date---->|<- Bytes->|<-----------------------     path/filename --------------------->
    e613475092c1f1aa15f7f068763e86735d1e0899|20190905-182943|      5019|/scratch/Devel/tmp/fstab.git/Makefile
    1df7a64f1b83aa5df7a33165de96c82b893a964d|20190828-120733|        19|/scratch/Devel/tmp/fstab.git/zzLastBkup
    Non Regular directories (example /scratch/Devel/tmp/fstab.git/src)  are not followed
    c1eef4ddfcfeeee8433b1c709302f0447c44ffe9|20190813-002443|      9899|/scratch/Devel/tmp/fstab.git/README.md
    7355b334293a61ab335f22e4690cc619fc2c366f|20190813-002443|     10142|/scratch/Devel/tmp/fstab.git/README
    ac7f11991c3304ad1b3a2a3290a0d50486243a03|20190905-182917|     36312|/scratch/Devel/tmp/fstab.git/fstabxref
    8624bcdae55baeef00cd11d5dfcfa60f68710a02|20190813-002443|     35147|/scratch/Devel/tmp/fstab.git/LICENSE
    b6d7c2f12487c000430f96018e5fd540357d940c|20190813-002443|        96|/scratch/Devel/tmp/fstab.git/.gitignore
    ac7f11991c3304ad1b3a2a3290a0d50486243a03|20190905-182917|     36312|/scratch/Devel/tmp/fstab.git/xstabxref
    b0cc415dae07fd22bd3d4e84c2cbf8af6877919b|20190813-002443|      1504|/scratch/Devel/tmp/fstab.git/src/message.txt
    d0c3210cf44363ffe15190a8b0ce78dc28045094|20190828-100341|      4376|/scratch/Devel/tmp/fstab.git/src/fstabhelp.c
    aed6d2397cf3ede6ceea15d33291381237dd78aa|20190830-182710|     49021|/scratch/Devel/tmp/fstab.git/src/fstabxref.c
    Linked directories (example /scratch/Devel/tmp/fstab.git/src/debug.h -> )  are not followed
    I run the program against the external disks and against the source directories I sort each listing file, and I then do a compare for the first column.
    The sha1sum (column1) on the external disk must match the source one. It matters not if the file dates are different.

    Even If the file names are different, with the sha1sum, their contents are most likely identical. Send me a personal message if you would like a copy of the program.

    I wrote the scanner, but did not write the rest of the code to where I was going to rename the files to their sha1sum so that I could eliminate duplicates.

    By the way, even though we have different mother boards, the bios vendor is common. my system is am now at the same bios version as you mentioned.
    Last edited by lsatenstein; 11th September 2019 at 12:03 AM.
    Leslie in Montreal

    Interesting web sites list
    http://forums.fedoraforum.org/showth...40#post1697840

  5. #5
    Join Date
    Dec 2012
    Location
    santa barbara, CA
    Posts
    1,195
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: FC29 + Ryzen + AsusTek PRIME X370-PRO: USB woes again

    No worries frankie, I make a myriad of proggies to make my life easier.
    Example here is my backup drives indexer, with a postgres database to accompany it, to sort out what I have, and what I have not backed up, and sorts it per drive, and also gives me a "to remove" list.
    I am on drive #23 already (smallest drive is 2TB, largest is 12TB), and I have a truckload of crap in there.

    Every 2 years I "refresh" each drive, by copying it fully to a temporary drive, reformatting it, re-encrypting it, and copying the data back into it.
    Also, if I find a duplicate of a file, I remove it FROM THE OLDER DRIVE.

    Code:
    <?php
    	$drive="EXTERNAL23";
    	$connstr="dbname=DRIVE_CATALOG user=postgres port=5432 host=192.168.0.18 connect_timeout=5";
    	$dbh= pg_connect($connstr);
    
    /*
    DRIVE_CATALOG=# \dt
                List of relations
     Schema |     Name     | Type  |  Owner   
    --------+--------------+-------+----------
     public | main_catalog | table | postgres
    (1 row)
    
    DRIVE_CATALOG=# \d main_catalog;
                             Table "public.main_catalog"
      Column   |         Type          |                Modifiers                
    -----------+-----------------------+-----------------------------------------
     fileid    | bigint                | default nextval('fileid_seq'::regclass)
     drive     | character varying(32) | 
     bytes     | integer               | 
     md5sum    | character varying(64) | 
     full_path | text                  | 
     ctime     | bigint                | 
    Indexes:
        "bytes_md5sum_uidx" UNIQUE, btree (bytes, md5sum)
    
    */
    	$fr= fopen("find.txt", "r");
    /*
      find.txt is created by simply running find ./ -print > find.txt in the top folder of each drive.
    */
    	while(!feof($fr))
    	{
    		$fname=fgets($fr);
    		$fname=rtrim($fname);
    	if (!feof($fr))
    	{
    		if (!is_dir($fname))
    		{
    			$filestat_array=array();
    			$filestat_array=stat($fname);
    			$bytes=$filestat_array['size'];
    			if ($bytes > 5000000) // I only calculate the md5sum of the first 5MB
    			{
    				$dastring=file_get_contents($fname,NULL,NULL,0,5000000);
    			}
    			else
    			{
    				$dastring=file_get_contents($fname);
    			}
    			$md5_result=md5($dastring);
    			printf("BYTES: [%d] MD5: [%s] FILE: [%s]\n", $bytes,$md5_result,$fname);
    			$curtime=time();
    			$escaped_path=pg_escape_string($fname);
    			$qins=sprintf("insert into main_catalog (ctime,bytes,md5sum,drive,full_path) values ('%s','%s','%s','%s','%s');",$curtime,$bytes,$md5_result,$drive,$escaped_path);
    			$rins=pg_query($dbh,$qins);
    			//if (!pg_affected_rows($rins))
    			if (!$rins)
    			{
    				$q1="select fileid,bytes,drive,full_path from main_catalog where md5sum='$md5_result' and bytes='$bytes';";
    				$r1= pg_query($dbh,$q1);
    				if (pg_numrows($r1))
    				{
    					list($orig_fileid,$orig_bytes,$orig_drive,$orig_path)=pg_fetch_row($r1,0);
    					pg_free_result($r1);
    					$daline=sprintf("FAILED INSERT: [%s][%s|%s] [%s] ORIG [id:%d][%s][%s]\n%d %s :FOR REMOVAL SIZE SORTING\n\n", $md5_result,$bytes,$orig_bytes,$fname,$orig_fileid,$orig_drive,$orig_path,$bytes,$escaped_path);
    				}
    				else
    					$daline=sprintf("FAILED FULLY: QUERY: [%s]\n", $qins);
    				$fa= fopen("FAILED_FILE_INSERTION.log", "a");
    				fwrite($fa, $daline);
    				fclose($fa);
    			}
    			else
    			{
    				pg_free_result($rins);
    				printf("INSERTED\n");
    			}
    		}
    	}
    	}
    	fclose($fr);
    	pg_close($dbh);
    ?>
    I use the fail inserted logs , sorting them by the first number ($bytes) (the size of the file), ** sort -rn ** , so that I can remove the largest files first, which use up more space. So, I go find them in the older drives, remove them from those, and delete their database entries, then I rerun the proggy in the newer drive, and voilla.
    Every once in a while an older drive suddenly has more than 50% available space, I then relocate the files to newer drives, and use the older drive as a scratch drive in my comp.
    "monsters John ... monsters from the ID..."
    "ma vule teva maar gul nol naya"

  6. #6
    Join Date
    Jun 2005
    Location
    Montreal, Que, Canada
    Posts
    6,229
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)

    Re: FC29 + Ryzen + AsusTek PRIME X370-PRO: USB woes again

    Wow!!
    Using your creativity with Fedora is a dose of self "feeling good" medicine.

    Cheers from me. Your nickname for me is better than what my wife calls me when she is angry with me.��
    Leslie in Montreal

    Interesting web sites list
    http://forums.fedoraforum.org/showth...40#post1697840

Similar Threads

  1. [SOLVED]
    FC29 - HPLip woes
    By bobx001 in forum Using Fedora
    Replies: 1
    Last Post: 6th February 2019, 02:38 PM
  2. Ryzen first experiences SUSE user has Ryzen
    By lsatenstein in forum Linux Chat
    Replies: 2
    Last Post: 22nd April 2017, 08:50 PM
  3. installation freezes - ASUSTeK SiS900 PCI Fast Ethernet
    By line in forum Installation, Upgrades and Live Media
    Replies: 11
    Last Post: 6th January 2008, 03:36 AM
  4. ASUSTek M2N32-SLI Deluxe Motherboard
    By independentgeo in forum Hardware & Laptops
    Replies: 0
    Last Post: 8th April 2007, 06:59 PM

Posting Permissions

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