Difference between revisions of "FreeBSD installation"
From Teknologisk videncenter
m |
m |
||
Line 1: | Line 1: | ||
__TOC__ | __TOC__ | ||
= Configuration files = | = Configuration files = | ||
+ | == /etc/issue == | ||
+ | <pre> | ||
+ | [root@bsd /etc]# echo " | ||
+ | |||
+ | |||
+ | |||
+ | |||
+ | |||
+ | |||
+ | ####### ###### ##### ###### | ||
+ | # ##### ###### ###### # # # # # # | ||
+ | # # # # # # # # # # | ||
+ | ##### # # ##### ##### ###### ##### # # | ||
+ | # ##### # # # # # # # | ||
+ | # # # # # # # # # # # | ||
+ | # # # ###### ###### ###### ##### ###### | ||
+ | |||
+ | |||
+ | |||
+ | Velkommen til FreeBSD version 6.1 | ||
+ | |||
+ | |||
+ | |||
+ | |||
+ | Mercantec" > /etc/issue | ||
+ | </pre> | ||
+ | |||
+ | == /etc/motd - Message of the day == | ||
+ | <pre> | ||
+ | [root@bsd /etc]# echo " | ||
+ | ******************************************************************************* | ||
+ | * LEGAL NOTICE * | ||
+ | * ============ * | ||
+ | * * | ||
+ | * ANY UNAUTHORISED ACCESS OR ATTEMPT TO ACCESS THIS SITE WILL - WITHOUT ANY * | ||
+ | * PRIOR WARNING - BE REPORTED TO LEGAL AUTHORITIES. * | ||
+ | * * | ||
+ | * Please report any attempts to * | ||
+ | * heth@mercantec.dk * | ||
+ | * Have a :-) day * | ||
+ | *******************************************************************************" > /etc/motd | ||
+ | </pre> | ||
+ | == /etc/nsswitch.conf == | ||
+ | nsswitch.conf -- name-service switch configuration file | ||
+ | * Make sure the line '''hosts:''' is configured properly. In the example below the dns resolver first look in /etc/hosts(files) then it uses dns | ||
+ | <source lang="text"> | ||
+ | # | ||
+ | # nsswitch.conf(5) - name service switch configuration file | ||
+ | # $FreeBSD: src/etc/nsswitch.conf,v 1.1.6.1 2008/11/25 02:59:29 kensmith Exp $ | ||
+ | # | ||
+ | group: compat | ||
+ | group_compat: nis | ||
+ | hosts: files dns | ||
+ | networks: files | ||
+ | passwd: compat | ||
+ | passwd_compat: nis | ||
+ | shells: files | ||
+ | services: compat | ||
+ | services_compat: nis | ||
+ | protocols: files | ||
+ | rpc: files | ||
+ | </text> | ||
== /etc/rc.conf == | == /etc/rc.conf == | ||
Example rc.conf | Example rc.conf | ||
Line 34: | Line 96: | ||
route_printers="-net 172.16.67.0/24 172.16.4.1" | route_printers="-net 172.16.67.0/24 172.16.4.1" | ||
</source> | </source> | ||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
[[Category:FreeBSD]] | [[Category:FreeBSD]] |
Revision as of 09:36, 14 May 2009
Contents
Configuration files
/etc/issue
[root@bsd /etc]# echo " ####### ###### ##### ###### # ##### ###### ###### # # # # # # # # # # # # # # # # ##### # # ##### ##### ###### ##### # # # ##### # # # # # # # # # # # # # # # # # # # # # ###### ###### ###### ##### ###### Velkommen til FreeBSD version 6.1 Mercantec" > /etc/issue
/etc/motd - Message of the day
[root@bsd /etc]# echo " ******************************************************************************* * LEGAL NOTICE * * ============ * * * * ANY UNAUTHORISED ACCESS OR ATTEMPT TO ACCESS THIS SITE WILL - WITHOUT ANY * * PRIOR WARNING - BE REPORTED TO LEGAL AUTHORITIES. * * * * Please report any attempts to * * heth@mercantec.dk * * Have a :-) day * *******************************************************************************" > /etc/motd
/etc/nsswitch.conf
nsswitch.conf -- name-service switch configuration file
- Make sure the line hosts: is configured properly. In the example below the dns resolver first look in /etc/hosts(files) then it uses dns
#
# nsswitch.conf(5) - name service switch configuration file
# $FreeBSD: src/etc/nsswitch.conf,v 1.1.6.1 2008/11/25 02:59:29 kensmith Exp $
#
group: compat
group_compat: nis
hosts: files dns
networks: files
passwd: compat
passwd_compat: nis
shells: files
services: compat
services_compat: nis
protocols: files
rpc: files
</text>
== /etc/rc.conf ==
Example rc.conf
<source lang="bash">
# -- sysinstall generated deltas -- # Wed Jan 14 14:04:35 2009
# Created: Wed Jan 14 14:04:35 2009
# Enable network daemons for user convenience.
# Please make all changes to this file, not to /etc/defaults/rc.conf.
# This file now contains just the overrides from /etc/defaults/rc.conf.
defaultrouter="83.90.47.29"
hostname="mars.tekkom.dk"
ifconfig_vr1="inet 83.90.47.30 netmask 255.255.255.252"
ifconfig_em0="inet 192.168.22.73 netmask 255.255.255.0"
ifconfig_em1="inet 172.16.4.16 netmask 255.255.255.0"
keymap="danish.iso"
#Enable ssh
sshd_enable="YES"
apache_enable="YES"
mysql_enable="YES"
dhcpd_enable="YES"
webmin_enable="YES"
ntpd_enable="YES"
#Internet NAT Router
gateway_enable="YES" # Enable as LAN gateway
ipnat_enable="YES" # Start ipnat function
ipnat_rules="/etc/ipnat.rules" # rules definition file for ipnat
searchd_enable="YES" # sphnix search engine to mediawiki
#Add school networks
# Add Internal Nets as static routes
static_routes="backbone tekkom printers"
route_tekkom="-net 192.168.128.0/17 172.16.4.1"
route_backbone="-net 172.16.4.0/24 172.16.4.1"
route_printers="-net 172.16.67.0/24 172.16.4.1"