|
|
|
[root@pulp3 ~]# curl -O http://vault.centos.org/7.4.1708/os/x86_64/Packages/adwaita-qt-0.4-1.el7.x86_64.rpm
|
|
% Total % Received % Xferd Average Speed Time Time Time Current
|
|
Dload Upload Total Spent Left Speed
|
|
100 3084 100 3084 0 0 6637 0 --:--:-- --:--:-- --:--:-- 6646
|
|
[root@pulp3 ~]# ls
|
|
adwaita-qt-0.4-1.el7.x86_64.rpm anaconda-ks.cfg original-ks.cfg
|
|
[root@pulp3 ~]# curl -X POST -F 'file=@./adwaita-qt-0.4-1.el7.x86_64.rpm' admin:admin@localhost:8000/pulp/api/v3/artifacts/ | python -mjson.tool
|
|
% Total % Received % Xferd Average Speed Time Time Time Current
|
|
Dload Upload Total Spent Left Speed
|
|
100 4013 100 706 100 3307 4987 23362 --:--:-- --:--:-- --:--:-- 23453
|
|
{
|
|
"_created": "2019-03-15T11:43:48.688708Z",
|
|
"_href": "/pulp/api/v3/artifacts/24f656c3-a4c9-41af-a1b8-c488eea4f942/",
|
|
"file": "/var/lib/pulp/artifact/2c/0d31b4a1220a9228e72d7ccc6bd42d1ce819058bf1be58769d831ba42016f1",
|
|
"md5": "097503338ba1626e6e080baf01965834",
|
|
"sha1": "c45540402acda226572abb491a8ea5c7e7d28c4f",
|
|
"sha224": "6c22efdbb57bd2e52103482d3b951df28bf05d0b50dadc73d4d9ec69",
|
|
"sha256": "2c0d31b4a1220a9228e72d7ccc6bd42d1ce819058bf1be58769d831ba42016f1",
|
|
"sha384": "f74b685646d17ad5e7addde1707dfa312a804a7986f45b55c53a4e986a4ca64831f8ea08e4949d848735306a61f0fd84",
|
|
"sha512": "5f0e6fd03a2ff3b269ae0e3bb6689d2948239c2e90197df69cf2fc142d43ea486fecd6fd0642e29846deb233beaa617e3a2251b3833a71cb1a21d2a195b17bed",
|
|
"size": 3084
|
|
}
|
|
[root@pulp3 ~]# pcurlp content/rpm/packages '{"relative_path":"adwaita-qt-0.4-1.el7.x86_64.rpm","_artifact":"/pulp/api/v3/artifacts/24f656c3-a4c9-41af-a1b8-c488eea4f942/","filename":"adwaita-qt-0.4-1.el7.x86_64.rpm"}'
|
|
{
|
|
"_artifact": "/pulp/api/v3/artifacts/24f656c3-a4c9-41af-a1b8-c488eea4f942/",
|
|
"_created": "2019-03-15T11:45:00.131908Z",
|
|
"_href": "/pulp/api/v3/content/rpm/packages/2a0aa9cb-2982-4167-9ff7-ccfe81af447b/",
|
|
"_type": "rpm.package",
|
|
"arch": "x86_64",
|
|
"changelogs": "[[\"Jan Grulich <jgrulich@redhat.com> - 0.3-1\", 1456747200, \"- Initial package\\n Resolves: bz#1306307\"], [\"Jan Grulich <jgrulich@redhat.com> - 0.3-2\", 1460980800, \"- Enable Qt5 version\\n Resolves: bz#1306307\"], [\"Jan Grulich <jgrulich@redhat.com> - 0.4-1\", 1461240000, \"- Update to version 0.4\\n Resolves: bz#1306307\"]]",
|
|
"checksum_type": "sha256",
|
|
"conflicts": "[]",
|
|
"description": "Theme to let Qt applications fit nicely into Gnome environment",
|
|
"enhances": "[]",
|
|
"epoch": "0",
|
|
"files": "[]",
|
|
"location_base": "",
|
|
"location_href": "adwaita-qt-0.4-1.el7.x86_64.rpm",
|
|
"name": "adwaita-qt",
|
|
"obsoletes": "[]",
|
|
"pkgId": "2c0d31b4a1220a9228e72d7ccc6bd42d1ce819058bf1be58769d831ba42016f1",
|
|
"provides": "[[\"adwaita-qt\", \"EQ\", \"0\", \"0.4\", \"1.el7\", false], [\"adwaita-qt(x86-64)\", \"EQ\", \"0\", \"0.4\", \"1.el7\", false]]",
|
|
"recommends": "[]",
|
|
"release": "1.el7",
|
|
"requires": "[[\"adwaita-qt4\", null, null, null, null, false]]",
|
|
"rpm_buildhost": "worker1.bsys.centos.org",
|
|
"rpm_group": "Unspecified",
|
|
"rpm_header_end": 2968,
|
|
"rpm_header_start": 1384,
|
|
"rpm_license": "LGPLv2+",
|
|
"rpm_packager": "CentOS BuildSystem <http://bugs.centos.org>",
|
|
"rpm_sourcerpm": "adwaita-qt-0.4-1.el7.src.rpm",
|
|
"rpm_vendor": "CentOS",
|
|
"size_archive": 124,
|
|
"size_installed": 0,
|
|
"size_package": 3084,
|
|
"suggests": "[]",
|
|
"summary": "Adwaita theme for Qt-based applications",
|
|
"supplements": "[]",
|
|
"time_build": 1478506224,
|
|
"time_file": 1552650228,
|
|
"url": "https://github.com/MartinBriza/adwaita-qt",
|
|
"version": "0.4"
|
|
}
|
|
[root@pulp3 ~]# pcurlp repositories '{"name":"onepackage"}'
|
|
{
|
|
"_created": "2019-03-15T11:45:32.051271Z",
|
|
"_href": "/pulp/api/v3/repositories/6b5d281d-0529-490a-a991-fab5ba4977b8/",
|
|
"_latest_version_href": null,
|
|
"_versions_href": "/pulp/api/v3/repositories/6b5d281d-0529-490a-a991-fab5ba4977b8/versions/",
|
|
"description": "",
|
|
"name": "onepackage"
|
|
}
|
|
[root@pulp3 ~]# pcurlp repositories/6b5d281d-0529-490a-a991-fab5ba4977b8/versions '{"add_content_units":["/pulp/api/v3/content/rpm/packages/2a0aa9cb-2982-4167-9ff7-ccfe81af447b/"]}'
|
|
{
|
|
"task": "/pulp/api/v3/tasks/5fb91801-48da-4199-ac86-d8c896cf4367/"
|
|
}
|
|
[root@pulp3 ~]# pcurlg tasks/5fb91801-48da-4199-ac86-d8c896cf4367
|
|
{
|
|
"_created": "2019-03-15T11:46:37.338357Z",
|
|
"_href": "/pulp/api/v3/tasks/5fb91801-48da-4199-ac86-d8c896cf4367/",
|
|
"created_resources": [
|
|
"/pulp/api/v3/repositories/6b5d281d-0529-490a-a991-fab5ba4977b8/versions/1/"
|
|
],
|
|
"error": null,
|
|
"finished_at": "2019-03-15T11:46:37.433748Z",
|
|
"job_id": "4a3ce2e2-17c9-477a-a8a9-319b5163bd65",
|
|
"name": "pulpcore.app.tasks.repository.add_and_remove",
|
|
"non_fatal_errors": [],
|
|
"parent": null,
|
|
"progress_reports": [],
|
|
"spawned_tasks": [],
|
|
"started_at": "2019-03-15T11:46:37.401710Z",
|
|
"state": "completed",
|
|
"worker": "/pulp/api/v3/workers/87dd0d12-61fb-44cb-a469-9050c3a2ced9/"
|
|
}
|
|
[root@pulp3 ~]# pcurlp publishers/rpm/rpm '{"name":"onepackage"}'
|
|
{
|
|
"_created": "2019-03-15T11:47:48.724514Z",
|
|
"_href": "/pulp/api/v3/publishers/rpm/rpm/bc12a76a-78fa-4f43-a4dd-af89bf506fc2/",
|
|
"_last_updated": "2019-03-15T11:47:48.724528Z",
|
|
"_type": "rpm.rpm",
|
|
"distributions": [],
|
|
"name": "onepackage"
|
|
}
|
|
[root@pulp3 ~]# pcurlp publishers/rpm/rpm/bc12a76a-78fa-4f43-a4dd-af89bf506fc2/publish '{"repository":"/pulp/api/v3/repositories/6b5d281d-0529-490a-a991-fab5ba4977b8/"}'
|
|
{
|
|
"task": "/pulp/api/v3/tasks/a3b99b53-21f6-4ef7-9306-5e51991b17c3/"
|
|
}
|
|
[root@pulp3 ~]# pcurlg tasks/a3b99b53-21f6-4ef7-9306-5e51991b17c3
|
|
{
|
|
"_created": "2019-03-15T11:48:41.338355Z",
|
|
"_href": "/pulp/api/v3/tasks/a3b99b53-21f6-4ef7-9306-5e51991b17c3/",
|
|
"created_resources": [
|
|
"/pulp/api/v3/publications/27d8738d-ea54-4c8f-984f-0d286205ee67/"
|
|
],
|
|
"error": null,
|
|
"finished_at": "2019-03-15T11:48:41.466008Z",
|
|
"job_id": "cd2cdbfd-d482-41e6-82c0-98a472bb40f5",
|
|
"name": "pulp_rpm.app.tasks.publishing.publish",
|
|
"non_fatal_errors": [],
|
|
"parent": null,
|
|
"progress_reports": [],
|
|
"spawned_tasks": [],
|
|
"started_at": "2019-03-15T11:48:41.400338Z",
|
|
"state": "completed",
|
|
"worker": "/pulp/api/v3/workers/87dd0d12-61fb-44cb-a469-9050c3a2ced9/"
|
|
}
|
|
[root@pulp3 ~]# pcurlp distributions '{"name":"onepackage","base_path":"centos/onepackage","publication":"/pulp/api/v3/publications/27d8738d-ea54-4c8f-984f-0d286205ee67/"}'
|
|
{
|
|
"_created": "2019-03-15T11:50:05.083288Z",
|
|
"_href": "/pulp/api/v3/distributions/e73478fe-f984-4805-8b4a-01b14691a7fb/",
|
|
"base_path": "centos/onepackage",
|
|
"base_url": "/pulp/content/centos/onepackage",
|
|
"content_guard": null,
|
|
"name": "onepackage",
|
|
"publication": "/pulp/api/v3/publications/27d8738d-ea54-4c8f-984f-0d286205ee67/",
|
|
"publisher": null,
|
|
"remote": null,
|
|
"repository": null
|
|
}
|
|
[root@pulp3 ~]# curl localhost:8080/pulp/content/centos/onepackage/repodata/repomd.xml
|
|
<?xml version="1.0" encoding="UTF-8"?>
|
|
<repomd xmlns="http://linux.duke.edu/metadata/repo" xmlns:rpm="http://linux.duke.edu/metadata/rpm">
|
|
<revision>1552650521</revision>
|
|
<data type="primary">
|
|
<checksum type="sha256">62ae6cb7445de13eeb6b8daf0c4a3e740cbd2e45255b9b8974cfaa2565d0d577</checksum>
|
|
<open-checksum type="sha256">4c39c5f4b898b56b8f0903088e417f6914d59937e3cc3660eae7a91c70aec16d</open-checksum>
|
|
<location href="repodata/primary.xml.gz"/>
|
|
<timestamp>1552650521</timestamp>
|
|
<size>710</size>
|
|
<open-size>1432</open-size>
|
|
</data>
|
|
<data type="filelists">
|
|
<checksum type="sha256">b0d316ed6872e1e8e77550da1a5385642974c206b0dc49eb4ef8114164ac15fc</checksum>
|
|
<open-checksum type="sha256">e9f639ce4cb24bd8b39f956353a11afe06316183e5c90c79961940af96d69327</open-checksum>
|
|
<location href="repodata/filelists.xml.gz"/>
|
|
<timestamp>1552650521</timestamp>
|
|
<size>235</size>
|
|
<open-size>296</open-size>
|
|
</data>
|
|
<data type="other">
|
|
<checksum type="sha256">197ca817f299490f624adc703de8b79cd9bf22059f90a14dd8a132d9bb2266fe</checksum>
|
|
<open-checksum type="sha256">cecb4405cb7f69d111b9bc9df5e88841e46dc8daf7d592a03d2a8992c2f79710</open-checksum>
|
|
<location href="repodata/other.xml.gz"/>
|
|
<timestamp>1552650521</timestamp>
|
|
<size>382</size>
|
|
<open-size>724</open-size>
|
|
</data>
|
|
<data type="primary_db">
|
|
<checksum type="sha256">671e64173fb6a05d33d5800d0a293576c989fea8296e7dfcee8f98fbc411123f</checksum>
|
|
<location href="repodata/primary.sqlite"/>
|
|
<timestamp>1552650521</timestamp>
|
|
<size>30720</size>
|
|
<database_version>10</database_version>
|
|
</data>
|
|
<data type="filelists_db">
|
|
<checksum type="sha256">53dfec40f9446e0b6143bd4ca95295e77015a874136635c2ff85582e5e0d54c5</checksum>
|
|
<location href="repodata/filelists.sqlite"/>
|
|
<timestamp>1552650521</timestamp>
|
|
<size>7168</size>
|
|
<database_version>10</database_version>
|
|
</data>
|
|
<data type="other_db">
|
|
<checksum type="sha256">8b8b59d25bfa2a625ce171956e749ab5c0402d1664e899c1070bb7aa797be106</checksum>
|
|
<location href="repodata/other.sqlite"/>
|
|
<timestamp>1552650521</timestamp>
|
|
<size>6144</size>
|
|
<database_version>10</database_version>
|
|
</data>
|
|
<data type="updateinfo">
|
|
<checksum type="sha256">c0cace4d6bd977ad29096c46467682b30b7ef65aff60fe7f7238096f9003d898</checksum>
|
|
<open-checksum type="sha256">2d438c5e29ec0e2eb9509db795b1c479f3c25a7e1e5537be4b5814f62cb7e81e</open-checksum>
|
|
<location href="repodata/updateinfo.xml.gz"/>
|
|
<timestamp>1552650521</timestamp>
|
|
<size>71</size>
|
|
<open-size>59</open-size>
|
|
</data>
|
|
</repomd>
|
|
[root@pulp3 ~]# cd /etc/yum.repos.d/
|
|
CentOS-Base.repo CentOS-Debuginfo.repo CentOS-Media.repo CentOS-Vault.repo epel.repo epel-testing-debuginfo.repo epel-testing-source.repo puppet5.repo yum.postgresql.org.repo
|
|
CentOS-CR.repo CentOS-fasttrack.repo CentOS-Sources.repo epel-debuginfo.repo epel-source.repo epel-testing.repo icinga-stable-release.repo puppetlabs.repo
|
|
[root@pulp3 yum.repos.d]# mkdir old
|
|
[root@pulp3 yum.repos.d]# mv * old/
|
|
mv: cannot move ‘old’ to a subdirectory of itself, ‘old/old’
|
|
[root@pulp3 yum.repos.d]# rm -rf /var/cache/yum/
|
|
[root@pulp3 yum.repos.d]# ls
|
|
old
|
|
[root@pulp3 yum.repos.d]# vi onepackage.repo
|
|
[root@pulp3 yum.repos.d]# cat onepackage.repo
|
|
[onepackage]
|
|
name = onepackage
|
|
baseurl = http://localhost:8080/pulp/content/centos/onepackage
|
|
gpgcheck = 0
|
|
[root@pulp3 yum.repos.d]# yum makecache
|
|
Loaded plugins: fastestmirror
|
|
onepackage | 2.6 kB 00:00:00
|
|
(1/4): onepackage/filelists_db | 7.0 kB 00:00:00
|
|
(2/4): onepackage/updateinfo | 71 B 00:00:00
|
|
(3/4): onepackage/primary_db | 30 kB 00:00:00
|
|
(4/4): onepackage/other_db | 6.0 kB 00:00:00
|
|
Determining fastest mirrors
|
|
|
|
|
|
One of the configured repositories failed (Unknown),
|
|
and yum doesn't have enough cached data to continue. At this point the only
|
|
safe thing yum can do is fail. There are a few ways to work "fix" this:
|
|
|
|
1. Contact the upstream for the repository and get them to fix the problem.
|
|
|
|
2. Reconfigure the baseurl/etc. for the repository, to point to a working
|
|
upstream. This is most often useful if you are using a newer
|
|
distribution release than is supported by the repository (and the
|
|
packages for the previous distribution release still work).
|
|
|
|
3. Run the command with the repository temporarily disabled
|
|
yum --disablerepo=<repoid> ...
|
|
|
|
4. Disable the repository permanently, so yum won't use it by default. Yum
|
|
will then just ignore the repository until you permanently enable it
|
|
again or use --enablerepo for temporary usage:
|
|
|
|
yum-config-manager --disable <repoid>
|
|
or
|
|
subscription-manager repos --disable=<repoid>
|
|
|
|
5. Configure the failing repository to be skipped, if it is unavailable.
|
|
Note that yum will try to contact the repo. when it runs most commands,
|
|
so will have to try and fail each time (and thus. yum will be be much
|
|
slower). If it is a very temporary problem though, this is often a nice
|
|
compromise:
|
|
|
|
yum-config-manager --save --setopt=<repoid>.skip_if_unavailable=true
|
|
|
|
onepackage: Check uncompressed DB failed
|
|
|