<br><br><div class="gmail_quote">On Tue, May 22, 2012 at 11:08 PM, 马磊 <span dir="ltr"><<a href="mailto:aware.why@gmail.com" target="_blank">aware.why@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div class="HOEnZb"><div class="h5"><br><br><div class="gmail_quote">On Tue, May 22, 2012 at 7:48 PM, Richard W.M. Jones <span dir="ltr"><<a href="mailto:rjones@redhat.com" target="_blank">rjones@redhat.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div><div>On Tue, May 22, 2012 at 07:44:04PM +0800, 马磊 wrote:<br>
> On Tue, May 22, 2012 at 7:37 PM, Richard W.M. Jones <<a href="mailto:rjones@redhat.com" target="_blank">rjones@redhat.com</a>>wrote:<br>
><br>
> > On Tue, May 22, 2012 at 06:38:45PM +0800, 马磊 wrote:<br>
> > > [malei@xen-test2 ~]$ guestfish --rw -a /home/malei/d.img<br>
> > ><br>
> > > Welcome to guestfish, the libguestfs filesystem interactive shell for<br>
> > > editing virtual machine filesystems.<br>
> > ><br>
> > > Type: 'help' for help on commands<br>
> > >       'man' to read the manual<br>
> > >       'quit' to quit the shell<br>
> > ><br>
> > > ><fs> mount-options '' /dev/vda1 /<br>
> > > libguestfs: error: mount_options: call launch before using this function<br>
> > > (in guestfish, don't forget to use the 'run' command)<br>
> > > ><fs> launch<br>
> > > ><fs> mount-options '' /dev/vda1 /<br>
> > > ><fs> ls /<br>
> > > ?? ????.txt<br>
> > > ?? ????.wav<br>
> > > ?? WinRAR ZIP ????.zip<br>
> > > root1<br>
> > > root2<br>
> > > ><fs><br>
> > > ===============================================<br>
> > > Does it have something to do with the LANG environment variable or the<br>
> > disk<br>
> > > img which is not bootable?<br>
> ><br>
> > I guess this is a FAT or VFAT image?  (Try the 'list-filesystems' command).<br>
> ><br>
> > There are several bugs, they even prevent me from creating such an<br>
> > image to start with :-(  I have filed these:<br>
> ><br>
> > <a href="https://bugzilla.redhat.com/show_bug.cgi?id=823885" target="_blank">https://bugzilla.redhat.com/show_bug.cgi?id=823885</a><br>
> > <a href="https://bugzilla.redhat.com/show_bug.cgi?id=823887" target="_blank">https://bugzilla.redhat.com/show_bug.cgi?id=823887</a><br>
> ><br>
> > How large is 'd.img'?  Would it be possible for me to get a copy of<br>
> > it, or of a similar image that fails in the same way?<br>
> ><br>
> > Rich.<br>
> ><br>
> > --<br>
> > Richard Jones, Virtualization Group, Red Hat<br>
> > <a href="http://people.redhat.com/~rjones" target="_blank">http://people.redhat.com/~rjones</a><br>
> > virt-p2v converts physical machines to virtual machines.  Boot with a<br>
> > live CD or over the network (PXE) and turn machines into Xen guests.<br>
> > <a href="http://et.redhat.com/~rjones/virt-p2v" target="_blank">http://et.redhat.com/~rjones/virt-p2v</a><br>
><br>
><br>
><br>
><br>
>      You're right! The partition containg chinese-character-name files is<br>
> vfat filesystem.<br>
> [malei@xen-test2 ~]$ guestfish --rw -a /home/malei/d.img<br>
><br>
> Welcome to guestfish, the libguestfs filesystem interactive shell for<br>
> editing virtual machine filesystems.<br>
><br>
> Type: 'help' for help on commands<br>
>       'man' to read the manual<br>
>       'quit' to quit the shell<br>
><br>
> ><fs> run<br>
> ><fs> list_filesystems<br>
> /dev/vda1: vfat<br>
> /dev/vda2: ntfs<br>
> /dev/vda3: ntfs<br>
> /dev/vda4: unknown<br>
> /dev/vda5: vfat<br>
> /dev/vda6: vfat<br>
> /dev/vda7: ntfs<br>
> ><fs> mount-options /dev/vda2 /<br>
> mount-options should have 3 parameter(s)<br>
> type 'help mount-options' for help on mount-options<br>
> ><fs> mount-options '' /dev/vda2 /<br>
> ><fs> ls /<br>
> System Volume Information<br>
> root1<br>
> root2<br>
> 新建 WinRAR ZIP 压缩文件.zip<br>
> 新建 文本文档.txt<br>
> 新建 波形声音.wav<br>
<br>
</div></div>It'd be great if you could get me / point me to a vfat image that<br>
contains Chinese character filenames.  One way (assuming this image<br>
does not contain sensitive data) is:<br>
<br>
  guestfish --ro -a /home/malei/d.img<br>
  ><fs> run<br>
  ><fs> download /dev/vda1 - | xz --best > /tmp/vda1.img.xz<br>
<br>
and then send me the file /tmp/vda1.img.xz.<br>
<div><br>
Rich.<br>
<br>
--<br>
Richard Jones, Virtualization Group, Red Hat <a href="http://people.redhat.com/~rjones" target="_blank">http://people.redhat.com/~rjones</a><br>
</div>libguestfs lets you edit virtual machines.  Supports shell scripting,<br>
bindings from many languages.  <a href="http://libguestfs.org" target="_blank">http://libguestfs.org</a><br>
</blockquote></div><br></div></div><div>I have sent it to you, check please.</div></blockquote><div><br></div><div>BTW, another problem about mount:</div><div><br></div><div>[malei@xen-test2 ~]$ guestfish --rw -a d.img -m /dev/vda1:/:utf8</div>
<div>libguestfs: error: mount_options: you must mount something on / first</div><div>guestfish: '/dev/vda1' could not be mounted.  Did you mean one of these?</div><div><span class="Apple-tab-span" style="white-space:pre">      </span>/dev/vda1 (vfat)</div>
<div><span class="Apple-tab-span" style="white-space:pre">      </span>/dev/vda2 (ntfs)</div><div><span class="Apple-tab-span" style="white-space:pre">     </span>/dev/vda3 (ntfs)</div><div><span class="Apple-tab-span" style="white-space:pre">     </span>/dev/vda4 (unknown)</div>
<div><span class="Apple-tab-span" style="white-space:pre">      </span>/dev/vda5 (vfat)</div><div><span class="Apple-tab-span" style="white-space:pre">     </span>/dev/vda6 (vfat)</div><div><span class="Apple-tab-span" style="white-space:pre">     </span>/dev/vda7 (ntfs) </div>
</div><br>