[Spacewalk-list] Fix yum repo definitions on spacewalk clients

2018-02-12 Thread Isaac Hailperin
Dear list,

I have spacewalk 2.4 installed on a CentOS 7 host, and manage CentOS 7 servers 
with it. Now I found that in /etc/yum.repos.d/ all configured repositories 
point to Internet repos. Which is not really how it should be, hosts should use 
the internal spacewalk repos. I assume this is due to packages like 
centos-release* being installed. I am just taking over this environment, so I 
am not 100% sure how all this came together.

Nonetheless, I need to fix this. If I just delete the packages to which the 
repo definitions belong to, I am left without any repositories (I have checked 
- none point to the internal repo, all belong to some installed package). As 
the clients are assigned to certain channels, I would like to add the 
corresponding repositories again.

So far I have tried re-registering the client with

# rhnreg_ks --serverUrl=https://YourSpacewalk.example.org/XMLRPC 
--sslCACert=/usr/share/rhn/RHN-ORG-TRUSTED-SSL-CERT 
--activationkey= --force
No success. I have also removed all channel subscriptions, and then added them 
again, no success.

What would be the easiest, or most reliable way to get the correct repo 
definitions back?

Maybe my assumption is wrong, but since the spacewalk client tools have 
knowledge of the subscribed channels, I assume that there is also a way to get 
the corresponding repository definitions in some automated way. What would that 
be?

Any hint or feedback is appreciated.

Regards,
Isaac


smime.p7s
Description: S/MIME cryptographic signature
___
Spacewalk-list mailing list
Spacewalk-list@redhat.com
https://www.redhat.com/mailman/listinfo/spacewalk-list

Re: [Spacewalk-list] Fix yum repo definitions on spacewalk clients

2018-02-12 Thread Robert Paschedag
Am 12. Februar 2018 10:51:55 MEZ schrieb Isaac Hailperin 
:
>Dear list,
>
>I have spacewalk 2.4 installed on a CentOS 7 host, and manage CentOS 7
>servers with it. Now I found that in /etc/yum.repos.d/ all configured
>repositories point to Internet repos. Which is not really how it should
>be, hosts should use the internal spacewalk repos. I assume this is due
>to packages like centos-release* being installed. I am just taking over
>this environment, so I am not 100% sure how all this came together.
>
>Nonetheless, I need to fix this. If I just delete the packages to which
>the repo definitions belong to, I am left without any repositories (I
>have checked - none point to the internal repo, all belong to some
>installed package). As the clients are assigned to certain channels, I
>would like to add the corresponding repositories again.
>
>So far I have tried re-registering the client with
>
># rhnreg_ks --serverUrl=https://YourSpacewalk.example.org/XMLRPC
>--sslCACert=/usr/share/rhn/RHN-ORG-TRUSTED-SSL-CERT
>--activationkey= --force
>No success. I have also removed all channel subscriptions, and then
>added them again, no success.
>
>What would be the easiest, or most reliable way to get the correct repo
>definitions back?
>
>Maybe my assumption is wrong, but since the spacewalk client tools have
>knowledge of the subscribed channels, I assume that there is also a way
>to get the corresponding repository definitions in some automated way.
>What would that be?
>
>Any hint or feedback is appreciated.
>
>Regards,
>Isaac

It should just work the way you tried. So it would be interesting to know, what 
error you get when you run the rhnreg_ks tool?

Do you get an error?

If not, do your servers show up as "system" within spacewalk?

If the servers show up in spacewalk, check they really have the channels 
subscribed. If they do not have channels subscribed, then something's wrong 
with the activation key.

Robert

___
Spacewalk-list mailing list
Spacewalk-list@redhat.com
https://www.redhat.com/mailman/listinfo/spacewalk-list


Re: [Spacewalk-list] Fix yum repo definitions on spacewalk clients

