# Question about editing rc.sysinit.author file on HD TiVo



## Runch Machine (Feb 7, 2002)

I am trying to edit the rc.sysinit.author file to include the command /tvbin/si9190test -format 10801 -c 1 -d 1. For those who may not know, this command will activate the component and HDMI outputs at the same time. 

I have used Filezilla to transfer the rc.sysinit.author file to my windows XP computer, edited the file using Wordpad, adding the command above at the very end, set Filezilla to transfer using binary mode, changed the /etc/rc.d directory to be writable using mount -o remount ,rw / made the file executable by using chmod +x rc.sysinit.author. Then I set back to read only using mount -o remount ,ro /. 

The problem is that when I reboot the HD TiVo, it does not run the rc.sysinit.author file. Telnet will not access HD Tivo and Filezilla won't either. Of course the si9190test command doesn't function either. 

I would appreciate any advice as to what I am doing wrong that is causing this not to work. Thanks.


----------



## rbautch (Feb 6, 2004)

Runch Machine said:


> I am trying to edit the rc.sysinit.author file to include the command /tvbin/si9190test -format 10801 -c 1 -d 1. For those who may not know, this command will activate the component and HDMI outputs at the same time.
> 
> I have used Filezilla to transfer the rc.sysinit.author file to my windows XP computer, edited the file using Wordpad, adding the command above at the very end, set Filezilla to transfer using binary mode, changed the /etc/rc.d directory to be writable using mount -o remount ,rw / made the file executable by using chmod +x rc.sysinit.author. Then I set back to read only using mount -o remount ,ro /.
> 
> ...


 You have to edit your author file with a unix editor. Wordpad adds dos line endings that look like this: ^M. Unless you have a serial cable, you'll have to pull the drive now, and either delete the dos line endings manually, run dos2unix on it, or copy an new author file to your drive. Think of this as a valuable learning experience.


----------



## Yog-Sothoth (Jun 14, 2005)

In the future, use this to edit Unix files (File Format > Unix). I first used this program years ago, as I was trying to figure out why my smb.conf file (for Samba) wouldn't load correctly.


----------



## alert5 (Nov 16, 2003)

> Originally Posted by Runch Machine
> I am trying to edit the rc.sysinit.author file to include the command /tvbin/si9190test -format 10801 -c 1 -d 1. For those who may not know, this command will activate the component and HDMI outputs at the same time.
> 
> I have used Filezilla to transfer the rc.sysinit.author file to my windows XP computer, edited the file using Wordpad, adding the command above at the very end, set Filezilla to transfer using binary mode, changed the /etc/rc.d directory to be writable using mount -o remount ,rw / made the file executable by using chmod +x rc.sysinit.author. Then I set back to read only using mount -o remount ,ro /.
> ...


As one of many bitten by this XP nonsense, I avoid these issues altogether by using Linux to access and edit my zippered boxes.

Dual booting XP and Linux is easy to set up if you don't have a dedicated Linux machine to work from. Well worth the effort IMHO to avoid pulling a hard drive.


----------



## MurrayW (Aug 28, 2005)

Runch Machine said:


> I am trying to edit the rc.sysinit.author file to include the command /tvbin/si9190test -format 10801 -c 1 -d 1. For those who may not know, this command will activate the component and HDMI outputs at the same time.
> 
> I have used Filezilla to transfer the rc.sysinit.author file to my windows XP computer, edited the file using Wordpad, adding the command above at the very end, set Filezilla to transfer using binary mode, changed the /etc/rc.d directory to be writable using mount -o remount ,rw / made the file executable by using chmod +x rc.sysinit.author. Then I set back to read only using mount -o remount ,ro /.
> 
> ...


I'd like to enable both component and HDMI outputs at the same time, so I think I will try this. I just want to make sure I have everything straight before I start. Borrowing from Runch Machine's original post, can someone let me know if this is the correct sequence and syntax to use:
1. FTP into the TiVo using Filezila. Use binary mode?

2. Transfer the rc.sysinit.author file to my XP computer.

3. Use a Unix friendly editor such as metapad or win32pad to add


> /tvbin/si9190test -format 10801 -c 1 -d 1


 Does it matter where I add this line to the rc.sysinit.author file?

4. Change the /etc/rc.d directory to be writable using


> mount -o remount ,rw /


 Do I have to point it to the /etc/rc.d directory somehow?

5. Transfer the rc.sysinit.author file to the TiVo using binary mode.

6. Make the file executable by using


> chmod +x rc.sysinit.author


