rpm – Internetblog.org.uk https://www.internetblog.org.uk Web hosting, Domain names, Dedicated servers Fri, 29 Jan 2016 11:05:52 +0000 en-US hourly 1 https://wordpress.org/?v=4.9.5 https://www.internetblog.org.uk/files/2016/01/cropped-favico-32x32.png rpm – Internetblog.org.uk https://www.internetblog.org.uk 32 32 How to Remove Software in Linux https://www.internetblog.org.uk/post/1531/how-to-remove-software-in-linux/ Wed, 14 Jul 2010 19:22:06 +0000 http://www.internetblog.org.uk/post/1531/how-to-remove-software-in-linux/ Delete icon
Question: How do I remote software that I installed from my Linux dedicated server?

Answer: The answer to that question depends on how you installed the software in the first place. Once you establish how and where the software has been installed, you can determine how to remove it.

1. Package Manager – Most software should be installed with a package manager like YUM or Apt. If that is the case, you remove it with the normal command for the package manager:

yum remove [packagename] apt-get remove [packagename]

2. Manual Deb, RPM, etc – If you installed a distribution package manually, you can remove it manually or use your package manager to remove it.

3. Binary Archive – If you were given a tar.gz or similar package with binaries inside, and you unpacked them to a directory, simply remove the directory. If the package had an installer program, try using that to uninstall it.

4. Source – If you compiled the software from source and used “make install” to install it, removing it may be more tricky. If you still have the source files, you can simply run “make uninstall”. Otherwise, you will have to find out where the files were installed and remove. They may be in several directories.

What is a Linux Package? https://www.internetblog.org.uk/post/1520/what-is-a-linux-package/ Mon, 12 Jul 2010 19:13:06 +0000 http://www.internetblog.org.uk/post/1520/what-is-a-linux-package/
linux packageQuestion
: I have a new Linux dedicated server, and I have read a lot of documentation referring to packages. What are Linux packages?

Answer: In Linux distributions, a “package” refers to a compressed file archive containing all of the files that come with a particular application. The files are usually stored in the package according to their relative installation paths on your system. Most packages also contain installation instructions for the OS, as well as a list of any other packages that are dependencies (prerequisites required for installation.

Common types of Linux packages include .deb, .rpm, and .tgz. Since Linux packages do not usually contain the dependencies necessary to install them, many Linux distributions use package managers that automatically read dependencies files and download the packages needed before proceeding with the installation. Some examples of package managers are APT, YUM, and Pacman.

Useful RPM Tips https://www.internetblog.org.uk/post/1366/useful-rpm-tips/ Thu, 27 May 2010 17:07:05 +0000 http://www.internetblog.org.uk/post/1365/useful-rpm-tips/ RPM logoAs I mentioned in an earlier post, YUM is a powerful package management system, commonly used in RPM-based Linux distributions, including Red Hat Enterprise Linux, CentOS, and Fedora. We have covered some of the basic YUM commands. Now, here are some helpful commands not in YUM that you can use to better manage your RPM packages.

1. Reset file permissions – This is for those times when you have made changes to an application that you probably should not have made. RPM can reset the permissions for all files in the package and return them to the state they were in when you installed it. Simply run this command:

rpm --setperms

2. Extract one file from an rpm – Whenever you do not actually want to install an RPM, you can extract its contents. This is also useful if you have changed something in one of the files and just need to extract the default file, like logrotate.conf. Run this command:

rpm2cpio logrotate-1.0-1.i386.rpm |cpio -ivd etc/logrotate.conf

3. Query 3rd party packages – In this example, suppose you are using CentOS, but you want to query packages from other repositories. This command will allow you to find packages not in the CentOS repository.

rpm -qa --qf '%{NAME} %{VENDOR}\n' | grep -v CentOS

Fixing YUM dependency problems: Part 2 https://www.internetblog.org.uk/post/786/fixing-yum-dependency-problems-part-2/ Wed, 16 Dec 2009 14:01:20 +0000 http://www.internetblog.org.uk/post/786/fixing-yum-dependency-problems-part-2/ YUM update CentOS
You have already tried “yum clean all” and you still are getting dependency errors. These errors can only mean that you have something that is installed that should not be or you need manually install the dependency to whatever package you must have despite YUM‘s warnings.

In case of the latter, you can find the package and install it manually with rpm. First, if you think the package is already there, you can try reinstalling it:

rpm -ivh —replacepkgs name-of-package.rpm

If that does not work, you may need to force the installation, ignoring any errors:

rpm -ivh --force name-of-package.rpm

Finally, you can also instruct rpm to ignore dependency problems:

rpm -ivh --nodeps name-of-package.rpm

The fact of the matter is, however, that all of this could lead you deeper into the abyss than you already were. The best solution is to avoid the problem, and if that is too late, back track and remove the offending package.

How to reinstall packages with YUM https://www.internetblog.org.uk/post/755/how-to-reinstall-packages-with-yum/ Mon, 07 Dec 2009 20:17:03 +0000 http://www.internetblog.org.uk/post/755/how-to-reinstall-packages-with-yum/ YUM logoQuestion: One of my applications in CentOS Linux is not working right. How do I reinstall it?

Answer: Early version of YUM did not have a “reinstall” function, but the newest version do. To reinstall a package, simply type as root:

yum reinstall package-name

If you are running a server with an older version of Fedora or other Redhat-based Linux distribution, your version of YUM may not support reinstallation. In such a case, you will have to manually reinstall it. From root, enter a command such as this to remove the files from the database:

rpm -e --justdb --nodeps packagename

YUM will then believe the package is not installed, even though it still is. Install as you normally would with:

yum install package-name