AskOverflow.Dev

AskOverflow.Dev Logo AskOverflow.Dev Logo

AskOverflow.Dev Navigation

  • 主页
  • 系统&网络
  • Ubuntu
  • Unix
  • DBA
  • Computer
  • Coding
  • LangChain

Mobile menu

Close
  • 主页
  • 系统&网络
    • 最新
    • 热门
    • 标签
  • Ubuntu
    • 最新
    • 热门
    • 标签
  • Unix
    • 最新
    • 标签
  • DBA
    • 最新
    • 标签
  • Computer
    • 最新
    • 标签
  • Coding
    • 最新
    • 标签
主页 / user-90881

Erik Sjölund's questions

Martin Hope
Erik Sjölund
Asked: 2012-09-19 05:48:52 +0800 CST

使用 qemu-img 转换 VMDK 映像失败,出现“读取扇区 131072 时出错:参数无效”

  • 4

我尝试使用qemu-img命令将在 OVA 文件中找到的 VMDK 映像转换为 QCOW2 格式,但失败并显示错误消息qemu-img: error while reading sector 131072: Invalid argument

user@ubuntu:/tmp$ wget ftp://ftp.sanger.ac.uk/pub/databases/Pfam/vm/PfamWeb_20120124.ova
user@ubuntu:/tmp$ tar xfv PfamWeb_20120124.ova
PfamWeb_20120124_2.ovf
PfamWeb_20120124_2.mf
PfamWeb_20120124_2-disk1.vmdk
user@ubuntu:/tmp$ qemu-img convert -O qcow2 PfamWeb_20120124_2-disk1.vmdk PfamWeb_20120124_2.qcow2
qemu-img: error while reading sector 131072: Invalid argument
user@ubuntu:/tmp$ qemu-img --version | grep "qemu-img version" 
qemu-img version 1.0, Copyright (c) 2004-2008 Fabrice Bellard
user@ubuntu:/tmp$ dpkg-query -f='${Version}\n' --show  qemu-utils
1.0+noroms-0ubuntu14.1
user@ubuntu:/tmp$ cat /etc/issue
Ubuntu 12.04.1 LTS \n \l

我该如何避免错误?

qemu
  • 2 个回答
  • 21209 Views
Martin Hope
Erik Sjölund
Asked: 2012-09-11 05:20:53 +0800 CST

查找占用大量 AFS 卷配额的目录

  • 0

我们的一位计算机用户几乎超出了 AFS 卷配额。运行fs listquota或fs lq给他警告:

olifri@ubuntu:~$ fs listquota ~
Volume Name                    Quota       Used %Used   Partition
H.olifri                      500000     492787   99%<<       38% <<WARNING

我想与他分享一个 shell 脚本,该脚本可以检测他的哪个目录占用了他的大部分 AFS 卷配额。然后他会更好地了解从哪里开始删除文件。

请注意,在 AFS 文件系统中,用户可以在 AFS 卷内安装其他 AFS 卷。这意味着使用/usr/bin/find的递归可能会进入我们不感兴趣的其他 AFS 卷。

我们的 AFS 客户端软件是 Openafs 1.6.1,它运行在 Ubuntu 12.04 计算机上。我们对 AFS 文件服务器没有管理员权限,因为它们由另一个部门管理。

命令/usr/bin/du似乎不知道 AFS 卷的概念。我现在最好的想法是为每个子目录编写一个脚本,该脚本将测试该目录是否是 AFS 卷的安装点。例如,该命令fs lsmount可用于此。对于普通目录fs lsmount会产生此结果

esjolund@ubuntu:~$ mkdir ~/testdir
esjolund@ubuntu:~$ fs lsmount ~/testdir
'/afs/pdc.kth.se/home/e/esjolund/testdir' is not a mount point.

并且对于 AFS 安装点fs lsmount会产生此结果

esjolund@ubuntu:~$ fs mkmount -dir ~/testmount -vol prj.sbc.esjolund00
esjolund@ubuntu:~$ fs lsmount ~/testmount
'/afs/pdc.kth.se/home/e/esjolund/testmount' is a mount point for volume '#prj.sbc.esjolund00'

在开始编写 shell 脚本之前,我想听听您对如何解决问题有什么更好的想法?

command-line-interface
  • 1 个回答
  • 239 Views

Sidebar

Stats

  • 问题 205573
  • 回答 270741
  • 最佳答案 135370
  • 用户 68524
  • 热门
  • 回答
  • Marko Smith

    新安装后 postgres 的默认超级用户用户名/密码是什么?

    • 5 个回答
  • Marko Smith

    SFTP 使用什么端口?

    • 6 个回答
  • Marko Smith

    命令行列出 Windows Active Directory 组中的用户?

    • 9 个回答
  • Marko Smith

    什么是 Pem 文件,它与其他 OpenSSL 生成的密钥文件格式有何不同?

    • 3 个回答
  • Marko Smith

    如何确定bash变量是否为空?

    • 15 个回答
  • Martin Hope
    Tom Feiner 如何按大小对 du -h 输出进行排序 2009-02-26 05:42:42 +0800 CST
  • Martin Hope
    Noah Goodrich 什么是 Pem 文件,它与其他 OpenSSL 生成的密钥文件格式有何不同? 2009-05-19 18:24:42 +0800 CST
  • Martin Hope
    Brent 如何确定bash变量是否为空? 2009-05-13 09:54:48 +0800 CST
  • Martin Hope
    cletus 您如何找到在 Windows 中打开文件的进程? 2009-05-01 16:47:16 +0800 CST

热门标签

linux nginx windows networking ubuntu domain-name-system amazon-web-services active-directory apache-2.4 ssh

Explore

  • 主页
  • 问题
    • 最新
    • 热门
  • 标签
  • 帮助

Footer

AskOverflow.Dev

关于我们

  • 关于我们
  • 联系我们

Legal Stuff

  • Privacy Policy

Language

  • Pt
  • Server
  • Unix

© 2023 AskOverflow.DEV All Rights Reserve