7. Set the /etc/rc.d directory back to read only using


> mount -o remount ,ro /


Thanks in advance for the help.

Murray


----------



## JWThiers (Apr 13, 2005)

MurrayW said:


> I'd like to enable both component and HDMI outputs at the same time, so I think I will try this. I just want to make sure I have everything straight before I start. Borrowing from Runch Machine's original post, can someone let me know if this is the correct sequence and syntax to use:
> 1. FTP into the TiVo using Filezila. Use binary mode?
> 
> 2. Transfer the rc.sysinit.author file to my XP computer.
> ...


or you can edit it in place with joe or hackman or vi...


----------



## MurrayW (Aug 28, 2005)

JWThiers said:


> or you can edit it in place with joe or hackman or vi...


I read a few posts that said the ftp'ing was the preferred method. Is that not true any longer? Also, I assume it really doesn't matter where I add this line (beginning, middle or end of the file) -- is that true?
thanks,
Murray


----------



## Redux (Oct 19, 2004)

MurrayW said:


> I read a few posts that said the ftp'ing was the preferred method.


Not sure most people would say that.

I personally do like ftp'ing out and editing in my more normal environment because I've got the search and editing tools I'm used to, just overall more comfortable. Vi and even joe are a little like wordstar, clumsy, and it all brings back bad memories. You can munge up a file pretty badly by ham-handed editing it live on the Tivo.

But you've got downside with my approach. You have to make sure your text editor is configured to save with Unix line endings (I use BBEdit on the Mac). Or I suppose you could apply a utility at the end to convert them. Plus the file ftp'd back in has to be chmod'ed and if you forget it can be a real pain to fix.


----------



## Runch Machine (Feb 7, 2002)

Thanks for all the suggestions.

Bottom line is that I rezippered the drive which replaced the rc.sysinit.author file with a working version. Then after rebooting HD Tivo I accessed HD Tivo with Telnet and edited the rc.sysinit.author file using the Joe file editor.

I put the si9190test command in after the crond startup and preceded the Si9190test command with a sleep 30 command. I don't think that was necessary, but it was nearly 3am at the time and I wanted to get this done. 

For those of you who want to try this, note that if your TV drops its HDMI connection and then activates it again, you will lose your component output until you run si9190test again. Most TVs that I have seen keep the HDMI connection active even when the TV is turned off or the input is not selected. Is these cases, you will be able to have both outputs always on. 

However, if you have a TV that deactivates its HDMI connection when it is turned off or not in use, then this will be of no use to you.

Anyway, installed as described above, if you boot up HD Tivo with both HDMI and component connected, you will have a picture on both until the unit starts downloading data from the satellite. Then the component picture will dissappear for about 90 seconds. 

I am going to experiment with locating the command higher in the file and see what happens.

UPDATE: I moved it up to just under the section that starts caller ID and removed the sleep 30. It works great and the amount of time the component output is off during boot up is just under 30 seconds. 

Remember when you do this to use rw to change access to read-write before you start editing the file. Then use ro for read-only after you are done editing. 

Editing with Joe gets easier the more you do it.


----------



## JWThiers (Apr 13, 2005)

MurrayW said:


> I read a few posts that said the ftp'ing was the preferred method. Is that not true any longer? Also, I assume it really doesn't matter where I add this line (beginning, middle or end of the file) -- is that true?
> thanks,
> Murray


Generally what I do is if it is just a simple add a line or two just do it in place, but if I have a lot of more complex search, cut, paste etc FTP out and bring it back.As to where to add that line I haven't the foggiest, I don't have and HD unit.


----------



## cheer (Nov 13, 2005)

Don't think it matters where you put the command.

Personally I do almost all editing on the Tivo itself with vi, but then I've been using vi for years. It's...um...user-hostile. But it works.

If you like to edit on the PC, I recommend an editor called TextPad, which can edit files safely for *nix systems. Alternatively, there's a utility for the Tivo called dos2unix. If the zipper installs the all-in-one utils, it ought to be there -- Gunny, does Zipper install the AIO tools? Anyway you can run dos2unix on the Tivo against a file you've uploaded from your PC and it will remove the extra linefeeds..


----------



## rbautch (Feb 6, 2004)

cheer said:


