opkg-upgrade

授权协议 Readme
开发语言 SHELL
所属分类 应用工具、 终端/远程登录
软件类型 开源软件
地区 不详
投 递 者 卞博简
操作系统 跨平台
开源组织
适用人群 未知
 软件概览

opkg-upgrade

List and install OpenWRT / LEDE opkg upgradable packages.

Little ash app for easier opkg package upgrades.

You should check for config conflicts after upgrades!
Make sure you have enough space on root before installing stuff!
This script is small enough but SSL support for curl/wget is not!
You also need free space for downloading and installing the packages!

If you use OpenWRT trunk (dev snapshots), you should probably NOT upgrade
Upgrading development versions can soft-brick your device.
You should try to backup your config and do a full install of a later snapshot if you are running dev/trunk.
Main releases are fine (just trunk/snapshots are affected by this).
It is probably the opposite for releases (recommended to upgrade), since you will get security patches if you upgrade those.


If you want to support this project, you can do it here ��

Paypal

paypal-image

Bitcoin

BTC-DONATE
1AJ9whK9g1Cq83JeQXcp9DdsKjZT7r91vH

Donate USD $10


Help example:

# ./opkg-upgrade.sh -h

Simple OPKG Updater v0.2.0

Usage: opkg-upgrade.sh [options]

Options:
  -V, --version         Show program name and version and exits
  -h, --help            Show this help screen and exits
  -i, --install [dir]   Install opkg-upgrade to [dir] or /usr/sbin
                        Leave [dir] empty for default (/usr/sbin)
  -u, --upgrade-check   Returns SUCCESS if there are updates available
                        Quiet execution, returns 0 or 1
  -l, --list-upgrades   Prints the list of available updates and exits
  -e, --email-list      Prints the list of updates in html email format
                        Includes subject, mime type and html formated data
  -s, --ssmtp <email>   Use the system's ssmtp to send update reports
                        You need to install and configure ssmtp beforehand
  -a, --always-send     Send e-mail even if there are no updates
                        By default e-mails are only sent when updates are available
  -t, --text-only       Send e-mail in plain text format.
                        By default, e-mails are sent in html format.
  -n, --no-opkg-update  Skip opkg update at the beginning,
                        may not find packages if not up to date
  -f, --force           Do not ask for confirmation,
                        will update everything available

Notes:
  - Short options should not be grouped. You must pass each parameter on its own.
  - You must have a working ssmtp install to use the ssmtp functionality. Make
    sure you can send e-mails from it before trying from opkg-upgrade.

Examples:
  opkg-upgrade.sh -n -f      # run without updating listings and asking for upgrade
  opkg-upgrade.sh --install  # install to /usr/sbin/opkg-upgrade
  opkg-upgrade.sh -l         # just print upgrades available
  opkg-upgrade.sh -e         # just print html formatted email
  opkg-upgrade.sh -s 'mail@example.com'    # mail upgrade report if have updates
  opkg-upgrade.sh -a -s 'mail@example.com' # mail upgrade report even if NO updates
  opkg-upgrade.sh -u && echo 'upgrades are available' || echo 'no upgrades available'

Example run:

# ./opkg-upgrade.sh

Simple OPKG Updater v0.1.2

Done | Updating package lists
Done | Getting upgradable packages list

Packages available for upgrade: 23

