TiVo Community
TiVo Community
TiVo Community
Go Back   TiVo Community > Underground Playground > TiVo Upgrade Center
TiVo Community
Reply
Forum Jump
 
Thread Tools
Old 08-19-2002, 01:50 PM   #121
Robert S
Registered User
 
Join Date: Jul 2002
Location: Cambridgeshire, UK
Posts: 9,725
Sorry dobbie, the original mkswap parameters were wrong, the current ones have been tested on a Series 1.

Is there something odd about the S2 partition structure?
__________________
Please do not PM me asking for TiVo backups. I don't have any.
Robert S is offline   Reply With Quote
Old 08-19-2002, 02:12 PM   #122
Merle Corey
Registered User
 
Join Date: Aug 2001
Location: Mount Prospect, IL, US
Posts: 64
Quote:
Originally posted by Robert S
Is there something odd about the S2 partition structure?
I was wondering that myself; that's why I wanted the image - so I could see if there's anything unusual about it.

Right now the only noteworthy thing is that it's a 13 partition structure, similar to the S1 Sony... But I'm pretty sure we knew that already.

Other than that, the layout appears to be exactly the same - /var on 9, roots on 4 and 7, swap on 8. I'm going to take a closer look at the swap and confirm that it's still the old version, but that's also fairly likely to be the case.

MC
Merle Corey is offline   Reply With Quote
Old 08-19-2002, 02:21 PM   #123
Merle Corey
Registered User
 
Join Date: Aug 2001
Location: Mount Prospect, IL, US
Posts: 64
And it's confirmed, series 2 still utilizes the old style swap - in other words, -v0 is required or mkswap will create something that the TiVo can't read.

(PM me if you really wanna know how to find out - it's easy - everything you need to know is in the man page for mkswap. )

I don't think there's much more to fiddle with at this point - what we need now is someone with a series 2 to try it out with the -v0 parameter.

MC
Merle Corey is offline   Reply With Quote
Old 08-19-2002, 02:50 PM   #124
Agent86
Registered Lurker
 
Agent86's Avatar
 
Join Date: Jan 2002
Posts: 571
So what has to be done? You know, the usual newbie stuff - commands to run, switch options, and option values (like swap size).

If it helps, I'm running dual 120gb drives in this unit.

Is it possible to do this without losing my programs, or do I have to start from scratch?

I have a feeling I might not like the answer to this one, based on prior posts in the thread .

- Agent 86
Agent86 is offline   Reply With Quote
Old 08-19-2002, 02:54 PM   #125
Robert S
Registered User
 
Join Date: Jul 2002
Location: Cambridgeshire, UK
Posts: 9,725
Not at all, we just want you to do method #3 from the top post with the new options. It shouldn't affect the rest of your setup.

Seeing as you already have working swap, perhaps Merle can suggest a sequence of commands to reduce your swap slightly and then increase it back to 64Mb so we can be sure it's working.
__________________
Please do not PM me asking for TiVo backups. I don't have any.
Robert S is offline   Reply With Quote
Old 08-19-2002, 02:55 PM   #126
Agent86
Registered Lurker
 
Agent86's Avatar
 
Join Date: Jan 2002
Posts: 571
I think I can handle that .

But don't I need to get MORE then 64 to make my TiVo happy when things go sour?

So ideally we'd drop it to some lower number, and then boost it to some higher number (i.e. 128, or whatever is needed for dual 120s).

Just feed me the proper command lines, and I'll make sure my fingers get them right .

Also, does Kazymyr's boot cd (v2.6i) have this tool on it? Do I boot in byteswapped or non-byteswapped mode?

- Agent 86

Last edited by Agent86 : 08-19-2002 at 03:08 PM.
Agent86 is offline   Reply With Quote
Old 08-19-2002, 03:10 PM   #127
Robert S
Registered User
 
Join Date: Jul 2002
Location: Cambridgeshire, UK
Posts: 9,725
Well, you only have room for 64Mb of swap, which is not enough for your system to recover from a GSOD. You should have done a pipe transfer, which would have saved your recordings and left you with a 128Mb hole where your swap partition should be.

What we're trying to figure out is that last step - repairing swap partition on an S2. I don't think there's any reason to think it's impossible, but people have been having problems.

DTiVoes and S2's are locked down, so you can't do the hacking required to add additional swap for emergencies. I think DTiVoes can be unlocked by hacking the boot PROM, but S2's are currently unhackable, so the only way to make your TiVo safe is to repeat the upgrade and this time expand swap to 128Mb (there's no point in going beyond 128Mb, even though MFS Tools 2.0 allows it, as the Linux kernel TiVo uses can only use 128MB per partition or file).

