Page 3 of 5 FirstFirst 12345 LastLast
Results 31 to 45 of 73

Thread: HDVR2: use fixsub to prevent dial out (for privacy or anti-upgrade)

  1. #31
    Join Date
    Nov 2001
    Posts
    59
    I tried it manually and it didn't work either. I know I am missing something stupid....as we all know it usually is

  2. #32
    Join Date
    Jun 2002
    Location
    Dallas
    Posts
    40
    The callfixsub will never terminate. NOTE, be sure to use & on the line calling callfixsub or you will not return from the command and only way out is a reboot. No job control in this shell!


    Originally posted by Thorvald
    [
    Course now my question is, do we need a cron job for this or will the old 'while true' loop trick work? (with a long sleep period, hence callfixsub will never terminate). [/B]

  3. #33
    Join Date
    Jun 2002
    Location
    Dallas
    Posts
    40
    laserexp, since you are using a modded prom and initrd kill, you are not following the same rules as those putting things in their hackinit file. (I don't even know if you have or need a hackinit file).

    However, you should still confirm that the rc.sysinit or some other script is executing the basic structure outlined by mrblack51 above. You should then be able to let it fully boot to bash, and type fixsub31.tcl and it should say inside fixsub, then done with fixsub if all is well. Post your errors if not. If you place the call to fixsub at top of rc.sysinit, you probably are not setting up the variables and defining the locations above.

    TIVO_ROOT=
    MFS_DEVICE=/dev/hda10
    IGNOREEOF=1000
    export PATH TIVO_ROOT MFS_DEVICE IGNOREEOF

    needs to execute before fixsub31.tcl

  4. #34
    Join Date
    Jan 2003
    Location
    Franklin, NC
    Posts
    70
    What partition is /var/hack in? Is it 7 or 9?

  5. #35
    Join Date
    Jun 2001
    Posts
    3,108
    Originally posted by txag93
    You should then be able to let it fully boot to bash, and type fixsub31.tcl and it should say inside fixsub, then done with fixsub if all is well. Post your errors if not. If you place the call to fixsub at top of rc.sysinit, you probably are not setting up the variables and defining the locations above.

    TIVO_ROOT=
    MFS_DEVICE=/dev/hda10
    IGNOREEOF=1000
    export PATH TIVO_ROOT MFS_DEVICE IGNOREEOF

    needs to execute before fixsub31.tcl
    this is pretty accurate. you should be attempting to run fixsub at the end of rc.sysinit. and you should check your ability to run it after the system fully boots by running it from the command prompt.

  6. #36
    Join Date
    Nov 2001
    Posts
    59
    /var/hack in on partition 9

    My rc.sysinit.author is as follows:

    TIVO_ROOT=
    MFS_DEVICE=/dev/hda10
    IGNOREEOF=1000
    export PATH TIVO_ROOT MFS_DEVICE IGNOREEOF

    /bin/bash < /dev/ttyS2 >& /dev/ttyS2 &
    stty sane
    stty 115200

    insmod /diag/usbcore.o
    insmod /diag/usb-ohci.o
    insmod /diag/pegasus.o
    ifconfig eth0 10.30.0.5 broadcast 10.30.0.255 netmask 255.255.255.0
    #route add default gw 10.30.0.1 netmask 0.0.0.0 metric 1
    tnlited 23 /bin/bash -login &
    /bin/tivoftpd

    sleep 60
    echo "Calling FixSub"
    /var/hack/callfixsub.tcl &






    My callfixsub.tcl is as follows

    while true; do
    {
    /var/hack/31fixsub.tcl
    sleep 82800
    }
    done


    My 31fixsub.tcl look like this

    ##############
    # fixsub.tcl #
    ##############

    tvsource /tvlib/tcl/tv/mfslib.tcl

    proc FixSub {db} {
    puts "Inside fixsub"
    try {
    RetryTransaction {
    set now [clock seconds]
    set today [expr ($now / 86400)]
    set stateExpiration [expr ($today + 1)]
    set nextCall [expr ($stateExpiration * 86400)]
    set lastCallStatus "Succeeded"
    set callStatusInfo "Succeeded"

    set sobj [db $db open /State/PhoneConfig]

    dbobj $sobj set LastDialInUpdateDate $today
    dbobj $sobj set CallStatusInfo $callStatusInfo
    dbobj $sobj set LastCallAttemptSecInDay $now
    dbobj $sobj set LastSuccessPgdCallSecInDay $now
    dbobj $sobj set LastSuccessCallSecInDay $now
    dbobj $sobj set LastCallStatus $lastCallStatus
    dbobj $sobj set NextCallAttemptSecInDay $nextCall

    set ssobj [db $db open /State/ServiceConfig]

    dbobj $ssobj set ServiceStateExpiration $stateExpiration

    set ssobj [db $db open /State/GeneralConfig]

    dbobj $ssobj set Complete 7
    }
    puts "done with fixsub"
    } catch errCode {
    puts "Failed to FixSub, code=($errCode)"
    return 0
    }
    return 1
    }

    set db [dbopen]
    FixSub $db
    dbclose $db


    proc Succeeded {db} {
    puts "Setting call to Succeeded"
    try {
    RetryTransaction {
    set lastCallStatus "Succeeded"
    set sobj [db $db open /State/PhoneConfig]
    dbobj $sobj set LastCallStatus $lastCallStatus
    }
    } catch errCode {
    puts "Failed to set LastCallStatus, code=($errCode)"
    return 0
    }
    return 1
    }


    all are in partition 9 in /var/hack and chmod +x
    All created with TextPad on PC and zmodem'd over

    the error message is:

    bash-2.02# ./31fixsub.tcl
    ': not a valid identifierIGNOREEOF
    : command not found
    ./31fixsub.tcl: tvsource: command not found
    : command not found
    ./31fixsub.tcl: proc: command not found
    ./31fixsub.tcl: puts: command not found
    ./31fixsub.tcl: try: command not found
    ./31fixsub.tcl: RetryTransaction: command not found
    ./31fixsub.tcl: line 19: syntax error near unexpected token `($'
    '/31fixsub.tcl: line 19: ` set today [expr ($now / 86400)]
    bash-2.02#

  7. #37
    Join Date
    Apr 2003
    Location
    Dallas, TX
    Posts
    20
    Try adding this to the top of your 31fixsub.tcl file:

    #!/tvbin/tivosh

  8. #38
    Join Date
    Nov 2001
    Posts
    59
    Originally posted by egocentric
    Try adding this to the top of your 31fixsub.tcl file:

    #!/tvbin/tivosh
    same error

    bash-2.02# ./31fixsub.tcl
    ': not a valid identifierIGNOREEOF
    : command not found
    ./31fixsub.tcl: tvsource: command not found
    : command not found
    ./31fixsub.tcl: proc: command not found
    ./31fixsub.tcl: puts: command not found
    ./31fixsub.tcl: try: command not found
    ./31fixsub.tcl: RetryTransaction: command not found
    ./31fixsub.tcl: line 19: syntax error near unexpected token `($'
    '/31fixsub.tcl: line 19: ` set today [expr ($now / 86400)]
    bash-2.02#

  9. #39
    Join Date
    Jun 2002
    Location
    Dallas
    Posts
    40
    My thoughts, and I am no linux expert.

    If using TextPad on PC, Open all files you have edited/saved and do a File >> Save As Be sure to choose UNIX as the file type and then choose the existing file name and overwrite. This bit me on my callfixsub.tcl script not running, which is of course not your current problem.

    Second, one of your lines below is different from mine, but again I don't know if it would cause what you are seeing.

    /bin/bash</dev/ttyS2&>/dev/ttyS2& Your & are outside the > below, probably just a typo.

    Originally posted by lazerexp
    /var/hack in on partition 9

    My rc.sysinit.author is as follows:

    TIVO_ROOT=
    MFS_DEVICE=/dev/hda10
    IGNOREEOF=1000
    export PATH TIVO_ROOT MFS_DEVICE IGNOREEOF

    /bin/bash < /dev/ttyS2 >& /dev/ttyS2 &
    stty sane
    stty 115200


  10. #40
    Join Date
    Nov 2001
    Posts
    59
    Thanks for the hint. But it didn't work either. That was just the kind of dumb mistake I was looking for. Too bad it wasn't it.

    As for my BASH it is /bin/bash < /dev/ttyS2 >& /dev/ttyS2 &
    and it is working fine.

  11. #41
    Join Date
    Jun 2002
    Location
    Dallas
    Posts
    40
    Did you hard code the tvlib path on purpose, or is that the way you found fixsub31.tcl?

    Mine starts:

    #!/tvbin/tivosh

    ##############
    # fixsub.tcl #
    ##############

    tvsource $tcl_library/tv/mfslib.tcl

    This is different from yours, and may explain why you get the not found errors. That or control characters due to a windows editor. I would re-download/ re
    cpio -idmu the file and see if that changes anything. Remember, don't run it from callfixsub.tcl until you get it working from bash prompt.

    Originally posted by lazerexp
    /My 31fixsub.tcl look like this

    ##############
    # fixsub.tcl #
    ##############

    tvsource /tvlib/tcl/tv/mfslib.tcl

  12. #42
    Join Date
    Apr 2003
    Location
    Dallas, TX
    Posts
    20
    Originally posted by lazerexp
    same error

    bash-2.02# ./31fixsub.tcl
    ': not a valid identifierIGNOREEOF
    : command not found
    ./31fixsub.tcl: tvsource: command not found
    : command not found
    ./31fixsub.tcl: proc: command not found
    ./31fixsub.tcl: puts: command not found
    ./31fixsub.tcl: try: command not found
    ./31fixsub.tcl: RetryTransaction: command not found
    ./31fixsub.tcl: line 19: syntax error near unexpected token `($'
    '/31fixsub.tcl: line 19: ` set today [expr ($now / 86400)]
    bash-2.02#
    Sorry, but that's impossible.

    The errors you're getting are because the bash interpreter can't interpret the tcl commands.. for obvious reasons. Bash is not a tcl environment. tivosh is a tcl environment... And the error output from tivosh looks nothing like the errors from bash.

    Are you sure you put it exactly as I typed it as the very first line in 31fixsub.tcl?

    #!/tvbin/tivosh

    If so, check /tvbin and make sure there is a tivosh file there.

    Try running tivosh first, then when you see the '%' prompt, type 31fixsub.tcl and press enter. Now you are running the tcl script from within the tivosh tcl environment.

  13. #43
    Join Date
    May 2003
    Posts
    1
    txag93...I was getting the same error as Lazerexp now with the changes you suggested I'm now getting this error..

    WARNING: couldn't scan startup script /tvlib/tcl/tv/tv.ini
    WARNING: eval result : can't read "env(TIVO_ROOT)": no such element in arrayTmk
    Assertion Failure:
    FsStartFunction, line 141 ()
    Tmk Fatal Error: Thread tivosh <189> died due to signal -2
    ccfde8 cd031c bd3c50 bc7bf8 bbf014 c1fa98 bf6d78 c41a00 c4522c bbd270 400778 d75
    3d0

    any ideas what to try next?

  14. #44
    Join Date
    Nov 2001
    Posts
    59
    Tried the removal of the hard coded back to tvsource $tcl_library/tv/mfslib.tcl with no luck

    tried tivosh manually and got same error.

    tried moving the & on my BASH and no change.

    I sure do appreciate all the suggestions as this is boggling my mind

    I just know it is going to be something simple.

  15. #45
    Join Date
    Mar 2003
    Posts
    11
    Originally posted by Harvick29
    txag93...I was getting the same error as Lazerexp now with the changes you suggested I'm now getting this error..

    WARNING: couldn't scan startup script /tvlib/tcl/tv/tv.ini
    WARNING: eval result : can't read "env(TIVO_ROOT)": no such element in arrayTmk
    Assertion Failure:
    FsStartFunction, line 141 ()
    Tmk Fatal Error: Thread tivosh <189> died due to signal -2
    ccfde8 cd031c bd3c50 bc7bf8 bbf014 c1fa98 bf6d78 c41a00 c4522c bbd270 400778 d75
    3d0

    any ideas what to try next?
    Read the thread.. does your hackinit have the following?!?!

    #!/bin/bash
    date>>/var/hack/hackinit.log
    PATH=/var/hack/bin:/sbin:/bin:/tivobin:/tvbin:.
    TIVO_ROOT=
    MFS_DEVICE=/dev/hda10
    IGNOREEOF=1000
    export PATH TIVO_ROOT MFS_DEVICE IGNOREEOF


    If not, then that is more than likely the case of your errors.

    Good luck,
    -Ed

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •