-->

Previous | Table of Contents | Next

Page 1263

SEE ALSO


newsfeeds(5)

arp

arp—Manipulate the system ARP cache.

SYNOPSIS


arp [-v] [-t type] -a [hostname]

arp [-v] -d hostname ...

arp [-v] [-t type] -s hostname hw_addr

arp [-v] -f filename

DESCRIPTION

arp manipulates the kernel's ARP cache in various ways. The primary options are clearing an address mapping entry and manually setting up one. For debugging purposes, the arp program also allows a complete dump of the ARP cache.

OPTIONS

-v Tell the user what is going on by being verbose.
-t type When setting or reading the ARP cache, this optional parameter tells arp which class of entries it should check for. The default value of this parameter is ether (hardware code 0x01 for IEEE 802.3 10Mbps Ethernet). Other values might include network technologies such as ARCnet (arcnet), PROnet (pronet), and AX.25 (ax25).
-a [hostname] Shows the entries of the specified hosts. If the hostname parameter is not used, all entries are displayed.
-d hostname Remove the entries of the specified host. This can be used if the indicated host is brought down, for example.
-s hostname hw_addr Manually create an ARP address mapping entry for host hostname with hardware address set to hw_addr. The format of the hardware address is dependent on the hardware class, but for most classes, you can assume that the usual presentation can be used. For the Ethernet class, this is six bytes in hexadecimal, separated by colons.
-f filename Similar to the -s option, only this time the address info is taken from file filename. This can be used if ARP entries for a lot of hosts have to be set up. The name of the data file is often /etc/ethers, but this is not official.
The format of the file is simple; it only contains ASCII text lines with a hostname and a hardware address separated by whitespace.

In all places where a hostname is expected, you can also enter an IP address in dotted-decimal notation.

FILES


/proc/net/arp



/etc/ethers

AUTHOR

Fred N. van Kempen (waltje@uwalt.nl.mugnet.org)

09 June 1994

Page 1264

badblocks

badblocks—Search a device for bad blocks.

SYNOPSIS


badblocks [ -b block-size ] [ -o output_file ] [ -v ][-w ] device blocks-count

DESCRIPTION

badblocks is used to search for bad blocks on a device (usually a disk partition). device is the special file corresponding to the device (such as /dev/hdXX). blocks-count is the number of blocks on the device.

OPTIONS

-b block-size Specify the size of blocks in bytes.
-o output_file Write the list of bad blocks to the specified file. Without this option, badblocks displays the list on its standard output.
-v Verbose mode.
-w Use write-mode test. With this option, badblocks scans for bad blocks by writing some patterns (0xaa, 0x55, 0xff, and 0x00) on every block of the device, reading every block and comparing the contents.

WARNING

Never use the -w option on a device containing an existing filesystem. This option erases data!

AUTHOR

badblocks was written by Remy Card (card@masi.ibp.fr), the developer and maintainer of the ext2 fs.

BUGS

I had no chance to make real tests of this program because I use IDE drives, which remap bad blocks. I only made some tests on floppies.

AVAILABILITY

badblocks is available for anonymous FTP from ftp.ibp.fr and tsx-11.mit.edu in /pub/linux/packages/ext2fs.

SEE ALSO


e2fsck(8), mke2fs(8)

Version 0.5b, November 1994

buffchan

buffchan—Buffered file-writing back end for InterNetNews.

SYNOPSIS


buffchan [ -b ][-c lines ][-C seconds ][-d directory ]

[-f fields ][-m map ][-p pidfile ][-l lines ][-L seconds ]

[-r ][-s file_format ][-u ]

DESCRIPTION

buffchan reads lines from standard input and copies certain fields in each line into files named by other fields within the line. buffchan is intended to be called by innd(8) as an exploder feed.

Page 1265

buffchan input is interpreted as a set of lines. Each line contains a fixed number of initial fields, followed by a variable number of filename fields. All fields in a line are separated by whitespace. The default number of initial fields is one; the _f flag may be used to specify a different number of fields. See filechan(8) for an example.

After the initial fields, each remaining field names a file to write. The -s flag may be used to specify a format string that maps the field to a filename. This is a sprintf(3) format string, which should have a single %s parameter that is given the field. The default value is /news/spool/out.going/%s. See the description of this flag in filechan(8). The _d flag may be used to specify a directory the program should change to before starting. If this flag is used, then the default for the _s flag is changed to be a simple %s.

Once buffchan opens a file, it keeps it open. The input must therefore never specify more files than the number of available descriptors can keep open. If the _b flag is used, the program will allocate a buffer and attach it to the file using setbuf(3). If the _u flag is used, the program will request unbuffered output.

If the _l flag is used with a number n, then buffchan will call fflush(3) after every n lines are written to a file. If the _c flag is used with a number n, then buffchan will close, and reopen, a file after every n lines are written to a file.

If the _L flag is used with a number n, then all files will be flushed every n seconds. Similarly, the _C flag may be used to specify that all files should be closed and reopened every n seconds.

By default, the program sets its standard error to /var/log/news/errlog. To suppress this redirection, use the _r flag.

If the _p flag is used, the program will write a line containing its process ID (in text) to the specified file.

buffchan can be invoked as an exploder feed (see newsfeeds(5)). As such, if a line starts with an exclamation point, it is treated as a command. There are three commands:

flush The flush command closes and reopens all open files; flush xxx flushes only the specified site. These are analogous to the ctlinnd(8) flush command and can be achieved by doing a send flush xxx command. Applications can tell that the flush has completed by renaming the file before issuing the command; buffchan has completed the command when the original filename reappears.
buffchan also changes the access permissions of the file from read-only for everyone to read-write for owner and group as it flushes or closes each output file. It changes the modes back to read-only if it reopens the same file.
drop The drop command is similar to the flush command except that any files are not reopened. If given an argument, then the specified site is dropped; otherwise, all sites are dropped. (Note that the site will be restarted if the input stream mentions the site.) When a ctlinnd "drop site" command is sent, innd will automatically forward the command to buffchan if the site is a funnel that feeds into this exploder. To drop all sites, use the ctlinnd send buffchan-site drop command.
readmap The map file (specified with the _m flag) is reloaded.

HISTORY

Written by Rich $alz (rsalz@uunet.uu.net) for InterNetNews.

SEE ALSO


ctlinnd(8), filechan(8), innd(8), newsfeeds(5).

cfdisk

cfdisk—Curses-based disk partition table manipulator for Linux.

SYNOPSIS


cfdisk [ -avz ] [ -c cylinders ][-h heads ][-s sectors-per-track ][-P opt ]

[device ]

Previous | Table of Contents | Next