opkg[通俗易懂]

opkg[通俗易懂]opkg是个安装器,小巧,功能全。root@hbg:/#opkgfilesopkgPackageopkg(9c97d5ecd795709c8584e972bfdf3aee3a5b846d-7)isinstalledonrootandhasthefollowingfiles:/bin/opkg–命令存放地/etc/opkg.conf…

大家好,又见面了,我是你们的朋友全栈君。

opkg是个安装器,小巧,功能全。

 

root@hbg:/# opkg files opkg
Package opkg (9c97d5ecd795709c8584e972bfdf3aee3a5b846d-7) is installed on root and has the following files:
/bin/opkg             –命令存放地
/etc/opkg.conf      –配置文件

 

查看已经安装的包信息:

cat /usr/lib/opkg/status

root@hbg:# cat /usr/lib/opkg/status
Package: snmp-utils          –包名称
Version: 5.4.4-1               –版本信息
Depends: libc, libnetsnmp      –依赖库
Status: install user installed   –状态信息,用户后来安装,还是包安装时已经内置的
Architecture: ar71xx             –架构信息
Installed-Time: 1450492264  –安装时间

Package: kmod-usb-storage
Version: 3.10.49-1
Depends: kernel (= 3.10.49-1-df26e12aa07bfcf42c989a3a108d9f47), kmod-scsi-core, kmod-usb-core
Status: install hold installed
Architecture: ar71xx
Installed-Time: 1450492264

安装包的详细信息

 /usr/lib/opkg/info

列表信息:

/usr/lib/opkg/list

 

目前支持的操作:

root@hbg:/# opkg
opkg must have one sub-command argument
usage: opkg [options…] sub-command [arguments…]
where sub-command is one of:

Package Manipulation:
        update                  Update list of available packages                        –更新所有可以更新的包
        upgrade <pkgs>          Upgrade packages                                      –更新某个包
        install <pkgs>          Install package(s)                                           –安装某个包
        configure <pkgs>        Configure unpacked package(s) 
        remove <pkgs|regexp>    Remove package(s)                                 –移除某个包
        flag <flag> <pkgs>      Flag package(s)
         <flag>=hold|noprune|user|ok|installed|unpacked (one per invocation)