2018-02-12 Thread Isaac Hailperin
>>Dear list,
>>
>>I have spacewalk 2.4 installed on a CentOS 7 host, and manage CentOS 7
>>servers with it. Now I found that in /etc/yum.repos.d/ all configured
>>repositories point to Internet repos. Which is not really how it should
>>be, hosts should use the internal spacewalk repos. I assume this is due
>>to packages like centos-release* being installed. I am just taking over
>>this environment, so I am not 100% sure how all this came together.
>>
>>Nonetheless, I need to fix this. If I just delete the packages to which
>>the repo definitions belong to, I am left without any repositories (I
>>have checked - none point to the internal repo, all belong to some
>>installed package). As the clients are assigned to certain channels, I
>>would like to add the corresponding repositories again.
>>
>>So far I have tried re-registering the client with
>>
>># rhnreg_ks --serverUrl=https://YourSpacewalk.example.org/XMLRPC
>>--sslCACert=/usr/share/rhn/RHN-ORG-TRUSTED-SSL-CERT
>>--activationkey= --force
>>No success. I have also removed all channel subscriptions, and then
>>added them again, no success.
>>
>>What would be the easiest, or most reliable way to get the correct repo
>>definitions back?
>>
>>Maybe my assumption is wrong, but since the spacewalk client tools have
>>knowledge of the subscribed channels, I assume that there is also a way
>>to get the corresponding repository definitions in some automated way.
>>What would that be?
>>
>>Any hint or feedback is appreciated.
>>
>>Regards,
>>Isaac
>
>It should just work the way you tried. So it would be interesting to know, 
>what error you get when you run the rhnreg_ks tool?
>
>Do you get an error?
>
>If not, do your servers show up as "system" within spacewalk?
>
>If the servers show up in spacewalk, check they really have the channels 
>subscribed. If they do not have channels subscribed, then something's wrong 
>with the activation key.
>
>Robert
>

Unforunatly, rhnreg_ks does not give any output, even with the verbose flag.
The client shows up in Spacewalk (albeit four times - always same UUID, but 
different spacewalk system ID) - with mostly the correct channels. I am not 
sure where the difference in channel config comes from - but that might be due 
to the mess we have here with channel configs. So lets not focus on channel 
correctnes for now - if I get any channel repos configured correctly that would 
mean a big step forward.

Should I have deleted the client bevor re-registering it?

Any place where I could get more logs/output?

Isaac

smime.p7s
Description: S/MIME cryptographic signature
___
Spacewalk-list mailing list
Spacewalk-list@redhat.com
https://www.redhat.com/mailman/listinfo/spacewalk-list

Re: [Spacewalk-list] Fix yum repo definitions on spacewalk clients

2018-02-12 Thread Avi Miller
Hi,


> On 12 Feb 2018, at 11:51 am, Isaac Hailperin  
> wrote:
> 
> What would be the easiest, or most reliable way to get the correct repo 
> definitions back?

There may be a misunderstanding here, but Spacewalk does not generate anything 
in /etc/yum.repos.d/. You don't see any repo definitions on the client side, 
it's all done in Spacewalk.

What is the output of "yum repolist" on a client after it has registered with 
Spacewalk? If there are channels associated with the activation key you used, 
they should be automatically enabled. If not, you may have to enable the 
channels manually via the web UI or spacecmd.

Cheers,
Avi

--
Oracle 
Avi Miller | Product Management Director | +61 (3) 8616 3496
Oracle Linux and Virtualization
417 St Kilda Road, Melbourne, Victoria 3004 Australia

___
Spacewalk-list mailing list
Spacewalk-list@redhat.com
https://www.redhat.com/mailman/listinfo/spacewalk-list

Re: [Spacewalk-list] Fix yum repo definitions on spacewalk clients

2018-02-12 Thread Isaac Hailperin
Ok, just verified: If I remove the .repo file for epel, the "epel/x86_64" is 
gone. But how does yum know about the other repository? Where is that defined? 
Does yum have a plugin that lets it query the correct repositories directly 
from spacewalk?

Isaac

Von: Isaac Hailperin
Gesendet: Montag, 12. Februar 2018 16:39
An: spacewalk-list@redhat.com
Betreff: AW: [Spacewalk-list] Fix yum repo definitions on spacewalk clients

Avi - interesting point:
# yum repolist |grep epel
 * epel: mirror.de.leaseweb.net
epel/x86_64Extra Packages for Enterprise Linux 7  12,278
!epel7-centos7-x86_64  EPEL 7 for CentOS 7 (x86_64)   13,357

I think the latter is the one defined in spacewalk. However there seems to be 
not corresponding yum repo in /etc/yum.repos.d - is that how it should be?
So all I would need to to is delete the local definition of epel?

Isaac


Von: spacewalk-list-boun...@redhat.com [spacewalk-list-boun...@redhat.com]" im 
Auftrag von "Avi Miller [avi.mil...@oracle.com]
Gesendet: Montag, 12. Februar 2018 16:30
An: spacewalk-list@redhat.com
Betreff: Re: [Spacewalk-list] Fix yum repo definitions on spacewalk clients

Hi,


On 12 Feb 2018, at 11:51 am, Isaac Hailperin 
mailto:isaac.hailpe...@lcsystems.ch>> wrote:

What would be the easiest, or most reliable way to get the correct repo 
definitions back?

There may be a misunderstanding here, but Spacewalk does not generate anything 
in /etc/yum.repos.d/. You don't see any repo definitions on the client side, 
it's all done in Spacewalk.

What is the output of "yum repolist" on a client after it has registered with 
Spacewalk? If there are channels associated with the activation key you used, 
they should be automatically enabled. If not, you may have to enable the 
channels manually via the web UI or spacecmd.

Cheers,
Avi

--
Oracle <http://www.oracle.com>
Avi Miller | Product Management Director | +61 (3) 8616 3496
Oracle Linux and Virtualization
417 St Kilda Road, Melbourne, Victoria 3004 Australia



smime.p7s
Description: S/MIME cryptographic signature
___
Spacewalk-list mailing list
Spacewalk-list@redhat.com
https://www.redhat.com/mailman/listinfo/spacewalk-list

Re: [Spacewalk-list] Fix yum repo definitions on spacewalk clients

2018-02-12 Thread Isaac Hailperin
Avi - interesting point:
# yum repolist |grep epel
 * epel: mirror.de.leaseweb.net
epel/x86_64Extra Packages for Enterprise Linux 7  12,278
!epel7-centos7-x86_64  EPEL 7 for CentOS 7 (x86_64)   13,357

I think the latter is the one defined in spacewalk. However there seems to be 
not corresponding yum repo in /etc/yum.repos.d - is that how it should be?
So all I would need to to is delete the local definition of epel?

Isaac


Von: spacewalk-list-boun...@redhat.com [spacewalk-list-boun...@redhat.com]" im 
Auftrag von "Avi Miller [avi.mil...@oracle.com]
Gesendet: Montag, 12. Februar 2018 16:30
An: spacewalk-list@redhat.com
Betreff: Re: [Spacewalk-list] Fix yum repo definitions on spacewalk clients

Hi,


On 12 Feb 2018, at 11:51 am, Isaac Hailperin 
mailto:isaac.hailpe...@lcsystems.ch>> wrote:

What would be the easiest, or most reliable way to get the correct repo 
definitions back?

There may be a misunderstanding here, but Spacewalk does not generate anything 
in /etc/yum.repos.d/. You don't see any repo definitions on the client side, 
it's all done in Spacewalk.

What is the output of "yum repolist" on a client after it has registered with 
Spacewalk? If there are channels associated with the activation key you used, 
they should be automatically enabled. If not, you may have to enable the 
channels manually via the web UI or spacecmd.

Cheers,
Avi

--
Oracle <http://www.oracle.com>
Avi Miller | Product Management Director | +61 (3) 8616 3496
Oracle Linux and Virtualization
417 St Kilda Road, Melbourne, Victoria 3004 Australia



smime.p7s
Description: S/MIME cryptographic signature
___
Spacewalk-list mailing list
Spacewalk-list@redhat.com
https://www.redhat.com/mailman/listinfo/spacewalk-list

Re: [Spacewalk-list] Fix yum repo definitions on spacewalk clients

2018-02-12 Thread Bruce Wainer
The yum-rhn-plugin loads them directly from Spacewalk I believe, or maybe
its cached during an rhn_check - not sure which. That is why when you run
any Yum command it prints out the line about "This server is receiving
updates from a Spacewalk system" or something like that (don't have a
terminal open right now). By the way, don't delete your .repo files,
because updates to things like epel-release, zfs-release, etc will just
create them again. Instead, disable all of the repos. This is what I run on
each system as part of my registration process:

#sed -i 's/enabled=1/enabled=0/' /etc/yum.repos.d/*.repo

Bruce Wainer

On Mon, Feb 12, 2018 at 10:42 AM, Isaac Hailperin <
isaac.hailpe...@lcsystems.ch> wrote:

> Ok, just verified: If I remove the .repo file for epel, the "epel/x86_64"
> is gone. But how does yum know about the other repository? Where is that
> defined? Does yum have a plugin that lets it query the correct repositories
> directly from spacewalk?
>
> Isaac
> --
> *Von:* Isaac Hailperin
> *Gesendet:* Montag, 12. Februar 2018 16:39
> *An:* spacewalk-list@redhat.com
> *Betreff:* AW: [Spacewalk-list] Fix yum repo definitions on spacewalk
> clients
>
> Avi - interesting point:
> # yum repolist |grep epel
>  * epel: mirror.de.leaseweb.net
> epel/x86_64Extra Packages for Enterprise Linux 7
> 12,278
> !epel7-centos7-x86_64  EPEL 7 for CentOS 7 (x86_64)
>  13,357
>
> I think the latter is the one defined in spacewalk. However there seems to
> be not corresponding yum repo in /etc/yum.repos.d - is that how it should
> be?
> So all I would need to to is delete the local definition of epel?
>
> Isaac
>
> --
> *Von:* spacewalk-list-boun...@redhat.com [spacewalk-list-bounces@
> redhat.com]" im Auftrag von "Avi Miller [avi.mil...@oracle.com]
> *Gesendet:* Montag, 12. Februar 2018 16:30
> *An:* spacewalk-list@redhat.com
> *Betreff:* Re: [Spacewalk-list] Fix yum repo definitions on spacewalk
> clients
>
> Hi,
>
>
> On 12 Feb 2018, at 11:51 am, Isaac Hailperin 
> wrote:
>
> What would be the easiest, or most reliable way to get the correct repo
> definitions back?
>
>
> There may be a misunderstanding here, but Spacewalk does not generate
> anything in /etc/yum.repos.d/. You don't see any repo definitions on the
> client side, it's all done in Spacewalk.
>
> What is the output of "yum repolist" on a client after it has registered
> with Spacewalk? If there are channels associated with the activation key
> you used, they should be automatically enabled. If not, you may have to
> enable the channels manually via the web UI or spacecmd.
>
> Cheers,
> Avi
>
> --
> Oracle <http://www.oracle.com>
> Avi Miller | Product Management Director | +61 (3) 8616 3496
> <+61%203%208616%203496>
> Oracle Linux and Virtualization
> 417 St Kilda Road, Melbourne, Victoria 3004 Australia
>
>
> ___
> Spacewalk-list mailing list
> Spacewalk-list@redhat.com
> https://www.redhat.com/mailman/listinfo/spacewalk-list
>
___
Spacewalk-list mailing list
Spacewalk-list@redhat.com
https://www.redhat.com/mailman/listinfo/spacewalk-list

Re: [Spacewalk-list] Fix yum repo definitions on spacewalk clients

2018-02-12 Thread Avi Miller
Hi,


> On 12 Feb 2018, at 5:52 pm, Bruce Wainer  wrote:
> 
> The yum-rhn-plugin loads them directly from Spacewalk I believe, or maybe its 
> cached during an rhn_check - not sure which. 

It's not cached. The yum-rhn-plugin pulls the current channel subscription from 
Spacewalk on each run on yum.

Cheers,
Avi

--
Oracle 
Avi Miller | Product Management Director | +61 (3) 8616 3496
Oracle Linux and Virtualization
417 St Kilda Road, Melbourne, Victoria 3004 Australia


___
Spacewalk-list mailing list
Spacewalk-list@redhat.com
https://www.redhat.com/mailman/listinfo/spacewalk-list


Re: [Spacewalk-list] Fix yum repo definitions on spacewalk clients

2018-02-12 Thread Isaac Hailperin
Ok, that makes more sense now. Thank you Avi for the clarification.

Isaac

-Original Message-
From: spacewalk-list-boun...@redhat.com 
[mailto:spacewalk-list-boun...@redhat.com] On Behalf Of Avi Miller
Sent: Montag, 12. Februar 2018 16:57
To: spacewalk-list@redhat.com
Subject: Re: [Spacewalk-list] Fix yum repo definitions on spacewalk clients

Hi,


> On 12 Feb 2018, at 5:52 pm, Bruce Wainer  wrote:
> 
> The yum-rhn-plugin loads them directly from Spacewalk I believe, or maybe its 
> cached during an rhn_check - not sure which. 

It's not cached. The yum-rhn-plugin pulls the current channel subscription from 
Spacewalk on each run on yum.

Cheers,
Avi

--
Oracle <http://www.oracle.com>
Avi Miller | Product Management Director | +61 (3) 8616 3496 Oracle Linux and 
Virtualization
417 St Kilda Road, Melbourne, Victoria 3004 Australia


___
Spacewalk-list mailing list
Spacewalk-list@redhat.com
https://www.redhat.com/mailman/listinfo/spacewalk-list


smime.p7s
Description: S/MIME cryptographic signature
___
Spacewalk-list mailing list
Spacewalk-list@redhat.com
https://www.redhat.com/mailman/listinfo/spacewalk-list

Re: [Spacewalk-list] Fix yum repo definitions on spacewalk clients

2018-02-12 Thread Isaac Hailperin
Bruce – thank you for the hint to just disable the repos – of course, now that 
you mention it its crystal clear ☺

Isaac

From: spacewalk-list-boun...@redhat.com 
[mailto:spacewalk-list-boun...@redhat.com] On Behalf Of Bruce Wainer
Sent: Montag, 12. Februar 2018 16:53
To: spacewalk-list@redhat.com
Subject: Re: [Spacewalk-list] Fix yum repo definitions on spacewalk clients

