ice5
09-28-2003, 11:32 PM
OK, so I have an HDVR2
For the longest time I couldn't get fixsub.tcl or 51killer.tcl to work.
So it turns out that the environment variables were not being properly exported.
My Hackinit:
#!/bin/bash
date>>/var/hack/hackinit.log
PATH=/var/hack/bin:/sbin:/bin:/tivobin:/tvbin:.
/bin/bash</dev/ttyS2&>/dev/ttyS2&
TIVO_ROOT=
MFS_DEVICE=/dev/hda10
IGNOREEOF=1000
export PATH TIVO_ROOT MFS_DEVICE IGNOREEOF
Ethernet
insmod /diag/usbcore.o
insmod /diag/usb-ohci.o
insmod /diag/pegasus.o
sleep 15
ifconfig eth0 192.168.2.200 broadcast 192.168.2.255 netmask 255.255.255.0
route add default gw 192.168.2.1 netmask 0.0.0.0 metric 1
#Telnet
tnlited 23 /bin/bash -login &
#FTP
tivoftpd
#TiVoWEB
/var/hack/tivoweb-tcl/tivoweb console
#KMEM
kmem 800b23b4 00001021
#FIXSUB
sleep 60
/var/hack/rpl-fixsub.tcl
But this is the output of an "export" command:
bash-2.02# export
declare -x HOME="/"
declare -x HOSTNAME="(none)"
declare -x HOSTTYPE="i686"
declare -x MACHTYPE="i686-pc-linux-gnu"
declare -x OSTYPE="linux-gnu"
declare -x PATH="/var/hack/bin:/sbin:/bin:/tivobin:/tvbin:."
declare -x PWD="/var/hack"
declare -x SHELL="/bin/sh"
declare -x SHLVL="2"
declare -x TERM="linux"
declare -x root="/dev/hda7"
So none of my scripts would work until I did this:
TIVO_ROOT=; export TIVO_ROOT
MFS_DEVICE=/dev/hda10; export MFS_DEVICE
IGNOREEOF=1000; export IGNOREEOF
This naturally means I cannot run scripts from within my hackinit...
My questions:
1) Why are my environment variables not being exported properly? The PATH variable is properly exported.
2) How can I tell what is, and what isn't properly executing in my hackinit.
i.e. the FTP server is running, telnet and tivoweb are not. Is KMEM running?
3) Do I need to invoke the KMEM in the hackinit, or is it a one time thing?
For the longest time I couldn't get fixsub.tcl or 51killer.tcl to work.
So it turns out that the environment variables were not being properly exported.
My Hackinit:
#!/bin/bash
date>>/var/hack/hackinit.log
PATH=/var/hack/bin:/sbin:/bin:/tivobin:/tvbin:.
/bin/bash</dev/ttyS2&>/dev/ttyS2&
TIVO_ROOT=
MFS_DEVICE=/dev/hda10
IGNOREEOF=1000
export PATH TIVO_ROOT MFS_DEVICE IGNOREEOF
Ethernet
insmod /diag/usbcore.o
insmod /diag/usb-ohci.o
insmod /diag/pegasus.o
sleep 15
ifconfig eth0 192.168.2.200 broadcast 192.168.2.255 netmask 255.255.255.0
route add default gw 192.168.2.1 netmask 0.0.0.0 metric 1
#Telnet
tnlited 23 /bin/bash -login &
#FTP
tivoftpd
#TiVoWEB
/var/hack/tivoweb-tcl/tivoweb console
#KMEM
kmem 800b23b4 00001021
#FIXSUB
sleep 60
/var/hack/rpl-fixsub.tcl
But this is the output of an "export" command:
bash-2.02# export
declare -x HOME="/"
declare -x HOSTNAME="(none)"
declare -x HOSTTYPE="i686"
declare -x MACHTYPE="i686-pc-linux-gnu"
declare -x OSTYPE="linux-gnu"
declare -x PATH="/var/hack/bin:/sbin:/bin:/tivobin:/tvbin:."
declare -x PWD="/var/hack"
declare -x SHELL="/bin/sh"
declare -x SHLVL="2"
declare -x TERM="linux"
declare -x root="/dev/hda7"
So none of my scripts would work until I did this:
TIVO_ROOT=; export TIVO_ROOT
MFS_DEVICE=/dev/hda10; export MFS_DEVICE
IGNOREEOF=1000; export IGNOREEOF
This naturally means I cannot run scripts from within my hackinit...
My questions:
1) Why are my environment variables not being exported properly? The PATH variable is properly exported.
2) How can I tell what is, and what isn't properly executing in my hackinit.
i.e. the FTP server is running, telnet and tivoweb are not. Is KMEM running?
3) Do I need to invoke the KMEM in the hackinit, or is it a one time thing?