128Mb should be enough for any TiVo to recover from a green screen, subject to confirmation when Merle's stocked up on big drives
__________________
Please do not PM me asking for TiVo backups. I don't have any.
Robert S is offline   Reply With Quote
Old 08-19-2002, 03:29 PM   #128
dobbie1
Registered User
 
Join Date: Apr 2002
Location: Memphis, TN
Posts: 158
I will give it a try with the 80G drive that had been expanded. Listed below are the steps, I think I should take.

1. Low level format the drive to get back to a clean drive.
2. Restore the backup with MFSTools2 using the default parameters as I used originally.
3. Expand drive with MFSTools2.
4. Return to TiVo and check swap file, there should not be any.
5. Remove drive from TiVo and with MFSTools 1 run mkswap with -v0 parameters.

Will this verify what is required. My system is a Series2 Standalone.

Regards,
dobbie1
dobbie1 is offline   Reply With Quote
Old 08-19-2002, 03:34 PM   #129
Agent86
Registered Lurker
 
Agent86's Avatar
 
Join Date: Jan 2002
Posts: 571
Well balls!

So, since its the off season its probably the best time to get this fix out of the way. It stinks that I'll lose all my season's passes, thumb ratings, and recordings, but if its the only option its the only option. I suppose that's why its called "hacking".

I'll just watch the few "new" shows I have (like Monk) over the next couple of days and then prep for surgery.

My backup image is a virgin image made with MFSTools 1.1. So what do I have to do to restore it to the 120GB drive, expand it, and make 128MB of swap properly?

My parents also have a Series 2 with the stock 40GB and a 120GB B drive - which means they fall victim to the same plague. Where is this piped procedure I can follow so that I can upgrade their A drive and extend the swap as well?

I really don't want to have to do all this ever again .

- Agent 86
Agent86 is offline   Reply With Quote
Old 08-19-2002, 04:03 PM   #130
stormsweeper
How *you* doin'?
 
stormsweeper's Avatar
 
Join Date: Nov 2001
Location: NYC, USA
Posts: 424
You could just make a new backup image and keep all your settings, but not recordings.
stormsweeper is offline   Reply With Quote
Old 08-19-2002, 04:13 PM   #131
Merle Corey
Registered User
 
Join Date: Aug 2001
Location: Mount Prospect, IL, US
Posts: 64
Agent86:

You don't have to lose anything (other than recordings). Make a new backup of your TiVo in its current state with:

mfsbackup -6so /mnt/bak/tivoagain.bak /dev/hdX

You'll preserve the season passes, etc, but flush the recordings.

When you go to do the 'mkswap', you'll need to do it in non-byteswapped mode, as that's how S2's work.

And thank you again for setting me up with the S2 image - it was a big help.

---

dobbie1:

Depending on what the "default parameters (you) used originally" are, yes, that's the process in a nutshell. If you used -s 128, then yes, you should have no swap. If you didn't specify, or used -s 64, you should have a working 64MB swap.

Technically, you don't need to low-level format the drive either, if you're looking to save a little time.

MC
Merle Corey is offline   Reply With Quote
Old 08-19-2002, 04:19 PM   #132
Agent86
Registered Lurker
 
Agent86's Avatar
 
Join Date: Jan 2002
Posts: 571
What command do I use to properly restore the backup?

Do I still use the -s 128, and then use mkswap -v0 to initialize it properly?

- Agent 86
Agent86 is offline   Reply With Quote
Old 08-19-2002, 04:36 PM   #133
Merle Corey
Registered User
 
Join Date: Aug 2001
Location: Mount Prospect, IL, US
Posts: 64
Much ado about nothing...

