• Win 7 drive map problem

    From mark lewis@1:3634/12.73 to Tommi Koivula on Wed Jan 2 12:36:34 2019

    On 2019 Jan 02 17:09:26, you wrote to Mike Powell:

    =##= Ende "backup_mbox01" =##=
    This is great! :)
    Common practice to backup in the BSD-World.

    I have no rsync daemon installed in OS/2, I'm just running the rsync
    client
    from OS/2 batch file:

    that what i did, too... threw everything over onto my linux box that has a much
    larger drive in it...

    i used a script file like this which i fired off as

    shadowsync c d e f g h

    yes, it is very much based on 4DOS/4OS2 scripting features... full logging of the script and rsync's actions with the logs split between each drive specified
    on the command line... logs are rotated backing up the last 9 to the logs/ directory... the latest log is in the same directory where the script is located... yes, all output is TEE'd so you can see it while it runs and is logged...

    yes, i also broke a cardinal rule by having the password and exclusion files in
    my rsync bin/ directory... it was just easier that way...the .pass file contains just the password used by the script for that one remote machine... each of the exclusion files are one directory, filename, or wildcard filename per line... if you need different passwords for different remote rsync servers,
    just copy the script to a new name and create the needed matching .pass and .exclude_* files... matching being to the script's name, of course...

    example exclude file: shadowsync.exclude_c
    /DMISL/
    /SWAP/*.4SW
    /SWAPPER.DAT
    LOG0001.DAT


    ==== Begin "shadowsync.cmd" ====
    @echo off
    setlocal
    set BASE_DIR=d:\os2progs\rsync
    set SCR_NAME=%@UPPER[%@NAME[%0]]
    set FNAMEBASE=%@LOWER[%SCR_NAME%]
    set DD= JanFebMarAprMayJunJulAugSepOctNovDec
    if '%1' EQ '' goto help

    set RSYNC_PARMS=-hia --no-g --no-o --protocol=30 --progress --stats --delete --password-file=%BASE_DIR%\bin\%FNAMEBASE%.pass

    goto execute

    :do_mydate
    set DY=%_DOW %_DAY %@SUBSTR[%DD,%@EVAL[%_MONTH * 3],3] %_YEAR
    iff '%MYFLAG' eq '' then
    set MYDATE= %@FORMAT[02.2,%_DAY]-%@SUBSTR[%DD,%@EVAL[%_MONTH*3],3]-%_YEAR %_TIME %SCR_NAME.CMD:
    else
    set MYDATE=%MYFLAG %@FORMAT[02.2,%_DAY]-%@SUBSTR[%DD,%@EVAL[%_MONTH*3],3]-%_YEAR %_TIME %SCR_NAME.CMD:
    endiff
    return

    :execute

    rem check our parameter is within the allowed range
    if %@LOWER['%1'] NE 'c' .and. %@LOWER['%1'] NE 'd' .and. %@LOWER['%1'] NE 'e' .and. %@LOWER['%1'] NE 'f' .and. %@LOWER['%1'] NE 'g' .and. %@LOWER['%1'] NE 'h' goto help1
    rem get our parameter and set the log file name
    set PARM1=%@LOWER[%1]
    set ARCLOG=%BASE_DIR\LOGS\%FNAMEBASE%_%PARM1
    set SLOG=%BASE_DIR\%FNAMEBASE%_%PARM1
    set SLOGS=TEE /A %SLOG%.log

    pushd %BASE_DIR

    iff exist %ARCLOG%9.log then
    echo Delete existing %ARCLOG%9.log
    del /y /q %ARCLOG%9.log
    endiff
    for %Z in (8 7 6 5 4 3 2 1) do (
    iff exist %ARCLOG%%%Z.log then
    echo Renaming %ARCLOG%%%Z.log to %ARCLOG%%@EVAL[%Z+1].log
    ren /q %ARCLOG%%%Z.log %ARCLOG%%@EVAL[%Z+1].log
    endiff
    )
    iff exist %SLOG%.log then
    echo Renaming %SLOG%.log to %ARCLOG%1.log
    ren /q %SLOG%.log %ARCLOG%1.log
    endiff

    echo. 2>&1 | %SLOGS
    gosub do_mydate
    echo %MYDATE [051] process executing 2>&1 | %SLOGS
    gosub do_mydate
    echo %MYDATE [053] PARM1 is '%PARM1' 2>&1 | %SLOGS
    gosub do_mydate
    echo %MYDATE [055] SLOG is '%SLOG' 2>&1 | %SLOGS
    gosub do_mydate
    echo %MYDATE [060] rsync version 2>&1 | %SLOGS
    echo ------------------------------------------------------------------------------
    bin\rsync --version 2>&1 | %SLOGS
    echo ------------------------------------------------------------------------------
    echo. 2>&1 | %SLOGS
    timer 2>&1 | %SLOGS
    echo. 2>&1 | %SLOGS
    set RSYNCCMD=bin\rsync %RSYNC_PARMS --exclude-from=%BASE_DIR\bin\%FNAMEBASE.exclude_%PARM1 %PARM1:/ USER@MACHINE::REMOTE_DIR/%PARM1
    gosub do_mydate
    echo %MYDATE [069] ********** working on %PARM1 ********** 2>&1 | %SLOGS
    gosub do_mydate
    echo %MYDATE [071] %RSYNCCMD 2>&1 | %SLOGS
    echo. 2>&1 | %SLOGS
    rem goto jump
    %RSYNCCMD 2>&1 | %SLOGS

    :jump
    echo. 2>&1 | %SLOGS
    gosub do_mydate
    echo %MYDATE [079] ********** work on %PARM1 is done ********** 2>&1 | %SLOGS echo. 2>&1 | %SLOGS
    timer 2>&1 | %SLOGS
    echo. 2>&1 | %SLOGS
    echo %MYDATE [083] ********** process complete ********** 2>&1 | %SLOGS

    popd
    shift
    if '%1' NE '' goto execute
    goto end

    :help1
    echo.
    echo parameter '%1' is invalid...

    :help
    echo.
    echo you must specify the drive or drives to work on...
    echo.
    echo eg: %SCR_NAME c d e
    echo.
    goto end

    :end
    endlocal

    ==== End "shadowsync.cmd" ====


    )\/(ark

    Always Mount a Scratch Monkey
    Do you manage your own servers? If you are not running an IDS/IPS yer doin' it wrong...
    ... Why do they call it a TV set when you only get one?
    ---
    * Origin: (1:3634/12.73)
  • From Torsten Bamberg@2:240/5832 to mark lewis on Thu Jan 3 01:00:46 2019
    Hallo mark!

    02.01.2019 12:36, mark lewis schrieb an Tommi Koivula:

    yes, it is very much based on ----/4OS2 scripting features...
    You know the scripting language rexx, buildin any OS/2 ?

    Bye/2 Torsten

    ... MAILBOX01 on OS2: up 13d 0h 48m load: 36 proc, 150 threads (tbupv1.1)
    --- GoldED+ 1.1.5-18
    * Origin: DatenBahn BBS Hamburg (2:240/5832)
  • From Torsten Bamberg@2:240/5832 to Tommi Koivula on Thu Jan 3 01:03:29 2019
    Hallo Tommi!

    02.01.2019 17:09, Tommi Koivula schrieb an Mike Powell:

    I have no rsync daemon installed in OS/2, I'm just running the rsync client from OS/2 batch file:
    for %a in ( c d e f g ) (
    rsync.exe -a --delete %a%:\ wat.localnet::backup\rbb\%a%
    )
    But rsync -D is running on your linux box. ;-)

    Anyway, one of the Boxes need to have a daemonized rsync.

    'Tommi
    Bye/2 Torsten

    ... MAILBOX01 on OS2: up 13d 0h 48m load: 36 proc, 150 threads (tbupv1.1)
    --- GoldED+ 1.1.5-18
    * Origin: DatenBahn BBS Hamburg (2:240/5832)
  • From Tommi Koivula@2:221/10 to Torsten Bamberg on Thu Jan 3 17:59:10 2019
    Hi Torsten.

    03 Jan 19 01:03, you wrote to me:

    I have no rsync daemon installed in OS/2, I'm just running the rsync
    client from OS/2 batch file:
    for %a in ( c d e f g ) (
    rsync.exe -a --delete %a%:\ wat.localnet::backup\rbb\%a%
    )
    But rsync -D is running on your linux box. ;-)

    Anyway, one of the Boxes need to have a daemonized rsync.

    Of course. :) Somehow I like to do it that way.

    'Tommi

    --- GoldED+/LNX 1.1.5-b20180707
    * Origin: telnet://v6.fidonet.fi (2:221/10)
  • From mark lewis@1:3634/12.73 to Torsten Bamberg on Thu Jan 3 11:07:54 2019

    On 2019 Jan 03 01:00:46, you wrote to me:

    yes, it is very much based on ----/4OS2 scripting features...

    You know the scripting language rexx, buildin any OS/2 ?

    of course i do... so what? it is not easily transferrable to other OSes but any
    OS that uses 4DOS and its derivitives can easily use the posted script... besides that, 4DOS scripting is much easier to understand and read... REXX always strikes me as like RPN :shrug:

    )\/(ark

    Always Mount a Scratch Monkey
    Do you manage your own servers? If you are not running an IDS/IPS yer doin' it wrong...
    ... The watermelons were so big it wouldn't take many to make a dozen.
    ---
    * Origin: (1:3634/12.73)
  • From Tommi Koivula@2:221/1.1 to mark lewis on Thu Jan 3 19:30:02 2019

    03 Jan 19 11:07:54, you wrote to Torsten Bamberg:

    yes, it is very much based on ----/4OS2 scripting features...

    You know the scripting language rexx, buildin any OS/2 ?

    of course i do... so what? it is not easily transferrable to other OSes
    but
    any OS that uses 4DOS and its derivitives can easily use the posted script... besides that, 4DOS scripting is much easier to understand and

    Yep. I never learned REXX, because I wrote all my .BATs with 4DOS, and then with 4OS2 and 4NT/TCC.

    'Tommi

    ---
    * Origin: IPv6 Point at [2001:470:1f15:cb0:2:221:1:1] (2:221/1.1)
  • From mark lewis@1:3634/12.73 to Tommi Koivula on Thu Jan 3 17:02:58 2019

    On 2019 Jan 03 19:30:02, you wrote to me:

    yes, it is very much based on ----/4OS2 scripting features...

    You know the scripting language rexx, buildin any OS/2 ?

    of course i do... so what? it is not easily transferrable to other
    OSes but any OS that uses 4DOS and its derivitives can easily use the
    posted script... besides that, 4DOS scripting is much easier to
    understand and

    Yep. I never learned REXX, because I wrote all my .BATs with 4DOS, and then with 4OS2 and 4NT/TCC.

    yep! i learned enough of REXX to have some scripts that created launch icons for my bbs nodes... by creating them procedurally, i knew their name and so could trigger them procedurally as well... or just click on them... i had something for the mail tossing routine such that when it was running, a mailbox
    with mail in it was displayed... when it was not running, the mail box icon was
    invisible... it was pretty neat when i first did it... later, i removed it and just let the process run without trying to trigger the icon to show...

    )\/(ark

    Always Mount a Scratch Monkey
    Do you manage your own servers? If you are not running an IDS/IPS yer doin' it wrong...
    ... Brain - the apparatus with which we think that we think.
    ---
    * Origin: (1:3634/12.73)