Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 124011 Details for
Bug 184355
sys-cluster/gm-2.0.26 (New Package)
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
gm-init.d
gm-init.d (text/plain), 3.32 KB, created by
Justin Bronder (RETIRED)
on 2007-07-05 21:14:45 UTC
(
hide
)
Description:
gm-init.d
Filename:
MIME Type:
Creator:
Justin Bronder (RETIRED)
Created:
2007-07-05 21:14:45 UTC
Size:
3.32 KB
patch
obsolete
>#!/sbin/runscript ># Copyright 1999-2005 Gentoo Foundation ># Distributed under the terms of the GNU General Public License v2 > >depend() { > need net > after ssh > before pbs_mom >} > >check_torque() { > local have_myri=0 > einfo "Checking with Torque to see if we have Myrinet" > hostname=$(hostname -s) > if [ ! -x /usr/bin/pbsnodes ]; then > ewarn "/usr/bin/pbsnodes cannot be executed! Assuming no Myrinet" > have_myri=0 > elif [ -n "$(/usr/bin/pbsnodes -a ${hostname} | egrep "${CHECK_TORQUE_REGEXP}")" ]; then > have_myri=1 > else > have_myri=0 > fi > > if [[ $have_myri -eq 0 ]]; then > einfo "Host doesn't have Myrinet, skipping" > return 0 > fi > return 1 >} > > > >start() { > ebegin "Starting GM Driver" > if [[ $USE_CHECK_TORQUE -ne 0 ]]; then > check_torque > if [[ $? -eq 0 ]]; then > eend 0 > return 0 > fi > fi > > if [ ! -x "/usr/bin/gm_board_info" ]; then > ewarn "GM Driver userland tools missing" > eend 1 > return 1 > fi > > /sbin/modprobe gm &>/dev/null > rc=${?} > if [[ ${rc} -ne 0 ]]; then > eend ${rc} "GM Module failed to load" > else > # We may have to wait a moment for these to appear > if [ ! -r /dev/gmp0 ]; then > sleep 2; > fi > # Doesn't matter if they don't though, you could use > # the udev rules in /etc/gm to avoid this. > if [ ! -r /dev/gmp0 ]; then > ewarn "/dev/gm* devices were not created, so I'll do it now" > for i in 0 1 2 3 4 5 6 7 ; do > mknod /dev/gm$i c 220 $(expr $i "*" 2) \ > && chmod --verbose 666 /dev/gm$i > /dev/null 2>&1 > mknod /dev/gmp$i c 220 $(expr $i "*" 2 + 1) \ > && chmod --verbose 600 /dev/gmp$i > /dev/null 2>&1 > done > fi > hostname=$(hostname -f) > /usr/bin/gm_set_name --host-name=$hostname >> /dev/null 2>&1 > rc=${?} > if [[ ${rc} -ne 0 ]]; then > ewarn "Failed to set the board's hostname" > fi > > # Boot the mapper if requested > if [[ $USE_GM_MAPPER -ne 0 ]]; then > einfo "Starting gm_mapper" > start-stop-daemon --start -p /var/run/gm_mapper.pid --exec /opt/gm/sbin/gm_mapper -- \ > --map-file-0=/var/run/gm_map.0 --daemon-pid-file=/var/run/gm_mapper.pid > rc=$? > if [[ ${rc} == 0 ]]; then > einfo "Waiting for gm_mapper to finish, (10s)" > for ((i=0;i<10;i++)); do > sleep 1 > echo -n " . " > done > else > ewarn "gm_mapper failed to start" > fi > fi > eend ${rc} > fi > return ${rc} > >} > >stop() { > ebegin "Stopping GM Driver" > if [[ $USE_CHECK_TORQUE -ne 0 ]]; then > check_torque > if [[ $? -eq 0 ]]; then > eend 0 > return 0 > fi > fi > > local rc=0 > if [[ $USE_GM_MAPPER -ne 0 ]] && [ -n "$(pidof gm_mapper)" ]; then > start-stop-daemon --stop -p /var/run/gm_mapper.pid > rc=$? > if [[ $rc -ne 0 ]]; then > ewarn "Stopping gm_mapper failed" > fi > fi > if [ -n "$( lsmod | grep -v 'Module' | awk '/^gm /{ print $1 }')" ]; then > /sbin/modprobe -r gm &>/dev/null > rc=${?} > eend ${rc} "GM Module failed to unload" > fi > return ${rc} >} ># vim:ts=4 >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 184355
:
124007
|
124008
| 124011