The following table shows a comparison of the most important and most used commands for package/software management in SuSE and Debian/Ubuntu systems.
|| apt command
|Search package||zypper se "pkgname"|| apt-cache search "pkgname"
|Install package||zypper in "pkgname"
||apt-get install "pkgname"
apt install "pkgname" (newer)
|Update package list from repository||zypper refresh
apt update (newer)
|Update all packages||zypper update||
|Upgrade all packages to new major version*||zypper dist-upgrade
apt dist-upgrade (newer)
|Update a single package||zypper update "pkgname"
||apt-get upgrade "pkgname"
apt upgrade "pkgname"
or "install" should also update the package
|Uninstall/remove a package||zypper remove "pkgname"
||apt-get remove "pkgname"
apt remove "pkgname"
|Show all packages found in repo(s)||zypper packages
|Show updateable packages||zypper list-updates
|Show dependencies of a package||N/A
||apt-cache depends "pkgname"
|Show description of a package||zypper info "pkgname"
||apt-cache show "pkgname"
|| rpm command
|List installed packages||rpm -qa||dpkg -l|
|List content of installed package||rpm -ql "pkgname"
||dpkg -L "pkgname"
|List content of package file||rpm -qlp "pkgname".rpm
||dpkg --contents "pkgname".deb
|Install package||rpm -i "pkgname".rpm
||dpkg -i "pkgname".deb
|Simulate installation of package||rpm -i --test "pkgname".rpm
||dpkg -i --simulate "pkgname"
|Update a package||rpm -U "pkgname".rpm
||N/A (use dpkg -i)
|Uninstall/remove a package||rpm -e "pkgname"
||dpkg -r "pkgname"
If you know additional zypper/apt/rpm/dpkg commands which are worth to be compared and mentioned here, please drop a comment.
Update June 14th, 2013: Added apt-get dist-upgrade to the table. This command allows to upgrade to a newer major software version (e.g. MySQL 5.0 -> 5.1). However it should be mentioned, that although this command exists in Debian, it is unlikely that it's going be used (except for a distribution upgrade, e.g. lenny -> squeeze). The reason for this is the "stable software version" mind of Debian. Ubuntu handles this approach differently and frequently adds newer major versions to their repositories.
Update July 10th, 2015: Added "list content" rpm and dpkg commands.
Update September 16th, 2015: Added "Simulate installation of package" rpm and dpkg commands.
Update March 13th, 2019: Added "apt" short commands.
anon from wrote on Jan 11th, 2014:
The zypper equivalent for a distribution upgrade (apt-get dist-upgrade) is "zypper dup". See https://en.opensuse.org/SDB:System_upgrade
The Arch wiki has a similar comparison of more tools:
Alexander from Zürich wrote on Jun 12th, 2013:
Might be worth mentioning, that for Debian the "Update all packages" would rather be:
Because of the "all packages" there. Don't know how that compares to zypper.
Personal Internet VMware PHP Linux Shell Bluecoat Proxy Windows Hardware Virtualization Nagios MySQL DB Monitoring Mail Android Network Wyse Hacks Tomcat Postgres Apple Mac Surveillance Backup BSD ZFS Solaris SmartOS Unix Multimedia Perl Database MongoDB CMS OTRS FreeBSD Wordpress LXC Nginx Proxmox DNS Graphics PowerDNS GlusterFS Security Chef HAProxy Icinga Ansible HTML MariaDB ELK Elasticsearch Containers Rancher Docker AWS Kibana Logstash Filebeat Varnish PGSQL PostgreSQL ElasticSearch CouchDB Bash Macintosh Container Minio Grafana InfluxDB Databases NFS OSSEC SystemD Java Zoneminder SSL TLS Icingaweb2 Cloud Wireless Kubernetes Ubuntu