Bug 512068 - Review Request: rancid - Really Awesome New Cisco confIg Differ
Summary: Review Request: rancid - Really Awesome New Cisco confIg Differ
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: Package Review
Version: rawhide
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: David Nalley
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
: rancid (view as bug list)
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2009-07-16 07:15 UTC by Gary T. Giesen
Modified: 2014-11-20 13:29 UTC (History)
9 users (show)

Fixed In Version: 2.3.2-3.fc11
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2009-08-15 08:13:31 UTC
Type: ---
david: fedora-review+
gwync: fedora-cvs+


Attachments (Terms of Use)

Description Gary T. Giesen 2009-07-16 07:15:07 UTC
Spec URL: http://giesen.fedorapeople.org/rancid/rancid.spec
SRPM URL: http://giesen.fedorapeople.org/rancid/rancid-2.3.2-1.fc11.src.rpm
Description: 
RANCID monitors a router's (or more generally a device's) configuration, 
including software and hardware (cards, serial numbers, etc) and uses CVS 
(Concurrent Version System) or Subversion to maintain history of changes.

Comment 1 Gary T. Giesen 2009-07-16 07:15:32 UTC
rpmlint output:

rpmlint -i rancid-2.3.2-1.fc11.src.rpm 
1 packages and 0 specfiles checked; 0 errors, 0 warnings.

Comment 2 Gary T. Giesen 2009-07-16 07:16:56 UTC
*** Bug 451189 has been marked as a duplicate of this bug. ***

Comment 3 Mamoru TASAKA 2009-07-16 15:10:09 UTC
Well, I still think that the names of man pages like {a,b,c..}login.1.gz
par.1.gz or so will easily cause name space conflict.
Would you discuss the naming of binaries and man packages with the
upstream first?

Comment 4 Gary T. Giesen 2009-07-16 16:53:19 UTC
I will see what I can do, but rancid is a long-established and widely-used utility in the ISP community, so I doubt I'll get much traction there.

