Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

new data not imported? #180

Closed
job opened this issue Jan 28, 2019 · 4 comments
Closed

new data not imported? #180

job opened this issue Jan 28, 2019 · 4 comments
Assignees
Labels
bug Something isn't working
Milestone

Comments

@job
Copy link
Member

job commented Jan 28, 2019

It appears there is a difference between what is stored on disk, and what is served up through the daemon. Perhaps I configured it wrong?

Every night a new rpki.db file is created, and 1 is added to the value in RPKI.CURRENTSERIAL, these are copied into place.

irrd@irrd01:~/routing_sources/rpki$ cat /home/irrd/dbs/RPKI.CURRENTSERIAL
186
irrd@irrd01:~/routing_sources/rpki$ grep changed: /home/irrd/dbs/rpki.db | sort | uniq
changed:    job@ntt.net 20190127
hanna:~ job$ whois -h irrd01.ip.gin.ntt.net -- -s RPKI -M 185.0.0.0/8  | grep changed | sort | uniq
changed:        job@ntt.net 20190115

This is the configuration, and RPKI is listed under sources_default: too:

        RPKI:
            nrtm_access_list: generic_nrtm_access
            import_serial_source: file:///home/irrd/dbs/RPKI.CURRENTSERIAL
            import_source: file:///home/irrd/dbs/rpki.db
@job
Copy link
Member Author

job commented Jan 28, 2019

on disk serial is 186, on DB i see 181 as latest

                  pk                  | source | serial_oldest_seen | serial_newest_seen | serial_oldest_journal | serial_newest_journal | serial_last_export | force_reload | last_error | last_error_timestamp |            created            |            updated
--------------------------------------+--------+--------------------+--------------------+-----------------------+-----------------------+--------------------+--------------+------------+----------------------+-------------------------------+-------------------------------
 492b3f69-3f2b-4bd2-8f0a-c985d277b70c | RPKI   |                181 |                181 |                       |                       |                    | f            |            |                      | 2019-01-16 20:43:12.670088+00 | 2019-01-16 20:50:16.954105+00

@job
Copy link
Member Author

job commented Jan 28, 2019

I set force_reload to true, and this triggered an actual reload:

hanna:~ job$ whois -h irrd01.ip.gin.ntt.net -- -s RPKI -M 185.0.0.0/8  | grep changed | sort | uniq
changed:        job@ntt.net 20190127

Is the expected behaviour that force_reload must be set to true to trigger the importer to do something?

@job
Copy link
Member Author

job commented Jan 28, 2019

I updated the configuration to the following:

        RPKI:
            authoritative: false
            import_timer: 300
            nrtm_access_list: generic_nrtm_access
            import_serial_source: file:///home/irrd/dbs/RPKI.CURRENTSERIAL
            import_source: file:///home/irrd/dbs/rpki.db

and bumped the CURRENTSERIAL to 187, but it didn't seem to reload the data.

@mxsasha
Copy link
Collaborator

mxsasha commented Jan 28, 2019

This looks like a bug. Do the logs have a message like "Skipping NRTM updates for RPKI, nrtm_host not set." ?

Currently, we run the full import if a serial is not known, or if force_reload is set. In other words, this works, if import_serial_source is not set, and never has been. Instead, this should be based on whether NRTM is configured. With a known serial, it looks like irrd will attempt an NRTM import, which will immediately stop due to lack of a configured NRTM server, and never update.

In general, force_reload should not need to be triggered. It's only purpose is to be able to force a complete reset of database contents, e.g. in case NRTM ran out of sync. In ideal cases, it is never needed. It happens to help here, but won't be needed once we fix the bug.

Quick fix: remove import_serial_source, remove the RPKI row from database_status. That'll have it import the whole file every import_timer. We'll make a proper fix later.

Note that #172 is also still open, which is likely a more suitable method for your use case.

@mxsasha mxsasha self-assigned this Jan 28, 2019
@mxsasha mxsasha added the bug Something isn't working label Jan 28, 2019
@mxsasha mxsasha added this to the IRRD 4.0.0 milestone Jan 29, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants