summaryrefslogtreecommitdiffstats
path: root/meta/recipes-core/initscripts/initscripts-1.0
Commit message (Collapse)AuthorAgeFilesLines
...
* initscripts: overwrite default hostname.shJackie Huang2013-07-101-2/+10
| | | | | | | | | | | | | | | | | | | /etc/init.d/hostname.sh does not have a graceful fallback if the /etc/hostname file doesn't exist. Other systems such as Ubuntu and RH will either leave the hostname in place, if a proper hostname is already set, otherwise it will set the hostname to 'localhost' when the /etc/hostname files doesn't exist. As you can see we have to add some additional handling to provide this behavior when the system's hostname command doesn't take the '-b' option. (From OE-Core rev: 09e59f1dad9fb52adb1717840837e42a36a6c7a1) Signed-off-by: Mark Asselstine <mark.asselstine@windriver.com> Signed-off-by: Jackie Huang <jackie.huang@windriver.com> Signed-off-by: Saul Wold <sgw@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* initscripts: let status return 0 when proc is running wellJesse Zhang2013-05-301-0/+1
| | | | | | | | | | | | | Ensure that the status returns 0 instead of the last shell command result, otherwise the calling script can not properly detect the status of pid. (From OE-Core rev: d9d4fdc769dfe6bf9838f5c5f3189a80f0e3cf90) Signed-off-by: Jesse Zhang <sen.zhang@windriver.com> Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Mark Hatle <mark.hatle@windriver.com> Signed-off-by: Saul Wold <sgw@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* base-files: add /run directory from FHS 3 draft specificationJonathan Liu2013-05-291-4/+3
| | | | | | | | | | | | | | | | | | | | This adds the /run directory from the Filesystem Hierarchy Standard 3.0 Draft [1] and refactors the filesystem as follows: - Remove creation of /var/volatile/run - Remove creation of /var/volatile/lock - Remove symbolic link from /var/run to /var/volatile/run - Remove symbolic link from /var/lock to /var/volatile/lock - Add symbolic link from /var/run to /run - Add symbolic link from /var/lock -> /run/lock - Add /run to /etc/fstab for sysvinit compatibility [1] http://www.linuxbase.org/betaspecs/fhs/fhs.html#runRuntimeVariableData (From OE-Core rev: 0e326280a15b0f2c4ef2ef4ec441f63f55b75873) Signed-off-by: Jonathan Liu <net147@gmail.com> Signed-off-by: Saul Wold <sgw@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* populate-volatile.sh: remove repeated leading slashes in TNAMEJonathan Liu2013-05-241-7/+7
| | | | | | | | | | | | | | | | This avoids triple slashes in the generated /etc/volatile.cache to reduce disk usage and in the output when verbose mode is enabled. As all the paths for volatiles start with a slash, we can change TNAME=${ROOT_DIR}/${TNAME} to TNAME=${ROOT_DIR}${TNAME}. To avoid a double slash when ROOT_DIR is /, we strip the extra slash from ROOT_DIR. (From OE-Core rev: af56670f656ec0989aa7fd6cf6037cbc9cd88185) Signed-off-by: Jonathan Liu <net147@gmail.com> Signed-off-by: Saul Wold <sgw@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* initscripts: fix read-only-rootfs-hook.sh to start earlierPaul Eggleton2013-04-101-0/+1
| | | | | | | | | | | Mount /var/volatile ourselves so that we can set up the writable area first. This fixes the urandom service not starting properly when read-only-rootfs is enabled. (From OE-Core rev: 44c7d8a27a84a04251408e9a7d9550629bc17704) Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* initscripts: fix read-only-rootfs-hook.sh to avoid using unionfsPaul Eggleton2013-04-101-11/+4
| | | | | | | | | | | Unionfs isn't available everywhere, and we can get similar results (if not quite as neatly) by using bind mounts + tmpfs and copying the data over. (From OE-Core rev: 5a8ba93efa554c3b4d3b48ca8d668419a8c77f42) Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* udev: move /run volatile entry to udev instead of initscriptsRoss Burton2013-03-261-1/+0
| | | | | | | | | | | | | | | | initscripts is generally installed on systemd-using images, but because it specifies that /run is a symlink to /var/run managed by volatiles it totally breaks systemd by copying/deleting /run from underneath systemd. Deleting sockets mid-boot doesn't leave systemd in a happy place. As this volatile reference of /run was introduced by udev 182, move it's reference to the udev recipe. This way it will never be present on systemd images, as systemd manages /run as a tmpfs itself. (From OE-Core rev: 5b0257e318340c2d6c8d3b0c3fa32272d6e9526b) Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* populate-volatile.sh: remove trailing whitespacesChen Qi2013-03-071-3/+3
| | | | | | | | | | Remove trailing whitespaces. (From OE-Core rev: 082dca6f73858581863f103b467ff73cebe2c0da) Signed-off-by: Chen Qi <Qi.Chen@windriver.com> Signed-off-by: Saul Wold <sgw@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* populate-volatile.sh: improve the handling of link config itemsChen Qi2013-03-071-16/+21
| | | | | | | | | | | | | | | | | | | | | | | | Previously, if there's a link config item in the config file like l root root 1777 /tmp /var/tmp and /tmp has existed, the symlink will not be created correctly. Another example is the /run directory. If /run directory has been created by some recipe or script before populate-volatile.sh runs, the symlink of /run to /var/run will not be created correctly. This patch ensures that the system creates symlinks exactly as the config file tells it. [YOCTO #3404] [YOCTO #3406] (From OE-Core rev: a54287d8e3d75a727c8ed5654a822bda256b0849) Signed-off-by: Chen Qi <Qi.Chen@windriver.com> Signed-off-by: Saul Wold <sgw@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* populate-volatile.sh: add ROOT_DIR variable to support running at rootfs timeChen Qi2013-03-071-17/+45
| | | | | | | | | | | | | | | | | | | | | | | | For populate-volatile.sh script to run correctly both at rootfs time and at system boot time, it needs to be aware of which situation it is now in. We use the ROOT_DIR variable to indicate whether it is run at rootfs time or not. ROOT_DIR being "/" indicates that this script is run at system boot time, otherwise, it is run at rootfs time. Also, we ignore failures when running this script at rootfs time. For example, if ${ROOT_DIR}/var/dir1 is symlink to /var/volatile/dir1, it's possible that the link is a dead link. So if we're going to create some file under ${ROOT_DIR}/var/dir1, it will fail. But the failure does no harm, because this script will always run at system boot time to set up the correct files and directories. [YOCTO #3406] (From OE-Core rev: 45396e3edcce4a33fcbef6456f31811f30c26c63) Signed-off-by: Chen Qi <Qi.Chen@windriver.com> Signed-off-by: Saul Wold <sgw@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* initscripts: Add status function to /etc/init.d/functionsJesse Zhang2013-02-081-0/+15
| | | | | | | | | | | | | | [ CQID: WIND00388860 ] Many initscripts want a simple way to display status information. Add the 'status' function to the functions file. (From OE-Core rev: adcb39845b6d3af9472fa5051a1d918344eb6bda) Signed-off-by: Jesse Zhang <sen.zhang@windriver.com> Signed-off-by: Mark Hatle <mark.hatle@windriver.com> Signed-off-by: Saul Wold <sgw@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* initiscripts: Fix populate-volatiles.sh whitespaceRichard Purdie2013-02-061-110/+97
| | | | | | (From OE-Core rev: d69935fbef2b5a8b187e58ac5ade0ffb9f95f803) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* initscripts: remove /var/cache from volatilesLaurentiu Palcu2013-02-061-2/+0
| | | | | | | (From OE-Core rev: 961376bf34dbc65e649c3fe6f2d9e1838d987aef) Signed-off-by: Laurentiu Palcu <laurentiu.palcu@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* initscripts: add read-only-rootfs-hook.sh scriptChen Qi2013-02-061-0/+19
| | | | | | | | | | | | | | Add read-only-rootfs-hook.sh script to support a read-only rootfs. This script makes a union mount of /var/lib and /var/volatile/lib, making /var/lib directory writable. [YOCTO #3406] (From OE-Core rev: a9591158962eee1f8ae04168d6256032ecd7bc6b) Signed-off-by: Chen Qi <Qi.Chen@windriver.com> Signed-off-by: Saul Wold <sgw@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* initscripts: let populate-volatile.sh create the /tmp linkChen Qi2013-02-062-8/+2
| | | | | | | | | | | | | | | | | | | | | | Previously, the /tmp link (/tmp -> /var/tmp) was created by the bootmisc.sh script. So in case of a read-only rootfs, this symlink would not be created correctly. The populate-volatile.sh script is intended to handle all directories and files related to volatile storage, so we should let it create the /tmp link. In addition, because of the improments of populate-volatile.sh, the data loss problem of bug#3404 is also resolved by this patch. [YOCTO #3406] [YOCTO #3404] (From OE-Core rev: 12c4acd7ac5a27cf3676065b60f1c8395c96854c) Signed-off-by: Chen Qi <Qi.Chen@windriver.com> Signed-off-by: Saul Wold <sgw@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* initscripts: remove finish.shChen Qi2013-01-151-14/+0
| | | | | | | | | | Remove finish.sh from initscripts as it is no longer used. (From OE-Core rev: 3bcd9188f919da1b10f692d29ef34cd18ef88184) Signed-off-by: Chen Qi <Qi.Chen@windriver.com> Signed-off-by: Saul Wold <sgw@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* replace portmap with rpcbind.Roy.Li2012-12-311-8/+8
| | | | | | | | | | | Rpcbind has more features, like ipv6 support and nfs4 support; Redhat, Fedora, debian, Ubuntu are using rpcbind by default. (From OE-Core rev: 86ec57e2837465954f51fc55fce990b5ec6b1063) Signed-off-by: Roy.Li <rongqing.li@windriver.com> Signed-off-by: Saul Wold <sgw@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* udev: upgrade to 182Alexandru DAMIAN2012-10-251-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This is the final upgrade of udev. Futher upgrades will only come in conjunction with systemd. The v4l1 removal patch is deprecated as the bug is fixed inside udev. There is a new patch fixing the path for default sh interpreter. New debug binaries are generated, and udev.inc is modified to package those correctly. The install locations changed for udevd and udevadm, so the scripts are updated accordingly. (From OE-Core rev: 3cbe52b94c4d559a037347ac419fafee5af84fe6) (From OE-Core rev: 8fc73baecf1b21b1a3e7eff478e25d2a7cae2879) Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Conflicts: meta/recipes-core/udev/udev_164.bb sgw - Fixed up DEPENDS += and added some OECONF options that where in the meta-oe version and make sense to be included. Signed-off-by: Saul Wold <sgw@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* initscripts/sysfs.sh: mount debugfs if presentTom Zanussi2012-09-241-0/+4
| | | | | | | | | | debugfs is another kernel virtual file system that should be mounted if configured, so if it's configured into the kernel, mount it. (From OE-Core rev: 55c4d3c55e4c3a7c2cda6d006cf7b78567bd3298) Signed-off-by: Tom Zanussi <tom.zanussi@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* initscripts: don't bg mk_dirs in populate-volatileChristopher Larson2012-07-261-2/+2
| | | | | | | | | | | | | | | | If a directory needs to be created to create something else in volatiles, there's no guarantees on ordering due to the backgrounding. We can't guarantee with certainty that the create directory commands are complete before the later ones run. This ensures that we wait for directory creations to complete before we proceed. Chris Hallinan hit an actual failure due to this back in March of last year. (From OE-Core rev: 138c3c26830e48a56ca7cb3e5feca324d13ec89c) Signed-off-by: Christopher Larson <chris_larson@mentor.com> Signed-off-by: Saul Wold <sgw@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* initscripts: test whether /etc/init.d/hwclock.sh existsAndreas Oberritter2012-03-131-2/+2
| | | | | | | | | | * bootmisc.sh executes /etc/init.d/hwclock.sh, which is optional (depends on CONFIG_HWCLOCK in busybox). (From OE-Core rev: 9c8300f030b69652ad39e1bc2979f5d9a03adf1e) Signed-off-by: Andreas Oberritter <obi@opendreambox.org> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* initscripts: Create the volatiles cache atomically.James Limbouris2012-03-021-4/+6
| | | | | | | | | | | If a machine loses power while building the volatiles cache, it will continue to operate with an incomplete set of volatiles. Fix this by updating atomically. (From OE-Core rev: a60432ff4588390f5f955a6da234298e958546e6) Signed-off-by: James Limbouris <james@digitalmatter.com.au> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* initscripts: Properly format date when set from timestampGary Thomas2012-03-011-1/+1
| | | | | | | | | Reformat date, as stored in /etc/timestamp, to match CLI format. (From OE-Core rev: 7aa4c51089cc4a2811bd11842647839d1e4b1e95) Signed-off-by: Gary Thomas <gary@mlbassoc.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* initscripts: mount and unmount cifs network filesystemsAndreas Oberritter2012-02-242-2/+8
| | | | | | | | | * Added cifs to mountnfs.sh and umountnfs.sh. (From OE-Core rev: c44e51f281101c8933679f679e3d4a75a41bedf7) Signed-off-by: Andreas Oberritter <obi@opendreambox.org> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* initscripts: Make /etc/timestamp consistent again.Gary Thomas2012-02-232-3/+3
| | | | | | | | | | | | | | | | | Commit cc8695 changed the way timestamps were handled and added some extra munging to be able to compare them reliably. This change makes the timestamp value the same everywhere and simplifies how the check to set the system clock based on the timestamp is done. Also, if the value stored in /etc/timestamp is newer [at all] than the current system time, set the system clock from the stored value, down to the minute, not just the day. (From OE-Core rev: 5aab6653c9afa05e7c1b3ccd6bd34aec05c2a6f8) Signed-off-by: Gary Thomas <gary@mlbassoc.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* initscripts: remove space from shebang, just cosmeticsMartin Jansa2012-01-249-9/+9
| | | | | | | | | * at least in initscripts it's consistent now (From OE-Core rev: 20d5effcf192d469883b5ac899cbd2340b71bd2c) Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* initscripts: add shebang where it was missing completelyMartin Jansa2012-01-247-0/+7
| | | | | | | (From OE-Core rev: d58fc7a3ccede8706bf6a6aa7f7301f716128db8) Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* initscripts: avoid mounting /sys if it is already mountedOtavio Salvador2012-01-061-2/+2
| | | | | | | (From OE-Core rev: fdb3d74458cd36a0fe53ee097394acc37d658ce9) Signed-off-by: Otavio Salvador <otavio@ossystems.com.br> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* initscripts: fix timestamp checking at bootmisc.shLauri Hintsala2011-12-151-4/+3
| | | | | | | | | | | | Timestamp checking has been broken by the commit 2078af333d704fd894a2dedbc19cef5775cdadbb. Currently the RTC time is always overwritten with the time from /etc/timestmap. Fix timestamp checking and clean the code. (From OE-Core rev: cc8695f22bc70ef958f81d0d3da73dece5f4700a) Signed-off-by: Lauri Hintsala <lauri.hintsala@bluegiga.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* The Skeleton initscript doesn't work on minimal imageRobert Yang2011-08-151-2/+3
| | | | | | | | | | | | | Fixes bug [YOCTO #1165] The /etc/init.d/skeleton doesn't work on minimal image, this is because of the pidofproc doesn't return "$?" correctly, so store $? in the variable status would fix it. (From OE-Core rev: 4d31193a6969df25bb85a9862b7295e85dcec04b) Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* Add pidofproc to ${sysconfdir}/init.d/functionsRobert Yang2011-05-181-2/+30
| | | | | | | | | | | Add pidofproc to ${sysconfdir}/init.d/functions, this is used for getting the pid of the process. It uses pidof to implement currently, it may also use the pidfile or ps to implement in the future. (From OE-Core rev: 114a11628fb04c30cc96c9fd23db7a7fbc4fd02e) Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* Cleanup the whitespace in functionsRobert Yang2011-05-181-5/+6
| | | | | | | | | | Cleanup the whitespace in functions, replace the 4 whitespaces indent with tab. (From OE-Core rev: 60df57a54ebfe8fa1c1574bcd7900c58810aa2d2) Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* Upstream-Status update for several recipesYu Ke2011-05-171-0/+2
| | | | | | | | | | | | | | | | - modutils - module-init-tools - libacpi - keymaps - initscripts - console-tools - mesa-demos - xserver-xf86-lite (From OE-Core rev: 46ea0444276c67b1489004e959bcf34970cd6c60) Signed-off-by: Yu Ke <ke.yu@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* initscripts: remove -i from halt/reboot arguments and allow overridePaul Eggleton2011-05-052-2/+2
| | | | | | | | | | | | | | Introduces a variable HALTARGS which specifies the arguments sent to halt and reboot, and sets the default value to "-d -f", dropping the previous -i (shut down all network interfaces before halt/reboot, which causes a freeze with NFS root.) Fixes [YOCTO #997]. (From OE-Core rev: ace183894a5319cd73c94fd2653bbe52f29dca0b) Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* initscripts: Drop outdated machine specific filesRichard Purdie2011-04-216-557/+0
| | | | Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* initscripts: Make umountfs a bit more robust, bump PRTom Rini2011-03-181-3/+3
| | | | | | | | | | | Avoids error messages on shutdown. Imported from OE commit 072cad0100fd828e7fee8f3fa3ade23e4306b394 (From OE-Core rev: 5188687660f5aa37014aac50c43e141f032455d7) Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* initscripts:Add a patch of GPLv2 license and its checksum to bb fileMei Lei2010-12-061-0/+345
| | | | | | Add this GPLv2 patch for local recipes license checksum Signed-off-by: Mei Lei <lei.mei@intel.com>
* image.bbclass/initscripts: Make /etc/timestamp usage consistent.Gary Thomas2010-11-142-5/+5
| | | | | | | | | | | | Timestamp is kept in UTC Remove superfluous 'create_etc_timestamp()' function - seems to be a duplicate of 'rootfs_update_timestamp()' Remove External function reference [sgw@linux.intel.com: merged 2 patches and cleanup commit message] Signed-off-by: Gary Thomas <gary@mlbassoc.com> Signed-off-by: Saul Wold <sgw@linux.intel.com>
* bootmisc.h: use "date -s" to set timeKevin Tian2010-09-031-1/+1
| | | | | | | | | | without "-s", 201009031653 would be interpreted incorrectly by date and then we saw below warning: date: invalid date 165320100903 Fix [BUGID #265] Signed-off-by: Kevin Tian <kevin.tian@intel.com>
* Major layout change to the packages directoryRichard Purdie2010-08-2731-0/+1729
Having one monolithic packages directory makes it hard to find things and is generally overwhelming. This commit splits it into several logical sections roughly based on function, recipes.txt gives more information about the classifications used. The opportunity is also used to switch from "packages" to "recipes" as used in OpenEmbedded as the term "packages" can be confusing to people and has many different meanings. Not all recipes have been classified yet, this is just a first pass at separating things out. Some packages are moved to meta-extras as they're no longer actively used or maintained. Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>