Today's quote of the day is: "A foolish consistency is the hobgoblin of small minds." --Ralph Waldo Emerson

So I got curious as to why, exactly, -s 128 failed. It didn't make much sense - I did a little digging, and it turns out that -s 128 fails to produce working swap because it initializes it improperly. It tries to do the right swap type (version 0), but munges the format.

This, however, triggered a suspicion and I just proved it true: We're (mostly) familiar with the "truncating to 130048kB" message that mkswap produces when making a version 0 swap of 128MB. The reason for that message is simple - that's the largest swap size supported by version 0 in a single partition/file.

130048kB/1024 = 127MB.

Oops.

The bug in MFST2 is that it fails to adjust for improper swap sizes fed to it on the command line. This is compounded by the README claiming that all swap sizes up to 512MB are valid.

So, I ran another test, this time using -s 127. It worked just fine.

In other words, the following produces a working restore with a maxed out swap partition:

mfsrestore -zxp -s 127 -i backupfile /dev/hdX

Well, Robert, we were looking for a simpler way to explain how to get working swap... I think I found it.

MC

(edit for typos)

Last edited by Merle Corey : 08-19-2002 at 04:46 PM.
Merle Corey is offline   Reply With Quote
Old 08-19-2002, 04:48 PM   #134
Robert S
Registered User
 
Join Date: Jul 2002
Location: Cambridgeshire, UK
Posts: 9,725
A86, you might want to wait until we have a verified method for doing swap on an S2. If you want to keep your SP's etc a new backup will preserve those (won't even have to make a guide call).

Restore with

mfstool restore -s 128 -xpi /mnt/dos/tivo.bak /dev/hdc

Which will restore the backup, increase swap size (broken), expand your partitions to fill the drive and optimise your partition layout for extra speed.

Whatever scheme we settle on for fixing swap, you should be able to do it from the MFS Tools 2.0 CD without rebooting because Series 2's aren't byteswapped.

dobbie, you don't particularly need to clear the disk first, I was slightly concerned earlier that you might inherit working swap from your previous install, but I don't think that applies here. Rather than a format, which is very slow, you could dd from /dev/zero over your drive. Set bsize and count to write 1Gb of data and you'll trash all the relevant stuff.

As I said, S2's aren't byteswapped, so MFS Tools 2.0 CD is the one to use, S1's must not use MFST2 CD because they are byteswapped. I would be quite happy for you to do mkswap before you test the restore, as long as you can verify that it worked.
__________________
Please do not PM me asking for TiVo backups. I don't have any.
Robert S is offline   Reply With Quote
Old 08-19-2002, 04:51 PM   #135
Agent86
Registered Lurker
 
Agent86's Avatar
 
Join Date: Jan 2002
Posts: 571
Sweet!

So all I have to do is boot up with MFSTools 2.0, and run

mfsbackup -6so /mnt/bak/tivoagain.bak /dev/hdX

and then follow that up with

restore -s 127 -zxpi /mnt/bak/tivoagain.bak /dev/hdX

and I'll be golden?

