* Problem building core-image-basic: Cannot create symlink from ./var/run to 'volatile/run'
@ 2012-02-15 23:21 Brandon Stafford
2012-02-16 0:36 ` Mark Hatle
0 siblings, 1 reply; 3+ messages in thread
From: Brandon Stafford @ 2012-02-15 23:21 UTC (permalink / raw)
To: openembedded-core
[-- Attachment #1: Type: text/plain, Size: 933 bytes --]
Hi all,
In trying to build core-image-basic for qemuarm, I ran into an error:
extract_archive:
Cannot create symlink from ./var/run to 'volatile/run': File exists.
(The full error message is posted here: http://pastebin.com/QPic3uHx )
Though this seems very similar to a post from a few months ago, I am not
sure how to go about debugging it:
http://lists.linuxtogo.org/pipermail/openembedded-devel/2011-October/035409.html
Can other folks build core-image-basic successfully? Any suggestions about
how to determine which recipe is attempting to make the symlink?
From what I can tell, the culprits could be meta/files/fs-perms.txt
or meta/recipes-core/base-files/base-files_3.0.14.bb, but I'm not sure
where to go from there. If it helps, I am able to build core-image-minimal
successfully.
Thanks,
Brandon
--
Brandon Stafford
Rascal Micro: small computers for art and science
Somerville, MA, USA
[-- Attachment #2: Type: text/html, Size: 2908 bytes --]
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Problem building core-image-basic: Cannot create symlink from ./var/run to 'volatile/run'
2012-02-15 23:21 Problem building core-image-basic: Cannot create symlink from ./var/run to 'volatile/run' Brandon Stafford
@ 2012-02-16 0:36 ` Mark Hatle
2012-02-16 21:21 ` Brandon Stafford
0 siblings, 1 reply; 3+ messages in thread
From: Mark Hatle @ 2012-02-16 0:36 UTC (permalink / raw)
To: openembedded-core
On 2/15/12 3:21 PM, Brandon Stafford wrote:
> Hi all,
>
> In trying to build core-image-basic for qemuarm, I ran into an error:
> extract_archive: Cannot create symlink from ./var/run to 'volatile/run': File
> exists.
>
> (The full error message is posted here: http://pastebin.com/QPic3uHx )
>
> Though this seems very similar to a post from a few months ago, I am not sure
> how to go about debugging it:
> http://lists.linuxtogo.org/pipermail/openembedded-devel/2011-October/035409.html
>
> Can other folks build core-image-basic successfully? Any suggestions about how
> to determine which recipe is attempting to make the symlink?
>
> From what I can tell, the culprits could be meta/files/fs-perms.txt or
> meta/recipes-core/base-files/base-files_3.0.14.bb <http://base-files_3.0.14.bb>,
> but I'm not sure where to go from there. If it helps, I am able to build
> core-image-minimal successfully.
The issue is most likely that something created the directory of "/var/run", and
then the later base-files attempted to create the symlink which caused the failure.
i.e. package foo created something like:
/var/run/foo
and then base-files attempts:
ln -s var/run volatile/run
and then you see the failure.
The fs-perm.txt file is supposed to prevent this situation from happening.
During the package generation, fs-perms should be checking that a directory
/var/run was never generated, and if it was, should be moving the files to
volatine/run.
fs-perms is used by package.bbclass, the "fixup_perms" function does the
expected changes.
In order to debug this, I'd first figure out which package has a /var/run
directory in it, and then verify that it's reproducible by rebuilding that
package. (Hopefully it is!)
I'd then suggest that you go through that function and remove the commend from
the "bb.note" calls. This should give you a clue if the fixup code is running
and what it's trying to do.
This is the code that -should- be doing the fixup:
# Create path to move directory to, move it, and then setup the$
bb.mkdirhier(os.path.dirname(target))
#bb.note("Fixup Perms: Rename %s -> %s" % (dir, ptarget))
os.rename(origin, target)
#bb.note("Fixup Perms: Link %s -> %s" % (dir, link))
os.symlink(link, origin)
I hope this helps figure out what went wrong.
--Mark
> Thanks,
> Brandon
>
> --
> Brandon Stafford
> Rascal Micro: small computers for art and science
> Somerville, MA, USA
>
>
>
> _______________________________________________
> Openembedded-core mailing list
> Openembedded-core@lists.openembedded.org
> http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-core
^ permalink raw reply [flat|nested] 3+ messages in thread* Re: Problem building core-image-basic: Cannot create symlink from ./var/run to 'volatile/run'
2012-02-16 0:36 ` Mark Hatle
@ 2012-02-16 21:21 ` Brandon Stafford
0 siblings, 0 replies; 3+ messages in thread
From: Brandon Stafford @ 2012-02-16 21:21 UTC (permalink / raw)
To: openembedded-core
[-- Attachment #1: Type: text/plain, Size: 1694 bytes --]
On Wed, Feb 15, 2012 at 7:36 PM, Mark Hatle <mark.hatle@windriver.com>wrote:
> On 2/15/12 3:21 PM, Brandon Stafford wrote:
>
>> Hi all,
>>
>> In trying to build core-image-basic for qemuarm, I ran into an error:
>> extract_archive: Cannot create symlink from ./var/run to 'volatile/run':
>> File
>> exists.
>>
>> (The full error message is posted here: http://pastebin.com/QPic3uHx )
>>
>> The issue is most likely that something created the directory of
> "/var/run", and then the later base-files attempted to create the symlink
> which caused the failure.
--Mark
>
Thanks for the suggestion, Mark.
It appears that dbus is the source of the conflict. If I add /volatile to
the paths, as in the patch below, the error disappears. I can't test it in
actual operation because of subsequent errors.
Is this the right fix?
diff --git a/meta/recipes-core/dbus/dbus.inc
b/meta/recipes-core/dbus/dbus.inc
index 2a25256..9dc40cf 100644
--- a/meta/recipes-core/dbus/dbus.inc
+++ b/meta/recipes-core/dbus/dbus.inc
@@ -81,9 +81,9 @@ do_install() {
> ${D}${sysconfdir}/default/volatiles/99_dbus
- mkdir -p ${D}${localstatedir}/run/dbus ${D}${localstatedir}/lib/dbus
+ mkdir -p ${D}${localstatedir}/volatile/run/dbus
${D}${localstatedir}/volatile/lib/dbus
- chown messagebus:messagebus ${D}${localstatedir}/run/dbus
${D}${localstatedir}/lib/dbus
+ chown messagebus:messagebus ${D}${localstatedir}/volatile/run/dbus
${D}${localstatedir}/volatile/lib/dbus
chown root:messagebus ${D}${libexecdir}/dbus-daemon-launch-helper
chmod 4755 ${D}${libexecdir}/dbus-daemon-launch-helper
Cheers,
Brandon
[-- Attachment #2: Type: text/html, Size: 2591 bytes --]
^ permalink raw reply related [flat|nested] 3+ messages in thread
end of thread, other threads:[~2012-02-16 21:30 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-02-15 23:21 Problem building core-image-basic: Cannot create symlink from ./var/run to 'volatile/run' Brandon Stafford
2012-02-16 0:36 ` Mark Hatle
2012-02-16 21:21 ` Brandon Stafford
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.