When does RMT Update its Database?

Hi there,

I’m just learning RMT and I’ve got a question on how it updates information contained in the [COLOR="#008000"]systems [/COLOR]and [COLOR="#008000"]hw_infos[/COLOR] tables. I’ve got an RMT Server running on SLES 15 SP1 and the client I’m registering is a SLES 12 SP4 box.

I install the 12 SP4 OS and on the registration installation screen I select to register the products against my local RMT Server (FQDN: [COLOR="#008000"]nsi-rmt.netsysint.net[/COLOR]). But I neglected to use the “Network Connection” button to define the hostname I wanted (which was supposed to be [COLOR="#008000"]sles12sp4-rmt.netsysint.net[/COLOR]). So the installation completes successfully, the 12 SP4 box is registered with the RMT Server, and when I look in YaST under “Software Repositories” I see all the repos with a URL of [COLOR="#008000"]https://nsi-rmt.netsysint.net[/COLOR].

So everything appears fine except the host name is [COLOR="#008000"]linux-[/COLOR]. I change the hostname to [COLOR="#008000"]sles12sp4-rmt.netsysint.net[/COLOR], reboot the box, and wait about 30 minutes.

I use the mysql -u root -p rmt command to connect to the RMT Server’s database and run select * from systems; What I see for a hostname is “[COLOR=”#008000"]install[/COLOR]" not “[COLOR=”#008000"]sles12sp4-rmt.netsysint.net[/COLOR]".

After more reboots of the SLES 12 SP4 box and more waiting, the RMT Database never reflected the change in the hostname. I finally had to use the SUSEConnect --url https://nsi-rmt.netsysint.net/ command to re-register the SLES 12 SP4 box with the RMT Server. But when I query the hw_infos table there are two rows that have the exact same uuid; and in the systems table there is still a record for the “install” hostname along with one for the new sles12sp4-rmt registration event.

My questions are as follows:
[LIST=1]
[]Is there some RMT client-side code that should run at boot-up to send updated information to the RMT Server? If so what is it?
[
]How often does the RMT server code update / clean-up the rmt database?
[*]And - will RMT ever delete the record information for the “install” hostname or does that have to be cleaned up manually by directly connecting to the database?
[/LIST]

Thanks for any insight!

Rich…

[QUOTE=rich_hanley;58142]Hi there,

I’m just learning RMT and I’ve got a question on how it updates information contained in the [COLOR="#008000"]systems [/COLOR]and [COLOR="#008000"]hw_infos[/COLOR] tables. I’ve got an RMT Server running on SLES 15 SP1 and the client I’m registering is a SLES 12 SP4 box.

I install the 12 SP4 OS and on the registration installation screen I select to register the products against my local RMT Server (FQDN: [COLOR="#008000"]nsi-rmt.netsysint.net[/COLOR]). But I neglected to use the “Network Connection” button to define the hostname I wanted (which was supposed to be [COLOR="#008000"]sles12sp4-rmt.netsysint.net[/COLOR]). So the installation completes successfully, the 12 SP4 box is registered with the RMT Server, and when I look in YaST under “Software Repositories” I see all the repos with a URL of [COLOR="#008000"]https://nsi-rmt.netsysint.net[/COLOR].

So everything appears fine except the host name is [COLOR="#008000"]linux-[/COLOR]. I change the hostname to [COLOR="#008000"]sles12sp4-rmt.netsysint.net[/COLOR], reboot the box, and wait about 30 minutes.

I use the mysql -u root -p rmt command to connect to the RMT Server’s database and run select * from systems; What I see for a hostname is “[COLOR=”#008000"]install[/COLOR]" not “[COLOR=”#008000"]sles12sp4-rmt.netsysint.net[/COLOR]".

After more reboots of the SLES 12 SP4 box and more waiting, the RMT Database never reflected the change in the hostname. I finally had to use the SUSEConnect --url https://nsi-rmt.netsysint.net/ command to re-register the SLES 12 SP4 box with the RMT Server. But when I query the hw_infos table there are two rows that have the exact same uuid; and in the systems table there is still a record for the “install” hostname along with one for the new sles12sp4-rmt registration event.

My questions are as follows:
[LIST=1]
[]Is there some RMT client-side code that should run at boot-up to send updated information to the RMT Server? If so what is it?
[
]How often does the RMT server code update / clean-up the rmt database?
[*]And - will RMT ever delete the record information for the “install” hostname or does that have to be cleaned up manually by directly connecting to the database?
[/LIST]

Thanks for any insight!

Rich…[/QUOTE]
Hi
With SUSEConnect, you should be able to delete the data (-d) and then run a cleanup on the client with the --cleanup option, then re-register with the new hostname.

Hello, Rich.

In order to update the hostname, change it on the client system and run SUSEConnect command without any parameters. The following message will be displayed:

Updating system details on http://your.rmt.server ...

…and hostname will be updated in RMT DB.

[LIST]
[]No code is executed automatically on client instances (unless you automate it yourself, that is), all operations related to registration, de-registration or migration of client systems are done manually with SUSEConnect.
[
]Registration data is never removed from RMT database unless you manually de-register the client system with SUSEConnect --de-register command. Removal of systems from RMT side has been requested/discussed, but it hasn’t been implemented yet: https://github.com/SUSE/rmt/issues/434
[/LIST]

HTH, Ivan.