(The above is a combo of your restore and Merle's fix)

- Agent 86

Last edited by Agent86 : 08-19-2002 at 05:01 PM.
Agent86 is offline   Reply With Quote
Old 08-19-2002, 04:57 PM   #136
Merle Corey
Registered User
 
Join Date: Aug 2001
Location: Mount Prospect, IL, US
Posts: 64
Quote:
Originally posted by Robert S

Whatever scheme we settle on for fixing swap, you should be able to do it from the MFS Tools 2.0 CD without rebooting because Series 2's aren't byteswapped.
Actually, a reboot is required between the restore and running mkswap. I don't know why, but mkswap won't recognize the new partition until a reboot has taken place.

Of course, we may not need mkswap any more...

MC
Merle Corey is offline   Reply With Quote
Old 08-19-2002, 05:00 PM   #137
Merle Corey
Registered User
 
Join Date: Aug 2001
Location: Mount Prospect, IL, US
Posts: 64
Quote:
Originally posted by Agent86

and I'll be golden?
Yeah, that's the way it looks. I just re-confirmed again.

On the one hand, it's nice to finally have the kinks in MFST2 resolved. On the other, I feel pretty silly about that 127MB vs 128MB thing.

Ah well. Live and learn.

MC
Merle Corey is offline   Reply With Quote
Old 08-19-2002, 05:46 PM   #138
Robert S
Registered User
 
Join Date: Jul 2002
Location: Cambridgeshire, UK
Posts: 9,725
Merle, 90% of discoveries are things that people, having heard them, say 'I could've thought of that'. Trust me, the 127Mb thing is not something you should feel ashamed of, quite the reverse, be proud. In fact I feel proud just for giving you a bit of prodding to help you on your way.

So, to finish up, we need to get this into the right places, obviously Hinsdale would be a good place to start. We'll have to wait for Tiger to resurface before we can get his MFS Tools docs changed, but we should probably try and get a mod to change his top post on the MFS Tools 2.0 announce thread.

Also, we need to get the emergency swap strategy worked out so people who come here with 64Mb swap and a green screen loop can learn how to save their TiVoes. It would obviously be good if someone who's actually done this could write it up.

Anyway, I'll get on rewriting the top post on this thread.
__________________
Please do not PM me asking for TiVo backups. I don't have any.
Robert S is offline   Reply With Quote
Old 08-19-2002, 06:17 PM   #139
Merle Corey
Registered User
 
Join Date: Aug 2001
Location: Mount Prospect, IL, US
Posts: 64
Oh, I'm not ashamed of it at all - I'm pretty puffed, truth be told. I just had a very large "D'oh!" moment when I realized what was going on, especially in light of that "128MB is such a nice, round number" post that I made elsewhere yesterday.

(And in all fairness, the limit is actually 133890048 bytes - about .3MB less than 128MB. 127MB just has the distinction of being the largest whole number within the limit. Theoretically speaking, Tiger should probably just have -s just be a toggle to activate the larger swap rather than a configurable value.)

I'll go ahead and confirm the swap requirements for very large configs (and I've made arrangements to get that second 120GB), but I really don't think there are any big surprises left for us to find.

I pm'd Hinsdale yesterday with regard to still needing *ahem* 128MB swap for larger configs. I haven't heard anything back yet, nor has there been an update to the How-To, but I assume he's just busy.

Beyond that, it looks like we're finally putting a wrap on this thing.

(Can I get a "woohoo!"?)

MC
Merle Corey is offline   Reply With Quote
Old 08-19-2002, 06:37 PM   #140
stormsweeper
How *you* doin'?
 
stormsweeper's Avatar
 
Join Date: Nov 2001
Location: NYC, USA
Posts: 424
Re: Much ado about nothing...

Quote:
Originally posted by Merle Corey
The bug in MFST2 is that it fails to adjust for improper swap sizes fed to it on the command line. This is compounded by the README claiming that all swap sizes up to 512MB are valid.

So, I ran another test, this time using -s 127. It worked just fine.
Yeah, I had that suspicion, as well. I even asked if anyone had tried specifying a swap more than 64MB and less than 128 but didn't get a response then. ( http://www.tivocommunity.com/tivo-vb...r=2#post595529 ) At the time I had fixed my problem and didn't have a suitable spare drive for testing anymore.

As to why you're having to reboot between restoring and running mkswap - the drive's partition map needs to be reread. I'm not enough of a linux guru to know how to do that from the command line, unless forcing a reread in pdisk will do it.

Last edited by stormsweeper : 08-19-2002 at 06:42 PM.
stormsweeper is offline   Reply With Quote
Old 08-19-2002, 08:21 PM   #141
hinsdale
TiVo Forum Special Member
 
Join Date: Apr 2001
Location: Hinsdale, IL, US
Posts: 83
Merle and Robert, I received your emails and thank you for the updates and good work on narrowing down the cause. I had mentioned to several people that emailed me over the last few weeks to try -s 127 and report their results as a possible solution to the swap file failure (apparently no one did this or reported their results). As stormsweeper mentioned this was one of the first theories floated as to the failure of the -s 128 creation. I hadnt had time to test this myself and wasnt following the thread closely enough to realize that this had not yet been tested.

