NEXUS rare database corruption?

Discussion in 'Education' started by pamuma, Jul 14, 2018.

  1. pamuma

    pamuma Newbie

    Joined:
    Aug 22, 2015
    Messages:
    45
    Likes Received:
    2
    Hi, i have a legitimate nexus and i saw that in the last update 2.7.4 they added more locking to prevent rare database corruption. And i ask me if someone know what mean. Is possible use illegitimate expansions on the old nexus version? (i do not mean to the 2.2)

    regards
     
  2.  
  3. CDLF

    CDLF Ultrasonic

    Joined:
    Jul 7, 2017
    Messages:
    70
    Likes Received:
    34
    Nexus² maintains its database of all imported samples and presets. This database could get corrupted in rare cases which should be fixed now.
    Accessing such a database from more than one instance of an app can lead to a lot of tricky problems, that's why they added more locking in order to prevent those.


    It's not a good in this case, but let's imagine the following theoretic example:

    Starting point: A = 1

    App instance I starts to add 2.
    App instance II starts to add 3.

    You'd now expect the result to be: A = 6, but it's not by default

    If we assume it really happens concurrent, this will gonna happen:
    So both are gonna read A.
    1 | 1
    Then both are will do the math
    1+2=3 | 1+3=4
    Finally they save the new value to that.
    The result of the faster instance will be the new value.
    either A = 3 or A = 4

    It becomes even more trickier when a third instance reads the value in between those two saving procedures.
    Instance III: Read: A = 3
    Instance II: Store A = 4
    Instance III: Add 2 --> 3 + 2 = 5 --> A = 5
    Now everything went wrong. So you have to ensure that only one instance at a time can change the value.
     
    • Like Like x 1
    • Interesting Interesting x 1
    • List
  4. twoheart

    twoheart Audiosexual

    Joined:
    Nov 21, 2015
    Messages:
    2,016
    Likes Received:
    1,233
    Location:
    Share many
    @CDLF That's with concurrent use of a db based on a record. It's even possible to do this for one field. There is no "ideal" locking scheme, because no machine is able to identify the process that has the "correct" value for a record. In this case there are acutually "alternative facts" :yes:
    And it depends on db type. For some db there is even a locking scheme on "page" level (MS Access works this way. To make it even more complicated I guess).

    For this scenario it seems to be the best way not using the db concurrently but every user has his/her own db. Of course db will differ over time but even better than if the db is corrupted (=unusable)
     
    • Agree Agree x 2
    • Like Like x 1
    • List
  5. Herr Durr

    Herr Durr Guest

    solved.. nexus needs a quantum computer to run properly... just another 50 years and it will all be ok :yes:
     
    • Funny Funny x 2
    • Like Like x 1
    • List
  6. twoheart

    twoheart Audiosexual

    Joined:
    Nov 21, 2015
    Messages:
    2,016
    Likes Received:
    1,233
    Location:
    Share many
    Not ... really.
    It isn't connected to a question of speed. The Problem occurs always with every application when you use a database with two or more people at the same time. The problem gets bigger when you use less records or more concurrent people because with less records or more people the probability of a conflict rises.

    You'll need to use one or another form of locking scheme. And if you don't use a locking scheme in a multiuser environment the result will be a destroyed database sooner or later.

    But when locking is used, you'll sooner or later run into the lock. Your machine will tell you, that you are not entiteled to use or change the very record. You'll need to wait for the other person(s) to end their work on the record.

    So using Nexus with more than one person would be easiest way to install one database for every user and not one for all on a network drive.
    The downside is, that you'll need more diskspace and changes are only effective on the local drive. So the database will differ between all the local installations.

    For example: When you've got 3 bottles (=records) of beer (=database) in your fridge and you are 5 people (=users) in the house you will need a locking scheme (e.g. a sticker like !!! THIS IS HERR's !!!), otherwise you will get a conflict with broken bottles (=corrupted database)

    Short: Just don't use Nexus :dunno:
     
    Last edited: Jul 15, 2018
    • Like Like x 1
    • Winner Winner x 1
    • List
  7. Herr Durr

    Herr Durr Guest

    I see...well as described it sounded like a problem that quantum superposition could deal with.. but what do I know..
    not much.. :bleh:

    maybe I'm mistaken.. but OP didn't sound as though he was using it on a network.
    or do you mean that multiple instances of the plug are equivalent to that?

    seems like there should be some sort of token that can be tossed around to
    identify the instance and the resource it wants.. and then also some sort of
    queuing scheme if there is something already accessing the database, but then
    that would mean more latency ? or couldn't that element of the db just be called into
    RAM, and then other requests could access it on the drive? I'm not a programmer
    at all.. but such problems still intrigue and inspire dilettante solutions.

    what would be the appropriate solution ?
     
    Last edited by a moderator: Jul 14, 2018
  8. twoheart

    twoheart Audiosexual

    Joined:
    Nov 21, 2015
    Messages:
    2,016
    Likes Received:
    1,233
    Location:
    Share many
    No, I don't think so, that would be a really dumb mistake of reFx

    I think the OP was off topic :rofl:

    He thought the problem with the db would be caused by using "pirated" libraries. I don't think taht's the case. I think @CDLF was on the right trail.

    I'm quite sure there are many books filled with thoughts about this matter, and I'm not a computer scientist.
    There is not the ONE proper solution for this problem. Who can computationally - in every case - decide, what's the correct entry for a data filed or record. So, at the end, if absolute correctness is needed, a lock must be set and no one should able to open the record for read/write access if the record is open already. After the lock is lifted, you will need to re-open the record and do the alterations after you checked manually what's in the record.
    If you would just use a queing scheme, you would not run into a lock but into unpredictable results in the database, because the resulting record is based on timing/coincidence. The last one who writes the record is the winner.
    The ultima ratio of dealing with this kind of problem is an intelligent person. Today at the end it's a human being that decides what has to be written into the record and was plausible. In the future this job may be done by a computer.
     
  9. Herr Durr

    Herr Durr Guest

    thanks for tolerating the ignorant questions.. being dumb doesn't prevent one from being interested..
    I think you hit the nail on the head again..and this is why try before buy is so popular.. since paying customers
    are so often abused by shoddy and inconsiderate programming and protection schemes that make you wonder why you
    spent your hard earned money on them in the first place...

    :hifive:
     
  10. pamuma

    pamuma Newbie

    Joined:
    Aug 22, 2015
    Messages:
    45
    Likes Received:
    2
    Thanks for answers, well someone know how i can use a downloaded expansion on a legitimate nexus?
     
  11. Vaijj

    Vaijj Platinum Record

    Joined:
    Feb 24, 2012
    Messages:
    327
    Likes Received:
    177
    think thats a no go theese days.. reg file requierd theese days..
     
  12. CDLF

    CDLF Ultrasonic

    Joined:
    Jul 7, 2017
    Messages:
    70
    Likes Received:
    34
    You can't. The master key mechanism prevents this.
     
Loading...
Similar Threads - NEXUS rare database Forum Date
Selling Nexus 2 license and Vengance plugins for 150€ Selling / Buying Wednesday at 4:38 PM
MacOS ReFX Nexus 4 no sound from some preset Software Apr 10, 2024
normal instruments vsts (Omnisphere, electra, nexus....) vs kontakt libraries Software Mar 17, 2024
Selling Xfer Serum and ReFX Nexus 3 (refx account) Selling / Buying Feb 4, 2024
ReFX Nexus 3 Moved Library - relocate? Software Jan 3, 2024
Loading...