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

Broken repository #3

Open
kedare opened this issue Oct 10, 2018 · 2 comments
Open

Broken repository #3

kedare opened this issue Oct 10, 2018 · 2 comments

Comments

@kedare
Copy link

kedare commented Oct 10, 2018

Looks like the repository URL has changed ?
I can't get this role to work, getting

TASK [kyleabenson.mssql : Update all packages] **************************************************************************************************************
Wednesday 10 October 2018  17:43:07 +0200 (0:00:02.447)       0:00:57.680 *****
fatal: [10.11.2.104]: FAILED! => {"changed": false, "msg": "https://packages.microsoft.com/rhel/7/mssql-server/repodata/repomd.xml: [Errno 14] HTTPS Error 40
4 - Not Found\nTrying other mirror.\nTo address this issue please refer to the below wiki article \n\nhttps://wiki.centos.org/yum-errors\n\nIf above article
doesn't help to resolve this issue please use https://bugs.centos.org/.\n\n\n\n One of the configured repositories failed (Microsoft SQL repo),\n and yum doe
sn't have enough cached data to continue. At this point the only\n safe thing yum can do is fail. There are a few ways to work \"fix\" this:\n\n     1. Conta
ct the upstream for the repository and get them to fix the problem.\n\n     2. Reconfigure the baseurl/etc. for the repository, to point to a working\n
  upstream. This is most often useful if you are using a newer\n        distribution release than is supported by the repository (and the\n        packages f
or the previous distribution release still work).\n\n     3. Run the command with the repository temporarily disabled\n            yum --disablerepo=mssql ..
.\n\n     4. Disable the repository permanently, so yum won't use it by default. Yum\n        will then just ignore the repository until you permanently enab
le it\n        again or use --enablerepo for temporary usage:\n\n            yum-config-manager --disable mssql\n        or\n            subscription-manager
 repos --disable=mssql\n\n     5. Configure the failing repository to be skipped, if it is unavailable.\n        Note that yum will try to contact the repo.
when it runs most commands,\n        so will have to try and fail each time (and thus. yum will be be much\n        slower). If it is a very temporary proble
m though, this is often a nice\n        compromise:\n\n            yum-config-manager --save --setopt=mssql.skip_if_unavailable=true\n\nfailure: repodata/rep
omd.xml from mssql: [Errno 256] No more mirrors to try.\nhttps://packages.microsoft.com/rhel/7/mssql-server/repodata/repomd.xml: [Errno 14] HTTPS Error 404 -
 Not Found\n", "rc": 1, "results": []}

The repos are available there: https://docs.microsoft.com/en-us/sql/linux/sample-unattended-install-redhat?view=sql-server-2017

@metaturso
Copy link

@kyleabenson there are a number of this project's forks already implementing a fix to this issue (it's just a single baseurl value to change in tasks/main.yml.)

Are you looking for someone to raise a pull request or are you not interested in having this resolved?

@mohamad7788
Copy link

mohamad7788 commented Oct 21, 2019

Hi,

I faced the same issue , and it seems that the mssql repo base-URL isn't accessible anymore ( getting 404 once opening the URL https://packages.microsoft.com/rhel/7/mssql-server/repodata/repomd.xml

Seems that the opened pull request Update MsSql server repo path #1 not merged yet to the master .

Then you need to fix the below in file(in your local files) ansible-role-mssql/tasks/main.yml

- name: Add the MsSQL server repo
  yum_repository:
    name: mssql
    description: Microsoft SQL repo
    file: /etc/yum.repos.d/msprod
    #    baseurl: https://packages.microsoft.com/rhel/7/mssql-server/
    baseurl: https://packages.microsoft.com/rhel/7/mssql-server-2017/
    gpgkey: https://packages.microsoft.com/keys/microsoft.asc
    gpgcheck: yes

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

3 participants