I will be updating the How-To to incorporate the larger swap partition creation.
hinsdale is offline   Reply With Quote
Old 08-19-2002, 09:05 PM   #142
Robert S
Registered User
 
Join Date: Jul 2002
Location: Cambridgeshire, UK
Posts: 9,725
Alternative suggestion for emergency swap for green screen recovery:

Use pdisk to transpose the labels on hdx8 and hdx4/7, run mkswap on hdx8.

Avoids problem with hacking fstab or rc.sysinit to activate swap - so may even work on DTiVoes and Series|2's. Would have to execute it just perfectly and back out correctly too.
__________________
Please do not PM me asking for TiVo backups. I don't have any.
Robert S is offline   Reply With Quote
Old 08-19-2002, 10:06 PM   #143
DCIFRTHS
I dumped SDV / cable
 
DCIFRTHS's Avatar
 
Join Date: Jan 2000
Location: New York
Posts: 2,075
Quote:

(Can I get a "woohoo!"?)

MC

woohoo

I haven't contributed anything technical to this discussion, but I have been following it VERY closely. This is really good news. You guys invested a lot, and I want to say - Thanks.

I really hope that everything is okay with Tiger. Hopefully he just has a new job, and hasn't had time to check in here....
DCIFRTHS is offline   Reply With Quote
Old 08-20-2002, 09:48 AM   #144
stormsweeper
How *you* doin'?
 
stormsweeper's Avatar
 
Join Date: Nov 2001
Location: NYC, USA
Posts: 424
Quote:
Originally posted by Robert S
Alternative suggestion for emergency swap for green screen recovery:

Use pdisk to transpose the labels on hdx8 and hdx4/7, run mkswap on hdx8.

Avoids problem with hacking fstab or rc.sysinit to activate swap - so may even work on DTiVoes and Series|2's. Would have to execute it just perfectly and back out correctly too.
Eek, and this would probably break a future upgrade too. I wouldn't recommend keeping this config for any longer than absolutely necessary. Be sure to change the partition map before you make a new backup.
stormsweeper is offline   Reply With Quote
Old 08-20-2002, 12:12 PM   #145
BobCamp1
Registered User
 
Join Date: May 2002
Posts: 992
I have been watching this thread with interest, as I want to upgrade my Tivo but I'm waiting for the problems with MFSTools to get resolved. (Thanks to everyone for all that work, I wish I had that much spare time!)

Hinsdale has already updated the instructions (man that was fast!) and has put in the -s 127 parameter.

However, isn't there a problem with swap file size when adding a very large B drive? I thought Merle's research (and other people's information) indicated that if the combined capacity was greater than 140GB, then you needed a 127 MB swap file. However, Hinsdale's instructions for adding a larger B drive don't mention this.

So, if I have a single 30GB A drive and add a 120GB B drive, that equals 150 GB. But according to Hinsdale's instructions (step 10, config #1), I'm just typing in:

mfsadd -x /dev/hdc /dev/hdb (Boot CD and Floppy users command)

Doesn't this just use my original 64MB swap file? Isn't that too small to avoid the GSOD/reboot problem with my new 150 GB capacity?

I'm thinking of copying my old A drive to the new 120 GB drive (using the -s 127 parameter to create a larger swap file), then using my old A drive as the new B drive. Unless there is something in MFSTools that lets me expand my swap file on the old A drive while preserving recordings.

Besides, when you have a small amount of RAM you generally need a bigger swap file. All series 1 units with upgraded hard drives should probably use a 127 MB swap file since they only have 16MB of RAM. What's an extra 63 MB for a swap file when you're adding a 120 GB hard drive?

Am I just being paranoid, or should I use the 127 MB swap file for my upgrade?
BobCamp1 is offline   Reply With Quote
Old 08-20-2002, 12:24 PM   #146
Robert S
Registered User
 
Join Date: Jul 2002
Location: Cambridgeshire, UK
Posts: 9,725
I would definitely recommend upgrading swap if at all possible. If you do a pipe transfer (will take several hours) to the new drive, you can save all your recordings, expand swap and stay in a single-drive configuration for now and add a large B drive later with mfsadd.

Alternatively if you just use mfsadd to add a B drive as long as your machine is a Series 1 standalone, you can add extra swap if your machine gets caught in a green screen loop. At 150Gb you're right on the limit for mfsfix, the true limit is believe to be between 150 and 155Gb, so you may or may not have problems.
__________________
Please do not PM me asking for TiVo backups. I don't have any.
Robert S is offline   Reply With Quote
Old 08-21-2002, 07:59 AM   #147
mrtickle
Registered User
 
Join Date: Aug 2001
Location: Birmingham, UK
Posts: 2,824
Quote:
Originally posted by hinsdale
Merle and Robert, I received your emails and thank you for the updates and good work on narrowing down the cause. I had mentioned to several people that emailed me over the last few weeks to try -s 127 and report their results as a possible solution to the swap file failure (apparently no one did this or reported their results). As stormsweeper mentioned this was one of the first theories floated as to the failure of the -s 128 creation. I hadnt had time to test this myself and wasnt following the thread closely enough to realize that this had not yet been tested.

I will be updating the How-To to incorporate the larger swap partition creation.
I see it's now changed to 127 in the guide, thanks. I can't find any mention though of the fact that you have to make the big drive the A drive, because otherwise the bigger swap won't fit. Or does MFStools2 create the swap on the B drive?
mrtickle is offline   Reply With Quote
Old 08-21-2002, 08:37 AM   #148
Robert S
Registered User
 
Join Date: Jul 2002
Location: Cambridgeshire, UK
Posts: 9,725
No, MFS Tools can't put a swap partition on the B drive (although this is possible in principle, it's probably not desirable and you would have to modify TiVo system files after a software update).

