Solved Appears to be a bug in seasons_view
#1
Unable to select shows in progress from the TV Shows view off the main menu.
- When selecting an item from "TV Shows - In Progress", the selection ends up on the Videos dialog.
- Note this happens on Raspberry PI also
- I believe this is due to changes in the database season_view
- The error indicates an infinite loop or something in the ORDER BY (in season_view), which has changed significantly from v17


Version info:
  Starting Kodi (18.0-RC5 Git:20190112-3cbd6c1eec). Platform: Windows NT x86 64-bit
  Using Release Kodi x64 build
  Kodi compiled 2019-01-12 by MSVC 191627023 for Windows NT x86 64-bit version 10.0 (0x0A000006)
  Running on Windows 10, kernel: Windows NT x86 64-bit version 10.0.17134



When looking in the log, it appears there is a problem with the sql query below:
12:33:41.181 T:12280   ERROR: SQL: [MyVideos116] Undefined MySQL error: Code (1038)
                                            Query: SELECT * FROM season_view  WHERE season_view.idShow = 1071
12:33:41.181 T:12280   ERROR: CVideoDatabase::GetSeasonsByWhere failed
12:33:42.028 T:12280   ERROR: XFILE::CDirectory::GetDirectory - Error getting videodb://inprogresstvshows/1071/
12:33:42.041 T:12280   ERROR: CGUIMediaWindow::GetDirectory(videodb://inprogresstvshows/1071/) failed


When executing that query in MySQL Workbench
0712:21:02 SELECT * FROM season_view  WHERE season_view.idShow = 1071 Error Code: 1038. Out of sort memory; increase server sort buffer size 1.391 sec

In fact, if I just try to query SELECT * FROM season_view (with no WHERE clause) same error.


Anyone seeing the problem I've described?  I saw something similar in the XBOX forum, but not sure it's the same root cause...
Reply
#2
Please install the nightly. This is fixed already.

Edit: I take it back - your bug is a new one.
First decide what functions / features you expect from a system. Then decide for the hardware. Don't waste your money on crap.
Reply
#3
I think I just confirmed my suspicion.  
I edited the Kodi v18 (MyVideos116) season_view SQL to reflect a similar ORDER BY clause as v17 Kodi (MyVideos107) as follows:

    GROUP BY `seasons`.`idSeason` , `seasons`.`idShow` , `seasons`.`season` , `seasons`.`name` , `seasons`.`userrating`

And now everything works again.
Reply
#4
Are you using a shared MySQL setup, or the local Kodi SQL databases?
My Signature
Links to : Official:Forum rules (wiki) | Official:Forum rules/Banned add-ons (wiki) | Debug Log (wiki)
Links to : HOW-TO:Create Music Library (wiki) | HOW-TO:Create_Video_Library (wiki)  ||  Artwork (wiki) | Basic controls (wiki) | Import-export library (wiki) | Movie sets (wiki) | Movie universe (wiki) | NFO files (wiki) | Quick start guide (wiki)
Reply
#5
Shared SQL, several Kodi and 2 windows clients.
Reply
#6
MySQL or MariaDB ? Because we had some annoyances with the latter that last two weeks. And which version?
Reply
#7
(2019-01-20, 23:36)Klojum Wrote: MySQL or MariaDB ? Because we had some annoyances with the later that last two weeks. And which version?
 MySQL - 5.1.73

PVR: NextPVR | Clients: LibreElec on Raspberry PI, Windows 10
Reply
#8
Can you upgrade to a recent MySQL server and see if the problem persists? MySQL 5.1 is EOL (end-of-life, not supported anymore) since 2013. We recommend MySQL server >= 5.6 or MariaDB server >= 5.5 for Kodi v18. There may be more changes that are incompatible with MySQL 5.1 in v18 and future versions.
Reply
#9
(2019-01-20, 22:04)JavaWiz Wrote:
text:
Error Code: 1038. Out of sort memory; increase server sort buffer size

Can you post the content of your my.cnf?

As per the error message, your MySQL server needs tuning to handle larger data sets but without knowing your current config it's hard to know what to recommend.

If you still have problems with MySQL 5.6+ then try doubling whatever existing sort buffer size value you have, or add sort buffer size = 1M (the default size is 262144, or 256KB) if you don't have a current setting.
Texture Cache Maintenance Utility: Preload your texture cache for optimal UI performance. Remotely manage media libraries. Purge unused artwork to free up space. Find missing media. Configurable QA check to highlight metadata issues. Aid in diagnosis of library and cache related problems.
Reply
#10
I am running MySQL on a DNS-323 under ALT-F, it only supports 5.1.73-1. I'll do a little googling to see what'll it'll take to upgrade.

Meanwhile, here is my.cnf, the sort buffer size is set to 64k, I will up to 1M as suggested.
 
Quote:# Example MySQL config file for small systems.
#
# This is for a system with little memory (<= 64M) where MySQL is only used
# from time to time and it's important that the mysqld daemon
# doesn't use much resources.
#
# MySQL programs look for option files in a set of
# locations which depend on the deployment platform.
# You can copy this option file to one of those
# locations. For information about these locations, see:
# http://dev.mysql.com/doc/mysql/en/option-files.html
#
# In this file, you can use all long options that a program supports.
# If you want to know which options a program supports, run the program
# with the "--help" option.
# The following options will be passed to all MySQL clients
[client]
#password       = your_password
port            = 3306
socket          = /var/run/mysql/mysql.sock
# Here follows entries for some specific programs
# The MySQL server
[mysqld]
port            = 3306
socket          = /var/run/mysql/mysql.sock
skip-locking
key_buffer_size = 16K
max_allowed_packet = 1M
table_open_cache = 4
sort_buffer_size = 64K
read_buffer_size = 256K
read_rnd_buffer_size = 256K
net_buffer_length = 2K
thread_stack = 128K
# Don't listen on a TCP/IP port at all. This can be a security enhancement,
# if all processes that need to connect to mysqld run on the same host.
# All interaction with mysqld must be made via Unix sockets or named pipes.
# Note that using this option without enabling named pipes on Windows
# (using the "enable-named-pipe" option) will render mysqld useless!
#
#skip-networking
server-id       = 1
# Uncomment the following if you want to log updates
#log-bin=mysql-bin
# binary logging format - mixed recommended
#binlog_format=mixed
# Uncomment the following if you are using InnoDB tables
#innodb_data_home_dir = /var/lib/mysql
#innodb_data_file_path = ibdata1:10M:autoextend
#innodb_log_group_home_dir = /var/lib/mysql
# You can set .._buffer_pool_size up to 50 - 80 %
# of RAM but beware of setting memory usage too high
#innodb_buffer_pool_size = 16M
#innodb_additional_mem_pool_size = 2M
# Set .._log_file_size to 25 % of buffer pool size
#innodb_log_file_size = 5M
#innodb_log_buffer_size = 8M
#innodb_flush_log_at_trx_commit = 1
#innodb_lock_wait_timeout = 50
[mysqldump]
quick
max_allowed_packet = 16M
[mysql]
no-auto-rehash
# Remove the next comment character if you are not familiar with SQL
#safe-updates
[myisamchk]
key_buffer_size = 8M
sort_buffer_size = 8M
[mysqlhotcopy]
interactive-timeout
 

PVR: NextPVR | Clients: LibreElec on Raspberry PI, Windows 10
Reply
#11
Thank you, bumping up the sort buffer size to 1M solved the problem for me.

PVR: NextPVR | Clients: LibreElec on Raspberry PI, Windows 10
Reply
#12
Sweet, had the same issue also. my setup is the very same. edited the my.cnf file and can confirm its fixed the issue
Reply
#13
Thread marked solved.
Reply

Logout Mark Read Team Forum Stats Members Help
Appears to be a bug in seasons_view0