<feed xmlns='http://www.w3.org/2005/Atom'>
<title>openembedded-core.git/meta/recipes-core/initscripts/initscripts-1.0, branch pyro</title>
<subtitle>Mirror of openembedded-core</subtitle>
<link rel='alternate' type='text/html' href='https://git.multitech.net/cgit/openembedded-core.git/'/>
<entry>
<title>initscripts/sysfs.sh: mount configfs if present</title>
<updated>2017-03-01T12:54:20+00:00</updated>
<author>
<name>Mike Looijmans</name>
<email>mike.looijmans@topic.nl</email>
</author>
<published>2017-02-22T14:32:09+00:00</published>
<link rel='alternate' type='text/html' href='https://git.multitech.net/cgit/openembedded-core.git/commit/?id=4f52130475d026c32f0380d301f56f6fa3df7ac9'/>
<id>4f52130475d026c32f0380d301f56f6fa3df7ac9</id>
<content type='text'>
configfs is another kernel virtual file system that should be mounted
if configured, so if it's configured into the kernel, mount it. It is
used to configure e.g. USB gadget mode and devicetree overlays.

Signed-off-by: Mike Looijmans &lt;mike.looijmans@topic.nl&gt;
Signed-off-by: Ross Burton &lt;ross.burton@intel.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
configfs is another kernel virtual file system that should be mounted
if configured, so if it's configured into the kernel, mount it. It is
used to configure e.g. USB gadget mode and devicetree overlays.

Signed-off-by: Mike Looijmans &lt;mike.looijmans@topic.nl&gt;
Signed-off-by: Ross Burton &lt;ross.burton@intel.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>initscripts: populate-volatile: suppress read-only-rootfs warnings</title>
<updated>2016-12-22T08:46:37+00:00</updated>
<author>
<name>André Draszik</name>
<email>adraszik@tycoint.com</email>
</author>
<published>2016-12-20T09:02:40+00:00</published>
<link rel='alternate' type='text/html' href='https://git.multitech.net/cgit/openembedded-core.git/commit/?id=765ee275f5499254b1f09e394c757072bea5f459'/>
<id>765ee275f5499254b1f09e394c757072bea5f459</id>
<content type='text'>
rm: can't remove '/etc/resolv.conf': Read-only file system
ln: /etc/resolv.conf: File exists

/etc/default/volatiles contains an entry:
l root root 0644 /etc/resolv.conf /var/run/resolv.conf