The yum-rhn-plugin loads them directly from Spacewalk I believe, or maybe its 
cached during an rhn_check - not sure which. That is why when you run any Yum 
command it prints out the line about "This server is receiving updates from a 
Spacewalk system" or something like that (don't have a terminal open right 
now). By the way, don't delete your .repo files, because updates to things like 
epel-release, zfs-release, etc will just create them again. Instead, disable 
all of the repos. This is what I run on each system as part of my registration 
process:

#sed -i 's/enabled=1/enabled=0/' /etc/yum.repos.d/*.repo

Bruce Wainer

On Mon, Feb 12, 2018 at 10:42 AM, Isaac Hailperin 
mailto:isaac.hailpe...@lcsystems.ch>> wrote:
Ok, just verified: If I remove the .repo file for epel, the "epel/x86_64" is 
gone. But how does yum know about the other repository? Where is that defined? 
Does yum have a plugin that lets it query the correct repositories directly 
from spacewalk?

Isaac

Von: Isaac Hailperin
Gesendet: Montag, 12. Februar 2018 16:39
An: spacewalk-list@redhat.com<mailto:spacewalk-list@redhat.com>
Betreff: AW: [Spacewalk-list] Fix yum repo definitions on spacewalk clients
Avi - interesting point:
# yum repolist |grep epel
 * epel: mirror.de.leaseweb.net<http://mirror.de.leaseweb.net>
epel/x86_64Extra Packages for Enterprise Linux 7  12,278
!epel7-centos7-x86_64  EPEL 7 for CentOS 7 (x86_64)   13,357

I think the latter is the one defined in spacewalk. However there seems to be 
not corresponding yum repo in /etc/yum.repos.d - is that how it should be?
So all I would need to to is delete the local definition of epel?

Isaac


Von: 
spacewalk-list-boun...@redhat.com<mailto:spacewalk-list-boun...@redhat.com> 
[spacewalk-list-boun...@redhat.com<mailto:spacewalk-list-boun...@redhat.com>]" 
im Auftrag von "Avi Miller [avi.mil...@oracle.com<mailto:avi.mil...@oracle.com>]
Gesendet: Montag, 12. Februar 2018 16:30
An: spacewalk-list@redhat.com<mailto:spacewalk-list@redhat.com>
Betreff: Re: [Spacewalk-list] Fix yum repo definitions on spacewalk clients
Hi,



On 12 Feb 2018, at 11:51 am, Isaac Hailperin 
mailto:isaac.hailpe...@lcsystems.ch>> wrote:

What would be the easiest, or most reliable way to get the correct repo 
definitions back?

There may be a misunderstanding here, but Spacewalk does not generate anything 
in /etc/yum.repos.d/. You don't see any repo definitions on the client side, 
it's all done in Spacewalk.

What is the output of "yum repolist" on a client after it has registered with 
Spacewalk? If there are channels associated with the activation key you used, 
they should be automatically enabled. If not, you may have to enable the 
channels manually via the web UI or spacecmd.

Cheers,
Avi

--
Oracle <http://www.oracle.com>
Avi Miller | Product Management Director | +61 (3) 8616 
3496
Oracle Linux and Virtualization
417 St Kilda Road, Melbourne, Victoria 3004 Australia


___
Spacewalk-list mailing list
Spacewalk-list@redhat.com<mailto:Spacewalk-list@redhat.com>
https://www.redhat.com/mailman/listinfo/spacewalk-list



smime.p7s
Description: S/MIME cryptographic signature
___
Spacewalk-list mailing list
Spacewalk-list@redhat.com
https://www.redhat.com/mailman/listinfo/spacewalk-list

Re: [Spacewalk-list] Fix yum repo definitions on spacewalk clients

2018-02-13 Thread William H. ten Bensel
http://spacewalk-list.redhat.narkive.com/aBoQIh6I/rhn-check-fails

snippet --> As of 02/13/2018 --> We have not found a better solution..

We ran into issues where "yum update" updated the centos-release RPM,
which in turn would push updated .repos to /etc/yum.repos.d/. This would
cause a similar issue to the errors described.

The solution we came up with, was to put the following in the post section
of the default kickstart: If there is a better idea, I am all ears.

mkdir -p /some/where/
echo "reposdir=" /some/where/" >> /etc/yum.conf


Some benefits, by doing this has been that 3rd party vendor apps that
install their own /etc/yum.repos.d/ will not cause any delays or issues
with running yum commands (if they cannot reach the site). If the client
is able to reach the site, then a request process will move the 3rd party
.repo in /some/where. 



Thanks and good luck




