What is the difference between these two commands?

1. pkgtrans /cdrom/cdrom0/Solaris_10/Product /var/spool/pkg/stream.pkg all

2. pkgtrans -s /cdrom/cdrom0/Solaris_10/Product /var/spool/pkg/stream.pkg all

The two commands make the same action.

The second question is: If I have file stream format package in /export/home/memam/ which called SUNWipc.pkg and I want to translate it to file system format, does this command pkgtrans /export/home/memam/SUNWipc.pkg /var/spool/pkg translate make this operation


The -s option in your first command tells pkgtrans to translate the package into a datastream package on device2 (the target).

If the device2 argument is a directory, then a filesystem type package will be placed in the directory. If device2 is a file, a datastream package will be created.

To translate your SUNWipc.pkg to a filesystem type package, assuming you wanted it placed in /var/spool/pkg/, you would need to run:

pkgtrans /export/home/memam/SUNWipc.pkg /var/spool/pkg/ SUNWipc
  • but the first two command make the same thing, so -s has no meaning – MUE Jan 19 '13 at 18:15
  • the first two commands are only the same if device2 is a file. – Tim Kennedy Jan 19 '13 at 20:55

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.