Koozali.org: home of the SME Server

Obsolete Releases => SME Server 7.x => Topic started by: stiperstones on October 08, 2006, 11:17:42 PM

Title: correct way to add yum repo using db command [solved]
Post by: stiperstones on October 08, 2006, 11:17:42 PM
Would like to add a new repo to yum repository using the db command could sombody please enlighten me followed the commands on wiki for adding  3rd party repo's (http://no.longer.valid/phpwiki/index.php/3rdPartyYumRepositories) but did not work
Title: correct way to add yum repo using db command [solved]
Post by: william_syd on October 09, 2006, 04:07:40 AM
What part didn't work ?

Did you do..
Code: [Select]
expand-template /etc/yum.conf
after the db commands ?

Also note that there disabled by default. So on the command line you need --enablerepo=(repo name) .
Title: correct way to add yum repo using db command [solved]
Post by: stiperstones on October 09, 2006, 08:58:59 PM
Thank you william_syd
I have found out myself that i had wrote my code wrong i added an = sign between value and answer


Incorrect input
Code: [Select]

/sbin/e-smith/db yum_repositories set my_repository_name repository \
BaseURL=http://www.myservername.org/pub/file/file/RPM/file/myrepository/ \
EnableGroups=yes \
GPGCheck=no \
Name='my_repository_name' \
Visible=no \
status=disabled



expand-template /etc/yum.conf


correct values
Code: [Select]

/sbin/e-smith/db yum_repositories set my_repository_name repository \
BaseURL http://www.myservername.org/pub/file/file/RPM/file/myrepository/ \
EnableGroups yes \
GPGCheck no \
Name 'my_repository_name' \
Visible no \
status disabled

expand-template /etc/yum.conf
Title: correct way to add yum repo using db command [solved]
Post by: william_syd on October 10, 2006, 03:05:21 AM
Yes, the incorrect method will give you this..
Code: [Select]
[root@vmsme7go ~]# /sbin/e-smith/db yum_repositories show my_repository_name
my_repository_name=repository
    BaseURL=http://www.myservername.org/pub/file/file/RPM/file/myrepository/=EnableGroups=yes
    GPGCheck=no=Name=my_repository_name
    Visible=no=status=disabled
[root@vmsme7go ~]#

instead of
Code: [Select]
[root@vmsme7go ~]# /sbin/e-smith/db yum_repositories show my_repository_name
my_repository_name=repository
    BaseURL=http://www.myservername.org/pub/file/file/RPM/file/myrepository/
    EnableGroups=yes
    GPGCheck=no
    Name=my_repository_name
    Visible=no
    status=disabled
[root@vmsme7go ~]#