Home> System Tutorial> LINUX> body text

Various software package installation methods on Ubuntu Linux system

WBOY
Release: 2024-01-26 20:36:12
forward
1005 people have browsed it

Ubuntu should be the most popular Linux desktop system at present. This section will introduce several methods of software installation on UbuntuLinux system.

The following will introduce four software installation methods: apt software package management tool, direct installation of deb software package, green software package installation, and bundle software installation package.

apt package management

apt is the abbreviation of AdvancedPackagingTool, which is used to install, update, and delete deb software packages on Linux distributions such as Ubuntu and Debian.

apt is a CS-structured system Linux formatted hard disk, which stores managed deb software packages on its server side. When a user needs to install or upgrade a certain software package, the client installed on the laptop will download the software package and all its dependencies from the server and install it.

The command format of apt is as follows:

apt [install | remove | search ...] 软件包名称 
Copy after login

Search for software packages about jdk-17 below:

The following is to install the openjdk-17-jdk software package:

图片

In fact, we only install the openjdk-17-jdk software package, but apt will manually install the dependent software packages together, and a total of 20 new software packages will be installed.

apt will install jdk to the /usr/lib/jvm directory.

The following is to delete the openjdk-17-jdk software package:

图片

The remove command will only delete openjdk-17-jdk itself, not all its dependencies. Therefore, after executing the remove command, the jdk is not uninstalled "cleanly".

In order to delete all dependencies of openjdk-17-jdk, you need to execute the autoremove command again:

图片

After executing the autoremove command, all jdk-related software packages will be deleted.

The use of the apt command is introduced here, but another thing worth paying attention to is the software source of apt.

In general, it is best to use foreign apt software sources, which can make us install software faster. I usually use Alibaba Cloud's apt software source. For the specific method of switching apt software source, please refer to the link below:

https://developer.aliyun.com/mirror/ubuntu?spm=a2c6h.13651102.0.0.3e221b118t6URV 
Copy after login

Install deb package directly

Although it is very convenient to use apt to install softwarelinux installation ubuntu software center, many software manufacturers' deb installation packages are not entrusted to apt management, such as Baidu Cloud Disk. For this type of software, we can only download the deb software package from its official website and install it ourselves.

The installation of the deb software package is also relatively simple. If you are using the Ubuntu desktop system, you only need to right-click and select the Softwareinstall application to open the deb software installation package:

图片

打开deb软件安装包的界面如右图所示linux装ubuntu软件中心,再点击install按键就可以启动安装流程了:

假如你没法登陆桌面环境,也可以在命令行中使用dpkg命令执行安装流程。dpkg的命令格式如下:

dpkg -I xxx.deb# info,查看软件包信息 dpkg -i xxx.deb# install,安装软件包 dpkg -r xxx# remove,卸载一个软件包 dpkg -P xxx # purge,完全清除一个软件包 # remove只是删掉数据和可执行文件,purge另外还删除所有的配置文件 
Copy after login

查看百度云盘deb软件安装包信息:

安装ubuntu软件中心_ubuntu20软件中心_linux装ubuntu软件中心

安装百度云盘:

图片

卸载百度云盘,注意这儿用的名子不是安装包的文件名:

图片

卸载百度云盘,并消除与其相关的配置文件:

图片

红色软件安装

红色软件统称可携式软件,是指这些无需安装,解压能够直接使用的软件。

比如IntelliJIDEA这款开发工具,为Linux平台提供的软件就是一个.tar.gz格式的压缩包,而不是deb安装包:

ubuntu20软件中心_linux装ubuntu软件中心_安装ubuntu软件中心

图片

将这个压缩包下载然后直接对其解压:

在其解压目录的bin子目录下有一个名叫idea.sh的可执行文件,直接执行idea.sh就可以启动IDEA了:

图片

尽管IDEA的安装过程很简单,但每次启动IDEA都须要执行一个shell脚本就有点麻烦了。我们希望它还能在桌面有一个启动图标,我们点击那种启动图标就可以启动IDEA。

Ubuntu的桌面图标配置文件都置于/usr/share/applications目录下,为了给IDEA创建一个桌面启动图标linux查看操作系统,我们在该路径下创建一个名为idea.desktop的文件,并在该文件中输入如下内容:

1[Desktop Entry] 2Name=Idea 3Comment=idea 4Exec=sh ~/program/idea-IU-231.8109.175/bin/idea.sh 5Icon=~/program/idea-IU-231.8109.175/bin/idea.png 6Terminal=false 7Type=Application 8Categories=Application; 
Copy after login

然后就可以在showApplications见到IDEA的启动图标,点击该图标就可以启动IDEA软件了:

图片

bundle软件安装包

最后一类是.bundle格式的软件安装包,.bundle文件是Linux系统中的一种可执行文件,可以类比Windows系统中的.exe文件。

比如常用的虚拟机软件VMware为Linux平台提供的软件安装包就是.bundle的格式。

我们从VMware官网下载的安装包文件名为:

VMware-Workstation-Full-17.0.0-20800274.x86_64.bundle 
Copy after login

下载完成后,为该文件降低x权限并执行安装流程:

.bundle文件执行完成后,VMware应用就安装完成了,可以在showApplications中看见与VMWare相关的3个应用:

图片

假如想要卸载VMware,可以执行下边的命令:

sudo vmware-installer -u vmware-workstation 
Copy after login

The above is the detailed content of Various software package installation methods on Ubuntu Linux system. For more information, please follow other related articles on the PHP Chinese website!

source:itcool.net
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!