User Tools

Site Tools


user:bmeehan1:start

osi0

For this project we had to put OpenBSD on desktops in the classroom. First we went and got the installer file from the openBSD website and loaded it onto a floppy disk. Then we set up all 8 desktops under the desk and hooked them up through a switch so that we could use 1 monitor and 1 keyboard for them all. Then we had to change some HDDs because a few were bad. Then we had to change a battery on one of the motherboards that runs the bios and then we had to add some RAM to a few desktops as well. When all was done we put the floppy in each computer and loaded the openBSD BIOS into the computer. We named all the computers versions of derp, setup IP addresses for each and allowed each of us to ssh into the computer when on the network. we had to make each of the computers numbers off by 1 for the ip addresses.

Web Ring Adventure

In class we decided to do a small project, similar to the web adventure project we did in UNUIX/LINUX. First, we made a basic html and an image made into a URL which pointed to the ip address of the next person. One would point to another and another and so on until the last person pointed back to the original. We used “a href” with a url to an image from the web and then the ip address embedded within that “a href” to the next person.

Class Time Script

We have been working on a script in class to be able to grab a users time logged into Lab46 and sort it. We are sorting it between time in class and time outside of class. We want to see how much time a user spends outside of class rather than in class. We also are sorting by the time that class starts and the time that class finishes so that it is not calculated into the time spent online and we can get a more accurate reading. (Lots of math.. lots..of..math).

Grub and Debian We installed Debian over top of OpenBSD today. After doing so we then set partitions for Debian, and OpenBSD to be installed on the same machine. Still having issues with getting Grub to recognize both OS and getting to choose one.

5/7/17 EOCE Primereg

Master Code

#!/bin/bash # # ##################################################################### ##################################################################### ## ## ## WARNING # # ## When running script I would HIGHLY recommend and appreciate ## ## if you ran this using all 8 pis. It just works…nicer. ## ## Ok, it just works in general :D ## ## ## ##################################################################### ##################################################################### # # ##################################################################### ## Setting the Units ## #####################################################################

      if [ -z $2 ]; then
              units=8
      else
               if [ $2 -le 8 ]; then
                      units=$2
              else
                      units=8
               fi
      fi

##################################################################### ## Setting the Range ## #####################################################################

      if [ -z ${4} ]; then
                      upper=1000
      else
                      upper=${4}
      fi

##################################################################### #####################################################################

      if [ -z $3 ]; then
                      start=2
      else
                      start=$3
      fi

##################################################################### ## Dividing the range into sections for each unit ## #####################################################################

      if [ ${upper} != ${start} ]; then
              newnum=$(echo "${upper}/${units}" | bc)
      fi

rm -f numbers rm -f time ##################################################################### ## Setting the Range and Units ## #####################################################################

groups=2 leftovers=0 start=2

let leftovers=$upper/$units let range=$upper/$units

for1); do

      nod=$i
      if [ $nod -gt 3 ]; then
              let nod=${nod}-4
      fi
              if [ $i -eq 4 ]; then
                      let groups=${groups}+1
              fi
                      let end=$start+$newnum-1
                      if [ $leftovers -gt 0 ]; then
                              let end=$end+1
                              let leftovers=$leftovers-1
                      fi
                              if [ $end -ge $upper ]; then
                                      let end=$upper-1
                              fi
      done

##################################################################### ## Incrementing Ranges for each Unit ## #####################################################################

begin=${start}

for pod in 2 3; do

              for num in 00 01 02 03; do
                      end=$(echo "${start}+(${newnum}-1)" | bc)
              echo "[pi${pod}_${num}] begin: ${begin} end: ${end}"
              echo -n "pi${pod}b_${num}" >> time
              ssh pi${pod}b_${num} ./primeregbs 0 1 ${begin} ${end} >> numbers                             2>> time
                      begin=$(echo "(${end}+1)" | bc)
                      let start=$end+1
              done

done

exit 0

PRIMEREG GRAPH

set title 'Prime Numbers' set xlabel 'Numbers on Pies' set ylabel 'Run Time'

set terminal png size 1000,800

unset key set tics out nomirror set border 3 front linetype black linewidth 1.0 dashtype solid

set xrange [1:8] set xtics 1, 100, 1001 set mxtics 1

set style line 1 linecolor rgb '#0060ad' linetype 1 linewidth 3

#plot 'numbers' using 1:($0+1) with lines linestyle 1 title 'data'

set yrange [0.0000:0.002] #set ytics 0.0000, 0.001 set mytics 1

plot 'time' using 2:xtic(1) with lines linestyle 1 title ' Run Times'

WORKER SCRIPT

#!/bin/bash ## ## ######################################################################### #########################################################################

podname=`hostname` begin=$1 end=$2

printf “Pod: %s Running: %6s-%-6s” $podname ${begin} ${end} #uptime | cut -d ',' -f1,2,4 | sed 's/^..*up /Uptime: /g'

#new line ./primeregbs #| cut -d ',' -f1,2,4 | sed 's/^..*up /Uptime: /g'

exit 0

THE PRIME PNG GRAPH URL

http://lab46.corning-cc.edu/~bmeehan1/primes.png

1)
i=0;i<${units};i++
user/bmeehan1/start.txt · Last modified: 2018/05/08 18:26 by bmeehan1