Ubuntu18.04可执行文件运行提示No such file or directory
参考原文见
https://blog.csdn.net/sun927/article/details/46593129?
最近我也遇到一个类似问题,同一个工具在Ubuntu16.04里面运行是好的,但是Ubuntu18.04运行就出错了。
我用file也看了是32bit的应用程序,但一直没想到Ubuntu18.04竟然默认去掉了32bit的library。
用uname命令打印系统信息,发现系统是64位系统
$ uname -a
Linux latitude-e5440 5.3.0-40-generic #32~18.04.1-Ubuntu SMP Mon Feb 3 14:05:59 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux
安装ia32-libs,提示找不到了,候选lib32ncurses5或lib32z1,我用了lib32z1.
sudo apt-get install ia32-libs
Building dependency tree
Reading state information... Done
Package ia32-libs is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source
However the following packages replace it:
lib32ncurses5 lib32z1 E: Package 'ia32-libs' has no installation candidate
$ sudo apt-get install lib32z1
另外,如果用到32bit的libstdc++6,应该是安装
lib32stdc++6。
顺便看了一下查询用到的so,有两种办法
之一是ldd命令
ldd ./combine-image
linux-gate.so.1 (0xf7f63000)
libc.so.6 => /lib32/libc.so.6 (0xf7d71000)
/lib/ld-linux.so.2 (0xf7f64000)
之二是readelf -d
readelf -d ./combine-image Dynamic section at offset 0x7f20 contains 21 entries:
Tag Type Name/Value
0x00000001 (NEEDED) Shared library: [libc.so.6]
0x0000000c (INIT) 0x8048880
调用的是32bit的libc.so。
之前有部分应用不能运行估计也是这个原因。
不知道这个方法是不是可以适合WSL
Ubuntu18.04可执行文件运行提示No such file or directory的更多相关文章
- 解决“运行arm-linux-gcc命令,提示No such file or directory”的问题
今天在ubuntu14.04上安装arm的交叉编译器arm-linux-gcc,环境变量配置好以后,运行arm-linux-gcc命令,总提示No such file or directory.然后去 ...
- Linux运行shell脚本提示No such file or directory错误的解决办法
Linux执行.sh文件,提示No such file or directory的问题: 原因:在windows中写好shell脚本测试正常,但是上传到 Linux 上以脚本方式运行命令时提示No s ...
- 64位Ubuntu14.04配置adb后提示No such file or directory
配置好SDK的环境变量后,输入adb提示 No such file or directory. 原因:由于是64位的linux系统,而Android SDK只有32位的,需要安装一些支持包才能使用 1 ...
- ITouch在xcode下提示‘No such file or directory, at ‘/SourceCache/DVTi...'
版权声明:本文为博主原创文章,转载或又一次发表请先与我联系. https://blog.csdn.net/jonahzheng/article/details/37692733 用一个台老 ...
- shell 执行提示No such file or directory
问题描述: 项目开发过程中ansible执行脚本失败,单独运行shell脚本提示:No such file or directory,脚本结构执行脚本a 调用另一脚本b, 但查看b脚本路径正确不存在找 ...
- linux执行python的脚本文件,提示提示No such file or directory
在window平台下,写好python脚本文件,迁移到linux平台,赋过可执行权限,执行该sh文件,却提示No such file or directory.ls 了下,确实有该文件,怎么会事呢, ...
- Linux执行.sh文件,提示No such file or directory的问题的解决方法
亲测有效:http://www.jb51.net/LINUXjishu/56395.html Linux执行.sh文件,提示No such file or directory的问题的解决方法 在win ...
- linux sh文件提示 no such file or directory
Linux执行.sh文件,提示No such file or directory的问题的解决方法 12-06-28 16:59作者:love__coder Linux执行.sh文件,提示No such ...
- Linux执行.sh文件,提示No such file or directory的问题
问题描述 在window平台下,写好shell脚本文件,迁移到linux平台,赋过可执行权限,执行该sh文件,却提示NO such file or directory 解决方案 难道是文件格式兼容性问 ...
随机推荐
- eclipse问题集合
[eclipse更换jdk版本]
- Python中安装框架如何换源以及升级
想安装tornado框架,但总是有奇怪错误,如下: 如果按照默认的下载源,就会死活不成功,出现 Traceback (most recent call last): File "e:\pyt ...
- Dubbo+zookeeper部署到tomcat上注意事项,遇到的问题,闪退,运行报错等
需要下载工具zookeeper-3.4.14.tar.gz,dubbo-2.5.x.zip,apache-tomcat-8.5.47-windows-x64.zip这些官网都可以先下载到 1.最新的z ...
- Shenandoah 与 ZGC
简介 Shenandoah GC 与 ZGC 同为新一代的低延迟收集器, 分别由RedHat和Oracle开发, 目前还在实验阶段, 尚未使用于生产环境. GC的三项指标: Footprint(内存占 ...
- Kubernetes 深入学习(一) —— 入门和集群安装部署
一.简介 1.Kubernetes 是什么 Kubernetes 是一个全新的基于容器技术的分布式架构解决方案,是 Google 开源的一个容器集群管理系统,Kubernetes 简称 K8S. Ku ...
- 《React后台管理系统实战 :四》产品分类管理页:添加产品分类、修改(更新)产品分类
一.静态页面 目录结构 F:\Test\react-demo\admin-client\src\pages\admin\category add-cate-form.jsx index.jsx ind ...
- redis的并发set
1.Redis高并发的问题 Redis缓存的高性能有目共睹,应用的场景也是非常广泛,但是在高并发的场景下,也会出现问题:缓存击穿.缓存雪崩.缓存和数据一致性,以及今天要谈到的缓存并发竞争. 这里的并发 ...
- 分页插件 layui.laypage 的用法
参考 layui.laypage 官方文档 https://www.layui.com/demo/laypage.html 第一步下载插件 (注意不能只引入引入 layui.css和layui.js ...
- webpack配置自动打包重新运行npm run dev出现报错
webpack配置自动打包重新运行npm run dev出现报错 运行npm run dev出现如下报错 Listening at http://localhost:8080(node:2328) U ...
- php 实现店铺装修7
type_id=0的情况 type_id=1的情况 type_id=2的情况 /** * @title 店铺装修--商品分类 * @param type ...