luci-app-statistics - git-17.126.47277-596f476-1 - git-17.129.29271-6467df3-1
luci-app-adblock - git-17.126.47277-596f476-1 - git-17.129.29271-6467df3-1
luci-lib-ip - git-17.126.47277-596f476-1 - git-17.129.29271-6467df3-1
luci-app-samba - git-17.126.47277-596f476-1 - git-17.129.29271-6467df3-1
luci-theme-bootstrap - git-17.126.47277-596f476-1 - git-17.129.29271-6467df3-1
luci-app-qos - git-17.126.47277-596f476-1 - git-17.129.29271-6467df3-1
luci-app-firewall - git-17.126.47277-596f476-1 - git-17.129.29271-6467df3-1
luci-app-diag-core - git-17.126.47277-596f476-1 - git-17.129.29271-6467df3-1
luci-proto-ppp - git-17.126.47277-596f476-1 - git-17.129.29271-6467df3-1
luci-mod-admin-full - git-17.126.47277-596f476-1 - git-17.129.29271-6467df3-1
luci-base - git-17.126.47277-596f476-1 - git-17.129.29271-6467df3-1
luci-app-commands - git-17.126.47277-596f476-1 - git-17.129.29271-6467df3-1
luci-app-vnstat - git-17.126.47277-596f476-1 - git-17.129.29271-6467df3-1
luci-proto-ipv6 - git-17.126.47277-596f476-1 - git-17.129.29271-6467df3-1
luci-app-wol - git-17.126.47277-596f476-1 - git-17.129.29271-6467df3-1
luci-app-upnp - git-17.126.47277-596f476-1 - git-17.129.29271-6467df3-1
luci-app-minidlna - git-17.126.47277-596f476-1 - git-17.129.29271-6467df3-1
luci-lib-nixio - git-17.126.47277-596f476-1 - git-17.129.29271-6467df3-1
luci-lib-jsonc - git-17.126.47277-596f476-1 - git-17.129.29271-6467df3-1
luci-app-p910nd - git-17.126.47277-596f476-1 - git-17.129.29271-6467df3-1
luci - git-17.126.47277-596f476-1 - git-17.129.29271-6467df3-1
luci-app-transmission - git-17.126.47277-596f476-1 - git-17.129.29271-6467df3-1
luci-app-openvpn - git-17.126.47277-596f476-1 - git-17.129.29271-6467df3-1

Proceed with upgrade? (Y/y to proceed) y

.... | Upgrading packages