Comment 5 David Nalley 2009-07-16 18:54:30 UTC
I am thrilled to see this in Fedora (it was actually on my todo list - though I wish upstream would accept jcollie's git patch. ) 

I'd like to hear back what upstream says about the naming issue as I think that's a potentially significant conflict. 

MUST: rpmlint must be run on every package. The output should be posted in the review.

[ke4qqq@nalleyt61 SPECS]$ rpmlint ./rancid.spec 
0 packages and 1 specfiles checked; 0 errors, 0 warnings.
[ke4qqq@nalleyt61 SPECS]$ rpmlint ../SRPMS/rancid-2.3.2-1.fc11.src.rpm 
1 packages and 0 specfiles checked; 0 errors, 0 warnings.
[ke4qqq@nalleyt61 SPECS]$ rpmlint ../RPMS/i586/rancid-* 
rancid.i586: W: non-standard-uid /etc/rancid/rancid.conf rancid
rancid.i586: W: non-standard-gid /etc/rancid/rancid.conf rancid
rancid.i586: E: non-readable /etc/rancid/rancid.conf 0640
rancid.i586: W: non-standard-uid /var/rancid/CVS rancid
rancid.i586: W: non-standard-gid /var/rancid/CVS rancid
rancid.i586: E: non-standard-dir-perm /var/rancid/CVS 0700
rancid.i586: W: non-standard-uid /etc/rancid/lg.conf rancid
rancid.i586: W: non-standard-gid /etc/rancid/lg.conf rancid
rancid.i586: E: non-readable /etc/rancid/lg.conf 0640
rancid.i586: W: non-standard-uid /var/rancid rancid
rancid.i586: W: non-standard-gid /var/rancid rancid
rancid.i586: E: non-standard-dir-perm /var/rancid 0700
rancid.i586: W: non-standard-uid /var/rancid/CVS/CVSROOT rancid
rancid.i586: W: non-standard-gid /var/rancid/CVS/CVSROOT rancid
rancid.i586: E: version-control-internal-file /var/rancid/CVS/CVSROOT
rancid.i586: E: non-standard-dir-perm /var/rancid/CVS/CVSROOT 0700
rancid.i586: W: non-standard-uid /etc/rancid rancid
rancid.i586: W: non-standard-gid /etc/rancid rancid
rancid.i586: E: non-standard-dir-perm /etc/rancid 0750
rancid.i586: W: non-standard-uid /var/log/rancid rancid
rancid.i586: W: non-standard-gid /var/log/rancid rancid
rancid.i586: E: non-standard-dir-perm /var/log/rancid 0700
rancid.i586: W: log-files-without-logrotate /var/log/rancid
rancid.i586: W: non-standard-dir-in-var rancid 
2 packages and 0 specfiles checked; 8 errors, 16 warnings.

I'd personally like to see log rotate fixed, but don't think it's a blocker.   The rest looks like rpmlint just complaining, though I don't think there is anything that's a blocker. 

OK: The package must be named according to the Package Naming Guidelines .
OK: The spec file name must match the base package %{name}, in the format %{name}.spec unless your package has an exemption. 
OK: The package must meet the Packaging Guidelines .
OK: The package must be licensed with a Fedora approved license and meet the Licensing Guidelines .
OK: The License field in the package spec file must match the actual license.
OK: If (and only if) the source package includes the text of the license(s) in its own file, then that file, containing the text of the license(s) for the package must be included in %doc
OK: The spec file must be written in American English.
OK: The spec file for the package MUST be legible. 
OK: The sources used to build the package must match the upstream source, as provided in the spec URL. Reviewers should use md5sum for this task. If no upstream URL can be specified for this package, please see the Source URL Guidelines 

[ke4qqq@nalleyt61 SOURCES]$ md5sum rancid-2.3.2.tar.gz*
4e2de3ff6850b311c0e2a442f7ae5d82  rancid-2.3.2.tar.gz
4e2de3ff6850b311c0e2a442f7ae5d82  rancid-2.3.2.tar.gz.1

OK: The package MUST successfully compile and build into binary rpms on at least one primary architecture. 
NA: If the package does not successfully compile, build or work on an architecture, then those architectures should be listed in the spec in ExcludeArch. Each architecture listed in ExcludeArch MUST have a bug filed in bugzilla, describing the reason that the package does not compile/build/work on that architecture. The bug number MUST be placed in a comment, next to the corresponding ExcludeArch line. 
OK: All build dependencies must be listed in BuildRequires, except for any that are listed in the exceptions section of the Packaging Guidelines ; inclusion of those as BuildRequires is optional. Apply common sense.
NA: The spec file MUST handle locales properly. This is done by using the %find_lang macro. Using %{_datadir}/locale/* is strictly forbidden.
NA: Every binary RPM package (or subpackage) which stores shared library files (not just symlinks) in any of the dynamic linker's default paths, must call ldconfig in %post and %postun. 
NA: If the package is designed to be relocatable, the packager must state this fact in the request for review, along with the rationalization for relocation of that specific package. Without this, use of Prefix: /usr is considered a blocker. 
OK: A package must own all directories that it creates. If it does not create a directory that it uses, then it should require a package which does create that directory. 
OK: A Fedora package must not list a file more than once in the spec file's %files listings. 
OK: Permissions on files must be set properly. Executables should be set with executable permissions, for example. Every %files section must include a %defattr(...) line. 
OK: Each package must have a %clean section, which contains rm -rf %{buildroot} (or $RPM_BUILD_ROOT). 
OK: Each package must consistently use macros. 
OK: The package must contain code, or permissable content. 
NA: Large documentation files must go in a -doc subpackage. (The definition of large is left up to the packager's best judgement, but is not restricted to size. Large can refer to either size or quantity). 
OK: If a package includes something as %doc, it must not affect the runtime of the application. To summarize: If it is in %doc, the program must run properly if it is not present. 
NA: Header files must be in a -devel package. 
NA: Static libraries must be in a -static package. 
NA: Packages containing pkgconfig(.pc) files must 'Requires: pkgconfig' (for directory ownership and usability). 
NA: If a package contains library files with a suffix (e.g. libfoo.so.1.1), then library files that end in .so (without suffix) must go in a -devel package. 
NA: In the vast majority of cases, devel packages must require the base package using a fully versioned dependency: Requires: %{name} = %{version}-%{release} 
NA: Packages must NOT contain any .la libtool archives, these must be removed in the spec if they are built.
NA: Packages containing GUI applications must include a %{name}.desktop file, and that file must be properly installed with desktop-file-install in the %install section. If you feel that your packaged GUI application does not need a .desktop file, you must put a comment in the spec file with your explanation. 
OK: Packages must not own files or directories already owned by other packages. The rule of thumb here is that the first package to be installed should own the files or directories that other packages may rely upon. This means, for example, that no package in Fedora should ever share ownership with any of the files or directories owned by the filesystem or man package. If you feel that you have a good reason to own a file or directory that another package owns, then please present that at package review time. 
OK: At the beginning of %install, each package MUST run rm -rf %{buildroot} (or $RPM_BUILD_ROOT). 
OK: All filenames in rpm packages must be valid UTF-8.

Comment 6 Gary T. Giesen 2009-07-16 20:36:51 UTC
I'll fix up the logrotate, and double check all the permissions to make sure they're appropriate. I'm not holding my breath on getting positive results re: namespace collision. Is anyone actually aware of any packages that collide? Rancid 1.0 was released in June of 1999, so the package is 10 years old and is pretty established.

Comment 7 Daniel Roesen 2009-07-17 08:07:59 UTC
Excellent news that someone finally packages up RANCID...

As I'm about to install RANCID here for a somewhat larger deployment (order of several hundred devices being monitored), I'm looking forward to use your package and provide feedback on problems if I find some.

I'm not really fond of RANCID yet from the software admin side, but I had to hack up original sources several times to make it "behave" in the past. I do hear that there are many patches and patchsets floating around, I hope the Fedora RPM will pick up the "usual canonical patchset(s)" to make life easier on users. I see a reference to "jcollie's git patch" e.g.

I'm not holding my breath either on the namespace discussion.

Gary, and ETA for the logrotate/perms-fixed version? I ponder holding off installation for that.

Comment 8 Gary T. Giesen 2009-07-17 15:59:00 UTC
I should have a new version tonight, I'm still doing testing on it to make sure everything works as planned.

Comment 9 Gary T. Giesen 2009-07-17 16:00:51 UTC
As another note, if there's any particular patch you want applied, let me know and  I'll definitely consider adding it. I'm looking to add the usercmd patch as well, since I believe it's been rejected several times by upstream but it's infinitely valuable to me.

Comment 10 Christopher McCrory 2009-07-18 17:58:53 UTC
FWIW a couple notes:

recommend not requiring telnet, rsh, ( and maybe openssh).  One or more are needed, but not necessarily all.  e.g. I don't even want rsh installed.  If an admin knows enough to want this package, they know what clients are needed also.

 
using /var/lib/rancid instead of /var/rancid might resolve some rpmlint warnings.

Comment 11 Gary T. Giesen 2009-07-18 18:30:51 UTC
I'm also considering not actually requiring CVS, since rancid can work with svn, and possibly git in the future. There really needs to be an RPM "Suggests" flag.

Comment 12 Christopher McCrory 2009-07-18 20:55:15 UTC
also crontab hardcodes /usr/lib/rancid/rancid-run which breaks on 64bit arch /usr/lib64/rancid/rancid-run .  recommend symlink in /usr/bin or generate at buildtime from within spec file.

in crontab: find ..  exec rm {} 
recommend exec rm '{}' in case a space shows up somewhere.  or use --delete ( maybe with --print)

maybe also add MAILTO=root in crontab so errors have a better chance of being read.  


rancid.conf file has a . in PATH <something>:.:<more> . recommend no '.' in PATH.


I could live with not requiring cvs as I use svn.

Comment 13 Gary T. Giesen 2009-07-22 08:10:00 UTC
New version:

Spec URL: http://giesen.fedorapeople.org/rancid/rancid.spec
SRPM URL: http://giesen.fedorapeople.org/rancid/rancid-2.3.2-2.fc11.src.rpm

Quite a few changes:

* Wed Jul 22 2009 Gary T. Giesen <giesen@snickers.org> 2.3.2-2
- Added logrotate (and updated crontab to let logrotate handle log file
  cleanup
- Removed Requires: for rsh, telnet, and openssh-clients
- Removed Requires: for cvs
- Cleaned up file permissions
- Added shell for rancid user for CVS tree creation and troubleshooting
- Patch cron file for installation path
- Removed installation of CVS root to permit SVN use
- Moved from libdir to libexecdir


rpmlint is still being whiny (but I don't believe it needs fixing):

$ rpmlint rancid-2.3.2-2.fc11.i586.rpm 
rancid.i586: W: non-standard-uid /etc/rancid/lg.conf rancid
rancid.i586: W: non-standard-gid /etc/rancid/lg.conf rancid
rancid.i586: E: non-readable /etc/rancid/lg.conf 0640
rancid.i586: W: non-standard-uid /etc/rancid/rancid.conf rancid
rancid.i586: W: non-standard-gid /etc/rancid/rancid.conf rancid
rancid.i586: E: non-readable /etc/rancid/rancid.conf 0640
rancid.i586: W: non-standard-uid /var/rancid rancid
rancid.i586: W: non-standard-gid /var/rancid rancid
rancid.i586: E: non-standard-dir-perm /var/rancid 0750
rancid.i586: W: non-standard-uid /etc/rancid rancid
rancid.i586: W: non-standard-gid /etc/rancid rancid
rancid.i586: E: non-standard-dir-perm /etc/rancid 0750
rancid.i586: W: non-standard-uid /var/log/rancid/old rancid
rancid.i586: W: non-standard-gid /var/log/rancid/old rancid
rancid.i586: E: non-standard-dir-perm /var/log/rancid/old 0750
rancid.i586: W: non-standard-uid /var/log/rancid rancid
rancid.i586: W: non-standard-gid /var/log/rancid rancid
rancid.i586: E: non-standard-dir-perm /var/log/rancid 0750
1 packages and 0 specfiles checked; 6 errors, 12 warnings.

Comment 14 Gary T. Giesen 2009-07-22 08:12:28 UTC
As a note for posterity, the non-standard directory permissions are required because both the logs and configs contain sensitive information (such as usernames, passwords, configuration logs) and thus eliminating read access by world.

Comment 15 Daniel Roesen 2009-07-22 08:21:43 UTC
Excellent, you have made some changes I was about to suggest (libexecdir, shell for rancid user). :) One left is to rename the GECOS field of the rancid user from "Account to run RANCID" to just "RANCID", given it will be used as full name in the email From field.

Comment 16 Gary T. Giesen 2009-07-23 01:55:16 UTC
New version:

Spec URL: http://giesen.fedorapeople.org/rancid/rancid.spec
SRPM URL: http://giesen.fedorapeople.org/rancid/rancid-2.3.2-3.fc11.src.rpm


One minor change, changed the GECOS per Daniel Roesen. This one should be good to go assuming there are no other issues that crop up.

Comment 17 David Nalley 2009-07-23 03:27:47 UTC
I tend to agree with lack of telnet and rsh, but I don't think that blocks the package, more of a preference than anything, so not within scope of the package review. 

provides and requires looks sane:

[ke4qqq@nalleyt61 i586]$ rpm -qp --provides ./rancid-2.3.2-3.fc11.i586.rpm 
config(rancid) = 2.3.2-3.fc11
rancid = 2.3.2-3.fc11
rancid(x86-32) = 2.3.2-3.fc11
[ke4qqq@nalleyt61 i586]$ rpm -qp --requires ./rancid-2.3.2-3.fc11.i586.rpm 
/bin/sh  
/bin/sh  
/usr/bin/expect  
/usr/bin/perl  
config(rancid) = 2.3.2-3.fc11
expect  
findutils  
iputils  
libc.so.6  
libc.so.6(GLIBC_2.0)  
libc.so.6(GLIBC_2.3)  
libc.so.6(GLIBC_2.3.4)  
libc.so.6(GLIBC_2.4)  
libutil.so.1  
libutil.so.1(GLIBC_2.0)  
logrotate  
perl  
perl >= 1:5
perl(CGI)  
perl(Getopt::Std)  
perl(LockFile::Simple)  
perl(Mail::Mailer)  
perl(POSIX)  
perl(Sys::Syslog)  
perl(newgetopt.pl)  
rpmlib(CompressedFileNames) <= 3.0.4-1
rpmlib(FileDigests) <= 4.6.0-1
rpmlib(PayloadFilesHavePrefix) <= 4.0-1
rtld(GNU_HASH)  
shadow-utils  

As you noted rpmlint still complaining about permissions - but doesn't appear to be a blocker. 

[ke4qqq@nalleyt61 i586]$ rpmlint ../../SPECS/rancid.spec 
0 packages and 1 specfiles checked; 0 errors, 0 warnings.
[ke4qqq@nalleyt61 i586]$ rpmlint ../../SRPMS/rancid-2.3.2-3.fc11.src.rpm 
1 packages and 0 specfiles checked; 0 errors, 0 warnings.
[ke4qqq@nalleyt61 i586]$ rpmlint ./rancid-2.3.2-3.fc11.i586.rpm 
rancid.i586: W: non-standard-uid /etc/rancid/lg.conf rancid
rancid.i586: W: non-standard-gid /etc/rancid/lg.conf rancid
rancid.i586: E: non-readable /etc/rancid/lg.conf 0640
rancid.i586: W: non-standard-uid /etc/rancid/rancid.conf rancid
rancid.i586: W: non-standard-gid /etc/rancid/rancid.conf rancid
rancid.i586: E: non-readable /etc/rancid/rancid.conf 0640
rancid.i586: W: non-standard-uid /var/rancid rancid
rancid.i586: W: non-standard-gid /var/rancid rancid
rancid.i586: E: non-standard-dir-perm /var/rancid 0750
rancid.i586: W: non-standard-uid /etc/rancid rancid
rancid.i586: W: non-standard-gid /etc/rancid rancid
rancid.i586: E: non-standard-dir-perm /etc/rancid 0750
rancid.i586: W: non-standard-uid /var/log/rancid/old rancid
rancid.i586: W: non-standard-gid /var/log/rancid/old rancid
rancid.i586: E: non-standard-dir-perm /var/log/rancid/old 0750
rancid.i586: W: non-standard-uid /var/log/rancid rancid
rancid.i586: W: non-standard-gid /var/log/rancid rancid
rancid.i586: E: non-standard-dir-perm /var/log/rancid 0750
1 packages and 0 specfiles checked; 6 errors, 12 warnings.
[ke4qqq@nalleyt61 i586]$ rpmlint ./rancid-debuginfo-2.3.2-3.fc11.i586.rpm 
1 packages and 0 specfiles checked; 0 errors, 0 warnings.

Thanks for doing the work on this. 
I don't see any blockers for approving the package thus: 

APPROVED

Comment 18 Gary T. Giesen 2009-07-23 03:44:15 UTC
New Package CVS Request
=======================
Package Name: rancid
Short Description: Really Awesome New Cisco confIg Differ
Owners: giesen
Branches: F-10 F-11 EL-4 EL-5
InitialCC:

Comment 19 Jason Tibbitts 2009-07-23 16:37:28 UTC
CVS done.

Comment 20 Fedora Update System 2009-07-28 00:27:37 UTC
rancid-2.3.2-3.fc11 has been submitted as an update for Fedora 11.
http://admin.fedoraproject.org/updates/rancid-2.3.2-3.fc11

Comment 21 Fedora Update System 2009-07-28 00:52:57 UTC
rancid-2.3.2-3.fc10 has been submitted as an update for Fedora 10.
http://admin.fedoraproject.org/updates/rancid-2.3.2-3.fc10

Comment 22 Fedora Update System 2009-07-28 18:23:34 UTC
rancid-2.3.2-3.fc11 has been pushed to the Fedora 11 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update rancid'.  You can provide feedback for this update here: http://admin.fedoraproject.org/updates/F11/FEDORA-2009-8057

Comment 23 Fedora Update System 2009-07-28 18:24:30 UTC
rancid-2.3.2-3.fc10 has been pushed to the Fedora 10 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update rancid'.  You can provide feedback for this update here: http://admin.fedoraproject.org/updates/F10/FEDORA-2009-8062

Comment 24 Fedora Update System 2009-08-15 08:13:24 UTC
rancid-2.3.2-3.fc10 has been pushed to the Fedora 10 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 25 Fedora Update System 2009-08-15 08:19:53 UTC
rancid-2.3.2-3.fc11 has been pushed to the Fedora 11 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 26 Daniel Roesen 2009-08-20 09:19:03 UTC
I do not have the details yet, but the update to 2.3.2-3 wiped out my CVSROOT completely. Just as a warning to other users...

Comment 27 David Brown 2014-11-20 03:55:30 UTC
Package Change Request
======================
Package Name: rancid
New Branches: epel7
Owners: dmlb2000 slankes

Comment 28 Gwyn Ciesla 2014-11-20 13:29:42 UTC
Git done (by process-git-requests).


Note You need to log in before you can comment on or make changes to this bug.