From:   Isaac Hailperin 
To: "spacewalk-list@redhat.com" 
Date:   02/13/2018 01:28 AM
Subject:    Re: [Spacewalk-list] Fix yum repo definitions on spacewalk 
clients
Sent by:spacewalk-list-boun...@redhat.com



This email originated from outside of the company. Please use discretion 
if opening attachments or clicking on links. 
Bruce – thank you for the hint to just disable the repos – of course, now 
that you mention it its crystal clear J
 
Isaac
 
From: spacewalk-list-boun...@redhat.com [
mailto:spacewalk-list-boun...@redhat.com] On Behalf Of Bruce Wainer
Sent: Montag, 12. Februar 2018 16:53
To: spacewalk-list@redhat.com
Subject: Re: [Spacewalk-list] Fix yum repo definitions on spacewalk 
clients
 
The yum-rhn-plugin loads them directly from Spacewalk I believe, or maybe 
its cached during an rhn_check - not sure which. That is why when you run 
any Yum command it prints out the line about "This server is receiving 
updates from a Spacewalk system" or something like that (don't have a 
terminal open right now). By the way, don't delete your .repo files, 
because updates to things like epel-release, zfs-release, etc will just 
create them again. Instead, disable all of the repos. This is what I run 
on each system as part of my registration process:

#sed -i 's/enabled=1/enabled=0/' /etc/yum.repos.d/*.repo

Bruce Wainer
 
On Mon, Feb 12, 2018 at 10:42 AM, Isaac Hailperin <
isaac.hailpe...@lcsystems.ch> wrote:
Ok, just verified: If I remove the .repo file for epel, the "epel/x86_64" 
is gone. But how does yum know about the other repository? Where is that 
defined? Does yum have a plugin that lets it query the correct 
repositories directly from spacewalk? 
 
Isaac

Von: Isaac Hailperin
Gesendet: Montag, 12. Februar 2018 16:39
An: spacewalk-list@redhat.com
Betreff: AW: [Spacewalk-list] Fix yum repo definitions on spacewalk 
clients
Avi - interesting point: 
# yum repolist |grep epel
 * epel: mirror.de.leaseweb.net
epel/x86_64Extra Packages for Enterprise Linux 7 
12,278
!epel7-centos7-x86_64  EPEL 7 for CentOS 7 (x86_64) 13,357
 
I think the latter is the one defined in spacewalk. However there seems to 
be not corresponding yum repo in /etc/yum.repos.d - is that how it should 
be?
So all I would need to to is delete the local definition of epel?
 
Isaac
 

Von: spacewalk-list-boun...@redhat.com [spacewalk-list-boun...@redhat.com
]" im Auftrag von "Avi Miller [avi.mil...@oracle.com]
Gesendet: Montag, 12. Februar 2018 16:30
An: spacewalk-list@redhat.com
Betreff: Re: [Spacewalk-list] Fix yum repo definitions on spacewalk 
clients
Hi, 
 


On 12 Feb 2018, at 11:51 am, Isaac Hailperin  wrote:
 
What would be the easiest, or most reliable way to get the correct repo 
definitions back?
 
There may be a misunderstanding here, but Spacewalk does not generate 
anything in /etc/yum.repos.d/. You don't see any repo definitions on the 
client side, it's all done in Spacewalk.
 
What is the output of "yum repolist" on a client after it has registered 
with Spacewalk? If there are channels associated with the activation key 
you used, they should be automatically enabled. If not, you may have to 
enable the channels manually via the web UI or spacecmd.
 
Cheers,
Avi
 
--
Oracle <http://www.oracle.com>
Avi Miller | Product Management Director | +61 (3) 8616 3496
Oracle Linux and Virtualization
417 St Kilda Road, Melbourne, Victoria 3004 Australia 
 

___
Spacewalk-list mailing list
Spacewalk-list@redhat.com
https://www.redhat.com/mailman/listinfo/spacewalk-list
 [attachment "smime.p7s" deleted by William H. ten Bensel/UPC] 
___
Spacewalk-list mailing list
Spacewalk-list@redhat.com
https://www.redhat.com/mailman/listinfo/spacewalk-list



**

This email and any attachments may contain information that is confidential 
and/or privileged for the sole use of the intended recipi

Re: [Spacewalk-list] Fix yum repo definitions on spacewalk clients

2018-02-15 Thread Alexandru Raceanu
I've been running following in the kickstart %post (non-chroot) to disable all 
repos except the ones from Spacewalk without any issues for couple of years 
now. 
snip 
sed -i -e '/reposdir=.*/d' -e '/cachedir.*/ 
s,$,\nreposdir=/etc/yum.repos.d/disabled,' /mnt/sysimage/etc/yum.conf 
snip 

