Really Slow Performance CIFS [Solved]

Bandit721
Posts: 7
Joined: Mon May 25, 2020 2:32 am
Has thanked: 13 times
Been thanked: 1 time

Really Slow Performance CIFS [Solved]

Unread post by Bandit721 »

Wondering if someone else has this same issue...

I'm running a CIFS share for my ROMs and all cores work fine with the exception of NG. When I go to Open a ROM, the initial file/folder listing retrieves quickly, but when I open a subfolder where the actual ROMs are located, it just hangs for over a minute. If I leave it long enough, it eventually opens and I can open a ROM and all works until I try to switch ROMs, then the same behavior happens.

My share is on a 5TB USB-3 drive formatted as exFAT on a Windows 10 PC. If I run the exact same file/folder structure from the SD card, it runs fine. I saw and earlier post about having the exact same files on both the SD card and the CIFS share, so I tried that and no change.

Any help would be appreciated.

Thanks!
throAU
Posts: 181
Joined: Fri Sep 11, 2020 1:06 am
Has thanked: 233 times
Been thanked: 27 times

Re: Really Slow Performance CIFS [Solved]

Unread post by throAU »

Are you using wired or wifi?

Some of the cheaper wifi dongles (e.g., like Terasic sell on their site with the De10-nano) are pretty damn slow.

They're fine for internet based updates, etc. but for transferring stuff to/from the mister, wired lan is the way to go.
Bandit721
Posts: 7
Joined: Mon May 25, 2020 2:32 am
Has thanked: 13 times
Been thanked: 1 time

Re: Really Slow Performance CIFS [Solved]

Unread post by Bandit721 »

Thanks for the reply...I get the same 1+ minute delay either wired or wireless. As I said, all other cores (including CD-based systems) work fine, just having an issue with NG.
Stupid Dufus
Posts: 157
Joined: Sun Aug 30, 2020 12:04 am
Has thanked: 98 times
Been thanked: 46 times

Re: Really Slow Performance CIFS [Solved]

Unread post by Stupid Dufus »

When I load the NG directory, it takes about 3 - 5 seconds for it to load. None of the others have any type of delay.

Connected via ethernet to a network folder on a NAS.
zakk4223
Posts: 289
Joined: Sun May 24, 2020 10:55 pm
Been thanked: 120 times

Re: Really Slow Performance CIFS [Solved]

Unread post by zakk4223 »

When Main_Mister processes the romset.xml file, it ends up performing about 250 stat64() calls to try and find individual romset.xml files that likely don't exist for most people. (so looking for something like /media/fat/games/NEOGEO/wjammers/romset.xml for every game in the romset.xml)

If I had to suspect something, it's that doing a bunch of stat calls across to a network share is massively slower than on the local file system. Taking a minute to load seems excessive (that's like 240msec per stat) but there could be a bunch of factors involved that make testing for file existence slow.

If you can ssh into the Mister, try going into one of your mounted directories with a lot of files and doing an 'ls -l' and seeing how slow that feels.
pac
Posts: 77
Joined: Mon May 25, 2020 6:11 am
Has thanked: 70 times
Been thanked: 26 times

Re: Really Slow Performance CIFS [Solved]

Unread post by pac »

I have all of my ROMs on a Synology-NAS. MiSTer is wired to an Asus router set to media bridge, so not exactly the best speed possible here.
Opening the ROMs folder for the NG takes like 1 second, not noticeable slower than browsing any other core`s ROMs folder.
Bandit721
Posts: 7
Joined: Mon May 25, 2020 2:32 am
Has thanked: 13 times
Been thanked: 1 time

Re: Really Slow Performance CIFS [Solved]

Unread post by Bandit721 »

Thanks for the feedback guys...yeah, I'm stumped. I did have my ROMs on an NTFS volume so I changed it to an exFAT and no difference. Again, it performs as expected when the ROMs are on the SD. I know NG is slightly different in that it uses the romset.xml file but wired it is on a gigabit network and still has the huge delay when others that are moving large files over the wire (PCE-CD & Sega CD) perform on par over the same network as they did when on the SD card. If it were just a few additional seconds, it would be no big deal but it's literally 1+ minutes. As mentioned in my initial post, it seems others had experienced the same thing but phrased it as "hangs" or "locks up" but I'm pretty sure that if they waited long enough, it would eventually present the directory listing. Once the directory displays, the ROMs load as expected.
dshadoff
Core Developer
Posts: 547
Joined: Sun May 24, 2020 9:30 pm
Has thanked: 20 times
Been thanked: 145 times

Re: Really Slow Performance CIFS [Solved]

Unread post by dshadoff »

How many folders/files are in that folder that takes so long to read ?
Bandit721
Posts: 7
Joined: Mon May 25, 2020 2:32 am
Has thanked: 13 times
Been thanked: 1 time

Really Slow Performance CIFS [Solved]

Unread post by Bandit721 »

@dshadoff - 159 (I'm using the HTGDB set).

*** Update: I just updated the Mister with Sorg's latest update to LINUX that he just posted and that seemed to fix it. All good now!

Thanks!
Post Reply