It's quite tricky to explain, but it's important to explain to be people that they need to choose upgrade profiles that allow MFS Tools 2 to increase swap for them. So things like dd + mfsadd and using mfsadd to add a B drive to an unmodified A drive should be deprecated in favour of pipe transfers, which have the same effect in almost all cases with only a little more pain.
__________________
Please do not PM me asking for TiVo backups. I don't have any.
Robert S is offline   Reply With Quote
Old 08-21-2002, 09:23 AM   #149
Cpen
CPenRun
 
Join Date: Jul 2002
Location: Cambridge, MA
Posts: 50
Tuning back into conversation

Robert:

So - When I upgraded my Philips 312 (2-drive) TiVo to 120 MB, I did not use the -s command (at all). As a result, my upgrade used the default 64MB swap file (confirmed by looking at var logs). Should I not be concerned because my total hard drive size is under 140MB?

or

Do I need to re-run my upgrade and use -s 127

I think I'm good to go, as I did not use -s128 (I have a working 64MB swap) and my hard drive space is under 140 MB (which I beleive means a 64MB swap will work just fine). If this is true, then I was just lucky - go figure.

P
Cpen is offline   Reply With Quote
Old 08-21-2002, 09:37 AM   #150
Robert S
Registered User
 
Join Date: Jul 2002
Location: Cambridgeshire, UK
Posts: 9,725
That's our current belief. Merle is planning to do some more experiments on big drives, so we may get really solid answers to these questions.

If we can get my partition relabeling idea proved out (and I think we're still waiting on an S2 owner successfully using mkswap), then our advice to people with working TiVoes over the limit would be to wait for the green screen to happen and then use emergency swap, rather than trash a perfectly good system.

Assuming no-one pops up in the next few days pointing out a major problem we've missed, I think we can say that MFS Tools 2.0 is a safe and effective upgrade tools when used within our guidelines.
__________________
Please do not PM me asking for TiVo backups. I don't have any.
Robert S is offline   Reply With Quote
Reply
Forum Jump




Thread Tools


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Advertisements

TiVo Community
Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
vBulletin Skins by: Relivo Media

(C) 2013 Magenium Solutions - All Rights Reserved. No information may be posted elsewhere without written permission.
TiVoŽ is a registered trademark of TiVo Inc. This site is not owned or operated by TiVo Inc.
All times are GMT -5. The time now is 09:42 PM.
OUR NETWORK: MyOpenRouter | TechLore | SansaCommunity | RoboCommunity | MediaSmart Home | Explore3DTV | Dijit Community | DVR Playground |