I hope this helps... 

/Alex 


From: "Isaac Hailperin"  
To: "spacewalk-list@redhat.com"  
Sent: Monday, February 12, 2018 10:51:55 AM 
Subject: [Spacewalk-list] Fix yum repo definitions on spacewalk clients 



Dear list, 



I have spacewalk 2.4 installed on a CentOS 7 host, and manage CentOS 7 servers 
with it. Now I found that in /etc/yum.repos.d/ all configured repositories 
point to Internet repos. Which is not really how it should be, hosts should use 
the internal spacewalk repos. I assume this is due to packages like 
centos-release* being installed. I am just taking over this environment, so I 
am not 100% sure how all this came together. 



Nonetheless, I need to fix this. If I just delete the packages to which the 
repo definitions belong to, I am left without any repositories (I have checked 
- none point to the internal repo, all belong to some installed package). As 
the clients are assigned to certain channels, I would like to add the 
corresponding repositories again. 



So far I have tried re-registering the client with 



# rhnreg_ks --serverUrl=https://YourSpacewalk.example.org/XMLRPC 
--sslCACert=/usr/share/rhn/RHN-ORG-TRUSTED-SSL-CERT 
--activationkey= --force 

No success. I have also removed all channel subscriptions, and then added them 
again, no success. 



What would be the easiest, or most reliable way to get the correct repo 
definitions back? 



Maybe my assumption is wrong, but since the spacewalk client tools have 
knowledge of the subscribed channels, I assume that there is also a way to get 
the corresponding repository definitions in some automated way. What would that 
be? 



Any hint or feedback is appreciated. 



Regards, 
Isaac 

___ 
Spacewalk-list mailing list 
Spacewalk-list@redhat.com 
https://www.redhat.com/mailman/listinfo/spacewalk-list

___
Spacewalk-list mailing list
Spacewalk-list@redhat.com
https://www.redhat.com/mailman/listinfo/spacewalk-list


Re: [Spacewalk-list] Fix yum repo definitions on spacewalk clients

2018-02-19 Thread Isaac Hailperin
Thank you Alex. It turns out my understanding was incomplete. Disabling repos 
is indeed an option, and knowing the spacewalk repos come via the rhn yum 
plugin helps to understand how it all works together.

In the end it was a bug (back from April 2017 ...) that keps me from using the 
repos - I had to roll back httpd on the spacewalk server. After that, all is 
fine again.

Isaac

-Ursprüngliche Nachricht-
Von: spacewalk-list-boun...@redhat.com 
[mailto:spacewalk-list-boun...@redhat.com] Im Auftrag von Alexandru Raceanu
Gesendet: Donnerstag, 15. Februar 2018 23:26
An: spacewalk-list@redhat.com
Betreff: Re: [Spacewalk-list] Fix yum repo definitions on spacewalk clients

I've been running following in the kickstart %post (non-chroot) to disable all 
repos except the ones from Spacewalk without any issues for couple of years 
now. 
snip 
sed -i -e '/reposdir=.*/d' -e '/cachedir.*/ 
s,$,\nreposdir=/etc/yum.repos.d/disabled,' /mnt/sysimage/etc/yum.conf 
snip 

I hope this helps... 

/Alex 


From: "Isaac Hailperin"  
To: "spacewalk-list@redhat.com"  
Sent: Monday, February 12, 2018 10:51:55 AM 
Subject: [Spacewalk-list] Fix yum repo definitions on spacewalk clients 



Dear list, 



I have spacewalk 2.4 installed on a CentOS 7 host, and manage CentOS 7 servers 
with it. Now I found that in /etc/yum.repos.d/ all configured repositories 
point to Internet repos. Which is not really how it should be, hosts should use 
the internal spacewalk repos. I assume this is due to packages like 
centos-release* being installed. I am just taking over this environment, so I 
am not 100% sure how all this came together. 



Nonetheless, I need to fix this. If I just delete the packages to which the 
repo definitions belong to, I am left without any repositories (I have checked 
- none point to the internal repo, all belong to some installed package). As 
the clients are assigned to certain channels, I would like to add the 
corresponding repositories again. 



So far I have tried re-registering the client with 



# rhnreg_ks --serverUrl=https://YourSpacewalk.example.org/XMLRPC 
--sslCACert=/usr/share/rhn/RHN-ORG-TRUSTED-SSL-CERT 
--activationkey= --force 

No success. I have also removed all channel subscriptions, and then added them 
again, no success. 



What would be the easiest, or most reliable way to get the correct repo 
definitions back? 