Upgrading luci-app-statistics on root from git-17.126.47277-596f476-1 to git-17.129.29271-6467df3-1...
Downloading http://downloads.lede-project.org/releases/17.01.1/packages/mipsel_74kc/luci/luci-app-statistics_git-17.129.29271-6467df3-1_all.ipk
Upgrading luci-app-adblock on root from git-17.126.47277-596f476-1 to git-17.129.29271-6467df3-1...
Downloading http://downloads.lede-project.org/releases/17.01.1/packages/mipsel_74kc/luci/luci-app-adblock_git-17.129.29271-6467df3-1_all.ipk
Upgrading luci-lib-ip on root from git-17.126.47277-596f476-1 to git-17.129.29271-6467df3-1...
Downloading http://downloads.lede-project.org/releases/17.01.1/packages/mipsel_74kc/luci/luci-lib-ip_git-17.129.29271-6467df3-1_mipsel_74kc.ipk
Upgrading luci-app-samba on root from git-17.126.47277-596f476-1 to git-17.129.29271-6467df3-1...
Downloading http://downloads.lede-project.org/releases/17.01.1/packages/mipsel_74kc/luci/luci-app-samba_git-17.129.29271-6467df3-1_all.ipk
Upgrading luci-theme-bootstrap on root from git-17.126.47277-596f476-1 to git-17.129.29271-6467df3-1...
Downloading http://downloads.lede-project.org/releases/17.01.1/packages/mipsel_74kc/luci/luci-theme-bootstrap_git-17.129.29271-6467df3-1_all.ipk
Upgrading luci-app-qos on root from git-17.126.47277-596f476-1 to git-17.129.29271-6467df3-1...
Downloading http://downloads.lede-project.org/releases/17.01.1/packages/mipsel_74kc/luci/luci-app-qos_git-17.129.29271-6467df3-1_all.ipk
Upgrading luci-app-firewall on root from git-17.126.47277-596f476-1 to git-17.129.29271-6467df3-1...
Downloading http://downloads.lede-project.org/releases/17.01.1/packages/mipsel_74kc/luci/luci-app-firewall_git-17.129.29271-6467df3-1_all.ipk
Upgrading luci-app-diag-core on root from git-17.126.47277-596f476-1 to git-17.129.29271-6467df3-1...
Downloading http://downloads.lede-project.org/releases/17.01.1/packages/mipsel_74kc/luci/luci-app-diag-core_git-17.129.29271-6467df3-1_all.ipk
Upgrading luci-proto-ppp on root from git-17.126.47277-596f476-1 to git-17.129.29271-6467df3-1...
Downloading http://downloads.lede-project.org/releases/17.01.1/packages/mipsel_74kc/luci/luci-proto-ppp_git-17.129.29271-6467df3-1_all.ipk
Upgrading luci-mod-admin-full on root from git-17.126.47277-596f476-1 to git-17.129.29271-6467df3-1...
Downloading http://downloads.lede-project.org/releases/17.01.1/packages/mipsel_74kc/luci/luci-mod-admin-full_git-17.129.29271-6467df3-1_mipsel_74kc.ipk
Upgrading luci-base on root from git-17.126.47277-596f476-1 to git-17.129.29271-6467df3-1...
Downloading http://downloads.lede-project.org/releases/17.01.1/packages/mipsel_74kc/luci/luci-base_git-17.129.29271-6467df3-1_mipsel_74kc.ipk
Upgrading luci-app-commands on root from git-17.126.47277-596f476-1 to git-17.129.29271-6467df3-1...
Downloading http://downloads.lede-project.org/releases/17.01.1/packages/mipsel_74kc/luci/luci-app-commands_git-17.129.29271-6467df3-1_all.ipk
Upgrading luci-app-vnstat on root from git-17.126.47277-596f476-1 to git-17.129.29271-6467df3-1...
Downloading http://downloads.lede-project.org/releases/17.01.1/packages/mipsel_74kc/luci/luci-app-vnstat_git-17.129.29271-6467df3-1_all.ipk
Upgrading luci-proto-ipv6 on root from git-17.126.47277-596f476-1 to git-17.129.29271-6467df3-1...
Downloading http://downloads.lede-project.org/releases/17.01.1/packages/mipsel_74kc/luci/luci-proto-ipv6_git-17.129.29271-6467df3-1_all.ipk
Upgrading luci-app-wol on root from git-17.126.47277-596f476-1 to git-17.129.29271-6467df3-1...
Downloading http://downloads.lede-project.org/releases/17.01.1/packages/mipsel_74kc/luci/luci-app-wol_git-17.129.29271-6467df3-1_all.ipk
Upgrading luci-app-upnp on root from git-17.126.47277-596f476-1 to git-17.129.29271-6467df3-1...
Downloading http://downloads.lede-project.org/releases/17.01.1/packages/mipsel_74kc/luci/luci-app-upnp_git-17.129.29271-6467df3-1_all.ipk
Upgrading luci-app-minidlna on root from git-17.126.47277-596f476-1 to git-17.129.29271-6467df3-1...
Downloading http://downloads.lede-project.org/releases/17.01.1/packages/mipsel_74kc/luci/luci-app-minidlna_git-17.129.29271-6467df3-1_all.ipk
Upgrading luci-lib-nixio on root from git-17.126.47277-596f476-1 to git-17.129.29271-6467df3-1...
Downloading http://downloads.lede-project.org/releases/17.01.1/packages/mipsel_74kc/luci/luci-lib-nixio_git-17.129.29271-6467df3-1_mipsel_74kc.ipk
Upgrading luci-lib-jsonc on root from git-17.126.47277-596f476-1 to git-17.129.29271-6467df3-1...
Downloading http://downloads.lede-project.org/releases/17.01.1/packages/mipsel_74kc/luci/luci-lib-jsonc_git-17.129.29271-6467df3-1_mipsel_74kc.ipk
Upgrading luci-app-p910nd on root from git-17.126.47277-596f476-1 to git-17.129.29271-6467df3-1...
Downloading http://downloads.lede-project.org/releases/17.01.1/packages/mipsel_74kc/luci/luci-app-p910nd_git-17.129.29271-6467df3-1_all.ipk
Upgrading luci on root from git-17.126.47277-596f476-1 to git-17.129.29271-6467df3-1...
Downloading http://downloads.lede-project.org/releases/17.01.1/packages/mipsel_74kc/luci/luci_git-17.129.29271-6467df3-1_all.ipk
Upgrading luci-app-transmission on root from git-17.126.47277-596f476-1 to git-17.129.29271-6467df3-1...
Downloading http://downloads.lede-project.org/releases/17.01.1/packages/mipsel_74kc/luci/luci-app-transmission_git-17.129.29271-6467df3-1_all.ipk
Upgrading luci-app-openvpn on root from git-17.126.47277-596f476-1 to git-17.129.29271-6467df3-1...
Downloading http://downloads.lede-project.org/releases/17.01.1/packages/mipsel_74kc/luci/luci-app-openvpn_git-17.129.29271-6467df3-1_all.ipk
Configuring luci-app-statistics.
Configuring luci-lib-jsonc.
Configuring luci-app-adblock.
Configuring luci-lib-nixio.
Configuring luci-lib-ip.
Configuring luci-base.
Configuring luci-mod-admin-full.
Configuring luci-app-firewall.
Configuring luci-app-samba.
Configuring luci-theme-bootstrap.
Configuring luci-app-qos.
Configuring luci-app-diag-core.
Configuring luci-proto-ppp.
Configuring luci-app-commands.
Configuring luci-app-vnstat.
Configuring luci-proto-ipv6.
Configuring luci-app-wol.
Configuring luci-app-upnp.
Configuring luci-app-minidlna.
Configuring luci-app-p910nd.
Configuring luci.
Configuring luci-app-transmission.
Configuring luci-app-openvpn.
Collected errors:
 * resolve_conffiles: Existing conffile /etc/config/luci_statistics is different from the conffile in the new package. The new conffile will be placed at /etc/config/luci_statistics-opkg.
 * resolve_conffiles: Existing conffile /etc/config/luci is different from the conffile in the new package. The new conffile will be placed at /etc/config/luci-opkg.

