#!/bin/sh # rc.modules 3.1 Thu Aug 28 14:01:35 PDT 2003 pjv # S390 Wed June 29, 2004 mkp # # This file loads extra drivers into the Linux kernel. # The modules will be looked for under /lib/modules/ # On systems using KMOD this file will be mostly commented out, but is still # useful for loading selected modules at boot time. # # Most Linux kernel modules will accept extra options such as IRQ or base # address, or to set various modes (such as 10baseT or BNC, etc). The Linux # kernel source is the best place to look for extra documentation for the # various modules. This can be found under /usr/src/linux/Documentation if # you've the installed the kernel sources. Also, the kernel source docs are # present on the Slackware CD in the /docs/linux-2.x.x directory. # # NOTE: This may not be a complete list of modules. If you don't see what # you're looking for, look around in /lib/modules/2.x.x/ for an appropriate # module. Also, if any problems arise loading or using these modules, try # compiling and installing a custom kernel that contains the support instead. # That always works. ;^) # ### Update module dependencies ### RELEASE=`uname -r` # If /usr is mounted and we have 'find', we can try to take a shortcut: if [ -x /usr/bin/find -a -e /lib/modules/$RELEASE/modules.dep \ -a /lib/modules/$RELEASE/modules.dep -nt /etc/modules.conf ]; then NEWMODS="`/usr/bin/find /lib/modules/$RELEASE -type f -newer /lib/modules/$RELEASE/modules.dep`" # Only rebuild dependencies if new module(s) are found: if [ ! "" = "$NEWMODS" ]; then echo "Updating module dependencies for Linux $RELEASE:" /sbin/depmod -a else echo "Module dependencies up to date (no new kernel modules found)." fi else # we don't have find, or there is no existing modules.dep, or it is out of date. echo "Updating module dependencies for Linux $RELEASE:" /sbin/depmod -A fi ### Filesystem Quota support ### if grep -q quota /etc/fstab ; then # modprobe quota_v1 modprobe quota_v2 fi ### Appletalk support ### # This is needed if you want to run netatalk, a package which allows # you to use you Linux box as a file and print server for Apple Macintosh # computers on your local network. #/sbin/modprobe appletalk ### IPX networking support ### #/sbin/modprobe ipx ### Network device support ### # # First, if setup probing found a network card, there may be an 'rc.netdevice' # file that we should run to load the network module: if [ -x /etc/rc.d/rc.netdevice ]; then . /etc/rc.d/rc.netdevice fi # Other network hardware drivers: # # OSA Card Support: #/sbin/modprobe qeth # LCS Card Support: #/sbin/modprobe lcs # CIP/CLAW Support: #/sbin/modprobe c7000 # Interface to z/VM CP: #/usr/sbin/cpint_load && /sbin/modprobe cpint ### Serial line load balancing support ### #/sbin/modprobe eql ### "dummy" IP support ### # A dummy IP driver. Essentially a loopback device. Can be useful -- # see the Network Administrator's Guide from sunsite.unc.edu:/pub/Linux/docs/LDP #/sbin/modprobe dummy ### Binary format support ### #/sbin/modprobe binfmt_elf #/sbin/modprobe binfmt_java #/sbin/modprobe binfmt_misc ### Filesystem support ### #/sbin/modprobe adfs #/sbin/modprobe affs #/sbin/modprobe coda #/sbin/modprobe ext2 #/sbin/modprobe fat #/sbin/modprobe hfs #/sbin/modprobe hpfs #/sbin/modprobe isofs #/sbin/modprobe minix #/sbin/modprobe msdos #/sbin/modprobe ncpfs #/sbin/modprobe nfs #/sbin/modprobe ntfs #/sbin/modprobe qnx4 #/sbin/modprobe romfs #/sbin/modprobe smbfs #/sbin/modprobe sysv #/sbin/modprobe ufs #/sbin/modprobe umsdos #/sbin/modprobe vfat ### RAID (Multiple Devices) support ### #/sbin/modprobe linear #/sbin/modprobe raid0 #/sbin/modprobe raid1 #/sbin/modprobe raid5 # SCSI kernel support: #/sbin/modprobe scsi_mod #/sbin/modprobe sd_mod #/sbin/modprobe sg #/sbin/modprobe sr_mod #/sbin/modprobe st # IP masquerading modules: # These modules are used with IP masquerading, a process which allows you to # use a Linux box connected to the Internet (via PPP or SLIP, or some other # means) as a gateway for other Linux, Windows, Macintosh boxes on your local # network that don't have real IP addresses on the Internet. The packets # going through the Linux machine are "masqueraded", or made to look as if # they're all coming from the one real IP address on the Internet. # # As a quick example (for a much more extensive treatment, see the IP-Masquerade # mini-HOWTO) to allow Internet access to a local network 192.168.11.0 with a # netmask of 255.255.255.0, you'd use these commands in /etc/rc.d/rc.local: # # # EXTERNAL -> external network interface # # INTERNAL -> internal network interface # EXTERNAL=eth0 # INTERNAL=eth1 # echo 1 > /proc/sys/net/ipv4/ip_forward # echo "Setting up NAT (Network Address Translation)..." # # by default, nothing is forwarded. # iptables -P FORWARD DROP # # Allow all connections OUT and only related ones IN # iptables -A FORWARD -i $EXTERNAL -o $INTERNAL -m state --state ESTABLISHED,RELATED -j ACCEPT # iptables -A FORWARD -i $INTERNAL -o $EXTERNAL -j ACCEPT # # enable MASQUERADING # iptables -t nat -A POSTROUTING -o $EXTERNAL -j MASQUERADE # # Then you'd have to set the other boxes on your local network to use the # Linux machine as their TCP/IP gateway. You'll probably also need to plug # in the IP address for your Internet service provider in each machine's DNS # setup. # # Now, on to the IP masquerading modules. The example above is good enough # for most things that use TCP in a relatively simple fashion. It'll work # for telnet and http, for instance. But, the system breaks down when you # get protocols that use ports in more complicated ways. Luckily the Linux # kernel gurus have thought of this and have prepared some modules that # support masquerading of trickier protocols. The ipchains command is mighty # flexible as well, and a lot of things can be made to work just by setting # that up correctly. # # Special modules for iptables. See also "man iptables" for information about # that powerfull firewall tool. # #/sbin/modprobe ipt_conntrack #/sbin/modprobe ip_conntrack #/sbin/modprobe ip_conntrack_ftp #/sbin/modprobe ip_conntrack_irc #/sbin/modprobe ip_nat_ftp #/sbin/modprobe ip_nat_irc #/sbin/modprobe ip_nat_snmp_basic # # These modules below are for ipchains (kernel 2.2.x). You can install ipchains # from /pasture. To use ipchains with newer kernels, you'll need this: # /sbin/modprobe ipchains # #/sbin/modprobe ip_masq_autofw #/sbin/modprobe ip_masq_cuseeme #/sbin/modprobe ip_masq_ftp #/sbin/modprobe ip_masq_irc #/sbin/modprobe ip_masq_mfw #/sbin/modprobe ip_masq_portfw #/sbin/modprobe ip_masq_quake #/sbin/modprobe ip_masq_raudio #/sbin/modprobe ip_masq_user #/sbin/modprobe ip_masq_vdolive