PDA

View Full Version : dump question: used initrd replacement - but no bash



KaneTheGerman
04-04-2003, 02:57 PM
Hi,

I'am new to the TiVo series 2 hacking stuff.
I have a Series 2 SVR-3000 and hacked it with the bash hack - which worked for older software versions. Now I want to go for the new software release, because I want to use the home media option :)
I worked through a lot of threads and found a lot of scattered info. So I now have a modified prom and used the nice C programs
from Mr. Black to replace the initrd - the program works fine and says it finds and replaces the kernel stuff.
Plugged in the hard drive back in my TiVo and it is still working :),
BUT where do I get my BASH now. Should it appear at the serial port ? There is nothing there :confused:
Do I have to apply additional scripts, hacks updates ?
Perhaps we can use this thread to get a list of files and steps needed to get this BASH - or is the information allready bundled somewhere ?

Steps:
1) modify your prom - some info is here http://www.dealdatabase.com/forum/showthread.php?s=&threadid=16576&highlight=modify+prom ?
2) get initrd replacement from alldeadhomiez (see http://www.dealdatabase.com/forum/showthread.php?s=&threadid=21976)
3) use Mr. Blacks C file to replace the stuff
4) .....:confused:

mrblack51
04-04-2003, 03:22 PM
once you have a modified prom and you killed the initrd, you can modify the filesystem however you want. Specifically, you can use standard bash hacks.

add the following to your rc.sysinit:



/bin/bash</dev/ttyS2&>/dev/ttyS2&

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


obviously, you will need to change the ip address as appropriate.

KaneTheGerman
04-04-2003, 04:42 PM
Yep, that was the last small info that I was missing.
Now I have my bash back again - thanks a lot.
So step 4 is:
4) modify your rc.sysinit :p

tinman
04-27-2003, 02:55 PM
I think I'm in the same situation as KanetheGerman. I have an HDVR2 with a hacked prom (thanks KRavEN!) and a replaced initrd as per the post here. Put drive back in but failed to get bash. I'm not using the bash environment hack version (U5?) but am using the version that came on the unit (3.1.0-01-2.151). I've set my baud rate to 9600 using teraterm and I know my serial cable is good as I've used it to get bash in my Sat T-60 (Series1) TIVO many times. So does this post mean I still can't get bash until I mod this file as per MrBlack51's suggestion?

One other question: How do I edit my rc.sysinit file? I've used the Johnny Death boot CD to boot up, verified I have the correct utils, but I don't know where the file is or how to edit it. My HDVR2 boot is HDX7. I know I should back the rc.sysinit up but I'm not sure where I should do that. It looks like if I ever find it and move it over to Windows to edit I'll have to dos2unix it and also do a changemod but again, I'm not sure of the exact commands needed. Any help is appreciated.

tinman
04-29-2003, 09:47 AM
No takers, huh. Well, I spent all weekend reading and fooling around with my HDVR2 and finally worked my way thru to the /etc directory and the other one (rc.d?) and found my rc.sysinit file. I edited it in joe (having backed it up first) but was not sure exactly where in there to insert the lines mentioned above. Plus I wasn't interested in the telnet aspect just yet so I only inserted the first line. I put it back in my TIVO and---no bash. I was stuck at "Welcome. Powering Up" screen. Since I had made only 2 changes, thought at first it was my rc.sysinit. But when I wrote my bootparams back to hda7 and nothing else, it booted but still no bash.

But now that I think about it, I may have replaced my edited rc.sysinit file with the .bak so perhaps I'm closer than I think. I'll go back and see if all I need is a few edits of the rc.sysinit. Also, if running bash, is there some snoop program that lets you watch your TIVO execute the boot up commands (similar to F8 in Windows)?

Since I'm not running U5 it doesn't seem that I should need the bash environment shell that's in there. Am I right. I understood with a hacked prom (got it), a hacked init.id (got it) and a few changes to the rc.sysinit, I should get bash. But still no go. Could MrBlack or someone more knowledgeable than I state what bootparams are needed if you're not running U5 and also what lines can be commented out in this post. I know there's another post by MrB that says you can comment out the 3 lines but it seems to me there's more than 3.

Anyway, I'll keep fooling around with this box and see what more I can learn. Also, for those in an endless powering up mode, first thing I'd do is check your bootparams and put it back to something simple like /dev/hda7 (if the's your boot) and see if it works and then work in form there.

KRavEN
04-29-2003, 02:12 PM
The changes that mrblack51 noted above should go at the very end of rc.sysinit.

rc.sysinit is indeed located in /etc/rc.d/

You can go ahead and replace both /dev/hda6 and /dev/hda3 with the tinyinitrd kernel and not worry about messing anything up.

Endless powering up is more than likely caused by something you messed up in rc.sysinit. Restore your backup and put the stuff at the end and you should be fine.

Also don't worry about the lan stuff being there. If you don't have the usb ethernet dongle then it doesn't hurt anything to have the modules loaded and just makes it easier for when you do get one.

tinman
04-29-2003, 11:34 PM
There's no doubt my bootparams were the problem on the powering up loop because I was able to boot once I wrote back the normal param. Modded the rc.sysinit with joe per this post and...hooray, got bash but...

bash: no job control in this shell
bash-2.02# ls
bash: ls: command not found
bash-2.02# cd /
bash-2.02# ls
bash: ls: command not found
bash-2.02# dir
bash: dir: command not found
bash-2.02# dir

So, where are my tools? Do I need to transfer some files over to the TIVO now from the Johnnydeath bootcd and if so, which ones?

mrblack51
04-30-2003, 12:53 AM
all the stuff like 'ls' and whatnot are normally installed during the bash_env hack steps. you need to drop your drive into a pc and boot with the mfstools disk for the u5 hack, then extract the devbin gzip to your drive as per the instructions in the u5 tutorial.

tinman
04-30-2003, 03:59 PM
I was trying to do this without the U5 being on my drive. I did a copy once you were kind enough to show us the way, MrB. I just thought I'd go ahead and try to hack without putting it on since I knew it would get upgraded anyway. If I just want to rz some files (is that correct?) which ones would I send across from the johnnydeath boot cd. Thanks.

mrblack51
04-30-2003, 04:03 PM
Originally posted by tinman
I was trying to do this without the U5 being on my drive. I did a copy once you were kind enough to show us the way, MrB. I just thought I'd go ahead and try to hack without putting it on since I knew it would get upgraded anyway. If I just want to rz some files (is that correct?) which ones would I send across from the johnnydeath boot cd. Thanks.

like i said, you arent installing the u5 version/hack since you arent messing with bash_env. but, you still need the devbin gziped file extracted on your tivo. the best way is to boot with the johnnydeath cd and do the couple steps relating to devbin. you dont need to worry about the image restore, hackinit, or bash_env