Done | Upgrade finished

Please check for config file conflicts!

When all up-to-date:

# ./opkg-upgrade.sh -f -n

Simple OPKG Updater v0.1.2

Done | Ignoring package lists update
Done | Getting upgradable packages list

No packages to install!

Install using git:

Clone it in current directory and use the -i option to install it to /usr/sbin/opkg-upgrade

# git clone git://github.com/tavinus/opkg-upgrade.git
# cd opkg-upgrade
# ./opkg-upgrade.sh -i

Install using curl or wget:

NOTE: curl / wget may fail because of missing SSL certificates.

You may choose to ignore the certificates check using:

  • curl -k
  • wget --no-check-certificate

Or you will need to fix your /etc/ssl/certs/ca-certificates.crt installation.
Please note that SSL support takes quite a lot of storage space.

This should be enough to make SSL work:

opkg install ca-certificates openssl-util

And this may be a workaround if you still have problems:

mkdir -p -m0755 /etc/ssl/certs && curl -k -o /etc/ssl/certs/ca-certificates.crt -L http://curl.haxx.se/ca/cacert.pem

Relevant links:

Oneliners to run from internet ( downloads to /tmp ) :

# using wget with SSL
wget 'https://raw.githubusercontent.com/tavinus/opkg-upgrade/master/opkg-upgrade.sh' -O "/tmp/opkg-upgrade.sh" && chmod 755 "/tmp/opkg-upgrade.sh" && /tmp/opkg-upgrade.sh

# using wget WITHOUT SSL
wget --no-check-certificate 'https://raw.githubusercontent.com/tavinus/opkg-upgrade/master/opkg-upgrade.sh' -O "/tmp/opkg-upgrade.sh" && chmod 755 "/tmp/opkg-upgrade.sh" && /tmp/opkg-upgrade.sh