which causes populate-volatile.sh to execute the following in link_file():
  if [ -L \"$2\" ]; then
    [ \"\$(readlink -f \"$2\")\" != \"\$(readlink -f \"$1\")\" ] &amp;&amp; { rm -f \"$2\"; ln -sf \"$1\" \"$2\"; };
  elif [ -d \"$2\" ]; then
    ...

At the time the image is created, /etc/resolv.conf is already a
symlink to /var/run/resolv.conf, but at boot time when
populate-volatiles.sh is run, /var/run/resolv.conf doesn't
exist, causing it to try to rm -f and ln -sf which of course
fails due to the read-only filesystem.

[YOCTO #10814]

Signed-off-by: André Draszik &lt;adraszik@tycoint.com&gt;
Signed-off-by: Ross Burton &lt;ross.burton@intel.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
rm: can't remove '/etc/resolv.conf': Read-only file system
ln: /etc/resolv.conf: File exists

/etc/default/volatiles contains an entry:
l root root 0644 /etc/resolv.conf /var/run/resolv.conf

which causes populate-volatile.sh to execute the following in link_file():
  if [ -L \"$2\" ]; then
    [ \"\$(readlink -f \"$2\")\" != \"\$(readlink -f \"$1\")\" ] &amp;&amp; { rm -f \"$2\"; ln -sf \"$1\" \"$2\"; };
  elif [ -d \"$2\" ]; then
    ...

At the time the image is created, /etc/resolv.conf is already a
symlink to /var/run/resolv.conf, but at boot time when
populate-volatiles.sh is run, /var/run/resolv.conf doesn't
exist, causing it to try to rm -f and ln -sf which of course
fails due to the read-only filesystem.

[YOCTO #10814]

Signed-off-by: André Draszik &lt;adraszik@tycoint.com&gt;
Signed-off-by: Ross Burton &lt;ross.burton@intel.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>initscripts: populate-volatile: don't run commands in background</title>
<updated>2016-12-22T08:46:36+00:00</updated>
<author>
<name>Mans Rullgard</name>
<email>mans@mansr.com</email>
</author>
<published>2016-12-16T16:28:38+00:00</published>
<link rel='alternate' type='text/html' href='https://git.multitech.net/cgit/openembedded-core.git/commit/?id=bead9e59768209dd70f9cba51d2f1e5925cc284d'/>
<id>bead9e59768209dd70f9cba51d2f1e5925cc284d</id>
<content type='text'>
If commands are run asynchronously they may be completed out of
order causing problems if later entries depend on earlier ones.

Signed-off-by: Mans Rullgard &lt;mans@mansr.com&gt;
Signed-off-by: Ross Burton &lt;ross.burton@intel.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
If commands are run asynchronously they may be completed out of
order causing problems if later entries depend on earlier ones.

Signed-off-by: Mans Rullgard &lt;mans@mansr.com&gt;
Signed-off-by: Ross Burton &lt;ross.burton@intel.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>initscripts: populate-volatile: improve config file parsing</title>
<updated>2016-12-13T22:47:26+00:00</updated>
<author>
<name>Mans Rullgard</name>
<email>mans@mansr.com</email>
</author>
<published>2016-12-01T12:30:34+00:00</published>
<link rel='alternate' type='text/html' href='https://git.multitech.net/cgit/openembedded-core.git/commit/?id=415eaacb83b1c6df5210fb423e3e96e530b1dc42'/>
<id>415eaacb83b1c6df5210fb423e3e96e530b1dc42</id>
<content type='text'>
This improves the config file parsing to permit blank lines and
comments following an entry or preceeded by whitespace.

Signed-off-by: Mans Rullgard &lt;mans@mansr.com&gt;
Signed-off-by: Ross Burton &lt;ross.burton@intel.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This improves the config file parsing to permit blank lines and
comments following an entry or preceeded by whitespace.

Signed-off-by: Mans Rullgard &lt;mans@mansr.com&gt;
Signed-off-by: Ross Burton &lt;ross.burton@intel.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>initscripts: Check for logrotate in dmesg.sh</title>
<updated>2016-08-23T16:44:05+00:00</updated>
<author>
<name>Ovidiu Vancea</name>
<email>ovidiu.vancea@ni.com</email>
</author>
<published>2016-08-12T15:04:12+00:00</published>
<link rel='alternate' type='text/html' href='https://git.multitech.net/cgit/openembedded-core.git/commit/?id=277a5975d43125623b5a51ddcb48f9ee2474d0fc'/>
<id>277a5975d43125623b5a51ddcb48f9ee2474d0fc</id>
<content type='text'>
Autodetect previously hardcoded logrotate location because it can be
installed in multiple places like /usr/bin/logrotate which is very
common besides /usr/sbin

Signed-off-by: Ovidiu Vancea &lt;ovidiu.vancea@ni.com&gt;
Signed-off-by: Ioan-Adrian Ratiu &lt;adrian.ratiu@ni.com&gt;
Signed-off-by: Ross Burton &lt;ross.burton@intel.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Autodetect previously hardcoded logrotate location because it can be
installed in multiple places like /usr/bin/logrotate which is very
common besides /usr/sbin

Signed-off-by: Ovidiu Vancea &lt;ovidiu.vancea@ni.com&gt;
Signed-off-by: Ioan-Adrian Ratiu &lt;adrian.ratiu@ni.com&gt;
Signed-off-by: Ross Burton &lt;ross.burton@intel.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>initscripts: check if swapon/swapoff exists before executing them</title>
<updated>2016-05-30T08:30:33+00:00</updated>
<author>
<name>Ming Liu</name>
<email>peter.x.liu@external.atlascopco.com</email>
</author>
<published>2016-05-26T21:14:33+00:00</published>
<link rel='alternate' type='text/html' href='https://git.multitech.net/cgit/openembedded-core.git/commit/?id=2cb1142710cc2beb762c4c2b8edd44d3a97dafa0'/>
<id>2cb1142710cc2beb762c4c2b8edd44d3a97dafa0</id>
<content type='text'>
Not all built images contain swapon/swapoff, for instance, it is
configurable with or without them in busybox. So it'd better to check if
they exist or not before executing them.

Redirecting the potential errors to /dev/null is not good enough, which
might suppress the *real* errors.

Signed-off-by: Ming Liu &lt;peter.x.liu@external.atlascopco.com&gt;
Signed-off-by: Ross Burton &lt;ross.burton@intel.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Not all built images contain swapon/swapoff, for instance, it is
configurable with or without them in busybox. So it'd better to check if
they exist or not before executing them.

Redirecting the potential errors to /dev/null is not good enough, which
might suppress the *real* errors.

Signed-off-by: Ming Liu &lt;peter.x.liu@external.atlascopco.com&gt;
Signed-off-by: Ross Burton &lt;ross.burton@intel.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>initscripts: populate-volatiles.sh: add mount-bind feature</title>
<updated>2016-02-13T08:27:17+00:00</updated>
<author>
<name>Jens Rehsack</name>
<email>rehsack@gmail.com</email>
</author>
<published>2016-02-12T09:17:32+00:00</published>
<link rel='alternate' type='text/html' href='https://git.multitech.net/cgit/openembedded-core.git/commit/?id=ab42fcaf1427a29c31ac2e93965e20849b1b1234'/>
<id>ab42fcaf1427a29c31ac2e93965e20849b1b1234</id>
<content type='text'>
Add ability to run "mount --bind" to populate-volatiles. Since several
programs use realpath to determine several full qualified file names,
there is no symlink to be resolved. So when speccing /run/lock - that's
the location - not /var/run/lock because of the program is smarter
than the operator/distributor.

See https://github.com/rehsack/meta-jens/blob/jethro/recipes-core/initscripts/initscripts/volatiles
for an example how to use the "b" feature.

Signed-off-by: Jens Rehsack &lt;sno@netbsd.org&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Add ability to run "mount --bind" to populate-volatiles. Since several
programs use realpath to determine several full qualified file names,
there is no symlink to be resolved. So when speccing /run/lock - that's
the location - not /var/run/lock because of the program is smarter
than the operator/distributor.

See https://github.com/rehsack/meta-jens/blob/jethro/recipes-core/initscripts/initscripts/volatiles
for an example how to use the "b" feature.

Signed-off-by: Jens Rehsack &lt;sno@netbsd.org&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>initscripts: hide the error in case system is not writeable</title>
<updated>2015-12-01T21:31:00+00:00</updated>
<author>
<name>Ming Liu</name>
<email>peter.x.liu@external.atlascopco.com</email>
</author>
<published>2015-11-23T22:12:38+00:00</published>
<link rel='alternate' type='text/html' href='https://git.multitech.net/cgit/openembedded-core.git/commit/?id=463bef8b055f8305b7aac5045fefe4276b1432ad'/>
<id>463bef8b055f8305b7aac5045fefe4276b1432ad</id>
<content type='text'>
To avoid reporting errors for /etc/timestamp is not writeable in a
readonly system.

Reported-by: Niklas Soderlund &lt;niklas.soderlund@external.atlascopco.com&gt;
Signed-off-by: Ming Liu &lt;peter.x.liu@external.atlascopco.com&gt;
Signed-off-by: Ross Burton &lt;ross.burton@intel.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
To avoid reporting errors for /etc/timestamp is not writeable in a
readonly system.

Reported-by: Niklas Soderlund &lt;niklas.soderlund@external.atlascopco.com&gt;
Signed-off-by: Ming Liu &lt;peter.x.liu@external.atlascopco.com&gt;
Signed-off-by: Ross Burton &lt;ross.burton@intel.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>initscripts/sysfs.sh: Mount devtmpfs on /dev/ if needed</title>
<updated>2015-10-24T11:19:36+00:00</updated>
<author>
<name>Mike Looijmans</name>
<email>mike.looijmans@topic.nl</email>
</author>
<published>2015-10-20T06:43:47+00:00</published>
<link rel='alternate' type='text/html' href='https://git.multitech.net/cgit/openembedded-core.git/commit/?id=a1cfb8a2691ed36700c96cbc1a0e744494294d2b'/>
<id>a1cfb8a2691ed36700c96cbc1a0e744494294d2b</id>
<content type='text'>
When booting from an initrd disk, or when the kernel config option
DEVTMPFS_MOUNT isn't provided, /dev/ will not be mounted at boot.

This small addition will check if /dev/ is "useful", and if not, will
mount devtmpfs if the kernel provides it.

With this change, it is possible to set an initscripts style image type
to "cpio.gz" and boot it as initrd. Without this change, the image won't
work properly because of the missing devices.

Signed-off-by: Mike Looijmans &lt;mike.looijmans@topic.nl&gt;
Signed-off-by: Ross Burton &lt;ross.burton@intel.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
When booting from an initrd disk, or when the kernel config option
DEVTMPFS_MOUNT isn't provided, /dev/ will not be mounted at boot.

This small addition will check if /dev/ is "useful", and if not, will
mount devtmpfs if the kernel provides it.

With this change, it is possible to set an initscripts style image type
to "cpio.gz" and boot it as initrd. Without this change, the image won't
work properly because of the missing devices.

Signed-off-by: Mike Looijmans &lt;mike.looijmans@topic.nl&gt;
Signed-off-by: Ross Burton &lt;ross.burton@intel.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>initscripts: Fix regression for requiring /bin/bash</title>
<updated>2015-08-09T22:14:30+00:00</updated>
<author>
<name>Jason Wessel</name>
<email>jason.wessel@windriver.com</email>
</author>
<published>2015-08-06T19:35:53+00:00</published>
<link rel='alternate' type='text/html' href='https://git.multitech.net/cgit/openembedded-core.git/commit/?id=4917e36a77bd6821b45db52caa43939d344d92f6'/>
<id>4917e36a77bd6821b45db52caa43939d344d92f6</id>
<content type='text'>
It is not possible to create a rootfs with only busybox + initscipts.
This is a result of a regression from commit
a4b53872a8a9a2743299acbff015f7f2750a69d6 (initscripts: add
/sbin/sushell for systemd service debug-shell).

The /sbin/sushell should just use /bin/sh else you end up with a
problem when creating the end image with a failed smart transaction
shown below:

ERROR: Unable to install packages. Command '/proj/bitbake_build/tmp/sysroots/x86_64-linux/usr/bin/smart --quiet --data-dir=/proj/bitbake_build/tmp/work/qemuarma9-wrs-linux-gnueabi/wrlinux-image-glibc-small/1.0-r1/rootfs/var/lib/smart install -y dropbear@armv7at2_vfp hac@armv7at2_vfp run-postinsts@all kernel-modules@qemuarma9 packagegroup-core-boot@qemuarma9' returned 1:
error: Can't install initscripts-1.0-r155.0@armv7at2_vfp: no package provides /bin/bash

Signed-off-by: Jason Wessel &lt;jason.wessel@windriver.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
It is not possible to create a rootfs with only busybox + initscipts.
This is a result of a regression from commit
a4b53872a8a9a2743299acbff015f7f2750a69d6 (initscripts: add
/sbin/sushell for systemd service debug-shell).

The /sbin/sushell should just use /bin/sh else you end up with a
problem when creating the end image with a failed smart transaction
shown below:

ERROR: Unable to install packages. Command '/proj/bitbake_build/tmp/sysroots/x86_64-linux/usr/bin/smart --quiet --data-dir=/proj/bitbake_build/tmp/work/qemuarma9-wrs-linux-gnueabi/wrlinux-image-glibc-small/1.0-r1/rootfs/var/lib/smart install -y dropbear@armv7at2_vfp hac@armv7at2_vfp run-postinsts@all kernel-modules@qemuarma9 packagegroup-core-boot@qemuarma9' returned 1:
error: Can't install initscripts-1.0-r155.0@armv7at2_vfp: no package provides /bin/bash

Signed-off-by: Jason Wessel &lt;jason.wessel@windriver.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
</feed>