Informational Commands:
        list                    List available packages                                           –列出所有可以列出的包
        list-installed          List installed packages                                        –列出安装的包     (在本地设备中测试出跟list命令结果一样
        list-upgradable         List installed and upgradable packages       –列出安装的可以更新的包
        list-changed-conffiles  List user modified configuration files                –列出用户更改过配置文件的包
        files <pkg>             List files belonging to <pkg>
        search <file|regexp>    List package providing <file>
        find <regexp>           List packages whose name or description matches <regexp>
        info [pkg|regexp]       Display all info for <pkg>                                –列出相关包的信息
        status [pkg|regexp]     Display all status for <pkg>                           –列出相关包的状态
        download <pkg>          Download <pkg> to current directory
        compare-versions <v1> <op> <v2>
                            compare versions using <= < > >= = << >>
        print-architecture      List installable package architectures
        depends [-A] [pkgname|pat]+
        whatdepends [-A] [pkgname|pat]+
        whatdependsrec [-A] [pkgname|pat]+
        whatrecommends[-A] [pkgname|pat]+
        whatsuggests[-A] [pkgname|pat]+
        whatprovides [-A] [pkgname|pat]+
        whatconflicts [-A] [pkgname|pat]+
        whatreplaces [-A] [pkgname|pat]+

Options:
        -A                      Query all packages not just those installed
        -V[<level>]             Set verbosity level to <level>.
        –verbosity[=<level>]   Verbosity levels:
                                        0 errors only
                                        1 normal messages (default)
                                        2 informative messages
                                        3 debug
                                        4 debug level 2
        -f <conf_file>          Use <conf_file> as the opkg configuration file
        –conf <conf_file>
        –cache <directory>     Use a package cache
        -d <dest_name>          Use <dest_name> as the the root directory for
        –dest <dest_name>      package installation, removal, upgrading.
                                <dest_name> should be a defined dest name from
                                the configuration file, (but can also be a
                                directory name in a pinch).
        -o <dir>                Use <dir> as the root directory for
        –offline-root <dir>    offline installation of packages.
        –add-arch <arch>:<prio>        Register architecture with given priority
        –add-dest <name>:<path>        Register destination with given path

Force Options:
        –force-depends         Install/remove despite failed dependencies      –强制安装或卸载,不关心依赖关系
        –force-maintainer      Overwrite preexisting config files
        –force-reinstall       Reinstall package(s)
        –force-overwrite       Overwrite files from other package(s)
        –force-downgrade       Allow opkg to downgrade packages
        –force-space           Disable free space checks
        –force-postinstall     Run postinstall scripts even in offline mode
        –force-remove  Remove package even if prerm script fails
        –force-checksum        Don’t fail on checksum mismatches
        –noaction              No action — test only
        –download-only No action — download only
        –nodeps                Do not follow dependencies                               –不安装依赖包
        –nocase                Perform case insensitive pattern matching
        –force-removal-of-dependent-packages
                                Remove package and all dependencies
        –autoremove            Remove packages that were installed
                                automatically to satisfy dependencies
        -t                      Specify tmp-dir.
        –tmp-dir               Specify tmp-dir.

 regexp could be something like ‘pkgname*’ ‘*file*’ or similar
 e.g. opkg info ‘libstd*’ or opkg search ‘*libop*’ or opkg remove ‘libncur*’

 

转载于:https://www.cnblogs.com/rohens-hbg/p/5147391.html

版权声明:本文内容由互联网用户自发贡献,该文观点仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 举报,一经查实,本站将立刻删除。

发布者:全栈程序员-用户IM,转载请注明出处:https://javaforall.cn/130157.html原文链接:https://javaforall.cn

【正版授权,激活自己账号】: Jetbrains全家桶Ide使用,1年售后保障,每天仅需1毛

【官方授权 正版激活】: 官方授权 正版激活 支持Jetbrains家族下所有IDE 使用个人JB账号...

(0)


相关推荐

  • chrome谷歌浏览器怎么清除指定网站cookie

    chrome谷歌浏览器怎么清除指定网站cookie

    2021年10月15日
  • Centos 7 Mysql 配置文件位置

    Centos 7 Mysql 配置文件位置一、Mysql的配置my.cnf位置1)、使用命令:psaux|grepmysql|grep’my.cnf’如果没有没有输出内容则是使用默认配置位置二、默认配置my.cnf位置使用命令:mysql–help|grep’my.cnf’/etc/my.cnf、/etc/mysql/my.cnf、/usr/local/etc/my.cnf、~/….

  • offset size_c语言sizeof求结构体长度

    offset size_c语言sizeof求结构体长度sizeof与offsetof在程序中经常遇到,但在面试中其应用使得许多小伙伴吃闭门羹,被面试官问得哑口无言。接下来对两者的应用做详细介绍。关于sizeof定义:sizeof乃C/C++中的一个操作符(operator),简单的说其作用就是返回一个对象或者类型所占的内存字节数。(MSDN上的解释为:Thesizeofkeywordgivestheamountofstorage,in

  • 倒立摆起摆控制_旋转倒立摆原理

    倒立摆起摆控制_旋转倒立摆原理**基于STM32控制的旋转倒立摆**文章目录基于STM32控制的旋转倒立摆前言一、旋转倒立摆的结构1.相对编码器与绝对编码器2.相对编码器与绝对编码器的信号采集3.STM32编码器模式4.使用STM32CubeMx配置过程二、倒立摆模型建立三、实验方案与实验现象1.整体方案2.实验现象与上位机数据反思与总结前言近期在学习简易旋转倒立摆装置,倒立摆其实是一个十分经典的自动控制模型,不过开始学习了解结构和原理还是花了很多时间,在思路以及调试过程中遇到了很多困难。我认为倒立摆有两个难点,一个是自动

  • IST:Iterative Shrinkage/Thresholding和Iterative Soft Thresholding

    IST:Iterative Shrinkage/Thresholding和Iterative Soft Thresholding本篇是对压缩感知重构算法之迭代软阈值(IST)的延续,可能需要以下基础:软阈值(SoftThresholding)函数和硬阈值(HardThresholding)函数。前面我们在讨论迭代软阈值算法时提到,一般文献中出现的IST或ISTA简称中的“S”并非指的是“soft”,而是“shrinkage”,即“IterativeShrinkage/ThresholdingAlgorithm”,那么IterativeSoftThresholding和IterativeShrinkage/

  • Intel 的AVX2指令集解读

    Intel 的AVX2指令集解读在IntelSandyBridge微架构中,Intel引入了256位SIMD扩展AVX,这套指令集在兼容原MMX、SSE、SSE2对128位整点SIMD支持的基础上,把支持的总向量数据宽度扩展成了256位。新增了若干条256位浮点SIMD指令。昨天,Intel刚刚发布了AVX2指令集,这套指令集在AVX基础上做了扩展,不过要在2013年发布的Haswell处理器上才能支持。参考1给出了

发表回复

您的电子邮箱地址不会被公开。

关注全栈程序员社区公众号