> Don't think it matters where you put the command.
> 
> Personally I do almost all editing on the Tivo itself with vi, but then I've been using vi for years. It's...um...user-hostile. But it works.
> 
> If you like to edit on the PC, I recommend an editor called TextPad, which can edit files safely for *nix systems. Alternatively, there's a utility for the Tivo called dos2unix. If the zipper installs the all-in-one utils, it ought to be there -- Gunny, does Zipper install the AIO tools? Anyway you can run dos2unix on the Tivo against a file you've uploaded from your PC and it will remove the extra linefeeds..


Yes, Zipper installs the AIO tool set.


----------



## cheer (Nov 13, 2005)

rbautch said:


> Yes, Zipper installs the AIO tool set.


Way cool. So just transfer the file to the Tivo via ftp, then telnet it and run "dos2unix -u <filename>" and hit Enter, and Bob's your uncle.


----------



## PortlandPaw (Jan 11, 2004)

I don't have an HD TiVo, but I understand hackman runs on it just fine and it does all the editing without having to worry about binary mode, or carriage returns, or any of those details we all forget from time to time. See my sig.


----------



## cheer (Nov 13, 2005)

PortlandPaw said:


> I don't have an HD TiVo, but I understand hackman runs on it just fine and it does all the editing without having to worry about binary mode, or carriage returns, or any of those details we all forget from time to time. See my sig.


I do have an HD Tivo, and yes I can attest to the fact that hackman runs on it just fine. I just never got in the habit of using it for editing.


----------



## PortlandPaw (Jan 11, 2004)

Isn't it amazing (and gratifying) to discover you have the correct tool right under your nose?


----------



## cheer (Nov 13, 2005)

PortlandPaw said:


> Isn't it amazing (and gratifying) to discover you have the correct tool right under your nose?


Don't say that in a crowded bar.


----------



## PortlandPaw (Jan 11, 2004)

Usually the beer mug is right under my nose.


----------



## JoelCFC25 (Apr 25, 2006)

I'm surprised that there aren't more people who know how to use vi. There were times when it was very common to get access to a *nix box and that was the only editor available, so it was sink or swim....and if you didn't know vi....*gurgle* *glug glug glug*


----------



## cheer (Nov 13, 2005)

I guess it depends on what you mean by common. The average PC user, I expect, has never had a shell account or otherwise interacted with a *nix box. On the other hand, shell accounts were common as a percentage of Internet users back in the early days. But that was a rather small population compared to today.

:wq


----------



## Yog-Sothoth (Jun 14, 2005)

I've always preferred "nano" for editing directly on a Linux box.


----------



## MEJHarrison (Sep 23, 2003)

JoelCFC25 said:


> I'm surprised that there aren't more people who know how to use vi.


I haven't used vi in years. So I was a little concerned when I hacked my Tivo recently. But it all came back just like riding a bicycle. It's really not a bad editor once you learn the basics. 

One of my college professors actually wrote a college level computer science text book using vi.  This was late 80's, so there were much better options available at the time (Like Word on a Mac). But that's what he was comfortable with.


----------



## 1-big-dog (May 20, 2006)

I have a question about editing files on the Tivo. I have a background with Unix (HP and Sun computers) but know very little about Linux and even less about the Linux on the Tivos. 

I have zippered my Tivos and run the enhancement scripts. 

{Aside: Thanks guys, you are rock stars!} 

Now I want to go in and use vi to edit some files. I telnet into the Tivo and when I open a file in vi it opens read-only. I checked the file permissions and they are 777 so anybody should be able to edit it. So I assume I am not root when I telnet in? who am I? (couldn't find an equivalent of the whoami command, so ??) And why can't I use vi to edit files that are 777? Any help you can provide would be greatly appreciated.


----------



## D'Ecosse (May 24, 2006)

I'm having same basic problem re editing/replacing or deleting files - also have the 777 permission on the applicable directories (I was in ftp rather than telnet)
Do I need to be in telnet to change something to allow editing of these files? 

Please excuse the rookie limited *nix familiarity!


----------



## cheer (Nov 13, 2005)

By default, the root partition on the Tivo is read-only -- which is why you get the read-only file messages despite the permissions.

```
mount -o remount,rw /
```
This will remount root as read-write. Make your changes, then:

```
mount -o remount,ro /
```
This will remount as read-only.

*Do not leave your root mounted as read-write!* It's not a journalling filesystem, and the Tivo doesn't ever run e2fsck on root (since Tivo thinks it's always read-only). This combined with the fact that the Tivo never shuts down gracefully can lead to orphaned inodes and other filesystem problems.


----------



## 1-big-dog (May 20, 2006)

Oh....that's why zipper and tweak put those aliases in the .profile!!!!! Great, thanks a bunch!!!!


----------

