Tweaking the base Debian 7.5 operating system

Displaying system messages

I prefer to permanently display the messages returned during boot up. This can be done by making the following changes to the /etc/inittab file. The default settings are as follows.

1:2345:respawn:/sbin/getty 38400 tty1
2:23:respawn:/sbin/getty 38400 tty2

By changing these to the following, we ensure that the first screen will always display the messages.

#1:2345:respawn:/sbin/getty 38400 tty1
2:2345:respawn:/sbin/getty 38400 tty2

Disabling IPv6

To disable IPv6 on the network interfaces, we edit the /etc/sysctl.conf file by adding the following parameters to the file.

net.ipv6.conf.all.disable_ipv6 = 1
net.ipv6.conf.default.disable_ipv6 = 1
net.ipv6.conf.lo.disable_ipv6 = 1
net.ipv6.conf.eth0.disable_ipv6 = 1

Enabling additional IPv4 addresses

If you have full control over the network, as is the case with private IP addresses, you could assign multiple IP addresses to the network interface – these are all defined in the /etc/network/interfaces file, which could end up as below.

# The primary network interface
auto eth0
iface eth0 inet static
    address 192.168.100.10
    netmask 255.255.255.0
    network 192.168.100.0
    broadcast 192.168.100.255
    gateway 192.168.100.1
    dns-nameservers 192.168.100.1
    dns-search domain.local

# host01.domain.local
auto eth0:1
iface eth0:1 inet static
    address 192.168.100.11
    netmask 255.255.255.0

# host02.domain.local
auto eth0:2
iface eth0:2 inet static
    address 192.168.100.12
    netmask 255.255.255.0

We would also change the /etc/host.conf file to define the DNS lookup order, by adding the following to it.

order hosts,bind

Once we’ve made these changes, we can reboot the system by issuing the following command in a “root” shell.

shutdown -r now
Advertisements

One thought on “Tweaking the base Debian 7.5 operating system

Comments are closed.