Saturday, October 5, 2013

RANCID on Fedora FIX- "Rlog output ended early. Expected RCS file..."

RANCID is Great!

RANCID, Really Awesome New Cisco confIg Differ (link) is an absolutely fantastic Cisco configuration backup system. It has native support for Cisco switches, routers, and firewalls, and stores revision history (through Subversion (link)). This allows SysAdmins to pull up the changes which were made, say, between last Tuesday when SystemX broke and today to pinpoint the problem update.

Rancid can be configured to reach out all the time through cron, although the official documentation from Rancid's admins has it check for changes every hour. If no changes have been made, no version is checked into the Rancid database.

I use Fedora 17/18 (link) for most all the linux tools on our network. It's an environment I'm comfortable with, and it's supported natively for almost every tool I've set up on it, RANCID included.

Except For A Strange Error Message...

I set up Rancid according to the official documentation here, but ran into a specific problem when accessing the web page of the 'networking' folder. The error message follows: Error: Rlog output ended early. Expected RCS file "/opt/cvs/project/file,v".

This error is documented on RANCID's web page (link), but there is no fix documented there or anywhere else I could easily find.

The Fix!

After using my google-foo for several hours, I stumbled upon a possible fix (link) - to add a configuration line to the viewvc.conf file that controls how ViewVC uses subversion and other tools. Here's how:

1. Follow the instructions for RANCID up to step 24.

2. Modify the following in the viewvc.conf file at /etc/viewvc/viewvc.conf
#cvs_roots = cvs:
root_parents = /usr/local/rancid/var/CVS : cvs
rcs_path = /usr/local/bin
address = <a>Email Helpdesk</a>
#use_enscript = 1
#enscript_path = /usr/bin/
#use_highlight = 1
#highlight_path = /usr/bin

3. Add the following line to the same file:
use_rcsparse = 1

4. Follow the rest of the instructions as listed. 


RANCID really is a fantastic tool. I hope with this fix you're able to enjoy it also!


  1. I've the same problem!
    Traceback (most recent call last):
    File "/usr/local/viewvc-1.1.21/lib/", line 4826, in main
    File "/usr/local/viewvc-1.1.21/lib/", line 402, in run_viewvc
    File "/usr/local/viewvc-1.1.21/lib/", line 2264, in view_directory
    file_data, options)
    File "/usr/local/viewvc-1.1.21/lib/vclib/ccvs/", line 266, in dirlogs
    alltags = _get_logs(self, path_parts, entries_to_fetch, rev, subdirs)
    File "/usr/local/viewvc-1.1.21/lib/vclib/ccvs/", line 1025, in _get_logs
    % file.path)
    Error: Rlog output ended early. Expected RCS file "/usr/local/rancid/var/CVS/networking/router.db,v"
    I also tried editing the configuration file as you suggest but the message don't change!!!
    It's driving me mad!

  2. Thanks a lot for your helpfull info.

  3. Wow! I've been searching for hours on this - THANK YOU THANK YOU!!!