source: trunk/packages/vizservers/start_nanoscale.sh.in @ 2871

Last change on this file since 2871 was 2787, checked in by ldelgass, 13 years ago

lspci in RHEL 5.8 now reports the (correct) capitalization of NVIDIA, so use
case insensitive grep when counting NVIDIA VGA controllers.

File size: 749 bytes
RevLine 
[2343]1#! /bin/sh
2
3DISPLAY=:0
4export DISPLAY
5
6# Fail on errors
7set -e
8
9exec_prefix="@exec_prefix@"
10bindir="@bindir@"
11libdir="@libdir@"
12. ${bindir}/rappture.env
13
[2350]14# lspci is either in /sbin or /usr/sbin
15PATH=/sbin:/usr/sbin:${PATH}
16export PATH
17
[2343]18# Determine the number of video cards we have.  The new render server
19# motherboards have the useless XGI Volari onboard video controllers (no 3D
20# capabilities) so we have to make sure we count only the nVidia cards.
21
[2787]22numVideo=`lspci | fgrep VGA | fgrep -i NVIDIA | wc -l`
[2343]23
24# Don't let nanoscale and the visualization servers run away.  Limit cpu time
25# to 20 minutes.
26
27minutes=20
28ulimit -t $(expr ${minutes} \* 60 )
29
30# Make /tmp the current working dirctory.
31cd /tmp
32
[2348]33exec ${bindir}/nanoscale -x ${numVideo}
[2343]34
35
Note: See TracBrowser for help on using the repository browser.