zypper: command not found in SUSE linux

Nitesh kumar picture Nitesh kumar · Feb 23, 2017 · Viewed 9.4k times · Source

I was not aware that zypper is like yum for SUSE. I deleted that file from bin, now I am not able to install any application through it. I throws an error that

sudo: zypper: command not found

How do I install zypper back and make it work like as normal?

Answer

Stéphane B. picture Stéphane B. · Feb 23, 2017

Depending on your system and architecture, find Zypper package file (RPM) in online repository (i.e. http://download.opensuse.org/distribution/13.2/repo/oss/suse/i586/ ), download it (wget) and install it (rpm -i) :

wget http://download.opensuse.org/distribution/13.2/repo/oss/suse/i586/zypper-1.11.14-2.1.i586.rpm

sudo rpm -ivh zypper-1.11.14-2.1.i586.rpm