* Possible bug with fsimage/pygrub
[not found] <1288784150.7402967.1496256072038.ref@mail.yahoo.com>
@ 2017-05-31 18:41 ` Ian Murray
2017-06-13 17:00 ` Wei Liu
0 siblings, 1 reply; 2+ messages in thread
From: Ian Murray @ 2017-05-31 18:41 UTC (permalink / raw)
To: xen-devel@lists.xen.org
[-- Attachment #1.1: Type: text/plain, Size: 2189 bytes --]
All,
Having a very strange problem. I created a CentOS 7 PV vm but could not get pygrub to pick-up the grub entries. I did some fault finding and concluded that `fsimage` was unable to find the grub.cfg.
I could start the vm as an HVM guest with no problem. I renamed the `grub2` folder to be `grub2.x` and `cp -a` that back to `grub2`. pygrub/fsimage were able to find the file after that. fsimage couldn't see grub2.x/grub.cfg.
I wrote small test case in python to illustrate the issue:
I can only think it is a bug in fsimage, or there is something very hidden about that directory that is causing this.
Any suggestions would be most welcome,
Thanks,
Ian
import fsimagefs = fsimage.open('/dev/xen2/email', 1048576, "seclabel")if fs.file_exists('/grub2.x/grub.cfg'): print "found"else: print "not found"if fs.file_exists('/grub2/grub.cfg'): print "found"else: print "not found"
The results are:- # python ~/test.py not foundfound
(mounted locally, after an update, but same behaviour as previously. The partition is on LVM and is formatted ext4)# ls -al grub2*grub2:total 52drwxr-xr-x. 6 root root 4096 May 31 02:39 .dr-xr-xr-x. 7 root root 4096 May 31 02:41 ..-rw-r--r--. 1 root root 86 Jan 10 23:32 device.mapdrwxr-xr-x. 2 root root 4096 Jan 10 23:32 fonts-rw-r--r--. 1 root root 4806 May 31 02:39 grub.cfg-rw-r--r--. 1 root root 4045 Jan 10 23:33 grub.cfg.1496194637.rpmsave-rw-r--r--. 1 root root 1024 May 31 02:39 grubenvdrwxr-xr-x. 2 root root 12288 Jan 10 23:32 i386-pcdrwxr-xr-x. 2 root root 4096 Jan 10 23:32 localedrwxr-xr-x. 3 root root 4096 Jan 10 23:28 themes-rw-r--r--. 1 root root 0 May 31 02:13 xxxx
grub2.x:total 44drwxr-xr-x. 6 root root 4096 May 31 02:13 .dr-xr-xr-x. 7 root root 4096 May 31 02:41 ..-rw-r--r--. 1 root root 86 Jan 10 23:32 device.mapdrwxr-xr-x. 2 root root 4096 Jan 10 23:32 fonts-rw-r--r--. 1 root root 4045 Jan 10 23:33 grub.cfg-rw-r--r--. 1 root root 1024 Jan 10 23:33 grubenvdrwxr-xr-x. 2 root root 12288 Jan 10 23:32 i386-pcdrwxr-xr-x. 2 root root 4096 Jan 10 23:32 localedrwxr-xr-x. 3 root root 4096 Jan 10 23:28 themes-rw-r--r--. 1 root root 0 May 31 02:13 xxxx
[-- Attachment #1.2: Type: text/html, Size: 6226 bytes --]
[-- Attachment #2: Type: text/plain, Size: 127 bytes --]
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: Possible bug with fsimage/pygrub
2017-05-31 18:41 ` Possible bug with fsimage/pygrub Ian Murray
@ 2017-06-13 17:00 ` Wei Liu
0 siblings, 0 replies; 2+ messages in thread
From: Wei Liu @ 2017-06-13 17:00 UTC (permalink / raw)
To: Ian Murray; +Cc: Wei Liu, xen-devel@lists.xen.org
On Wed, May 31, 2017 at 06:41:12PM +0000, Ian Murray wrote:
> All,
> Having a very strange problem. I created a CentOS 7 PV vm but could not get pygrub to pick-up the grub entries. I did some fault finding and concluded that `fsimage` was unable to find the grub.cfg.
> I could start the vm as an HVM guest with no problem. I renamed the `grub2` folder to be `grub2.x` and `cp -a` that back to `grub2`. pygrub/fsimage were able to find the file after that. fsimage couldn't see grub2.x/grub.cfg.
>
> I wrote small test case in python to illustrate the issue:
> I can only think it is a bug in fsimage, or there is something very hidden about that directory that is causing this.
> Any suggestions would be most welcome,
> Thanks,
> Ian
> import fsimagefs = fsimage.open('/dev/xen2/email', 1048576, "seclabel")if fs.file_exists('/grub2.x/grub.cfg'): print "found"else: print "not found"if fs.file_exists('/grub2/grub.cfg'): print "found"else: print "not found"
> The results are:- # python ~/test.py not foundfound
> (mounted locally, after an update, but same behaviour as previously. The partition is on LVM and is formatted ext4)# ls -al grub2*grub2:total 52drwxr-xr-x. 6 root root 4096 May 31 02:39 .dr-xr-xr-x. 7 root root 4096 May 31 02:41 ..-rw-r--r--. 1 root root 86 Jan 10 23:32 device.mapdrwxr-xr-x. 2 root root 4096 Jan 10 23:32 fonts-rw-r--r--. 1 root root 4806 May 31 02:39 grub.cfg-rw-r--r--. 1 root root 4045 Jan 10 23:33 grub.cfg.1496194637.rpmsave-rw-r--r--. 1 root root 1024 May 31 02:39 grubenvdrwxr-xr-x. 2 root root 12288 Jan 10 23:32 i386-pcdrwxr-xr-x. 2 root root 4096 Jan 10 23:32 localedrwxr-xr-x. 3 root root 4096 Jan 10 23:28 themes-rw-r--r--. 1 root root 0 May 31 02:13 xxxx
> grub2.x:total 44drwxr-xr-x. 6 root root 4096 May 31 02:13 .dr-xr-xr-x. 7 root root 4096 May 31 02:41 ..-rw-r--r--. 1 root root 86 Jan 10 23:32 device.mapdrwxr-xr-x. 2 root root 4096 Jan 10 23:32 fonts-rw-r--r--. 1 root root 4045 Jan 10 23:33 grub.cfg-rw-r--r--. 1 root root 1024 Jan 10 23:33 grubenvdrwxr-xr-x. 2 root root 12288 Jan 10 23:32 i386-pcdrwxr-xr-x. 2 root root 4096 Jan 10 23:32 localedrwxr-xr-x. 3 root root 4096 Jan 10 23:28 themes-rw-r--r--. 1 root root 0 May 31 02:13 xxxx
>
What about extended attributes and other meta data? Maybe they are not
retained after you copied the files?
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2017-06-13 17:00 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <1288784150.7402967.1496256072038.ref@mail.yahoo.com>
2017-05-31 18:41 ` Possible bug with fsimage/pygrub Ian Murray
2017-06-13 17:00 ` Wei Liu
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).