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

Creating monthy snapshot of repositories #1

Open
vishalspatil opened this issue Jan 8, 2015 · 6 comments
Open

Creating monthy snapshot of repositories #1

vishalspatil opened this issue Jan 8, 2015 · 6 comments

Comments

@vishalspatil
Copy link

First of all Happy New Year, I have started using dtmrepo to sync rhel 7 channel from RHN.

the requirement now is to freeze a snapshot of repository synced from RHN every month with a date.

So that it can be used to maintain a patch baseline for updating packages on all severs for a single customer. [All Servers of a customer should be on same patch level]

Do you have any kind of script readily available to achieve this.

@dtmateojr
Copy link
Owner

I have created a separate script that performs a "cheap copy" of a repo. It basically creates hard links so save space and at the same time preserve older packages that dtmrepo might throw away when newer packages are downloaded. I'll upload the script tomorrow.

Cheers,

Demo

On 8 Jan 2015, at 19:23, vishalspatil [email protected] wrote:

First of all Happy New Year, I have started using dtmrepo to sync rhel 7 channel from RHN.

the requirement now is to freeze a snapshot of repository synced from RHN every month with a date.

So that it can be used to maintain a patch baseline for updating packages on all severs for a single customer. [All Servers of a customer should be on same patch level]

Do you have any kind of script readily available to achieve this.


Reply to this email directly or view it on GitHub.

@vishalspatil
Copy link
Author

Thanks you very much dtmateo,

On Thu, Jan 8, 2015 at 5:30 PM, dtmateojr [email protected] wrote:

I have created a separate script that performs a "cheap copy" of a repo.
It basically creates hard links so save space and at the same time preserve
older packages that dtmrepo might throw away when newer packages are
downloaded. I'll upload the script tomorrow.

Cheers,

Demo

On 8 Jan 2015, at 19:23, vishalspatil [email protected] wrote:

First of all Happy New Year, I have started using dtmrepo to sync rhel 7
channel from RHN.

the requirement now is to freeze a snapshot of repository synced from
RHN every month with a date.

So that it can be used to maintain a patch baseline for updating
packages on all severs for a single customer. [All Servers of a customer
should be on same patch level]

Do you have any kind of script readily available to achieve this.


Reply to this email directly or view it on GitHub.


Reply to this email directly or view it on GitHub
#1 (comment).

Regards
Vishal

@dtmateojr
Copy link
Owner

Have a look at the clone script. To create a snapshot of your repo simply do
clone myrepo myrepo-clone

That will create a "snapshot" cheap copy of myrepo. You can then serve myrepo-clone to your clients.

@vishalspatil
Copy link
Author

Thanks you again , I will check.

@vishalspatil
Copy link
Author

Hi dtmateo,

Hope you are doing good, I just came across one problem for on my repo
server[using dtmrepo]

when we sync from RHSM the repodata folder is created outside the
os,optional and supplementary repo.

[root@dtmrepo rhel7s-x86_64]# ls
optional os supplementary

[root@dtmrepo optional]# ls
repodata rhel-7-server-optional-rpms

[root@dtmrepo os]# ls
repodata rhel-7-server-rpms

so when we provide the baseurl in repo file it is unable to find repod.xml

http://dtmrepo.xyz.com/dtmrepo/rhel7s-x86_64/supplementary/rhel-7-server-supplementary-rpms/repodata/repomd.xml:
[Errno 14] HTTP Error 404 - Not Found

can you let us know where can we tune this parameter in dtmrepo script so
that repodata folder is created inside the os,optional and supplemenatry
repo folder.

Thanks in advance.

On Fri, Jan 9, 2015 at 9:40 AM, dtmateojr [email protected] wrote:

Have a look at the clone script. To create a snapshot of your repo simply
do
clone myrepo myrepo-clone

That will create a "snapshot" cheap copy of myrepo. You can then serve
myrepo-clone to your clients.


Reply to this email directly or view it on GitHub
#1 (comment).

Regards
Vishal

@dtmateojr
Copy link
Owner

Is it able to generate the repo data? Have a look inside repodata and make sure the files are there. Repodata creation may fail if you have broken RPMS. Also make sure that you have the correct SELinux context otherwise do

chcon -R -t httpd_sys_content_t /path/to/your/repo

On 1 May 2015, at 1:44, vishalspatil [email protected] wrote:

Hi dtmateo,

Hope you are doing good, I just came across one problem for on my repo
server[using dtmrepo]

when we sync from RHSM the repodata folder is created outside the
os,optional and supplementary repo.

[root@dtmrepo rhel7s-x86_64]# ls
optional os supplementary

[root@dtmrepo optional]# ls
repodata rhel-7-server-optional-rpms

[root@dtmrepo os]# ls
repodata rhel-7-server-rpms

so when we provide the baseurl in repo file it is unable to find repod.xml

http://dtmrepo.xyz.com/dtmrepo/rhel7s-x86_64/supplementary/rhel-7-server-supplementary-rpms/repodata/repomd.xml:
[Errno 14] HTTP Error 404 - Not Found

can you let us know where can we tune this parameter in dtmrepo script so
that repodata folder is created inside the os,optional and supplemenatry
repo folder.

Thanks in advance.

On Fri, Jan 9, 2015 at 9:40 AM, dtmateojr [email protected] wrote:

Have a look at the clone script. To create a snapshot of your repo simply
do
clone myrepo myrepo-clone

That will create a "snapshot" cheap copy of myrepo. You can then serve
myrepo-clone to your clients.


Reply to this email directly or view it on GitHub
#1 (comment).

Regards
Vishal

Reply to this email directly or view it on GitHub.

dtmateojr pushed a commit that referenced this issue Jun 13, 2016
1. /etc/yum.repos.d/master.repo has been replaced with
redhat-dtmrepo.repo
2. The change in #1 was because I have found a way to
sync multiple different versions of RHEL products from
subscription-manager using product certificates.
3. Because of #2, genrepoconfig is pretty much redundant but the tool
still exists but now references /etc/yum.repos.d/redhat-dtmrepo.repo.
4. For ALL distros that sync with Red Hat subscription-manager, the
configuration MUST always declare "releasever" and "arch".
5. Instructions have been updated.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants