How to install .p51 packages in Solaris 11.4?

Does anyone know how to install a package that comes in a p5i file in Solaris 11.4? The first thing the Oracle documentation says is to "launch packagemanager". Well they removed packagemanager from 11.4 (and you can't install it yourself). I want a package from http://pkg.openindiana.org/hipster/en/catalog.shtml?version=0.5.11%2C0.5.11-2018.0.0.0&action=Browse

When I mouse over the "Install" link it pops up "Launch the Package Manager and install this package". Uh, no Package Manager. I tried downloading the p5i file and then saying "# pkg install pkg-name" but that didn't work either. This is a mystery.

And while I'm asking, this should probably go in the Solaris subforum but for the life of me I can't figure out how to get there either. Whenever I click on the "ask a question" button it takes me here.

I'm not a Solaris person for a few decades now; but just as a wild guess, did you try "the web method" (for example, for logrotate ):

pkg install -g http://pkg.openindiana.org/hipster/p5i/0/system%2Ffile%2Flogrotate.p5i logrotate

(maybe use the directory of the package versus the file name)

Also, which packages are you trying to install?

Ref:

Installing and Updating Packages -
Updating Systems and Adding Software in Oracle(R) Solaris 11.4

Frankly, I'm as confused as you are. Before, Solaris has "

packagemanager

" which used the .p5i file extension.

Then, Oracle switches to pkg and in the documentation (online and PDF), there is zero mention of . p5i files (as if . p5i files never existed).

Indeed, this is really strange, indeed.

See also, for reference:

Installing packages in Solaris 11

https://www.unix.com/solaris/227455-installing-packages-solaris-11-a.html

Please note I search the net for quite some time and could not find any "bridge" discussion between the " .p5i " files mentioned in packagemanager and the pkg system on Solaris. This really did not make sense to me.

Why is there no discussion (that I can find) linking the two different package management systems on Solaris?

Well that didn't work but I think we're on the right track.

root@hemlock:~# pkg install -g http://pkg.openindiana.org/hipster/p5i/0/system%2Ffile%2Flogrotate.p5i logrotate


Errors were encountered while attempting to retrieve package or file data for
the requested operation.
Details follow:

  http protocol error: Unknown error code: 404 reason: Not Found
URL: 'http://pkg.openindiana.org/hipster/p5i/0/system%2Ffile%2Flogrotate.p5i/versions/0/'

I tried a few other variations, like this:

root@hemlock:~# pkg install -g http://pkg.openindiana.org/hipster/info/0/pkg://openindiana.org/system/file/logrotate@3.15.0,5.11-2018.0.0.0:20190307T195640Z logrotate

Errors were encountered while attempting to retrieve package or file data for
the requested operation.
Details follow:

  http protocol error: Unknown error code: 400 reason: Bad Request
URL: 'http://pkg.openindiana.org/hipster/info/0/pkg://openindiana.org/system/file/logrotate@3.15.0,5.11-2018.0.0.0:20190307T195640Z/versions/0/'

root@hemlock:~# install -g http://pkg.openindiana.org/hipster/info/0/pkg://openindiana.org/system/file/logrotate logrotate
find: cycle detected for /lib/secure/32/
find: cycle detected for /lib/crypto/32/
find: cycle detected for /lib/32/
find: cycle detected for /lib/fm/32/
find: cycle detected for /usr/lib/gss/32/
find: cycle detected for /usr/lib/pool/32/
find: cycle detected for /usr/lib/python2.7/vendor-packages/nss/32/
find: cycle detected for /usr/lib/python2.7/vendor-packages/solaris/32/
find: cycle detected for /usr/lib/python2.7/vendor-packages/zfs/32/
find: cycle detected for /usr/lib/reparse/32/
find: cycle detected for /usr/lib/secure/32/
find: cycle detected for /usr/lib/brand/solaris10/32/
find: cycle detected for /usr/lib/32/
find: cycle detected for /usr/lib/scsi/32/
find: cycle detected for /usr/lib/lwp/32/
find: cycle detected for /usr/lib/fm/topo/plugins/32/
find: cycle detected for /usr/lib/fm/32/
find: cycle detected for /usr/lib/rad/client/c/32/
find: cycle detected for /usr/lib/cfgadm/32/
find: cycle detected for /usr/lib/locale/en_US.UTF-8/32/
find: cycle detected for /usr/lib/locale/en_US.UTF-8/LO_LTYPE/32/
find: cycle detected for /usr/lib/locale/en_US.UTF-8/LC_CTYPE/32/
find: cycle detected for /usr/lib/security/32/
find: cycle detected for /usr/lib/link_audit/32/
find: cycle detected for /usr/lib/nfs/32/
find: cycle detected for /usr/lib/elfedit/32/
install: logrotate was not found anywhere!
root@hemlock:~# install -g http://pkg.openindiana.org/hipster/info/0/pkg://openindiana.org/system/file/logrotate
/usr/sbin/install[263]: shift: (null): bad number
root@hemlock:~# pkg install -g http://pkg.openindiana.org/hipster/p5i/0/system%2Ffile%2Flogrotate.p5i logrotate

Errors were encountered while attempting to retrieve package or file data for
the requested operation.
Details follow:

  http protocol error: Unknown error code: 404 reason: Not Found
URL: 'http://pkg.openindiana.org/hipster/p5i/0/system%2Ffile%2Flogrotate.p5i/versions/0/'

I think I just need to figure out what name to feed pkg install. I'd be curious if anyone has been able to install OpenIndiana packages in Solaris 11.4. The one I'm really interested in is firefox. Apparently they have Firefox 60 which is not available anywhere else. The Firefox that comes with 11.4 is 52 which is now way out of date.

Maybe as a test case, you can download the file locally first, in the case of logrotate, you will get this file:

system_file_logrotate.p5i

Then try the same idea but with a local file:

yoursystem# pkg install -g file://path_to/system_file_logrotate.p5i  logrotate

Honestly, I don't have Solaris so I cannot try this out, so I'm just grasping at straws, hopefully it's not completely off-the-wall.

Update:

Also, I found this quite detailed discussion for you:

https://serverfault.com/questions/348139/how-to-manually-download-individual-files-from-the-openindiana-or-solaris-pkg

Maybe review that link and give it a try and post back your (hopefully good) results?

Thanks.

OK well I just checked what I should have checked at the start. It turns out that OpenIndiana is only for x86 Solaris, not SPARC. So even if I could download it, it wouldn't run. Sigh.

Thanks anyway though. Perhaps this will be useful to someone else.

LOL

Yes, people generally learn more from "mistakes" or "failures" than "success".... and that is why your post is good for everyone who might be working on a similar project. UNIX.com is not about "the best solution" and nor is it a "show off site" where people are trying (at least hopefully not) to "out code" each other in a big popularity contest. Here is a site for sharing our collective tech experience, freely and with as little commercial and marketing influence; and in a way which everyone is kind and respectful of others, regardless of the number of years of experience. Do we always succeed? No of course not. But we try and that is our goal.

I'm sure many people in the future will benefit from your self-discovery journey on this topic, Michele31416,

Thanks for posting back and closing the loop.