Modify

Opened 3 years ago

Closed 3 years ago

Last modified 21 months ago

#19893 closed defect (not_a_bug)

Some binaries from additional packages return "not found" (wrong libc link possible)

Reported by: slawek@… Owned by: developers
Priority: normal Milestone:
Component: packages Version: Trunk
Keywords: libc binary packages Cc: jaroslav@…

Description

Problem cases

  • Case 1:

linked to ld-musl

root@OpenWrt:~# which miniupnpd
/usr/sbin/miniupnpd
root@OpenWrt:~# miniupnpd
-ash: miniupnpd: not found
root@OpenWrt:~# strings /usr/sbin/miniupnpd | head
/lib/ld-musl-mips-sf.so.1
_fini
__libc_start_main
libip4tc.so.0
__RLD_MAP
_ITM_deregisterTMCloneTable
_ITM_registerTMCloneTable
libip6tc.so.0
memset
memcpy

  • Case 2:

linked to ld-musl

root@OpenWrt:~# opkg install bash
Installing bash (4.3.39-1) to root...
Downloading http://downloads.openwrt.org/snapshots/trunk/ar71xx/generic/packages/packages/bash_4.3.39-1_ar71xx.ipk.
Configuring bash.
/bin/bash
/bin/rbash
root@OpenWrt:~# bash
-ash: bash: not found
root@OpenWrt:~# which bash
/bin/bash
root@OpenWrt:~# /bin/bash
-ash: /bin/bash: not found
root@OpenWrt:~# strings /bin/bash | head
	YTt
/lib/ld-musl-mips-sf.so.1
_fini
__libc_start_main
libncurses.so.5
__RLD_MAP
tgoto
tgetflag
tgetstr
tgetent

  • Anti-case (working binary):

linked to ld-uClibc

root@OpenWrt:~# strings /usr/bin/python | head
/lib/ld-uClibc.so.0
_init
_fini
__uClibc_main
Py_Main
libpython2.7.so.1.0
__RLD_MAP
_ITM_registerTMCloneTable
_ITM_deregisterTMCloneTable
libpthread.so.0

System configuration

root@OpenWrt:~# cat /etc/openwrt_release 
DISTRIB_ID='OpenWrt'
DISTRIB_RELEASE='Bleeding Edge'
DISTRIB_REVISION='r45141'
DISTRIB_CODENAME='chaos_calmer'
DISTRIB_TARGET='ar71xx/generic'
DISTRIB_DESCRIPTION='OpenWrt Chaos Calmer r45141'
DISTRIB_TAINTS=

Current libc:

root@OpenWrt:~# find / -iname "ld-*"
/lib/ld-uClibc-0.9.33.2.so
/lib/ld-uClibc.so.0
/rom/lib/ld-uClibc-0.9.33.2.so
/rom/lib/ld-uClibc.so.0

Repositories configuration:

root@OpenWrt:~# cat /etc/opkg.conf 
dest root /
dest ram /tmp
lists_dir ext /var/opkg-lists
option overlay_root /overlay
src/gz chaos_calmer_base http://downloads.openwrt.org/snapshots/trunk/ar71xx/generic/packages/base
src/gz chaos_calmer_luci http://downloads.openwrt.org/snapshots/trunk/ar71xx/generic/packages/luci
src/gz chaos_calmer_management http://downloads.openwrt.org/snapshots/trunk/ar71xx/generic/packages/management
src/gz chaos_calmer_packages http://downloads.openwrt.org/snapshots/trunk/ar71xx/generic/packages/packages
src/gz chaos_calmer_routing http://downloads.openwrt.org/snapshots/trunk/ar71xx/generic/packages/routing
src/gz chaos_calmer_telephony http://downloads.openwrt.org/snapshots/trunk/ar71xx/generic/packages/telephony