# using curl with SSL
curl -L 'https://raw.githubusercontent.com/tavinus/opkg-upgrade/master/opkg-upgrade.sh' -o "/tmp/opkg-upgrade.sh" && chmod 755 "/tmp/opkg-upgrade.sh" && /tmp/opkg-upgrade.sh

# using curl WITHOUT SSL
curl -k -L 'https://raw.githubusercontent.com/tavinus/opkg-upgrade/master/opkg-upgrade.sh' -o "/tmp/opkg-upgrade.sh" && chmod 755 "/tmp/opkg-upgrade.sh" && /tmp/opkg-upgrade.sh

Local install to current dir ( ./opkg-upgrade.sh ) :

Run with ./opkg-upgrade.sh after downloading

# using wget with SSL
wget 'https://raw.githubusercontent.com/tavinus/opkg-upgrade/master/opkg-upgrade.sh' -O "opkg-upgrade.sh" && chmod 755 "opkg-upgrade.sh"

# using wget WITHOUT SSL
wget --no-check-certificate 'https://raw.githubusercontent.com/tavinus/opkg-upgrade/master/opkg-upgrade.sh' -O "opkg-upgrade.sh" && chmod 755 "opkg-upgrade.sh"

# using curl with SSL
curl -L 'https://raw.githubusercontent.com/tavinus/opkg-upgrade/master/opkg-upgrade.sh' -o "opkg-upgrade.sh" && chmod 755 "opkg-upgrade.sh"

# using curl WITHOUT SSL
curl -k -L 'https://raw.githubusercontent.com/tavinus/opkg-upgrade/master/opkg-upgrade.sh' -o "opkg-upgrade.sh" && chmod 755 "opkg-upgrade.sh"

System install to /usr/sbin/opkg-upgrade (no .sh extension) :

Run with opkg-upgrade after downloading

# using wget with SSL
wget 'https://raw.githubusercontent.com/tavinus/opkg-upgrade/master/opkg-upgrade.sh' -O "/usr/sbin/opkg-upgrade" && chmod 755 "/usr/sbin/opkg-upgrade"

# using wget WITHOUT SSL
wget --no-check-certificate 'https://raw.githubusercontent.com/tavinus/opkg-upgrade/master/opkg-upgrade.sh' -O "/usr/sbin/opkg-upgrade" && chmod 755 "/usr/sbin/opkg-upgrade"

# using curl with SSL
curl -L 'https://raw.githubusercontent.com/tavinus/opkg-upgrade/master/opkg-upgrade.sh' -o "/usr/sbin/opkg-upgrade" && chmod 755 "/usr/sbin/opkg-upgrade"

