{"action":"created","issue":{"url":"https://api.github.com/repos/saltstack/salt/issues/49672","repository_url":"https://api.github.com/repos/saltstack/salt","labels_url":"https://api.github.com/repos/saltstack/salt/issues/49672/labels{/name}","comments_url":"https://api.github.com/repos/saltstack/salt/issues/49672/comments","events_url":"https://api.github.com/repos/saltstack/salt/issues/49672/events","html_url":"https://github.com/saltstack/salt/issues/49672","id":360906336,"node_id":"MDU6SXNzdWUzNjA5MDYzMzY=","number":49672,"title":"pkg.installed not working correctly on ppc64le architecture","user":{"login":"sjtbham","id":10603918,"node_id":"MDQ6VXNlcjEwNjAzOTE4","avatar_url":"https://avatars0.githubusercontent.com/u/10603918?v=4","gravatar_id":"","url":"https://api.github.com/users/sjtbham","html_url":"https://github.com/sjtbham","followers_url":"https://api.github.com/users/sjtbham/followers","following_url":"https://api.github.com/users/sjtbham/following{/other_user}","gists_url":"https://api.github.com/users/sjtbham/gists{/gist_id}","starred_url":"https://api.github.com/users/sjtbham/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sjtbham/subscriptions","organizations_url":"https://api.github.com/users/sjtbham/orgs","repos_url":"https://api.github.com/users/sjtbham/repos","events_url":"https://api.github.com/users/sjtbham/events{/privacy}","received_events_url":"https://api.github.com/users/sjtbham/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-09-17T14:51:02Z","updated_at":"2018-09-17T15:17:18Z","closed_at":null,"author_association":"NONE","body":"### Description of Issue/Question\r\nWhen running on `ppc64le` systems, with architecture based packages, salt is trying to repeatedly install the package when it is already installed. For example we want to ensure the `iptables` package is installed on the system via salt. This works as expected on `x86_64` arch systems, but doesn't work properly on `ppc64le` systems.\r\n\r\n### Setup\r\nExample state for package installation\r\n```\r\niptables-pkg:\r\n  pkg:\r\n    - installed\r\n    - name: {{ pillar.packages.names.iptables | default('iptables') }}\r\n```\r\n\r\n### Steps to Reproduce Issue\r\n```# salt-call state.highstate\r\n[ERROR   ] The following packages failed to install/update: iptables\r\n```\r\n\r\nOn ppc64le salt client (trimmed to relevant output):\r\n```\r\n# salt-call state.highstate test=true\r\n----------\r\n          ID: iptables-pkg\r\n    Function: pkg.installed\r\n        Name: iptables\r\n      Result: None\r\n     Comment: The following packages would be installed/updated: iptables\r\n     Started: 15:40:47.161451\r\n    Duration: 91.094 ms\r\n     Changes:\r\n```\r\n\r\nListing the versions of the packages installed:\r\n```\r\n# salt-call pkg.list_pkgs\r\nlocal:\r\n    ----------\r\n    iptables.ppc64le:\r\n        1.4.21-24.1.el7_5\r\n```\r\n\r\nWhilst salt is running in non test mode, you can see it running processes like `yum -y install iptables` (in output from `ps -ef`) which salt things has failed (though the package is actually installed) I assume due to some architecture mismatching?\r\n\r\nChecking what yum thinks is installed:\r\n```\r\n# yum list iptables\r\nLoaded plugins: product-id, search-disabled-repos, subscription-manager, versionlock\r\nInstalled Packages\r\niptables.ppc64le                                                 1.4.21-24.1.el7_5                                                  @pkg1/7.5\r\n```\r\n\r\n\r\n### Versions Report\r\n```\r\n# salt-call --versions-report\r\nSalt Version:\r\n           Salt: 2018.3.2\r\n\r\nDependency Versions:\r\n           cffi: 1.6.0\r\n       cherrypy: Not Installed\r\n       dateutil: 1.5\r\n      docker-py: Not Installed\r\n          gitdb: Not Installed\r\n      gitpython: Not Installed\r\n          ioflo: 1.3.8\r\n         Jinja2: 2.7.2\r\n        libgit2: Not Installed\r\n        libnacl: Not Installed\r\n       M2Crypto: 0.28.2\r\n           Mako: Not Installed\r\n   msgpack-pure: Not Installed\r\n msgpack-python: 0.5.6\r\n   mysql-python: Not Installed\r\n      pycparser: 2.14\r\n       pycrypto: 2.6.1\r\n   pycryptodome: Not Installed\r\n         pygit2: Not Installed\r\n         Python: 2.7.5 (default, May 31 2018, 09:45:54)\r\n   python-gnupg: Not Installed\r\n         PyYAML: 3.11\r\n          PyZMQ: 15.3.0\r\n           RAET: Not Installed\r\n          smmap: Not Installed\r\n        timelib: Not Installed\r\n        Tornado: 4.2.1\r\n            ZMQ: 4.1.4\r\n\r\nSystem Versions:\r\n           dist: redhat 7.5 Maipo\r\n         locale: UTF-8\r\n        machine: ppc64le\r\n        release: 4.14.0-49.10.1.el7a.ppc64le\r\n         system: Linux\r\n        version: Red Hat Enterprise Linux Server 7.5 Maipo\r\n```\r\n\r\n```\r\n# uname -p\r\nppc64le\r\n```\r\n\r\nNote the master is also running 2018.3 but is running on x86_64 architecture."},"comment":{"url":"https://api.github.com/repos/saltstack/salt/issues/comments/422057811","html_url":"https://github.com/saltstack/salt/issues/49672#issuecomment-422057811","issue_url":"https://api.github.com/repos/saltstack/salt/issues/49672","id":422057811,"node_id":"MDEyOklzc3VlQ29tbWVudDQyMjA1NzgxMQ==","user":{"login":"sjtbham","id":10603918,"node_id":"MDQ6VXNlcjEwNjAzOTE4","avatar_url":"https://avatars0.githubusercontent.com/u/10603918?v=4","gravatar_id":"","url":"https://api.github.com/users/sjtbham","html_url":"https://github.com/sjtbham","followers_url":"https://api.github.com/users/sjtbham/followers","following_url":"https://api.github.com/users/sjtbham/following{/other_user}","gists_url":"https://api.github.com/users/sjtbham/gists{/gist_id}","starred_url":"https://api.github.com/users/sjtbham/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sjtbham/subscriptions","organizations_url":"https://api.github.com/users/sjtbham/orgs","repos_url":"https://api.github.com/users/sjtbham/repos","events_url":"https://api.github.com/users/sjtbham/events{/privacy}","received_events_url":"https://api.github.com/users/sjtbham/received_events","type":"User","site_admin":false},"created_at":"2018-09-17T15:17:18Z","updated_at":"2018-09-17T15:17:18Z","author_association":"NONE","body":"Looks to be related to similar report:\r\nhttps://bugzilla.redhat.com/show_bug.cgi?id=1461288\r\n\r\ni.e. \r\n```\r\n# rpm --eval \"%{_host_cpu}\"\r\npowerpc64le\r\n```\r\n\r\ndoes not match the name used in the rpm, both `grains/core.py` and `utils/pkg/rpm.py` seem to use the rpm macro for the osarch."}}
{"actor":{"display_login":"sjtbham"}}