I am building a personal, local repository to store all the versions of packages i want. I have used createRepo to create the reop, populated its dir with rpms, created the necessary directory summary meta data via createpo and am working with the zypper cmd to query it.

Is there a cmd that will return the version number of the package? I see that i can do a search but it does not show all of the metadata of the packages found eg author, version, etc. eg zypper search <package>

I see if i do a 'info' cmd then i get the version amongst other metadata. eg zypper info <package>

As i hope to host multiple versions of the same package, is there a query that will simply return the version if the repo has the package?

  • Or do i need to specify the version in the query - how do i do this?
    – Fearghal
    Jan 9, 2015 at 17:16

1 Answer 1


you can use the "-s" for the packages version.

zypper se -s pacemaker
Loading repository data...
Reading installed packages...

S | Name                               | Type       | Version        | Arch   | Repository           
i | drbd-pacemaker                     | package    | 8.4.1-0.11.6   | x86_64 | SLE11-HAE-SP2-Pool   
  | libpacemaker-devel                 | package    | 1.1.6-1.29.1   | x86_64 | SLE11-HAE-SP2-Updates
  | libpacemaker-devel                 | package    | 1.1.6-1.27.26  | x86_64 | SLE11-HAE-SP2-Pool   
i | libpacemaker3                      | package    | 1.1.6-1.29.1   | x86_64 | SLE11-HAE-SP2-Updates
v | libpacemaker3                      | package    | 1.1.6-1.27.26  | x86_64 | SLE11-HAE-SP2-Pool   

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .