Home of the Squeezebox™ & Transporter® network music players.
Page 5 of 6 FirstFirst ... 3456 LastLast
Results 41 to 50 of 51
  1. #41
    Senior Member Stig Nygaard's Avatar
    Join Date
    Feb 2006
    Location
    Copenhagen
    Posts
    186
    Hi Michael

    Okay, I have tested performance of a LMS791-installation on my Windows 10 desktop PC. Performance was very fine opening lists like for example the Alternative Rock station list. So no performance problem on Windows it seems.
    I did however see the same crash of LMS when trying to set the Library Name for the first time on the initial setup, as I have seen when doing clean installs of LMS791 on my NAS. But that's probably a completely different story...

    On my NAS-installation of LMS791 I have now also applied the modifications of SkinManager.pm, and I have attached the log from when I opened the Alternative Rock stationlist afterwards. I clicked to open the station list at 21:51:15:

    LMSImageproxyLog.txt

    Hope it makes you wiser :-)
    /Stig
    http://www.rockland.dk - http://www.last.fm/user/rockland - http://www.discogs.com/user/StigNygaard - https://plus.google.com/+StigNygaard
    Server: LMS 7.9.1 - 1491548882 @ Sat Apr 8 on ReadyNAS Ultra 2. Controllers & players: 2x Squeezebox Touch, [Not used: Squeezebox Classic,] 2x OrangeSqueeze. Stereo: Marantz PM6005 and F3/Lyd Audiovector 2.

    You might like to try my Art Grabr for fetching big cover-art from various sites - or Album Linkr for a better last.fm desktop experience...

  2. #42
    Babelfish's Best Boy mherger's Avatar
    Join Date
    Apr 2005
    Location
    Switzerland
    Posts
    19,547
    Thanks a lot! Yes, that log is quite interesting. Let's look at this snippet:

    Code:
    [17-04-19 21:51:17.6780] Slim::Utils::Misc::msg (1244) Warning: [21:51:17.6773] mysb: 0.00327777862548828 at /usr/share/perl5/Slim/Web/Template/SkinManager.pm line 283.
    [17-04-19 21:51:17.6924] Slim::Utils::Misc::msg (1244) Warning: [21:51:17.6916] mysb: 0.00301098823547363 at /usr/share/perl5/Slim/Web/Template/SkinManager.pm line 283.
    [17-04-19 21:51:17.7207] Slim::Utils::Misc::msg (1244) Warning: [21:51:17.7200] mysb: 0.0169610977172852 at /usr/share/perl5/Slim/Web/Template/SkinManager.pm line 283.
    [17-04-19 21:51:17.7531] Slim::Utils::Misc::msg (1244) Warning: [21:51:17.7524] mysb: 0.0210268497467041 at /usr/share/perl5/Slim/Web/Template/SkinManager.pm line 283.
    [17-04-19 21:51:22.7725] Slim::Utils::Misc::msg (1244) Warning: [21:51:22.7718] mysb: 5.00802183151245 at /usr/share/perl5/Slim/Web/Template/SkinManager.pm line 283.
    [17-04-19 21:51:22.7891] Slim::Utils::Misc::msg (1244) Warning: [21:51:22.7884] mysb: 0.00420618057250977 at /usr/share/perl5/Slim/Web/Template/SkinManager.pm line 283.
    [17-04-19 21:51:22.8044] Slim::Utils::Misc::msg (1244) Warning: [21:51:22.8037] mysb: 0.00397300720214844 at /usr/share/perl5/Slim/Web/Template/SkinManager.pm line 283.
    [17-04-19 21:51:22.8195] Slim::Utils::Misc::msg (1244) Warning: [21:51:22.8187] mysb: 0.00370192527770996 at /usr/share/perl5/Slim/Web/Template/SkinManager.pm line 283.
    [17-04-19 21:51:22.8348] Slim::Utils::Misc::msg (1244) Warning: [21:51:22.8341] mysb: 0.00311899185180664 at /usr/share/perl5/Slim/Web/Template/SkinManager.pm line 283.
    [17-04-19 21:51:22.8495] Slim::Utils::Misc::msg (1244) Warning: [21:51:22.8487] mysb: 0.00323700904846191 at /usr/share/perl5/Slim/Web/Template/SkinManager.pm line 283.
    [17-04-19 21:51:22.8713] Slim::Utils::Misc::msg (1244) Warning: [21:51:22.8705] mysb: 0.0104079246520996 at /usr/share/perl5/Slim/Web/Template/SkinManager.pm line 283.
    [17-04-19 21:51:27.8907] Slim::Utils::Misc::msg (1244) Warning: [21:51:27.8900] mysb: 5.00787615776062 at /usr/share/perl5/Slim/Web/Template/SkinManager.pm line 283.
    As you can see, most requests would be dealt with within a fraction of a second. But there are two which took >5s! Unfortunately we don't have the URLs logged... Could I therefore ask you for another test? Could you please edit this line:

    Code:
    warn "mysb: " . (Time::HiRes::time() - $t);
    to include the URL:

    Code:
    warn "mysb ($url, $host): " . (Time::HiRes::time() - $t);
    Michael

    http://www.herger.net/slim-plugins - MusicArtistInfo, MusicInfoSCR

  3. #43
    Senior Member Stig Nygaard's Avatar
    Join Date
    Feb 2006
    Location
    Copenhagen
    Posts
    186
    Quote Originally Posted by mherger View Post
    Thanks a lot! Yes, that log is quite interesting. Let's look at this snippet:

    As you can see, most requests would be dealt with within a fraction of a second. But there are two which took >5s! Unfortunately we don't have the URLs logged... Could I therefore ask you for another test? Could you please edit this line:

    Code:
    warn "mysb: " . (Time::HiRes::time() - $t);
    to include the URL:

    Code:
    warn "mysb ($url, $host): " . (Time::HiRes::time() - $t);
    I was actually trying to include urls. But guessing perl when you have never done perl before is not easy :-)

    Anyway, here's the log with your latest changes. Unfortunately I cannot see a pattern? :

    LMSImageresizerLog.txt
    /Stig
    http://www.rockland.dk - http://www.last.fm/user/rockland - http://www.discogs.com/user/StigNygaard - https://plus.google.com/+StigNygaard
    Server: LMS 7.9.1 - 1491548882 @ Sat Apr 8 on ReadyNAS Ultra 2. Controllers & players: 2x Squeezebox Touch, [Not used: Squeezebox Classic,] 2x OrangeSqueeze. Stereo: Marantz PM6005 and F3/Lyd Audiovector 2.

    You might like to try my Art Grabr for fetching big cover-art from various sites - or Album Linkr for a better last.fm desktop experience...

  4. #44
    Senior Member Stig Nygaard's Avatar
    Join Date
    Feb 2006
    Location
    Copenhagen
    Posts
    186
    Quote Originally Posted by Stig Nygaard View Post
    Anyway, here's the log with your latest changes. Unfortunately I cannot see a pattern? :
    Or the longer list for Copenhagen local. It's almost every 7th, but once the 8th:

    LMSImageresizerCPHLog.txt
    /Stig
    http://www.rockland.dk - http://www.last.fm/user/rockland - http://www.discogs.com/user/StigNygaard - https://plus.google.com/+StigNygaard
    Server: LMS 7.9.1 - 1491548882 @ Sat Apr 8 on ReadyNAS Ultra 2. Controllers & players: 2x Squeezebox Touch, [Not used: Squeezebox Classic,] 2x OrangeSqueeze. Stereo: Marantz PM6005 and F3/Lyd Audiovector 2.

    You might like to try my Art Grabr for fetching big cover-art from various sites - or Album Linkr for a better last.fm desktop experience...

  5. #45
    Babelfish's Best Boy mherger's Avatar
    Join Date
    Apr 2005
    Location
    Switzerland
    Posts
    19,547
    I still believe this is an issue particular to your setup. Sometimes DNS lookups seem to be very slow. What changed from 7.8 to 7.9 is that we do a lot of those lookups when rendering a page with artwork (in order to figure out what resizing method to use).

    What surprises me is the fact that this lookup seems not to apply any caching. Or maybe there's some caching going on in the OS, and that's what is broken on your system ;-).

    Therefore I wonder whether the following would improve the situation for you. It's adding caching in our code. Basically replace Slim::Utils::Network::ip_is_private with the following code:

    Code:
    my %cache;
    require Tie::Cache::LRU::Expires;
    tie %cache, 'Tie::Cache::LRU::Expires', EXPIRES => 60, ENTRIES => 100;
    
    sub ip_is_private {
    	my $ip = shift;
    	my $cached = $cache{$ip};
    	
    	return $cached if defined $cached;
    	
    	my $packed_ip = inet_aton($ip);
    	
    	my $is_private;
    
    	if ($packed_ip) {
    		# http://www.perlmonks.org/?node_id=791164
    		$is_private = $packed_ip =~ m{
    	        ^
    	        (?: \x0A             # 10.0.0.0/8
    	        |   \xAC[\x10-\x1F]  # 172.16.0.0/12
    	        |   \xC0\xA8         # 192.168.0.0/16
    	        )
    	    }x;
    	}
        
        $cache{$ip} = $is_private ? 1 : 0;
        return $is_private;
    }
    Michael

    http://www.herger.net/slim-plugins - MusicArtistInfo, MusicInfoSCR

  6. #46
    Senior Member Stig Nygaard's Avatar
    Join Date
    Feb 2006
    Location
    Copenhagen
    Posts
    186
    Quote Originally Posted by mherger View Post
    Therefore I wonder whether the following would improve the situation for you. It's adding caching in our code. Basically replace Slim::Utils::Network::ip_is_private with the following code:
    I'll try that tonight.
    I also have another router somewhere I could try if you think that might make a difference?
    /Stig
    http://www.rockland.dk - http://www.last.fm/user/rockland - http://www.discogs.com/user/StigNygaard - https://plus.google.com/+StigNygaard
    Server: LMS 7.9.1 - 1491548882 @ Sat Apr 8 on ReadyNAS Ultra 2. Controllers & players: 2x Squeezebox Touch, [Not used: Squeezebox Classic,] 2x OrangeSqueeze. Stereo: Marantz PM6005 and F3/Lyd Audiovector 2.

    You might like to try my Art Grabr for fetching big cover-art from various sites - or Album Linkr for a better last.fm desktop experience...

  7. #47
    Babelfish's Best Boy mherger's Avatar
    Join Date
    Apr 2005
    Location
    Switzerland
    Posts
    19,547

    Problems with LMS79x and Spotify onReadyNAS Ultra 2 [1/3]

    > I also have another router somewhere I could try if you think that might
    > make a difference?


    It might be worth a try. But as you don't experience the same problem on
    your desktop, I'd assume the ReadyNAS is part of the problem. Is it
    still running Perl 5.8.x?

    --

    Michael

  8. #48
    Senior Member Stig Nygaard's Avatar
    Join Date
    Feb 2006
    Location
    Copenhagen
    Posts
    186
    Quote Originally Posted by mherger View Post
    I still believe this is an issue particular to your setup. Sometimes DNS lookups seem to be very slow. What changed from 7.8 to 7.9 is that we do a lot of those lookups when rendering a page with artwork (in order to figure out what resizing method to use).
    BANG, there it was! I was just looking through the configuration settings on my NAS and stumbled over a DNS-page where the IP-addresses of three domain name servers was entered. But why do they have to be that on my NAS I wondered? So I deleted them all.
    Well, that was not the solution. Half of the menus in LMS disappeared (pretty much all the stuff that is not purely local was gone).
    Okay, so apparently the NAS has to explicitly be told the address of at least one domain name server.

    Two of the previously entered addresses was external. Probably from an ISP I was using 4-5 years ago. The third was just pointing to my router. When I just enter the local IP of my router as DNS, performance is on top again! The two others was significantly slower it turned out.

    There must have been a performance-difference also on LMS781 then, but DNS-lookups in such smaller numbers that you wouldn't notice?

    I am ashamed. I was sure it wasn't my setup that was the problem. I'm happy we have found the reason, but soo sorry to taking all that time from you. I owe you if there's anything you ever need someone to check on an ReadNAS Ultra.

    Thanks so much for helping me here and for the work you continue to do on LMS :-)
    /Stig
    http://www.rockland.dk - http://www.last.fm/user/rockland - http://www.discogs.com/user/StigNygaard - https://plus.google.com/+StigNygaard
    Server: LMS 7.9.1 - 1491548882 @ Sat Apr 8 on ReadyNAS Ultra 2. Controllers & players: 2x Squeezebox Touch, [Not used: Squeezebox Classic,] 2x OrangeSqueeze. Stereo: Marantz PM6005 and F3/Lyd Audiovector 2.

    You might like to try my Art Grabr for fetching big cover-art from various sites - or Album Linkr for a better last.fm desktop experience...

  9. #49
    Babelfish's Best Boy mherger's Avatar
    Join Date
    Apr 2005
    Location
    Switzerland
    Posts
    19,547

    Problems with LMS79x and Spotify onReadyNAS Ultra 2 [1/3]

    > There must have been a performance-difference also on LMS781 then, but
    > DNS-lookups in such smaller numbers that you wouldn't notice?


    Yes. If only every tenth call was slow, you probably wouldn't notice
    when only one call is done a day or every few hours. But with the new
    imageproxy it's done for every single image on a page.

    > I am ashamed. I was sure it wasn't my setup that was the problem.


    They always do ;-). "Wasn't me!"

    --

    Michael

  10. #50
    Senior Member Stig Nygaard's Avatar
    Join Date
    Feb 2006
    Location
    Copenhagen
    Posts
    186
    For the record, and trying to get something useful out of this thread :-) ...

    Quote Originally Posted by mherger View Post
    Is it still running Perl 5.8.x?
    Yes, ReadyNAS Ultra is running: Perl Version: 5.8.8 - i486-linux-gnu-thread-multi.

    Regarding the crashes I got when doing the initial setup of a clean LMS79x installs on my ReadyNAS and on my Windows PC, I came to think about the new 79x option to include pictures and videos in your scanning/library. I think I saw in some thread that scanning for pictures might make LMS crash. I just tried installing LMS791 on Synology DS716+ II (via pinkdot's LmsRepack packages), and noticed it did not crash when setting the Media Library Name on the Basic Settings tab. But this time I also de-selected the "Picture" and "Video" check-boxes before applying the settings. I'm not sure if I did that already at this point when installing on my NAS or on my Windows PC.

    It made me think:
    1) It would of course be good to fix it so it doesn't crash, but...
    2) Maybe "Pictures" and "Video" shouldn't be selected by default on a clean install? I would guess it are nice bonus features for a few people, but most probably just install LMS for streaming and handling of their Music collection. And it 's such a bad start to crash the first time you start LMS.
    Last edited by Stig Nygaard; 2017-04-23 at 08:59.
    /Stig
    http://www.rockland.dk - http://www.last.fm/user/rockland - http://www.discogs.com/user/StigNygaard - https://plus.google.com/+StigNygaard
    Server: LMS 7.9.1 - 1491548882 @ Sat Apr 8 on ReadyNAS Ultra 2. Controllers & players: 2x Squeezebox Touch, [Not used: Squeezebox Classic,] 2x OrangeSqueeze. Stereo: Marantz PM6005 and F3/Lyd Audiovector 2.

    You might like to try my Art Grabr for fetching big cover-art from various sites - or Album Linkr for a better last.fm desktop experience...

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
  •