首页 > 系统相关 >Linux Yum 命令使用举例

Linux Yum 命令使用举例

时间:2022-08-30 19:34:58浏览次数:105  
标签:15 x86 fc15 举例 64 yum Linux Yum Fedora

Linux Yum 命令使用举例 第2页_Linux教程_Linux公社-Linux系统门户网站  https://www.linuxidc.com/Linux/2011-09/42108p2.htm

#10,使用yum groupinstall 安装某个特定软件组:
上个命令是列出软件组,使用“yum groupinstall ”来安装特定的软件组:
使用举例:
# yum groupinstall 'DNS Name Server'
Dependencies Resolved
Install       2 Package(s)
Is this ok [y/N]: y
Package(s) data still to download: 3.6 M
(1/2): bind-9.8.0-9.P4.fc15.x86_64.rpm             | 3.6 MB     00:15
(2/2): bind-chroot-9.8.0-9.P4.fc15.x86_64.rpm   |  69 kB     00:00
-----------------------------------------------------------------
Total               235 kB/s | 3.6 MB     00:15
Installed:
  bind-chroot.x86_64 32:9.8.0-9.P4.fc15
Dependency Installed:
  bind.x86_64 32:9.8.0-9.P4.fc15
Complete!

#11,使用“groupupdate”升级软件组
使用“yum groupinstall”安装软件组后,可用下面命令升级该软件组到最新版本:
# yum groupupdate 'Graphical Internet'
Dependencies Resolved
Upgrade       5 Package(s)
Is this ok [y/N]: y  
Running Transaction
  Updating   : evolution-data-server-3.0.2-1.fc15.x86_64     1/10
  Updating   : evolution-3.0.2-3.fc15.x86_64                 2/10
  Updating   : evolution-NetworkManager-3.0.2-3.fc15.x86_64  3/10
  Updating   : evolution-help-3.0.2-3.fc15.noarch            4/10
  Updating   : empathy-3.0.2-3.fc15.x86_64                   5/10
  Cleanup    : evolution-NetworkManager-3.0.1-1.fc15.x86_64  6/10
  Cleanup    : evolution-help-3.0.1-1.fc15.noarch            7/10
  Cleanup    : evolution-3.0.1-1.fc15.x86_64                 8/10
  Cleanup    : empathy-3.0.1-3.fc15.x86_64                   9/10
  Cleanup    : evolution-data-server-3.0.1-1.fc15.x86_64     10/10
Complete!

#12,”yum groupremove”卸载软件组
使用举例:
# yum groupremove 'DNS Name Server'
Dependencies Resolved
Remove        2 Package(s)
Is this ok [y/N]: y
Running Transaction
  Erasing    : 32:bind-chroot-9.8.0-9.P4.fc15.x86_64  1/2
  Erasing    : 32:bind-9.8.0-9.P4.fc15.x86_64            2/2
Complete!

#13,列出当前yum软件源
使用举例
# yum repolist
repo id     repo name                        status
Fedora      Fedora 15 - x86_64               24,085
updates     Fedora 15 - x86_64 - Updates     5,612
列出所有软件源(“yum repolist all”):
# yum repolist all
repo id                   repo name                                status
fedora                    Fedora 15 - x86_64                       enabled: 24,085
fedora-debuginfo          Fedora 15 - x86_64 - Debug               disabled
fedora-source             Fedora 15 - Source                       disabled
rawhide-debuginfo         Fedora - Rawhide - Debug                 disabled
rawhide-source            Fedora - Rawhide - Source                disabled
updates                   Fedora 15 - x86_64 - Updates             enabled:  5,612
updates-debuginfo         Fedora 15 - x86_64 - Updates - Debug     disabled
updates-source            Fedora 15 - Updates Source               disabled
updates-testing           Fedora 15 - x86_64 - Test Updates        disabled
updates-testing-debuginfo Fedora 15 - x86_64 - Test Updates Debug  disabled
updates-testing-source    Fedora 15 - Test Updates Source          disabled
也可以使用命令“yum repositories disabled”查看已损坏的软件源。

#14,使用“yum –enablerepo”从已损坏软件源安装软件
默认情况下,yum安装软件只从当前未被损坏的软件源中安装软件。如果我们想要从已损坏源中安装软件,可以使用命令:
# yum --enablerepo=fedora-source install vim-X11.x86_64
Dependencies Resolved
Install       1 Package(s)
Is this ok [y/N]: y
Running Transaction
  Installing : 2:vim-X11-7.3.138-1.fc15.x86_64   1/1