Maybe my assumption is wrong, but since the spacewalk client tools have 
knowledge of the subscribed channels, I assume that there is also a way to get 
the corresponding repository definitions in some automated way. What would that 
be? 



Any hint or feedback is appreciated. 



Regards, 
Isaac 

___ 
Spacewalk-list mailing list 
Spacewalk-list@redhat.com 
https://www.redhat.com/mailman/listinfo/spacewalk-list

___
Spacewalk-list mailing list
Spacewalk-list@redhat.com
https://www.redhat.com/mailman/listinfo/spacewalk-list


smime.p7s
Description: S/MIME cryptographic signature
___
Spacewalk-list mailing list
Spacewalk-list@redhat.com
https://www.redhat.com/mailman/listinfo/spacewalk-list

Re: [Spacewalk-list] Fix yum repo definitions on spacewalk clients

2018-02-22 Thread Ivan Zenteno
I'm assuming you're talking about this bug
https://bugzilla.redhat.com/show_bug.cgi?id=1445428 with apache version

2018-02-19 10:10 GMT-06:00 Isaac Hailperin :

> Thank you Alex. It turns out my understanding was incomplete. Disabling
> repos is indeed an option, and knowing the spacewalk repos come via the rhn
> yum plugin helps to understand how it all works together.
>
> In the end it was a bug (back from April 2017 ...) that keps me from using
> the repos - I had to roll back httpd on the spacewalk server. After that,
> all is fine again.
>
> Isaac
>
> -Ursprüngliche Nachricht-
> Von: spacewalk-list-boun...@redhat.com [mailto:spacewalk-list-
> boun...@redhat.com] Im Auftrag von Alexandru Raceanu
> Gesendet: Donnerstag, 15. Februar 2018 23:26
> An: spacewalk-list@redhat.com
> Betreff: Re: [Spacewalk-list] Fix yum repo definitions on spacewalk clients
>
> I've been running following in the kickstart %post (non-chroot) to disable
> all repos except the ones from Spacewalk without any issues for couple of
> years now.
> snip
> sed -i -e '/reposdir=.*/d' -e '/cachedir.*/ 
> s,$,\nreposdir=/etc/yum.repos.d/disabled,'
> /mnt/sysimage/etc/yum.conf
> snip
>
> I hope this helps...
>
> /Alex
>
>
> From: "Isaac Hailperin" 
> To: "spacewalk-list@redhat.com" 
> Sent: Monday, February 12, 2018 10:51:55 AM
> Subject: [Spacewalk-list] Fix yum repo definitions on spacewalk clients
>
>
>
> Dear list,
>
>
>
> I have spacewalk 2.4 installed on a CentOS 7 host, and manage CentOS 7
> servers with it. Now I found that in /etc/yum.repos.d/ all configured
> repositories point to Internet repos. Which is not really how it should be,
> hosts should use the internal spacewalk repos. I assume this is due to
> packages like centos-release* being installed. I am just taking over this
> environment, so I am not 100% sure how all this came together.
>
>
>
> Nonetheless, I need to fix this. If I just delete the packages to which
> the repo definitions belong to, I am left without any repositories (I have
> checked - none point to the internal repo, all belong to some installed
> package). As the clients are assigned to certain channels, I would like to
> add the corresponding repositories again.
>
>
>
> So far I have tried re-registering the client with
>
>
>
> # rhnreg_ks --serverUrl=https://YourSpacewalk.example.org/XMLRPC
> --sslCACert=/usr/share/rhn/RHN-ORG-TRUSTED-SSL-CERT
> --activationkey= --force
>
> No success. I have also removed all channel subscriptions, and then added
> them again, no success.
>
>
>
> What would be the easiest, or most reliable way to get the correct repo
> definitions back?
>
>
>
> Maybe my assumption is wrong, but since the spacewalk client tools have
> knowledge of the subscribed channels, I assume that there is also a way to
> get the corresponding repository definitions in some automated way. What
> would that be?
>
>
>
> Any hint or feedback is appreciated.
>
>
>
> Regards,
> Isaac
>
> ___
> Spacewalk-list mailing list
> Spacewalk-list@redhat.com
> https://www.redhat.com/mailman/listinfo/spacewalk-list
>
> ___
> Spacewalk-list mailing list
> Spacewalk-list@redhat.com
> https://www.redhat.com/mailman/listinfo/spacewalk-list
>
> ___
> Spacewalk-list mailing list
> Spacewalk-list@redhat.com
> https://www.redhat.com/mailman/listinfo/spacewalk-list
>
___
Spacewalk-list mailing list
Spacewalk-list@redhat.com
https://www.redhat.com/mailman/listinfo/spacewalk-list