root@OpenWrt:~# opkg list-installed
6in4 - 21-1
base-files - 157-r45141
bash - 4.3.39-1
block-mount - 2015-03-22-eb9181b33bdda2e1ce81094d77913f7b68e26156
busybox - 1.23.2-1
dnsmasq - 2.72-4
dropbear - 2014.65-2
firewall - 2015-02-26
fstools - 2015-03-22-eb9181b33bdda2e1ce81094d77913f7b68e26156
hostapd-common - 2015-03-25-1
ip - 4.0.0-1
ip6tables - 1.4.21-1
iptables - 1.4.21-1
iw - 3.17-1
iwinfo - 2015-03-23-40f2844fadc05f4a4de7699dbc12fee295b7057b
jshn - 2015-03-22-b8d9b382e39823850331edc2a92379173daf1be3
jsonfilter - 2014-06-19-cdc760c58077f44fc40adbbe41e1556a67c1b9a9
kernel - 3.18.9-1-a86385e8467388dda6a71e6db80bea44
kmod-ath - 3.18.9+2015-03-09-3
kmod-ath9k - 3.18.9+2015-03-09-3
kmod-ath9k-common - 3.18.9+2015-03-09-3
kmod-cfg80211 - 3.18.9+2015-03-09-3
kmod-crypto-aes - 3.18.9-1
kmod-crypto-arc4 - 3.18.9-1
kmod-crypto-core - 3.18.9-1
kmod-crypto-hash - 3.18.9-1
kmod-fs-ext4 - 3.18.9-1
kmod-gpio-button-hotplug - 3.18.9-1
kmod-ip6tables - 3.18.9-1
kmod-ipt-conntrack - 3.18.9-1
kmod-ipt-core - 3.18.9-1
kmod-ipt-nat - 3.18.9-1
kmod-iptunnel - 3.18.9-1
kmod-iptunnel4 - 3.18.9-1
kmod-ipv6 - 3.18.9-1
kmod-ledtrig-usbdev - 3.18.9-1
kmod-lib-crc-ccitt - 3.18.9-1
kmod-lib-crc16 - 3.18.9-1
kmod-mac80211 - 3.18.9+2015-03-09-3
kmod-nf-conntrack - 3.18.9-1
kmod-nf-conntrack6 - 3.18.9-1
kmod-nf-ipt - 3.18.9-1
kmod-nf-ipt6 - 3.18.9-1
kmod-nf-nat - 3.18.9-1
kmod-nf-nathelper - 3.18.9-1
kmod-nls-base - 3.18.9-1
kmod-ppp - 3.18.9-1
kmod-pppoe - 3.18.9-1
kmod-pppox - 3.18.9-1
kmod-scsi-core - 3.18.9-1
kmod-sit - 3.18.9-1
kmod-slhc - 3.18.9-1
kmod-tun - 3.18.9-1
kmod-usb-core - 3.18.9-1
kmod-usb-ohci - 3.18.9-1
kmod-usb-storage - 3.18.9-1
kmod-usb2 - 3.18.9-1
libblobmsg-json - 2015-03-22-b8d9b382e39823850331edc2a92379173daf1be3
libbz2 - 1.0.6-2
libc - 0.9.33.2-1
libdb47 - 4.7.25.4.NC-5
libffi - 3.0.13-1
libgcc - 4.8-linaro-1
libgcrypt - 1.6.1-1
libgdbm - 1.11-1
libgmp - 6.0.0-1
libgnutls - 3.3.13-3
libgpg-error - 1.12-1
libip4tc - 1.4.21-1
libip6tc - 1.4.21-1
libiwinfo - 2015-03-23-40f2844fadc05f4a4de7699dbc12fee295b7057b
libiwinfo-lua - 2015-03-23-40f2844fadc05f4a4de7699dbc12fee295b7057b
libjson-c - 0.12-1
libjson-script - 2015-03-22-b8d9b382e39823850331edc2a92379173daf1be3
liblua - 5.1.5-1
liblzo - 2.08-1
libmagic - 5.20-1
libncurses - 5.9-2
libnettle - 2.7.1-1
libnl-tiny - 0.1-4
libopenssl - 1.0.2a-0
libpcap - 1.5.3-1
libpthread - 0.9.33.2-1
libsqlite3 - 3081002-1
libubox - 2015-03-22-b8d9b382e39823850331edc2a92379173daf1be3
libubus - 2015-01-22-2d660c519d2fcff95248da9f4fd9b37d61f9eb09
libubus-lua - 2015-01-22-2d660c519d2fcff95248da9f4fd9b37d61f9eb09
libuci - 2015-03-26.1-1
libuci-lua - 2015-03-26.1-1
libxml2 - 2.9.2-3
libxtables - 1.4.21-1
lua - 5.1.5-1
luci - git-15.079.29361-3e37216-1
luci-app-firewall - git-15.079.29361-3e37216-1
luci-app-openvpn - git-15.079.29361-3e37216-1
luci-base - git-15.079.29361-3e37216-1
luci-lib-ip - git-15.079.29361-3e37216-1
luci-lib-nixio - git-15.079.29361-3e37216-1
luci-mod-admin-full - git-15.079.29361-3e37216-1
luci-proto-ipv6 - git-15.079.29361-3e37216-1
luci-proto-ppp - git-15.079.29361-3e37216-1
luci-theme-bootstrap - git-15.079.29361-3e37216-1
luci-theme-openwrt - git-15.079.29361-3e37216-1
miniupnpd - 1.9.20150609-1
mtd - 20
netifd - 2015-03-27-94bfecc312f8bcecb857d6b070d1c22869226ce4
odhcp6c - 2015-03-25-5710bd46493eaa75a3c6b532d21b8237a691c5a8
odhcpd - 2015-03-06-721db56281dba79158470d7f69ccc7577f11fbb6
openssl-util - 1.0.2a-0
openvpn-easy-rsa - 2013-01-30-2
openvpn-openssl - 2.3.6-3
opkg - 9c97d5ecd795709c8584e972bfdf3aee3a5b846d-7
ppp - 2.4.7-5
ppp-mod-pppoe - 2.4.7-5
procd - 2015-03-27-74d835463e05e5761f6f5271e487f299f29d3f07
python - 2.7.10-5
python-base - 2.7.10-5
python-codecs - 2.7.10-5
python-compiler - 2.7.10-5
python-ctypes - 2.7.10-5
python-db - 2.7.10-5
python-decimal - 2.7.10-5
python-distutils - 2.7.10-5
python-email - 2.7.10-5
python-gdbm - 2.7.10-5
python-light - 2.7.10-5
python-logging - 2.7.10-5
python-multiprocessing - 2.7.10-5
python-ncurses - 2.7.10-5
python-openssl - 2.7.10-5
python-pydoc - 2.7.10-5
python-sqlite3 - 2.7.10-5
python-unittest - 2.7.10-5
python-xml - 2.7.10-5
resolveip - 2
rpcd - 2015-03-11-361b823e8d670bc122349041294983468ef36845
swconfig - 10
tcpdump - 4.5.1-4
terminfo - 5.9-2
uboot-envtools - 2014.10-2
ubox - 2015-03-29-dd338ce30b6158f3f6feda9f01a2f409a8a5832c
ubus - 2015-01-22-2d660c519d2fcff95248da9f4fd9b37d61f9eb09
ubusd - 2015-01-22-2d660c519d2fcff95248da9f4fd9b37d61f9eb09
uci - 2015-03-26.1-1
uhttpd - 2015-03-11-ae3fe30b6a1d4a45a34b3a896e9a4997c5da500f
uhttpd-mod-ubus - 2015-03-11-ae3fe30b6a1d4a45a34b3a896e9a4997c5da500f
vpnc - 0.5.3.r550-1
vpnc-scripts - 20150116-1
wpad-mini - 2015-03-25-1
zlib - 1.2.8-1

Attachments (0)

Change History (4)

comment:1 Changed 3 years ago by anonymous

You are using an old trunk snapshot image (r45141). The default libc was changed from uclibc to musl recently, so all new trunk builds will be against musl. You will have to use a newer image, or compile packages to suit your current environment.

comment:2 Changed 3 years ago by nbd

  • Resolution set to not_a_bug
  • Status changed from new to closed

comment:3 Changed 3 years ago by anonymous

I've also run into this problem. I installed CC rc2, and then tried to install a package with opkg.

opkg install tcpdump

tcpdump

-ash: tcpdump not found

I changed the opkg.conf, so instead of pointing at snapshots/trunk it points at chaos_calmer/15.05-rc2. After a sysupgrade to remove all incorrect package versions now when I install tcpdump it runs.

comment:4 Changed 21 months ago by mayurovmih@…

It's cool but this info have to be added on Openwrt.org and/or Forum!

Add Comment

Modify Ticket

Action
as closed .
The resolution will be deleted. Next status will be 'reopened'.
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.