--- BingNFS2 - Notes ---

Bingnfs2 iSCSI


Do a expect Password Update
cd /work/Do-Password/
vi /var/tmp/ckthese
## drop the email in

WINDOW ONE 
cat /var/tmp/ckthese |awk '{print "/D2/admlocal/mvsftp/ORIG-expectPWCHG-changes-password "$3" "$7"       ;  sleep 3"}' >/var/tmp/runlist.sh 
sh /var/tmp/runlist.sh

WINDOW TWO
tail -f expect.out
cat expect.out |egrep -v 'call|NIS'
re-run and that were not succesful.


Do User Deletes
Delete users - BINGNFS2

mvsftp - window 0
 split -l 230 inMaster_and_Passwd.del.sun del.sun-

 mv del.sun saved.del.sun
 ls del.sun-a*
 ./mvto-delsuns del.sun-a*

TO CHECK HOW MANY DONE
cat del.sun |egrep -n <user from tail -f /var/log/SUN_del.LOG>

 
root - window 1 - set terminal name 
 /var/yp/src/cpPW-Shad-Adj --ck4corruption.ksh
 /var/yp/src/cpPW-Shad-Adj -06-16-2020-del.sun-a*

 /admlocal/bin/run_SunsAMProc.ksh del  >/var/log/SUN_del.LOG

 WHEN DONE ... 
  wc -l uids_in_use newids
  uid.pl
  wc -l uids_in_use newids  
 
 
root - window 2 - set terminal name 
 tail -f /var/log/SUN_del.LOG
 
root -window 3 - set terminal name 
 clear;/var/yp/src/ck4corruption.ksh
 
 if numbers out of sync
       cd /var/yp/src/UTIL
         sh cleanup
         sh getANDcompem
         sh mk-pw-sed-entry.sh  ### as usually the issue is passwd.adjunct
 IF all ok
  /admlocal/adm/makenis_check
 
WHEN DONE
 crontab -e 
 uncommet HOLD-A
 
-- --- -- -- -- -- -- -- -- --- --
-- --- -- -- -- -- -- -- -- --- --
 
 

To take iSCSI off line ...

    00 -   /sbin/zpool clear u0pool
    01 -   /usr/sbin/umount /u0
    02 -   df -h /u0
    ## If this is returned it is NOT unmounted.
        Filesystem             size   used  avail capacity  Mounted on
        u0pool                 3.8T   2.3T   1.5T    62%    /u0
    ## Got To Step 03


    ## If it returns nothing or just the root / partition it is unmounted.
    ## GoTo 0Z
   
    
    ## It is then necessary  to force it to unmount.
    03 -      /usr/sbin/umount -f /u0 && /usr/sbin/umount -l /u0
    ## check if it unmounted with
    04 -      df -h /u0
    ## If it is unmounted to to step OZ
    ## Otherwise ... Pause for a few seconds and
    ##   Repeat Steps 03 and 04 till it is unmounted...



    0Z - /usr/sbin/svcadm disable svc:/network/iscsi/initiator:default 
-- 
To restart ...

    /usr/sbin/svcadm enable svc:/network/iscsi/initiator:default
    /usr/sbin/mount /u0 
    ### if this fails
    bash
    bash /usr/local/bin/mountu0.bash



### ########################################################### ### Start here ### ########################################################### cd /var/yp/src ### ########################################################### ### Check 3x a day for accounts to be created ### Tru NOT do do it close to a 10's ### ########################################################### cat /admlocal/mvsftp/add.sun ### ########################################################### ### There are accounts to be created these create them. ### ########################################################### /admlocal/bin/run_SunsAMProc.ksh add >/var/log/SUN_add.LOG 2>&1 ### ########################################################### ### This will nake sure it runs w/o other processes running ### It might conflict with. ### ########################################################### /D2/admlocal/OTR/oktorun.ksh "/admlocal/bin/run_SunsAMProc.ksh add >/var/log/SUN_add.LOG 2>&1" Y ### If the NIS databse needs to be manual build outside of the on the 10's build ### Status and direction to build provided with this commmand /var/yp/src/alltouch ### ########################################################### ### Command to check the status of the NIS/PW files ### ########################################################### /var/yp/src/ck4corruption.ksh ### ########################################################### ### To Check how far out of sync and if are built is needed ### ########################################################### cd /var/yp/src/UTIL sh cleanup sh getANDcompem sh uniqem passwd.uids shadow.uids sh uniqem passwd.uids passwd.adjunct.uids sh uniqem shadow.uids passwd.adjunct.uids ### ########################################################### ### Location of the backups for the NIS/PW files ### ########################################################### /u0/Backups/safe_nis /u0/Backups/nis/files ### ########################################################### ### If there is a problem with the files become way out of sync ### ########################################################### cd /u0/Backups/safe_nis wc -l /u0/Backups/safe_nis/passwd /u0/Backups/safe_nis/shadow /u0/Backups/safe_nis/passwd.adjunct ls -ltr /u0/Backups/safe_nis ### if the line counts match cp -p /u0/Backups/safe_nis/passwd /u0/Backups/safe_nis/shadow /var/yp/src cp -p /u0/Backups/safe_nis/passwd.adjunct /var/yp/src/security cd /var/yp/src/ ./alltouch /admlocal/adm/makenis_check ### ########################################################### ### If the line count doesn't match work back throught the numbered sets ### Till you find a set that works. ### ########################################################### wc -l passwd.0 shadow.0 passwd.adjunct.0 ### ########################################################### ### You might need to add back old users if you go back to ### far. Check last tun of adds to date of files ### Bit of work to do this ### ########################################################### su - mvsftp bash cd ARCHIVE/ ls -ltr *-add.sun ### find the one closest to the date and time from the passwd shadow passwd.adjunct files cat .

Valid HTML 4.0 Transitional