2

I've been working with a RedHat Satellite that is used for internal Linux systems. It's set up to sync a subset of the channels available from RedHat, and the sync has been done using satellite-sync in a cron job.

The satellite was recently upgraded from 5.7 to 5.8. This upgrade includes replacing the satellite-sync with the new cdn-sync. According to RedHat documentation, it should be a drop-in replacement, and they recommend running it through a cron job that randomizes run time to be between 1 am and 3 am, like this:

0 1 * * * perl -le 'sleep rand 9000' && cdn-sync --email >/dev/null 2>1

However, we have found that when we do that, nothing gets downloaded. There is no error message; all we get is an email that says the command took 00:00 minutes:seconds to run. We've also tried directing output to a log file instead of to /dev/null, but we get no other information and no error message. Still, nothing gets synced.

How can we get cdn-sync to actually sync the packages?

Jenny D
  • 27,358
  • 21
  • 74
  • 110

1 Answers1

1

The very first time you run cdn-sync after upgrading, you need to specify the channel that you want to keep synced. So we had to manually run

cdn-sync-c rhel-x86_64-server-6 -c rhel-x86_64-server-optional-6 [...other channels] --email

When we had run it this way manually once, the cron job started working.

Jenny D
  • 27,358
  • 21
  • 74
  • 110