User:Ixo/Script/xo-update: Difference between revisions
Jump to navigation
Jump to search
m (User:Ixo/Script/ixo-update moved to User:Ixo/Script/xo-update) |
m (ixo -> xo) |
||
Line 1: | Line 1: | ||
Summary |
Summary |
||
<onlyinclude> |
<onlyinclude> |
||
* |
* xo-update: Do an olpc-update to specific build (joyride or Update), log results. |
||
</onlyinclude> |
</onlyinclude> |
||
Description |
Description |
||
Line 14: | Line 14: | ||
#!/bin/bash |
#!/bin/bash |
||
## FILE: |
## FILE: xo-update ###### |
||
# 2008 01 10, Iain D, ixo AT myna DOT ws |
# 2008 01 10, Iain D, ixo AT myna DOT ws |
||
## RELEASED under CC-BY-SA-NC 3.0 license. |
## RELEASED under CC-BY-SA-NC 3.0 license. |
||
ver="update.1- |
ver="update.1-696" |
||
cd ~olpc |
cd ~olpc |
||
echo "------- $ver -------------------------------------" |
echo "------- $ver -------------------------------------" |
||
Line 23: | Line 23: | ||
# Below is various system information nice to log before the update |
# Below is various system information nice to log before the update |
||
# (aka xo-info) |
# (aka xo-info) |
||
grep -v "garbage-to-ignore" /etc/issue /boot/olpc_build |
grep -v "garbage-to-ignore" /etc/issue /boot/olpc_build /versions/pristine/*/boot/olpc_build |
||
ls -Ld /versions/* /versions/contents/* /versions/pristine/* /versions/configs/* |
ls -Ld /versions/* /versions/contents/* /versions/pristine/* /versions/configs/* |
||
ls -ld /versions/running /versions/boot |
ls -ld /versions/running /versions/boot |
||
Line 36: | Line 36: | ||
#!/bin/bash |
#!/bin/bash |
||
## FILE: |
## FILE: xo-update-record ####### |
||
# 2008 01 12, Iain D, ixo AT myna DOT ws |
# 2008 01 12, Iain D, ixo AT myna DOT ws |
||
## RELEASED under CC-BY-SA-NC 3.0 license. |
## RELEASED under CC-BY-SA-NC 3.0 license. |
||
/home/olpc/bin/ |
/home/olpc/bin/xo-update >>update-log-$$.out 2>>update-log-$$.out |
||
NOTES: |
NOTES: |
||
* Assumed that scripts are in /home/olpc/bin , both have 'x' execute bit set. |
* Assumed that scripts are in /home/olpc/bin , both have 'x' execute bit set. |
||
* Currently need to set manually the version number '''update.1- |
* Currently need to set manually the version number '''update.1-696''' to update, future feature is passing it along, or picking from list (or latest). |
Revision as of 11:38, 16 February 2008
Summary
- xo-update: Do an olpc-update to specific build (joyride or Update), log results.
Description
- Log various system information during an olpc-update for later examination
Benefits
- Creates permanent record and timing of update, for later viewing.
First script:
#!/bin/bash ## FILE: xo-update ###### # 2008 01 10, Iain D, ixo AT myna DOT ws ## RELEASED under CC-BY-SA-NC 3.0 license. ver="update.1-696" cd ~olpc echo "------- $ver -------------------------------------" date # Below is various system information nice to log before the update # (aka xo-info) grep -v "garbage-to-ignore" /etc/issue /boot/olpc_build /versions/pristine/*/boot/olpc_build ls -Ld /versions/* /versions/contents/* /versions/pristine/* /versions/configs/* ls -ld /versions/running /versions/boot # /usr/sbin/olpc-update $ver # date echo "------- ______________________ $ver"
Second script:
#!/bin/bash ## FILE: xo-update-record ####### # 2008 01 12, Iain D, ixo AT myna DOT ws ## RELEASED under CC-BY-SA-NC 3.0 license. /home/olpc/bin/xo-update >>update-log-$$.out 2>>update-log-$$.out
NOTES:
- Assumed that scripts are in /home/olpc/bin , both have 'x' execute bit set.
- Currently need to set manually the version number update.1-696 to update, future feature is passing it along, or picking from list (or latest).