# using curl WITHOUT SSL
curl -k -L 'https://raw.githubusercontent.com/tavinus/opkg-upgrade/master/opkg-upgrade.sh' -o "/usr/sbin/opkg-upgrade" && chmod 755 "/usr/sbin/opkg-upgrade"
  • 一、简介 Opkg 是一个基于 ipkg 的轻量级的软件包管理系统,主要用于嵌入式系统,目前应用opkg的有Open WRT 和 Open Embedded。1  Opkg的详细使用方法可以参考Open WRT的 WIKI页面2,不再赘述,本文将重点解释opkg的工作原理。  Opkg 的源代码可以在Google Code 3或Yocto Project 4上找到。Opkg的版本目前到了0.3.0

  • 1.介绍 在OpenWrt下使用的软件包管理技术叫做OPKG,是Open Package Management的缩写,是一款基于ipkg的轻量级包管理器,由C语言编写,类似于apt / dpkg,常用于路由、交换机等嵌入式设备中,用来管理软件包的安装升级与下载,目前已成为开源界嵌入式系统软件包管理的标准。 通过OPKG管理的软件包,可以轻松解决软件包依赖的问题。例如,如果我们要安装软件包A,但是软

  • OpenWrt包管理系统OPKG OPKG(Open/OpenWrt Package)是一个轻量快速的软件包管理系统,是 IPKG 的克隆, 目前已成为开源嵌入式系统领域的事实标准。OPKG 常用于路由、交换机等嵌入式设备中, 用来管理软件包的下载、安装、升级、卸载和查询等,并处理软件包的依赖关系。功能和 桌面 Linux 操作系统 Ubuntu 中的 apt-get、Redhat 中的 yum

  • 在这篇文章的指导下解决了,Opkg update失败的问题,问题出在开发板的网络DNS配置,开发板可以访问局域网的,但是不能访问互联网,另外angstrom linux 软件源 feeds 地址改变了 不在是原来的 所有需要更改 /etc/opkg/*下的conf文件,前缀改成http://feeds.angstrom-distribution.org/feeds/,原来的地址是http://ww

  • Opkg 是一个轻量快速的套件管理系统,目前已成为 Opensource 界嵌入式系统标准。常用于路由、交换机等嵌入式设备中,用来管理软件包的安装升级与下载。 常用命令 opkg update 更新可以获取的软件包列表 opkg upgrade 对已经安装的软件包升级 opkg list 获取软件列表 opkg install 安装指定的软件包 opkg remove 卸载已经安装的指定的软件包

  • 说明: 1、OpenWrt本身系统没什么问题,关键点是一些路由器尝试的限制,比如一些厂商设置成内存分区为只读,那么这个安装软件就变得没什么意义了。 2、opkg的操作有点反人类,正常步骤是查询,安装;而opkg在一些厂商的限制下需要update,然后download,最后install;且有时会安装在tmp区,重启会没有。 常用安装步骤: 如果想要安装一个软件,但是不知道什么具体的名字,可以用命令

  • 解决方法: echo “nameserver 114.114.114.114”>/tmp/resolv.conf rm -f /var/lock/opkg.lock opkg update

 相关资料
  • Opkg 是一个輕量快速的套件管理系統,目前已成為 Opensource 界嵌入式系統標準。

  • opkg install 自动安装 先查看本路由器安装了什么软件,软件源里有什么软件可以安装。命令如下: opkg update opkg list-installed opkg list 尝试执行tcpdump,会报错“tcpdump: not found”,说明此软件没有安装。可自行安装,命令如下: opkg install tcpdump 然后再执行,会发现成功了。命令如下: tcpdu

  • 极路由和优酷都提供了官方opkg软件仓库(package repository,又称软件源),但开发者无法提交新软件进去,一旦需要用的软件不在里面,怎么办?有两个办法:添加到开源仓库 或者 搭建自己的仓库。 添加到开源软件仓库 极路由、优酷、小米、魔豆使用的都是OpenWrt 12.09老系统,而OpenWrt.org官方已不再维护12.09和对应的仓库了,所以本站发起了一个开源项目——12.09

  • 之前的文档《opkg软件仓库》讲解的是手动编译出ipk,然后手动上传到七牛。项目里package较少时,可以这么做。而如果package很多(比如开源项目),开发者经常提交,管理员会来不及编译,所以如果代码提交时触发自动编译自动发布,那就更方便了。git配合持续集成(Continued Integration,CI)可以实现这一点。 常见的git代码托管服务有国际知名的github.com和国内飞

  • 问题内容: 我正在使用wss(受保护的Web套接字)以及来自后端的Spring和STOMP(用于javascript客户端)。 有谁知道为什么得到: 问题答案: 我用tomcat的nginx https代理遇到了同样的问题。这是因为我不支持wss请求。为了支持wss请求,我使用如下配置:

  • Sequelize v6 是 v5 之后的下一个主要版本. 以下列出了一些重大更改以帮助你进行升级. 重大变化 支持 Node 10 以及更高 Sequelize v6 将支持 Node 10 及更高版本 #10821. CLS 你现在应该使用 cls-hooked 软件包来支持 CLS. const cls = require('cls-hooked'); const namespace = c

相关阅读

相关文章

相关问答

相关文档