Complete!

#15,使用Yum Shell
如下事例:
# yum shell
Setting up Yum Shell
> info samba.x86_64
Available Packages
Name        : samba
Arch        : x86_64
Epoch       : 1
Version     : 3.5.11
Release     : 71.fc15.1
Size        : 4.6 M
Repo        : updates
Summary     : Server and Client software to interoperate with Windows machines
URL         : http://www.samba.org/
License     : GPLv3+ and LGPLv3+
Description :
            : Samba is the suite of programs by which a lot of PC-related
            : machines share files, printers, and other information (such as
            : lists of available files and printers). The Windows NT, OS/2, and
            : Linux operating systems support this natively, and add-on packages
            : can enable the same thing for DOS, Windows, VMS, UNIX of all
            : kinds, MVS, and more. This package provides an SMB/CIFS server
            : that can be used to provide network services to SMB/CIFS clients.
            : Samba uses NetBIOS over TCP/IP (NetBT) protocols and does NOT
            : need the NetBEUI (Microsoft Raw NetBIOS frame) protocol.
>

可以使用yum shell 运行多个命令:
举例:
# cat yum_cmd.txt
repolist
info nfs-utils-lib.x86_64
# yum shell yum_cmd.txt
repo id     repo name                        status
fedora      Fedora 15 - x86_64               24,085
updates     Fedora 15 - x86_64 - Updates     5,612
Available Packages
Name        : nfs-utils-lib
Arch        : x86_64
Version     : 1.1.5
Release     : 5.fc15
Size        : 61 k
Repo        : fedora
Summary     : Network File System Support Library
URL         : http://www.citi.umich.edu/projects/nfsv4/linux/
License     : BSD
Description : Support libraries that are needed by the commands and
            : daemons the nfs-utils rpm.
Leaving Shell

 

标签:15,x86,fc15,举例,64,yum,Linux,Yum,Fedora
From: https://www.cnblogs.com/jmbt/p/16640549.html

相关文章

  • 在linux下如何使用yum查看安装了哪些软件包
    在linux下如何使用yum查看安装了哪些软件包_wenwenxiong的博客-CSDN博客_yum查看软件版本 https://blog.csdn.net/wenwenxiong/article/details/51785221Linux系统下yum......
  • yum出错Error: Cannot find a valid baseurl for repo: base
    最近在安装mysql的rpm包时,出现了一个问题,当使用命令:rpm-iMysql-server-xxxx.rpm时出现以下错误: error:Faileddependencies:ld-linux.so.2isneededbyMySql-serv......
  • Linux下重命名文件或文件夹(mv命令与rename命令)
    Linux下重命名文件或文件夹(mv命令与rename命令)-山高我为峰-博客园 https://www.cnblogs.com/liaojie970/p/6746331.html在Linux下重命名文件或目录,可以使用mv命令......
  • Linux的NFS的配置
    快速代码#nfs的Server配置文件和配置方法echo'/newnfs192.168.3.*rw,sync,no_root_squash)'>>/etc/exports#根目录新建文件夹,权限777mkdir/newnfs&&chmod77......
  • 如何查看和复制PetaLinux(Yocto)的wic文件中的内容
    如何查看和复制PetaLinux(Yocto)的wic文件中的内容总结使用“wicls”命令,ls”查看wic文件里的分区和文件。使用“wiccp”命令,在LinuxHost和wic文件的分区之间,复制......
  • linux 下安装jdk
    、检查当前系统中是否已安装JDK​命令:java-version:查看JDK安装版本,命令执行后显示如下,说明本系统默认已经安装JDK1.8.0_242。[root@localhost~]#java-versionopenj......
  • window远程登录linux使用别名的形式
    ssh免密登录远程机器使用别名server#prerequirementssh-keygen-trsassh-copy-id-iid_rsa.pubxxx//~/.ssh/authorized_keys公钥copy到allserver,私钥放......
  • linux安装java环境
    1.在线下载jdkwget--no-check-certificate--no-cookies--header"Cookie:oraclelicense=accept-securebackup-cookie"http://download.oracle.com/otn-pub/java/jdk/......
  • linux 启动脚本
    #!/bin/bashAPP_NAME=app_api.jar#使用说明,用来提示输入参数usage(){echo"pleaseenterthecorrespondingparameters[start|stop|restart|status]"......
  • Linux bash which command All In One
    LinuxbashwhichcommandAllInOnewhichPython3$whichpython#pythonnotfound$whichpython3/usr/bin/python3VSCode$whichcode/usr/local/b......