- Table of Contents
- Copyright
- About the Lead Authors
- About the Contributing Authors
- Acknowledgments
- Tell Us What You Think!
- Introduction
- I. Red Hat Linux Installation and User Services
- Chapter 1. Introduction to Red Hat Linux
- Chapter 2. Installation of Your Red Hat System
- Chapter 3. LILO and Other Boot Managers
- Chapter 4. Configuring the X Window System, Version 11
- Chapter 5. Window Managers
- Chapter 6. Connecting to the Internet
- Chapter 7. IRC, ICQ, and Chat Clients
- Chapter 8. Using Multimedia and Graphics Clients
- II. Configuring Services
- Chapter 9. System Startup and Shutdown
- Chapter 10. SMTP and Protocols
- Chapter 11. FTP
- Chapter 12. Apache Server
- Chapter 13. Internet News
- Chapter 14. Domain Name Service and Dynamic Host Configuration Protocol
- Chapter 15. NIS: Network Information Service
- Chapter 16. NFS: Network Filesystem
- Chapter 17. Samba
- III. System Administration and Management
- Chapter 18. Linux Filesystems, Disks, and Other Devices
- Chapter 19. Printing with Linux
- Chapter 20. TCP/IP Network Management
- Chapter 21. Linux System Administration
- Chapter 22. Backup and Restore
- Chapter 23. System Security
- IV. Red Hat Development and Productivity
- Chapter 24. Linux C/C++ Programming Tools
- Chapter 25. Shell Scripting
- Chapter 26. Automating Tasks
- Chapter 27. Configuring and Building Kernels
- Chapter 28. Emulators, Tools, and Window Clients
- V. Appendixes
- A. The Linux Documentation Project
- B. Top Linux Commands and Utilities
- C. The GNU General Public License
- D. Red Hat Linux RPM Package Listings
Introduction to Leafnode+
As mentioned before, many companies and individuals run a news cache of some sort instead of getting a full newsfeed. This saves time and money. The news cache described in this chapter is very simple to set up and maintain, and is called Leafnode+. At the time of this writing, Leafnode+ was not shipping with Red Hat, but it is easily downloadable from http://www.io.com/~kazushi/leafnode+/. Leafnode+ is from the same project as Leafnode—http://www.leafnode.org/—and the projects are intending to merge eventually. Both offer very similar features, but the authors developed them in different ways.
How Leafnode+ Works
Leafnode+ was designed to look like a regular NNRP-based server that any newsreader can connect to—but with a difference! You specify in the configuration a default news server that Leafnode+ gets its articles from; this is normally your ISP's news server. At this point you run fetchnews, which is the utility that downloads news articles and posts any messages you've written. On its first run it will build up a list of groups to put in the active list. However, it won't download any articles; it only presents "psuedo articles" to inform you that it has registered your interest in the group. For example, if you are reading the comp.os.linux.announce newsgroup, the first time you read it you'll find a single article informing you that Leafnode+ knows of your interest and will start fetching that group for you. When fetchnews runs again, and for as long as you read to that group, that newsgroup will be retrieved.
Articles are stored locally, and so is the news server's active list. The active list is the current newsgroup listing for that particular news server. This is useful because the list doesn't have to be refetched every time you open your newsreader.
Another useful Leafnode+ feature is that it can connect to multiple news servers. There are a number of public news servers on the Internet that are usually related to a particular topic. As an example, Microsoft provides a news server called msnews.microsoft.com and has specific newsgroups on Microsoft-related topics. (Newsgroups are named microsoft.*.). Similarly, Red Hat has a news server called news.redhat.com. (Newsgroups are named redhat.*.). To make full use of this neat feature, you can configure Leafnode+ to talk to specific servers and link newsgroups with these servers. When you use the newsreader, it makes browsing through all the different groups on all the different news servers transparent and it caches it all for you!
Leafnode+ is best suited to small installations of a few dozen users. It is well suited to dial-up users and makes news reading simple in such situations.
Downloading and Configuring Leafnode+
Since Leafnode+ is not part of the standard Red Hat 7 distribution, you have to download it. This is a pretty simple process, since there is already an RPM included on the CD-ROMs with this book. If you feel adventurous you can have a go at downloading the newer version, compiling and installing it yourself. It would be wise to check both http://www.leafnode.org/ and http://www.io.com/~kazushi/leafnode+/ to see the status of the projects.
Install it with this command:
rpm -i leafnode+-2.10-1.i386.rpm
This installs the configuration files under /etc/leafnode.conf, some documentation in /usr/doc/leafnode+-2.10, and the binaries that do all the work in /usr/sbin. Of course, the appropriate startup files are installed in the /etc/rc.d tree.
Edit the /etc/leafnode.conf file and add in your news server. There are several examples provided. In the simplest case the file would contain
server = news.isp.net username = username password = password timeout_short = 7 timeout_long = 21 timeout_active = 14 maxcount = 2000
At that point run fetchnews as the news user. Assuming a root shell type
su news -c /usr/sbin/fetchnews
This will run for a while—it's downloading your news active list. Once that is complete, run your newsreader and read the psuedo articles that Leafnode+ provides. After you've visited all the newsgroups you are interested in, run fetchnews again in the same manner.
Leafnode+ actually consists of a set of three binaries. The install process configures two of the three binaries. One is texpire, which expires old news articles and is configured to run daily. Another is leafnode, which acts like a news server for your newsreader and is run from inetd. Lastly, there's fetchnews. Because this is the most dynamic part, you're left to configure that on your own based on your needs. You can have it run every hour out of cron, as part of your ppp-up script, or run it by hand. Remember, fetchnews also delivers the articles you post. The more often it runs, the quicker your posts propagate and new news is delivered, but for cost reasons it's wise to run it less often in dial-on-demand situations.
When you have fetchnews configured to your liking, you can forget about Leafnode+. That is, with one caveat—it can consume a large number of inodes so make sure the partition it's on (usually /var) has enough inodes.
Introduction to trn | Next Section

Account Sign In
View your cart